Hey guys! in this project in order to get the battery cooperating with the solar panels I need to pwm the battery to limit its voltage.
Tht`s what we did up to now: esc conncted straight to the panels, full throttle and voltage was about 5.3 volts. Then, with a max 1745 ic (voltage regulator with feedback) we forced the voltage to be 5.5, with the battery providing the current to keep that extra .2 volts.
No the ic is dead ande we cant get teh circuti to work again, very frustrating.
So i made a pwmmer circut with no feedback (better than nothing...) wich works well on the testbench, but I have a problem: it needs the pwm to be provided by an external source (arduino!) and, to be able to control it from ground, I want to pwm it with the ardupilot, simply having it outputting a pwm signal proportional to the reading of the throttle channel. Yes, I dont need the ardupilot to handle the throttle (sun in barely enough to fly, throttle is always 100%!), I just need it to read the position of the throttle stick and output a consequent pwm signal from 0 - 100%. Plain and simple. How to?
I think that the easyest way is to use one of the free pwm pin of the ardupilot (do we have it?) and just use the 3rd cahnnel input to set the pwm output. I know how to set a pwm output, but were in the code can I find the 3rd channel readings?