AntPlus module custom Device

Hi

I am trying to figure out how AntPlus module with its predefined classes behaves. All of those classes like AntPlus.BikeCadence  or AntPlus.BikeSpeed, are they specific for certain Garmin wearables that are specifically programmed to answer to these classes? Or can these be used to ask information about any Garmin unit? Or the Garmin unit would need to be programmed in order to correctly understand and return the demanded data? We are trying to build a communication between a boat and a Garmin watch where we want to get information about the boat, all from speed, position, batteryinfo etc to more manufacturer specific data.

I am still not able to understand if these classes are predefined to specific default cases that are mostly common (training gear etc). And in case one needs to create a "custom device", a boat "device" in this case, then would one need to create own "device id(type)" and implement own protocols? Or somehow, whatever Garmin unit would always respond to any of these classes?

Thanks in advance.

  • I’m just learning this stuff aswell, but I’ll give it a shot.

    AntPlus APIs are for getting information from sensors, which are already connected to your Garmin device via the sensors menu. You cannot use it for connecting new sensors. Apparenty sensors which can be connected to Garmin device identify themselves as some basic type (power, speed, cadende, etc). These sensors can be from any manufacturer, not just Garmin.

    Now it gets even further away my knowledge... In order to use this API with your own device, I think you first must make it connectible via the device sensor menu, as one of the supported types. After that, AntPlus APi has option to request manufacturer specific data. To my understanding, this can contain any data in own format, which then you interpret on device once you receive it.

    So AntPlus mainly is for common sensor types, for anyone to get the basic data easily from them, without having to know anything about Ant protocol itself. But if you are planning to get highly customized data from boat, I suppose using Ant API directly would be easier way for you.

  • Does the boat have something that talks Ant?  Is there a spec for that interface?  You may find something on thisisant.com.

    If not, you're probably looking at a major effort. And then you'll be coding using the low level Ant calls.

  • Hi @Kurev and ,

    Thanks both of you for the answers.

    This is what I was thinking also. This setup has been decided before looking deeply into the available API thus their thoughts were that there is enough functionality in the Garmin devices. Getting the speed, position and most common sensor data will probably be available out of the box through sensors, but sending custom commands for example to steer the boat or the throttle level requires implementation of own protocols.

    There is a Multi Function Display on the boat but that is limited in "speaking" CAN-BUS as I understand it. No protocols are in place either. So my guessing was that we need to create our own protocols. We will need to program on a raspberry-pi in order to talk through CAN-BUS directly with the boat's system. And as you mention I thought that it was a big effort but reading it from others who has more experience of the Garmin world is reassuring.

  • Depending on your end goal for the information, I believe it would be simpler to implement a BLE communication link between the Garmin wearable and the raspberry pi instead for what you are describing.  That may limit the wearables you can interface with, however.