Skip to Content
Interfacing PIC Microcontrollers
book

Interfacing PIC Microcontrollers

by Martin P. Bates
April 2011
Intermediate to advanced
312 pages
9h 32m
English
Newnes
Content preview from Interfacing PIC Microcontrollers
Clear ResLo and ResHi
Loop
Add Num1 to ResLo
If Carry set, increment ResHi
Decrement Num2
Until Num2 = 0
12 Declare registers: Num1, Num2
Load integer into Num1
Complement Num1
Increment Num1
Add Num1 to Num2
Result in Num2
Assessment 6
1 The key code is obtained by taking the row low and checking the column input. If it is
low, the ASCII code is loaded and the scan quit.
2 The code to operate the LCD only needs to be written once, saved and included into
new programs as required, saving time and effort.
3 The negative result is detected when the carry flag is cleared. A minus sign character is
displayed, and the inverse 2s complement of the result calculated ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Interfacing PIC Microcontrollers, 2nd Edition

Interfacing PIC Microcontrollers, 2nd Edition

Martin P. Bates

Publisher Resources

ISBN: 9780750680288