Weird ANT messages

Hi,

I’m currently working on an app that receives data from an nRF52840 via ANT.

I have set the frequency to 8 Hz to receive 8 messages per second. The messages are arriving correctly, but there is always one additional message that is constant for each Garmin watch but differs between models.

For example, I am sending messages from the nRF52840 with the payload [1,1,1,1,1,1,1,1], and this is what I receive on my Garmin Fenix 7s:

1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1
1 3 57 48 255 0 0 0

I have also noticed that on some watches (e.g., Forerunner 965), there are two of these "garbage" messages instead of one.

Sometimes these extra messages remain constant, while other times, the first value in the payload varies.

This is a critical issue for me because filtering out these messages is difficult—they are not always received in the same order, but there is always one per second.

What could be causing this issue?

Thanks, Bartosz.

  • Is it your code on the ANT device that is sending these messages? If you see it with all Garmin devices, then maybe you have a bug there? How do you receive them with a non-Garmin receiver?

  • My ANT device sends only payload [1,1,1,1,1,1,1,1], of course if my sensor sends real data that weird constant message also apperas on the Garmin watch. I've tested my ANT sensor using ANT dongle on my computer and also on the other NRF52840 board which only listen to ANT messages; in both cases everything was correct. It might be bug in my code but I have no idea where and why. Here is my code at Garmin watch "

            var channel = getAntChannelNumber();
            var device_number = (channel == _DEFAULT_CHANNEL_NUMBER) ? 12345 : 12346;

            var deviceCfg = new Ant.DeviceConfig({
                :deviceNumber => device_number,
                :deviceType =>0,  
                :transmissionType => 0,  
                :messagePeriod => (32768 / _communication_freq).toNumber(),  
                :radioFrequency => channel,
                :searchTimeoutLowPriority => 6,
                :searchThreshold => 0  
            });
            var channel_assigment = new Ant.ChannelAssignment(Ant.CHANNEL_TYPE_RX_NOT_TX, Ant.NETWORK_PUBLIC);
            _generic_channel = new Ant.GenericChannel(method(:onMessage), channel_assigment);
            _generic_channel.setDeviceConfig(deviceCfg);
            try{
                var opened = _generic_channel.open();
                _state = opened ? WaitingForDevice : ChannelNotOpened;
            }catch(exception){
                _state = ChannelNotOpened;
            }"
    and here is method which process every received data "
    function onMessage(msg as Message) as Void {
            var payload = msg.getPayload();   // payload here is 8 times [1,1,1,1,1,1,1,1] and once constant weird message per second
    }  "
  • Log the whole msg, not only the payload! Can it be coming from another ant device somehow?