• Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

PIC programming project

Not open for further replies.


New Member
HI all..

Im doing a final year project for my school which involves PIC programming. im using PIC16F628 microcontroller.

Part of my project involves code scanning and checking..
im using the serial USART to recieve the code but im stuck at how to cross-check the recieved code with the one stored in the PIC..

If anyone could help me out with any solutions or suggestions, I wud be very greatful..


New Member
Well. I would just take advantage of the SUBWF command. Load your 8bit snipet into W and subtract from the [file] that has the correct and appropriate 8bit snipet. If they are the same then the Z flag should set.


bcf status,Z
movf sample,w
subwf actual,w
btfss status,Z
goto repeat

Assuming you are programming in Assembly.
Not open for further replies.

Latest threads

EE World Online Articles