Re: RC Receiver with PIC16F628A Very Glitchy
I willl Try your suggestions with the Cap and Resistors.
Ultimately I think the Pulsin timing is wrong and still trying to figure what the correct values should be, or to use pulsin at all.
Using my Saleag logic analyzer I captured a 50M sample and toggled channel 3 to capture the pulse width.
With the switch High the width was 1900µs in the off state it was 1500µs. i can upload the captures later if need be.
So i then looked at 5 different High widths and they ranged from 1895µs to 1910µs.
The confusing part for me is with a 20Mhz clock this gives me 2µs resolution. What does that mean?
I then plugged in the values without the steering servo plugged in:
Code:
IF (pulse >= 185) AND (pulse <= 195) Then
I get no response.
Alain,
The board I designed uses the 5v from the ESC.
I am not driving an LED directly, I am driving a ULN2003 Darlington array which closes the ground for the LEDs but powered from the receiver as well. ULN2003 is rated at 500mA.
The receiver is powered from the ESC and thus plugged into the 7.2V Battery pack for the car.
Should i have separate power supplies?
Thanks,
Gary D.
There are 10 kinds of people. Those that know binary and those that do not.
Bookmarks