--
You received this message because you are subscribed to the Google Groups "ant-api" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ant-api+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ant-api/1944bd68-6649-4809-8658-fd1af15d7670n%40googlegroups.com.
Hey, Gabor,Thank you very much for your detailed explanation. I already knew some of it, but it helps me to connect things properly.I reduced my description to the preparation of the board (my mistake), as I had found a reference to this in the first message here in the group. However, what I initially had in mind corresponds exactly to the picture on the left and the intention of the library (as I understand it): Connect an Arduino (Leonardo) to the DK via the serial interface.
To view this discussion on the web visit https://groups.google.com/d/msgid/ant-api/61b7f19f-c39b-49c7-9118-4c91d25e5321n%40googlegroups.com.
Hi Markus,Markus Rebbert <markus....@gmail.com> ezt írta (időpont: 2021. febr. 10., Sze, 17:00):Hey, Gabor,Thank you very much for your detailed explanation. I already knew some of it, but it helps me to connect things properly.I reduced my description to the preparation of the board (my mistake), as I had found a reference to this in the first message here in the group. However, what I initially had in mind corresponds exactly to the picture on the left and the intention of the library (as I understand it): Connect an Arduino (Leonardo) to the DK via the serial interface.That might work, but then you have to keep in your mind two important things.On one hand: the nRF-52 DK is --- a DK. That is, it is intended for development. That is without any application code.If your intended use-case is to use the DK as a "dumb" ANT radio module, then first you have to somehow either develop, or obtain application software, which application software would realize the business logic which makes that DK board into an "ANT network processor".
A more cheaper, simpler, less painful solution would be to purchase a real (and "dumb") ANT network processor. AFAIK, the currently available such devices on the market are ANT+ "USB-sticks". You might be able to buy some earlier non-USB models on eBay, but with the nRF-52 DK you have to solve the problem of "dumbifying" the DK yourself.
Note, that nRF-52 DK is a hardware DK which comes with a software-DK (SDK), i.e., with the nRF5 SDK. That SDK has many-many examples, several of them are examples of how one could make an application realizing, say, the ANT+ HRM profile. That SDK is for the C++ programming language, on which the Wiring language is based, too.Summary: if you want to connect the nRF-52 DK as a "dumb" ANT-radio to some external Arduino compatible MCU -- that is quite possible, too, provided that
- you define a suitable serial communication protocol for yourself
- and write the appropriate C++ code for the DK that sends/receives messages according to that protocol over the hardware serial port of the nRF-52 DK board and controls the ANT+ radio of the board accordingly
- and you write some Wiring code on your favourite Arduino compatible MCU (the Leonardo) that speaks the same protocol and use that protocol over the serial port of the said MCU
- and finally you connect the serial ports of both your MCU and the DK board via a suitable cabling
However, on the other hand, you have to note that the n-RF52 DK is not a dumb ANT+ radio (albeit it can emulate such one), not at all. It is a complete SoC. It contains, among others, a quite powerful ARM Cortex M4 MCU itself, which is an Arduino compatible MCU, much more powerful alone than the MCU in the Leonardo board...
In other words, if you have both the Leonardo and the nRF-52 DK, then forget about the Leonardo and use the onboard Arduino compatible MCU of the DK. After you have read the "Getting Started" of the DK board, you will have learnt that the DK board:
- is an Arduino compatible MicroController Unit (MCU) itself
- its PCB board and its hardware GPIO interfaces are configured such way that you can use any Arduino form-factor compatible "shield" with the DK
- its ARM Cortex M4 MCU is far more powerful than the ATmega32u4 MCU on the Leonardo board...
- and so on and so forth.
In other words, using a Leonardo to control an nRF52-DK "in dumb ANT+ radio mode" is a pure waste, IMHO,
I would simply suggest you to assign all your "Arduino code" to the ARM Cortex M4 onboard on the n-RF 52DK instead of the good old Leonardo, which is a mediocre MCU compared to the Cortex M4....
To view this discussion on the web visit https://groups.google.com/d/msgid/ant-api/CANrsrrx5rB2spm80u1056GHsYNp-iQg3%3DCmXms7VyuPeprR5FQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ant-api/CAGXAbSqbjXwOiok7vBPi_RKYuzzxMgViGLoiFmTnvekZ4HOQCA%40mail.gmail.com.
Nrfutil is actually "the" flasher tool used by the Arduino framework...
--
But you asked what I want to achieve in a very first step: I would like to control a fan depending on heart rate, (virtual) speed and temperature.
The fan is controlled with an AC dimmer; the connected Arduino is controlled via RF-433Mhz. (works already). That's it (for the moment).So one thing led to another. I wanted to stay with Arduino and not learn a new IDE, debugger etc., but concentrate on the use case. In the process, I found this helpful library, including the reference to the two serial interfaces, which makes debugging more convenient, etc. - therefore the Leonardo. And yes, you're also right, maybe an RPi and Go, Python & Co. would bring me closer to my goal (and would be closer to where I come from - but where's the fun in that? ;))I think I now have three alternatives:1. use the DK also as MCU (I had actually already started with that - but found the debugging a bit unusual)
2. switch completely to RPI etc.
3. find an ANT+ alternative (stick, etc.) (any suggestions?) - and use it with the Leonardo.
To view this discussion on the web visit https://groups.google.com/d/msgid/ant-api/b6853b4d-5a5c-480a-a34d-8e357c259482n%40googlegroups.com.
Hi,Markus Rebbert <markus....@gmail.com> ezt írta (időpont: 2021. febr. 12., P, 13:54):But you asked what I want to achieve in a very first step: I would like to control a fan depending on heart rate, (virtual) speed and temperature.Let me guess: indoor bike training?
I think I now have three alternatives:1. use the DK also as MCU (I had actually already started with that - but found the debugging a bit unusual)I also use an MCU from the nRF-52 series. Particularly, I use the Adafruit nRF52804 Feather Express, but I started with the corresponding NordicSemi DK: the nRF52840-DK (which was an expensive overkill, too). The nRF52840-DK board has been fully integrated with the ArduinoIDE: the Adafruit-nRF52 Arduino-framework contains direct support for that.Now, about your nRF-52DK: checkout this webpage: https://jimmywongiot.com/2020/09/07/arduino-ide-with-nrf52-dk-board/It seems SparkFun has made the integration for you...
2. switch completely to RPI etc.That has pros and cons. If battery operated is the goal, then I think the MCU alternative makes sense.
3. find an ANT+ alternative (stick, etc.) (any suggestions?) - and use it with the Leonardo.An ANT+ USB stick would be a simple solution, but then you need an USB-host for communication with that (and to power it). A Raspberry can be a USB host, but USB-host role is not common in the MCU world. I know that Ha Thach, the maintainer of the TinyUSB project for MCU-s works on eventual USB-OTG support, but I do not know how mature is that. Anyway, you would need an MCU with true HW-support for USB, many cheaper MCU-s use software-only quirks to implement the USB-client role, if at all.Cujo has already linked in D52 modules from Garmin, but they cost almost as much as the nRF-52DK itself, AFAIK...
Hi,orr...@gmail.com schrieb am Freitag, 12. Februar 2021 um 14:23:34 UTC+1:Hi,Markus Rebbert <markus....@gmail.com> ezt írta (időpont: 2021. febr. 12., P, 13:54):But you asked what I want to achieve in a very first step: I would like to control a fan depending on heart rate, (virtual) speed and temperature.Let me guess: indoor bike training?correct.I think I now have three alternatives:1. use the DK also as MCU (I had actually already started with that - but found the debugging a bit unusual)I also use an MCU from the nRF-52 series. Particularly, I use the Adafruit nRF52804 Feather Express, but I started with the corresponding NordicSemi DK: the nRF52840-DK (which was an expensive overkill, too). The nRF52840-DK board has been fully integrated with the ArduinoIDE: the Adafruit-nRF52 Arduino-framework contains direct support for that.Now, about your nRF-52DK: checkout this webpage: https://jimmywongiot.com/2020/09/07/arduino-ide-with-nrf52-dk-board/It seems SparkFun has made the integration for you...Right. I already did that - but I use PlatformIO instead - including the JLINK-Debugger-Support.2. switch completely to RPI etc.That has pros and cons. If battery operated is the goal, then I think the MCU alternative makes sense.This is the reason why i wanted to use the MCU.