Re: [WheelWatcher] WW-01 Code



Curt,

What do the waveforms look like on the servo control pins (B1 and B2)? They should be oscillating at a 50 Hz rate (20ms period), with the high part of each square wave between 0.5 ms and 2.5ms, and then say low for the remainder of each 20ms period.

-Pete

CURTIS M ARMER wrote:
Pete
The motors will not move for any test as long as I have the #define
LEFT_CLK_ON_TIMER_1 uncommented.  If I comment it out then the servos move in
oppisite directions forever as soon as device is programmed.
Power is not a issue, I have proper voltages and all grounds connected together. I have never used a crystal oscillator before but maybe thats where my problem
is.  I am getting a 20mhz sine wave from the crystal but Im not sure its
supposed to be a sine or square wave. I also tried a can crystal with ttl
output and that still produced sine wave. Thats another reason I tried porting
to PIC18 since it has built in oscillator.
Here is the code I use to set fuses:
#include <16F877.h>
#device ADC=8
#device *=16
#DEVICE CCSICD=TRUE
#use delay(clock=20000000)
#use rs232(baud=9600,parity=n,bits=8,xmit=PIN_C6,rcv=PIN_C7)
#fuses HS,NOWDT,PUT,NOLVP,NOBROWNOUT
Curt
_______________________________________________
WheelWatcher mailing list
WheelWatcher@xxxxxxxxxxxxxxxxx
http://list.nubotics.com/mailman/listinfo/wheelwatcher





This archive was generated by a fusion of Pipermail (Mailman edition) and MHonArc.