>=20 > > I'm using the CCS compiler. The code looks like this: > > > > Output_low(PIN_A1); > > Delay_ms(200); > > Output_high(PIN_A1); >=20 > That's very interesting, but does it produce any assembler=20 > :-) There is probably a .LST file or even .ASM file created,=20 > which will show what it is actually doing from startup. As=20 > it's a C compiler, I would expect that the above 3 lines will=20 > use quite a few resources to blink the LED, not a string of nop's! >=20 Here is what it says in the documentation: -- This function will create code to perform a delay of the specified length. Time is specified in milliseconds. This function works by executing a precise number of instructions to cause the requested delay. It does not use any timers. If interrupts are enabled the time spent in an interrupt routine is not counted toward the time. -- I created a simple CCS C program with just a 10 us delay. Here is the relevant assembler: .................... delay_us(10); 0009: MOVLW 03 000A: MOVWF 20 000B: DECFSZ 20,F 000C: GOTO 00B > Does pin A1 have any other function on the chip you are using=20 > (eg comparator input etc). I'm sure you mentioned which PIC=20 > it was, could you remind me? >=20 No. I am using a 16F628. [snip good debugging approaches] >=20 > A few pointers to be going on with, these are all standard=20 > debug thoughts that you can store away for next time, even if=20 > they don't find the problem this time! Once you've tried=20 > them, let us know what the result was, and we'll go one from there. >=20 > As you mentioned that you have 2 boards, one working and one=20 > not, try to test both of them and compare what happens. >=20 > Nigel I am kind of interested in an abstract way, but I don't have the time to investigate this further. Once I built a board that works, I know there is not a flaw in my software or hardware *design*, even if there may be a problem in one particular instance. I am building this for a proof-of concept demo, and I am much more concerned about the functionality of the device. If I were planning to manufacture 100,000 of these, I might be more worried about my manufacturing processes. I already know my SMT soldering is suspect. :-) Alex -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu