I know, but there is something funny going on. I looked at it with 'xxd' and you have a CR/^M/0x0D with no LF/0x0A, and I will bet that's confusing the compiler. I'm willing to bet if you took these lines out: // This method of providing delays isn't efficient with respect to clock cycles. It takes 9 usec to decrement a variable. However, it does work.^M// Purists advocate inserting Assembly language into the code. My attempts to implement this were not successful. // Executing delay_1_msec 1000 times takes about 1 sec.^M//void delay_1_msec (void) and retyped void delay_1_msec (void) with the remaining part of the function uncommented, it would work. On Sun, Feb 28, 2010 at 9:16 PM, Jason Hsu wrote: > Please use MPLAB to view my code. =A0That's what I used to create it. > > On Sun, Feb 28, 2010 at 11:11 PM, Alex Harford wrote: >> Jason, the strange thing I see is that the newlines are odd looking. >> See what it looks like opened on a Linux box in vim: >> >> http://imgur.com/qvgwj >> >> There are ^Ms shown, but where you pasted the code in, there is a ^M >> but it didn't cause a newline!? >> >> Maybe a dos2unix / unix2dos pass will straighten things out. >> > > > > > -- > Jason Hsu > http://www.jasonhsu.com/swrwatt.html > http://www.jasonhsu.com/swrwatt-c.txt > http://www.jasonhsu.com/swrwatt-asm.txt > -- > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist > -- = http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist