Basic program operations [PICProgramm.cs]
This commit is contained in:
@@ -1,33 +1,33 @@
|
||||
;TPicSim1
|
||||
;Programm zum Test des 16F84-Simulators.
|
||||
;Es werden alle Literal-Befehle gepr?ft
|
||||
;(c) St. Lehmann
|
||||
;Ersterstellung: 23.03.2016
|
||||
;
|
||||
|
||||
;Definition einiger Symbole
|
||||
;zuerst Hardware-Register
|
||||
status equ 03h
|
||||
ra equ 05h
|
||||
rb equ 06h
|
||||
|
||||
;f?r den Benutzer frei verwendbare Register
|
||||
count equ 0ch
|
||||
|
||||
;Definition des Prozessors
|
||||
device 16F84
|
||||
|
||||
;Festlegen des Codebeginns
|
||||
org 0
|
||||
start
|
||||
movlw 11h ;in W steht nun 11h, Statusreg. unver?ndert
|
||||
andlw 30h ;W = 10h, C=x, DC=x, Z=0
|
||||
iorlw 0Dh ;W = 1Dh, C=x, DC=x, Z=0
|
||||
sublw 3Dh ;W = 20h, C=1, DC=1, Z=0
|
||||
xorlw 20h ;W = 00h, C=1, DC=1, Z=1
|
||||
addlw 25h ;W = 25h, C=0, DC=0, Z=0
|
||||
|
||||
|
||||
ende
|
||||
goto ende ;Endlosschleife, verhindert Nirwana
|
||||
|
||||
;TPicSim1
|
||||
;Programm zum Test des 16F84-Simulators.
|
||||
;Es werden alle Literal-Befehle gepr?ft
|
||||
;(c) St. Lehmann
|
||||
;Ersterstellung: 23.03.2016
|
||||
;
|
||||
|
||||
;Definition einiger Symbole
|
||||
;zuerst Hardware-Register
|
||||
status equ 03h
|
||||
ra equ 05h
|
||||
rb equ 06h
|
||||
|
||||
;f?r den Benutzer frei verwendbare Register
|
||||
count equ 0ch
|
||||
|
||||
;Definition des Prozessors
|
||||
device 16F84
|
||||
|
||||
;Festlegen des Codebeginns
|
||||
org 0
|
||||
start
|
||||
movlw 11h ;in W steht nun 11h, Statusreg. unver?ndert
|
||||
andlw 30h ;W = 10h, C=x, DC=x, Z=0
|
||||
iorlw 0Dh ;W = 1Dh, C=x, DC=x, Z=0
|
||||
sublw 3Dh ;W = 20h, C=1, DC=1, Z=0
|
||||
xorlw 20h ;W = 00h, C=1, DC=1, Z=1
|
||||
addlw 25h ;W = 25h, C=0, DC=0, Z=0
|
||||
|
||||
|
||||
ende
|
||||
goto ende ;Endlosschleife, verhindert Nirwana
|
||||
|
||||
|
||||
Reference in New Issue
Block a user