; W = received byte
mov_wf b ; W = b = received byte
- panic morse_TI4
+ D 0x70
+ mov_fw cbyte
+ call debugbyte
+ mov_fw b
+ call debugbyte
mov_lfsr slavetable, 1
mov_ff cslot, FSR1L ; FSR1 -> slave's flags
; lastd<n> [o0]*
; FSR1 -> lastd<n>
;
+ mov_wf xdebug+0
mov_wf u ; u = [C0]*
- xor_wfw INDF1 ; lastd<n> = [d0]*
+ mov_ff INDF1, xdebug+1
+ xor_wff INDF1 ; lastd<n> = [d0]*
+ ; to force test of repeated detection notification,
+ ; comment out previous line
+ mov_ff INDF1, xdebug+2
mov_lw 0x07
ior_wff FSR1L ; FSR1L -> detmsgh
return ; to addmsgs_<something>, very shortly
mov_lfsr slavetable, 1 ; FSR1H -> slavetable
mov_ff cslot, FSR1L ; FSR1 -> new ste_flags
- return
bt_f_if1 POSTDEC1, stf_sentinel ; FSR1 -> ste_slave
bra nextslave_looparound
; Ok, we have a slave:
+ D 0x71
+ mov_fw cslot
+ call debugbyte
mov_fw INDF1 ; W = new slave number
goto i2cm_read_start
; now we do our own detection
mov_lw (slavetable + ste_flags) & 0xff ; select our own slot
mov_wf cslot
+ D 0x72
+ mov_fw cslot
+ call debugbyte
call read_detection_head_master
goto i2cmu_read_got_byte
; TOS - 4 -> bt_f_if1 w, b'bbb'
; TOSL ???bbb00
; other conditions on entry and exit as for entry to addmsgs_<kind>, above
- panic morse_TI5
+ ;dec_f_ifz xdebug+7
+ ;bra boom
+
+ mov_ff t, xdebug+1
rr_fw TOSL ; W = 0???bbb0
+ mov_wf xdebug+2
rr_w ; W = 00???bbb
- ior_wfw 0xf8 ; W = 11111bbb
+ ior_lw 0xf8 ; W = 11111bbb
mov_wf FSR0L ; FSR0L = 11111bbb
+ mov_wf xdebug+3
clr_f FSR0H ; FSR0 -> bitnum2bit[bbb]
add_wfw t ; W = adjdetbasel + 11111bbb
; ie = 0 SSSSSSS (det msg low byte)
mov_fw v ; W = 0 SSSSSSS (det msg low byte)
goto serial_addbyte_another
+boom panic morse_TI5
+
;======================================================================
include final.inc