i have an external sensor in my system that outputs analog voltage 0-5V and im using the RSSI on ardu copter (pixhawk) to read that voltage and transmit it down to telemetry.
the issue im getting is that the analog readings on the SBUS (103) pin are not stable.
when my sensor outputs 2.0V for example, and RSSI is set to 0 to 5V, instead of showing steady 40% im getting fluctations from 20 to 70% or so. i double checked and voltage is stable.
any idea how to proceed from here and what could be causing it?
here is my RSSI and pin setup:
RSSI_ANA_PIN = 103 (SBUS)
RSSI_PIN_HIGH = 5 (v)
RSSI_PIN_LOW = 0 (v)
RSSI_TYPE = 1 (Analog Pin)
BRD_PWM_COUNT = 6 (means Aux outputs are GPIO free to use)
when i try AUX1 pin (50) instead of SBUS pin (103) - i get constant 0 RSSI, not sure why too.
thanks for looking.
OK thats interesting, i may have misunderstood the meaning of BRD_PWM_COUNT, i thought this effects motor outputs so for a Hexacopter needs to be set to 6. are you saying this parameter effects only AUX outputs?
i have set BRD_PWM_COUNT to 0 and RSSI pin to 50 (Aux1) all the way to 55 (Aux6) and still when i put 5V in the signal pin of Aux1-Aux6 (should be 100% RSSI) i get 0% constant.
Yes, brd_pwm_count only effects AUX.
There are some nuances with this that really depend on firmware version: if using a ChibiOS firmware (*.apj file), you need to be on at least 3.6.6, preferably latest stable. If using a nuttx firmware, I think this feature was only available on aux 5 and/or 6. You loose a lot of other features using a Nuttx firmware though, so I suggest making sure you’re on latest stable then posting a parameter file
This works no problem with current stable (3.6.12, Chibios of course) with a Pixhawk with the parameters set as you had them in your 1st post using the Sbus I/O pin. I have a Pixhawk on the bench and just tested it with a 1.5V input. I think 3.3V is max but you can scale it with the min/max values.
whats the best way to read current fw before i upgrade?
so far my results are:
sbus pin - fluctuating readings.
aux1-aux6 - constant 0
reluctantly i had to use the ADC pin - this works as it should, but i would really like to use sbus or aux as these are much easier to connect to.