79514666

Date: 2025-03-17 13:11:01
Score: 1
Natty:
Report link

you should see Garmin sensor dcumentation. The Code that should work is:

function initialize() {
    Sensor.setEnabledSensors( [Sensor.SENSOR_HEARTRATE] );
    Sensor.enableSensorEvents( method( :onSensor ) );
}

function onSensor(sensorInfo as Sensor.Info) as Void {
    System.println( "Heart Rate: " + sensorInfo.heartRate );
}

if it isn't working and you don't forgot all the rest of the code (you can generate with monkey c extension in visual studio code) remember that garmin edge isn't tracking heart rate you need garmin hrm.

It should work,
Tobiasz

Reasons:
  • Contains signature (1):
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Tobiasz