ive got this code right here please check it out... im using mplab v8.66 hi-tech c compiler v9.81
it fails to initialize, what could be wrong with it? need help please.. this is for controlling a servo motor
this is the error
i got it from this link
it fails to initialize, what could be wrong with it? need help please.. this is for controlling a servo motor
Rich (BB code):
; FILE: outLed.asm ; AUTH: (Your name here) ; DATE: (date) ; DESC: Makes B0,B2,B4,B6 low and B1,B3,B5,B7 hi ; NOTE: Tested on PIC16F84-04/P. ; REFs: Easy Pic'n p. 23 (Predko p. 173 is bogus?) list p=16F84 radix hex ;---------------------------------------------------------------------- ; cpu equates (memory map) myPortB equ 0x06 ; (p. 10 defines port address) ;---------------------------------------------------------------------- org 0x000 start movlw 0x00 ; load W with 0x00 make port B output (p. 45) tris myPortB ; copy W tristate, port B outputs (p. 58) movlw b'10101010' ; load W with bit pattern (p. 45) movwf myPortB ; load myPortB with contents of W (p. 45) circle goto circle ; done end ;---------------------------------------------------------------------- ; at burn time, select: ; memory uprotected ; watchdog timer disabled ; standard crystal (4 MHz) ; power-up timer on
this is the error
Rich (BB code):
Error [876] C:\Documents and Settings\Administrator\My Documents\pic16F84 projects\Tutorials\servo.asm; 2. syntax error
Error [223] servo.pre; 4. digit out of range
Error [876] servo.pre; 13. syntax error
Error [800] servo.pre; 13. undefined symbol "b"
Rich (BB code):
http://www.pages.drexel.edu/~kws23/tutorials/PICTutorial/PICTutorial.html