From 1f088bee39dac2508c8512b0c651bee0500197ca Mon Sep 17 00:00:00 2001 From: ian Date: Sun, 25 Dec 2005 13:03:06 +0000 Subject: [PATCH] lasttelldone documented but not implemented --- detpic/nmra-stream.asm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/detpic/nmra-stream.asm b/detpic/nmra-stream.asm index 213d5ac..9d816cb 100644 --- a/detpic/nmra-stream.asm +++ b/detpic/nmra-stream.asm @@ -29,6 +29,7 @@ nextaction equ 6 ; bit 6: change polarity on next interrupt y/n fromserial res 1 ; from-serial buffer location (in buffer bank) totrack equ FSR2L ; to-track buffer location (in buffer bank) totrackbit res 1 ; bit location of pointer within byte +lasttelldone res 1 ; last nmra msg we've told host we've finished ; ; buffers are each 16 bytes (this is hardwired) ; and there are four of them starting at 0x500, 0x510, 0x520, 0x530. @@ -46,6 +47,20 @@ totrackbit res 1 ; bit location of pointer within byte ; being transmitted; if nothing is currently being transmitted ; because there is no nmra data at all then totrack points to the ; start of the same buffer as fromserial + ; + ; lasttelldone points to the last buffer whose complete transmission + ; we've reported to the host. + ; + ; We maintain the following properties, notionally: + ; + ; lasttelldone <= totrack <= fromserial < lasttelldone + ; + ; / \ + ; ' `- equal if we have nothing but + ; equal if we have idle to trasmit + ; told the host about our + ; current buffer state + ; bufferpage equ 5 -- 2.30.2