Skip to main content
Version: v3

FAT_BURRING

Creating Sensors

const fatburn = hmSensor.createSensor(hmSensor.id.FAT_BURRING)

console.log(fatburn.current)
console.log(fatburn.target)

FAT_BURRING instance

fatburn: object

PropertiesDescriptionType
currentCurrent fat burning minutesnumber
targetFat burning target in minutesnumber

Registering sensor instance callback events

fatburn.addEventListener(event, callback: Callback)

The events of CHANGE

The value of event

hmSensor.event.CHANGE

Callback

() => void

The example of the events

fatburn.addEventListener(hmSensor.event.CHANGE, function () {
console.log('the current fatburn: ' + fatburn.current + ' target: ' + fatburn.target + '\r\n')
})