Heart intervals broken on Venu firmware update (and now other devices)

Hi,

My app has been working consistently for quite a long period. Venu had a firmware update and I started to get reports of the app displaying zero results. The cause of this is that no interval data is being generated / seen by the app though BPM is being reported. A user has tried many other HRV like apps and they all FAIL as well.

I've tried various changes to the sensor handling to see if this fixes the issue to no avail. I am now in the situation that a) the simulator shows no issues and works perfectly every time (even with original code that stopped working after the firmware update and b) users are now in the situation that if they run the app twice then they will get interval/beat data. This remains the case for a period of time ie subsequent runs work every time and then reverts to having the app run twice.

These on device issues (simulator has no issues and no crashes) are almost impossible to debug now as the ability to read the LOG file has been removed (they no longer exist - someone said because of MTP file system). Either the simulator needs to get up with API and firmware iterations or there needs to be better tools for live debug. ERA doesn't report anything of course.

original code (has worked OK for months):

var _ans;
if (Sensor has :enableSensorType) {
Sys.println(">=CIQ 3.2 detected");
_ans = Sensor.enableSensorType( Sensor.SENSOR_HEARTRATE);
if (_ans) {
Sys.println("Strap enabled");
} else {
Sys.println("no strap");
_ans = Sensor.enableSensorType( Sensor.SENSOR_ONBOARD_HEARTRATE);
if (_ans) { Sys.println("OHR enabled");} else {Sys.println("no OHR either");}
}
} else {
_ans = Sensor.setEnabledSensors( [Sensor.SENSOR_HEARTRATE]);
Sys.println("Enable response ="+_ans);
}
Sensor.registerSensorDataListener(self.method(:onHeartRateData), options);
Note: sensors are disabled on exit of app.
Current code ( various versions of this have been tried with enabling both together and separately as here)
if (Sensor has :enableSensorType) {
Sys.println(">=CIQ 3.2 detected");
//_ans = Toybox.Sensor.setEnabledSensors( [Sensor.SENSOR_HEARTRATE, Sensor.SENSOR_ONBOARD_HEARTRATE]);
// USE enableSensor as it doesn't disable other sensor types
_ans = Toybox.Sensor.enableSensorType( Sensor.SENSOR_HEARTRATE);
Sys.println("Enable3.2a ="+_ans);
_ans = Toybox.Sensor.enableSensorType( Sensor.SENSOR_ONBOARD_HEARTRATE);
Sys.println("Enable3.2b ="+_ans);
// ONBOARD only works on > 3.2.0 devices
} else {
_ans = Toybox.Sensor.setEnabledSensors( [Sensor.SENSOR_HEARTRATE]);
Sys.println("Enable ="+_ans);
}
Any ideas welcome!!! This has broken 3 different apps.
Regards,
David