flash: fixed wait times etc.
This commit is contained in:
@@ -82,7 +82,7 @@ checkFlash_end:
|
|||||||
flashProcess:
|
flashProcess:
|
||||||
rcall Flash_Init
|
rcall Flash_Init
|
||||||
flashProcess_loop1:
|
flashProcess_loop1:
|
||||||
; wait up to 20s for incoming FLASH_DATA message
|
; wait up to 10s for incoming FLASH_DATA message
|
||||||
ldi r16, CPRO_CMD_FLASH_DATA
|
ldi r16, CPRO_CMD_FLASH_DATA
|
||||||
rcall ioWaitForGivenMsg ; (r16, r17, r18, r19, r20, r22, X)
|
rcall ioWaitForGivenMsg ; (r16, r17, r18, r19, r20, r22, X)
|
||||||
brcc flashProcess_end ; no FLASH_DATA or FLASH_END msg
|
brcc flashProcess_end ; no FLASH_DATA or FLASH_END msg
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
; @clobbers: r16, r17, r20, X (r18, r19, r22)
|
; @clobbers: r16, r17, r20, X (r18, r19, r22)
|
||||||
|
|
||||||
ioWaitForGivenMsg:
|
ioWaitForGivenMsg:
|
||||||
ldi r20, 100 ; number of tries
|
ldi r20, 10 ; number of tries
|
||||||
ioWaitForGivenMsg_loop:
|
ioWaitForGivenMsg_loop:
|
||||||
push r16
|
push r16
|
||||||
push r20
|
push r20
|
||||||
|
|||||||
@@ -124,8 +124,8 @@ ioRawSendMsg_attnHigh:
|
|||||||
|
|
||||||
ioRawWaitForValidMsg:
|
ioRawWaitForValidMsg:
|
||||||
ldi r16, 0 ; expect ATTN low
|
ldi r16, 0 ; expect ATTN low
|
||||||
ldi r17, 200
|
ldi r17, 100
|
||||||
rcall ioWaitForAttnState100ms ; wait for up to 20s
|
rcall ioWaitForAttnState100ms ; wait for up to 10s
|
||||||
brcs ioRawWaitForValidMsg_attnLow
|
brcs ioRawWaitForValidMsg_attnLow
|
||||||
ret
|
ret
|
||||||
ioRawWaitForValidMsg_attnLow:
|
ioRawWaitForValidMsg_attnLow:
|
||||||
@@ -138,8 +138,8 @@ ioRawWaitForValidMsg_attnLow:
|
|||||||
ret
|
ret
|
||||||
ioRawWaitForValidMsg_packetReceived:
|
ioRawWaitForValidMsg_packetReceived:
|
||||||
ldi r16, 0xff ; expect ATTN high
|
ldi r16, 0xff ; expect ATTN high
|
||||||
ldi r17, 200
|
ldi r17, 100
|
||||||
rcall ioWaitForAttnState100ms ; wait for up to 20s
|
rcall ioWaitForAttnState100ms ; wait for up to 10s
|
||||||
brcc ioRawWaitForValidMsg_end
|
brcc ioRawWaitForValidMsg_end
|
||||||
ldi xl, LOW(flashRecvBuffer)
|
ldi xl, LOW(flashRecvBuffer)
|
||||||
ldi xh, HIGH(flashRecvBuffer)
|
ldi xh, HIGH(flashRecvBuffer)
|
||||||
|
|||||||
Reference in New Issue
Block a user