avr: decreased verbosity. minor fixes.
- address claiming modes now work
This commit is contained in:
80
avr/main.asm
80
avr/main.asm
@@ -61,16 +61,18 @@ main:
|
||||
rcall Led_SetPattern
|
||||
#endif
|
||||
|
||||
; sbi DDRA, PORTA2 ; debug
|
||||
; sbi PINA, PORTA2 ; debug (toggle)
|
||||
; cbi PORTA, PORTA2 ; debug (on)
|
||||
; sbi PORTA, PORTA2 ; debug (off)
|
||||
|
||||
; ldi r16, 1
|
||||
; sts twiMasterScanEnabled, r16
|
||||
|
||||
main_loop:
|
||||
rcall runModulesUntilIdle
|
||||
sbi DDRA, PORTA2 ; debug
|
||||
; sbi PINA, PORTA2 ; debug (toggle)
|
||||
; cbi PORTA, PORTA2 ; debug (on)
|
||||
; sbi PORTA, PORTA2 ; debug (off)
|
||||
|
||||
sei ; make sure interrupts really are enabled
|
||||
; only modify SE, SM1 and SM0
|
||||
in r16, MCUCR
|
||||
ldi r17, (1<<SE) | (1<<SM1) | (1<<SM0)
|
||||
@@ -216,36 +218,6 @@ initialWait_l2: ; wait for 10ms
|
||||
|
||||
#ifdef MODULES_LCD
|
||||
|
||||
printStartSendPackage:
|
||||
in r15, SREG ; debug
|
||||
push r15
|
||||
cli
|
||||
ldi r18, 1
|
||||
ldi r19, 3
|
||||
rcall LCD_SetCursor
|
||||
ldi r16, 'S'
|
||||
rcall LCD_PrintChar
|
||||
ldi r16, ' '
|
||||
rcall LCD_PrintChar
|
||||
pop r15
|
||||
out SREG, r15
|
||||
ret
|
||||
|
||||
|
||||
printEndSendPackage:
|
||||
in r15, SREG ; debug
|
||||
push r15
|
||||
cli
|
||||
ldi r18, 2
|
||||
ldi r19, 3
|
||||
rcall LCD_SetCursor
|
||||
ldi r16, 'E'
|
||||
rcall LCD_PrintChar
|
||||
pop r15
|
||||
out SREG, r15
|
||||
ret
|
||||
|
||||
|
||||
printTimerMark:
|
||||
in r15, SREG ; debug
|
||||
push r15
|
||||
@@ -261,46 +233,6 @@ printTimerMark:
|
||||
|
||||
|
||||
printSendStats:
|
||||
#if 0
|
||||
in r15, SREG ; debug
|
||||
push r15
|
||||
cli
|
||||
|
||||
ldi r18, 1
|
||||
ldi r19, 5
|
||||
rcall LCD_SetCursor
|
||||
ldi zl, LOW(textStatsPacketsIn)
|
||||
ldi zh, HIGH(textStatsPacketsIn)
|
||||
rcall LCD_PrintFromFlash
|
||||
lds r18, com2StatsPacketsIn
|
||||
lds r19, com2StatsPacketsIn+1
|
||||
rcall LCD_PrintHexWord
|
||||
|
||||
ldi r18, 1
|
||||
ldi r19, 6
|
||||
rcall LCD_SetCursor
|
||||
ldi zl, LOW(textStatsPacketsOut)
|
||||
ldi zh, HIGH(textStatsPacketsOut)
|
||||
rcall LCD_PrintFromFlash
|
||||
lds r18, com2StatsPacketsOut
|
||||
lds r19, com2StatsPacketsOut+1
|
||||
rcall LCD_PrintHexWord
|
||||
|
||||
ldi r18, 1
|
||||
ldi r19, 7
|
||||
rcall LCD_SetCursor
|
||||
ldi zl, LOW(textStatsPacketsRecvErr)
|
||||
ldi zh, HIGH(textStatsPacketsRecvErr)
|
||||
rcall LCD_PrintFromFlash
|
||||
lds r18, com2StatsBusyError
|
||||
lds r19, com2StatsBusyError+1
|
||||
rcall LCD_PrintHexWord
|
||||
|
||||
pop r15
|
||||
out SREG, r15
|
||||
ret
|
||||
|
||||
#else
|
||||
in r15, SREG ; debug
|
||||
push r15
|
||||
cli
|
||||
|
||||
Reference in New Issue
Block a user