From 7fae05b4393f67be97219d77a74766766546ee31 Mon Sep 17 00:00:00 2001 From: ian Date: Fri, 30 Dec 2005 04:08:00 +0000 Subject: [PATCH] start scanning with board 1, not 2. trying to debug it still ... --- detpic/mascan.asm | 9 +++++---- detpic/serout.asm | 6 ++++++ 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/detpic/mascan.asm b/detpic/mascan.asm index 0a0978c..159650d 100644 --- a/detpic/mascan.asm +++ b/detpic/mascan.asm @@ -65,6 +65,7 @@ i2cmu_read_got_byte ; W = received byte mov_wf b ; W = b = received byte + panic morse_TI4 mov_lfsr slavetable, 1 mov_ff cslot, FSR1L ; FSR1 -> slave's flags @@ -220,8 +221,6 @@ nextslave_nowrite return ; do not scan while booster PWM is off while polarising ; to avoid all trains disappearing and reappearing - return ; do not scan yet - neg_fw outmsg_begin add_wfw outmsg_end and_lw outbuf_size - 1 @@ -235,6 +234,7 @@ nextslave_nowrite mov_lfsr slavetable, 1 ; FSR1H -> slavetable mov_ff cslot, FSR1L ; FSR1 -> new ste_flags + panic morse_TI3 bt_f_if1 POSTDEC1, stf_sentinel ; FSR1 -> ste_slave bra nextslave_looparound ; Ok, we have a slave: @@ -279,8 +279,8 @@ i2c_consider_restartread @ ; INITIALISATION mascan_init @ - mov_lw (slavetable + ste_flags + ste_size) & 0xff - ; start with 1st actual slave + mov_lw (slavetable + ste_flags) & 0xff + ; pretend we've just done us, to start with 1st actual slave mov_wf cslot clr_f cbyte bs_f cbyte, cbyte_halted ; serial output of `hello' will start us up @@ -441,6 +441,7 @@ addmsg_one ; TOS - 4 -> bt_f_if1 w, b'bbb' ; TOSL ???bbb00 ; other conditions on entry and exit as for entry to addmsgs_, above + panic morse_TI5 rr_fw TOSL ; W = 0???bbb0 rr_w ; W = 00???bbb ior_wfw 0xf8 ; W = 11111bbb diff --git a/detpic/serout.asm b/detpic/serout.asm index 377c555..85da2c7 100644 --- a/detpic/serout.asm +++ b/detpic/serout.asm @@ -92,6 +92,9 @@ serialtxfc_init @ ;====================================================================== ; ACTUAL TRANSMISSION +boo + panic morse_TI1 + ;---------------------------------------------------------------------- serialtx_intrl @ ; are we ready to transmit ? @@ -107,6 +110,9 @@ serialtx_intrl @ xor_wfw outmsg_end bra_z tx_bufempty + mov_fw INDF0 + xor_lw 0x02 + bra_z boo mov_fw INDF0 mov_wf TXREG bra_n tx_justsent_noacknmra -- 2.30.2