I've been working on a project using the 16F871 chip, I got two samples f= rom Microchip, updated MPLAB to the latest version, and set to get going on t= his. = The first thing I always do is something simple, just to let me know that= the chip is working, rather than do something elaborate and try to figure out= what I did wrong. So I did the simple, read a port switch, and turn on an LED= when the switch activates. No go. I used portA for the input, set the TRIS t= o 0xFF, and used portC as the output, setting TRIS to 0x00 Seems the portC is not behaving as an output. I'm using a 4MHz TTL oscil= lator (yes its working, have it hooked to OSC1 input, and get an output on OSC2= , input is set to HS. I even backed off and made the program simple by just TURNING on the LED = but portC seems to be...not working or intializing. Now, one thing that is strange is I get the following error in MPLAP when= I assemble. Building TEST.HEX... Compiling TEST.ASM: Command line: "C:\PROGRA~1\MPLAB\MPASMWIN.EXE /p16F871 /q D:\A_STC\TEST.A= SM" Message[301] D:\A_STC\P16F871.INC 35 : MESSAGE: (Processor-header file mismatch. Verify selected processor.) Warning[224] D:\A_STC\TEST.ASM 19 : Use of this instruction is not recommended. Warning[224] D:\A_STC\TEST.ASM 22 : Use of this instruction is not recommended. Build completed successfully. Whats the deal with the processor header file mismatch? here is the source file list p=3D16F871 ; list directive to define processor #include ; processor specific variable definitions PORTA EQU H'0005' PORTB EQU H'0006' PORTC EQU H'0007' PORTD EQU H'0008' PORTE EQU H'0009' PCLATH EQU H'000A' org 0x000 ; The main line code starts here main goto init org 0x010 init movlw 0xFF tris PORTA = movlw 0x00 tris PORTC here = bcf PORTC,2 bsf PORTC,0 bcf PORTC,1 bsf PORTC,2 nop nop nop goto here end ____________________________________________________________________ Get free email and a permanent address at http://www.netaddress.com/?N=3D= 1 -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! use mailto:listserv@mitvma.mit.edu?body=SET%20PICList%20DIGEST