Help reading RPM

Development & General Chat for the superb openxvario project.

Moderator: rainer

Post Reply
Drashiel
Posts: 8
Joined: Sun Nov 22, 2015 8:12 pm
Country: -

Help reading RPM

Post by Drashiel »

Hi,
I tried to use OpenXvario on Arduino nano with 2 NTC, GPS, GY86 (magnetometer, vario), and RPR220 as RPM sensor with sport protocol.
Everything works alone, configuring only GPS I get GPS data correctly, configuring GY86 I get mag data and vario data, temperature sensors are ok and rpm readings are OK stand alone.
But I tried to get everything and this is driving me crazy. Enabling all functions (GPS, GY86, NTC, a voltage divider to get voltage from battery and RPM) works until I get any value from the RPM sensor. At this time, the microcontroller crashes and hang. Suspecting an issue with the RPR220 implement, I did the same test removing the RPR sensor and putting D8 I/O on high and low values manually and I get a hang. I can get everything connected and working until I move the propeller and RPM sensor updates D8 pin. This causes Arduino to hang. RPM reads values If it's configured stand-alone.
I tried with 2 different boards and getting the same results. I think there is any kind of issue with watchdog since on a board with old bootloader at the moment to get RPM reads, it hangs but after updating bootloader sometimes it crash and restart.
I double-check power lines (it is powered with an 8A UBEC), there is nothing connected to Arduino board.
I did a bootloader update since there is an issue with old bootloaders that may crash.
I checked to disable functionalities and I can get RPM with everything except the GY86 board, so enabling the GY86 board (and vario and mag) causes any kind of issue and causes a crash when reading D8 pin.
Does anybody have an issue like me?
Thanks,
Regards.

User avatar
kalle123
Posts: 905
Joined: Sat Mar 29, 2014 10:59 am
Country: -
Location: Moenchengladbach

Re: Help reading RPM

Post by kalle123 »

I would make a test with splitting the sensors up on two Arduinos.
Bildschirmfoto_2021-03-26_08-22-26.jpg
(101.85 KiB) Not downloaded yet
The upper oXs has current and voltage and the lower one vario and gps. Right side is the connector.

So I was flexible with the sensors. Could fly with only a vario, could plug in the gps or only had voltage and current or use all.

br KH
Drashiel
Posts: 8
Joined: Sun Nov 22, 2015 8:12 pm
Country: -

Re: Help reading RPM

Post by Drashiel »

Well, I´m completely lost, more than yesterday. I did more tests enabling rpm debug, with my Horus powered on and linked with S8R receiver, as soon as I get any value on RPM sensor, Arduino crashes. With Horus powered off, I get values on debugging with everything connected (GY86, NTC, etc). As soon as I power on Horus, Arduino crash or restarts itself.
Carbo
Posts: 467
Joined: Fri Aug 02, 2013 6:55 pm
Country: Germany
Location: Freinsheim RP

Re: Help reading RPM

Post by Carbo »

Try to block RF with a small ceramic capacitor between D8 and GND. TX and RX (telemetry) RF are able to disturb the measurement.
Drashiel
Posts: 8
Joined: Sun Nov 22, 2015 8:12 pm
Country: -

Re: Help reading RPM

Post by Drashiel »

Hi Carbo, I don´t think this is causing arduino hangs.

Post Reply

Return to “OpenXVario - an open source vario supported by the open source firmwares!!”