Acknowledged
CIQQA-3521

[BUG] CIQ DataField Crashes when a Generic ANT Device Connects when 2 Generic ANT Channels are in use on Edge 1030 Plus

This issue is happening on an Edge 1030 plus with firmware version 6.75.

The user is running 2 CIQ datafields that each have a generic ANT channel.

It's fine when the first datafield connects to the Generic ANT device, but the second datafield to connect will crash immediately after connecting to the Generic ANT device.

This video shows the crash occuring on the Edge 1030 plus.

https://youtube.com/shorts/Ee1lZghs0TQ

This video shows it working properly on and Edge 540.

https://youtube.com/shorts/5tU7LBOFPZw

The two Datafields are the Moxy 1st Sensor Datafield and the Moxy 2nd Sensor Datafield.  Both are version 2.25.  The datafield that crashes is the second one that happens to connect to the Moxy sensor, not necessarily the one that is titled "Moxy 2nd Sensor"

Here is a link to an error log file.

https://www.dropbox.com/scl/fi/gsos98hut9nejxvtyd6ix/CIQ_LOG-1.BAK?rlkey=21okef2zvy9w1y8ttb4mep44r&dl=0

This is an error message.

Error: System Error
Details: 'Failed invoking <symbol>'
Time: 2025-09-04T13:56:22Z
Part-Number: 006-B3570-00
Firmware-Version: '6.75'
Language-Code: eng
ConnectIQ-Version: 5.1.1
Store-Id: a31a35bd-7131-4865-a5d2-4751e5bfe946
Store-Version: 93
Filename: 472DAB9B
Appname: Moxy 1st Sensor
Stack: 
  - pc: 0x100019f8
  - pc: 0x100010e9

The pc: 0x100010e9 location is 268439785 in decimal.  Here's the location in the debug file closest to that number.

<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="31" lineNum="145" parent="globals/MoxySensor" pc="268439645" symbol="onMessage"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="31" lineNum="146" parent="globals/MoxySensor" pc="268439653" symbol="onMessage"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="31" lineNum="147" parent="globals/MoxySensor" pc="268439667" symbol="onMessage"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="31" lineNum="148" parent="globals/MoxySensor" pc="268439679" symbol="onMessage"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="24" parent="globals/MoxySensor" pc="268439697" symbol="initialize"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="25" parent="globals/MoxySensor" pc="268439700" symbol="initialize"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="26" parent="globals/MoxySensor" pc="268439709" symbol="initialize"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="28" parent="globals/MoxySensor" pc="268439718" symbol="initialize"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="32" parent="globals/MoxySensor" pc="268439745" symbol="initialize"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="34" parent="globals/MoxySensor" pc="268439774" symbol="initialize"/>
<entry filename="C:\\Users\\rschm\\OneDrive\\Documents\\GitHub\\Moxy1stSensor\\source\\MoxySensor.mc" id="32" lineNum="45" parent="globals/MoxySensor" pc="268439868" symbol="initialize"/>
</pcToLineNum>
<symbolTable>
<entry id="8388639" module="true" symbol="Graphics"/>
<entry field="true" id="38" symbol="deviceMfg"/>
<entry id="16" object="true" symbol="MoxySensor"/>

This puts the error somewhere after line 34 in the MoxySensor.mc file.  Lines 34 to 43 of this file are shown below.

        var deviceConfig = new Ant.DeviceConfig({
            :deviceNumber              => deviceNumber,
            :deviceType                => 31,
            :transmissionType          => 0,
            :messagePeriod             => 8192,
            :radioFrequency            => 57,
            :searchTimeoutLowPriority  => 2,  // 2.5 seconds per unit
            :searchTimeoutHighPriority => 0,
            :searchThreshold           => 0
        });

It isn't clear to me what the problem could be.  The code runs fine if the other datafield isn't already connected to a sensor.  It is only the second datafield to connect that has a problem.  It also works on the Edge540 and it has worked on many other devices in the past.

Parents
  • What is deviceNumber set to in both datafields? I.e are they both trying to connect to the nearest device (0) or the same specific ANT ID, or two different ANT ID-s?

    Any chance you'll be able to reproduce it on a device by yourself?

    Can you add a logging line after the code you posted? Does it really crash before the log? Or maybe it crashes the next line (I suppose it would be where you actually open the connection?)

    Or is it where you initialize the Generic channel?

    It would really help (I guess also to Garmin stuff) to understand really what code is crashing and what are the circumstances.

Comment
  • What is deviceNumber set to in both datafields? I.e are they both trying to connect to the nearest device (0) or the same specific ANT ID, or two different ANT ID-s?

    Any chance you'll be able to reproduce it on a device by yourself?

    Can you add a logging line after the code you posted? Does it really crash before the log? Or maybe it crashes the next line (I suppose it would be where you actually open the connection?)

    Or is it where you initialize the Generic channel?

    It would really help (I guess also to Garmin stuff) to understand really what code is crashing and what are the circumstances.

Children
  • The two data fields are trying to connect to two different ANT IDs.  This is set as a CIQ datafield setting.  You can see the two ANT IDs on the screen before the connection.

    I don't have an Edge 1030 plus here.  The problem does not happen on the Edge 540 that I have here.

    I have thought of adding logging lines to the code to isolate the precise crash location, but then I will have to instruct my customer on sideloading the datafield and retrieving the CIQ console file.  I'm hoping Garmin can reproduce the problem easily on a device and using the ANT+ Simulator.  If they can't reproduce the problem, then I will work on getting a console file with logging lines.

    The code in the error file points to where the sensor is being initialized, but it it strange that it is failing there.  In the video, you can see that the Moxy sensor appears to connect momentarily because SmO2 and THb data are shown.  It shouldn't be trying to initialize the channel again.