Skip to content

Instantly share code, notes, and snippets.

@Novakov
Created October 8, 2012 12:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Novakov/3852163 to your computer and use it in GitHub Desktop.
Save Novakov/3852163 to your computer and use it in GitHub Desktop.
.nolist
.include "m128def.inc"
.list
.listmac
.DSEG
ram_tab: .byte 60
.cseg
.org 0
rjmp ResetProcessor ;
ResetProcessor : ;
cli ;
Main:
cbi DDRA, 0
sbi PORTA, 0
loop:
in r16, PINA
andi r16, 0x1
cpi r16, 0x0
breq Copy
rjmp loop
Copy:
ldi r16, 0xbd
sts ram_tab, r16
rjmp loop
rom_tab:
.db 0x01, 0x00 , 0xffff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment