viewof sensorPower = Inputs.range([0.1, 10], {
value: 2,
step: 0.1,
label: "Sensor Power (µW)"
})
viewof sensorDuration = Inputs.range([10, 500], {
value: 150,
step: 10,
label: "Sensor Duration (ms)"
})
viewof sensorInterval = Inputs.range([1, 30], {
value: 5,
step: 1,
label: "Sensor Interval (min)"
})
viewof mcuActive = Inputs.range([1, 50], {
value: 12,
step: 1,
label: "MCU Active Power (µW)"
})
viewof mcuSleep = Inputs.range([0.1, 2], {
value: 0.5,
step: 0.1,
label: "MCU Sleep Power (µW)"
})
viewof nfcPower = Inputs.range([10, 100], {
value: 30,
step: 5,
label: "NFC TX Power (µW)"
})
viewof nfcDuration = Inputs.range([10, 200], {
value: 50,
step: 10,
label: "NFC Duration (ms)"
})
viewof txInterval = Inputs.range([5, 60], {
value: 30,
step: 5,
label: "TX Interval (min)"
})
// Calculations
wearTime = 18 // hours
readingsPerDay = (wearTime * 60) / sensorInterval
txPerDay = (wearTime * 60) / txInterval
energyPerReading = (sensorPower * sensorDuration / 1000) + (mcuActive * 50 / 1000)
energyPerTx = (nfcPower * nfcDuration / 1000) + (mcuActive * 20 / 1000)
energySensing = readingsPerDay * energyPerReading
energyTx = txPerDay * energyPerTx
energySleep = mcuSleep * wearTime * 3600
totalEnergy = energySensing + energyTx + energySleep
avgPower = totalEnergy / (wearTime * 3600)
html`<div style="background: #2C3E50; color: white; padding: 20px; border-radius: 8px; margin: 20px 0;">
<h3 style="color: #16A085; margin-top: 0;">Power Budget Results</h3>
<div style="display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 15px;">
<div>
<strong>Readings per Day:</strong> ${readingsPerDay.toFixed(0)}<br>
<strong>TX per Day:</strong> ${txPerDay.toFixed(0)}<br>
<strong>Sensing Energy:</strong> ${energySensing.toFixed(2)} µJ
</div>
<div>
<strong>TX Energy:</strong> ${energyTx.toFixed(2)} µJ<br>
<strong>Sleep Energy:</strong> ${energySleep.toFixed(2)} µJ<br>
<strong style="color: ${avgPower < 50 ? '#16A085' : '#E67E22'};">Avg Power: ${avgPower.toFixed(2)} µW</strong>
</div>
</div>
<div style="margin-top: 15px; padding: 10px; background: rgba(255,255,255,0.1); border-radius: 4px;">
<strong>Total Daily Energy:</strong> ${totalEnergy.toFixed(2)} µJ = ${(totalEnergy/1000).toFixed(3)} mJ<br>
<strong>Status:</strong> ${avgPower < 50 ? 'Within typical budget' : 'Exceeds typical budget'}
</div>
</div>`Interactive Power Budget Calculator
Interactive Power Budget Calculator
animation
connected-health
Try Increase MCU Sleep Power (µW) while keeping sensor and transmission settings unchanged. Then press Calculate power budget.
Observe After pressing Calculate power budget, watch sleep energy and avg power as MCU Sleep Power (µW) changes.
Explain Explain why MCU Sleep Power (µW) dominates the total energy budget after you press Calculate power budget.
Technical boundaries. The calculation fixes wear time at 18 hours and MCU active time at 50 ms per reading and 20 ms per transmission. Sleep energy covers the full wear time.
Interactive Power Budget Calculator
Calculate Smart Lens Power Requirements
Use this calculator to estimate the total power budget for a smart contact lens design.
Key Insight: The MCU sleep current typically dominates the total energy budget. Optimizing sleep power has more impact than reducing sensor measurement time.