avr: fixed calls for 64K ATmega.
This commit is contained in:
@@ -28,7 +28,7 @@
|
|||||||
|
|
||||||
Main_SendValueReport:
|
Main_SendValueReport:
|
||||||
push r17
|
push r17
|
||||||
rcall NET_Buffer_Alloc ; (R16, R17, X)
|
bigcall NET_Buffer_Alloc ; (R16, R17, X)
|
||||||
pop r17
|
pop r17
|
||||||
brcc Main_SendValueReport_end ; jmp on error
|
brcc Main_SendValueReport_end ; jmp on error
|
||||||
push r16 ; buffer num
|
push r16 ; buffer num
|
||||||
@@ -36,10 +36,10 @@ Main_SendValueReport:
|
|||||||
adiw xh:xl, 1
|
adiw xh:xl, 1
|
||||||
ldi yl, LOW(netInterfaceData)
|
ldi yl, LOW(netInterfaceData)
|
||||||
ldi yh, HIGH(netInterfaceData)
|
ldi yh, HIGH(netInterfaceData)
|
||||||
rcall NETMSG_ValueWriteReport ; (R16, R17, R18, R19, R20, R21, R23, R24, R25)
|
bigcall NETMSG_ValueWriteReport ; (R16, R17, R18, R19, R20, R21, R23, R24, R25)
|
||||||
sbiw xh:xl, 1
|
sbiw xh:xl, 1
|
||||||
pop r16 ; buffer num
|
pop r16 ; buffer num
|
||||||
rcall NET_Interface_AddOrReleaseOutMsg ; (R16, R17, R18, X)
|
bigcall NET_Interface_AddOrReleaseOutMsg ; (R16, R17, R18, X)
|
||||||
Main_SendValueReport_end:
|
Main_SendValueReport_end:
|
||||||
ret
|
ret
|
||||||
; @end
|
; @end
|
||||||
@@ -59,7 +59,7 @@ Main_SendValueReport_end:
|
|||||||
|
|
||||||
Main_SendValueResponse:
|
Main_SendValueResponse:
|
||||||
push r17
|
push r17
|
||||||
rcall NET_Buffer_Alloc ; (R16, R17, X)
|
bigcall NET_Buffer_Alloc ; (R16, R17, X)
|
||||||
pop r17
|
pop r17
|
||||||
brcc Main_SendValueResponse_end ; jmp on error
|
brcc Main_SendValueResponse_end ; jmp on error
|
||||||
push r16 ; buffer num
|
push r16 ; buffer num
|
||||||
@@ -68,10 +68,10 @@ Main_SendValueResponse:
|
|||||||
adiw xh:xl, 1
|
adiw xh:xl, 1
|
||||||
ldi yl, LOW(netInterfaceData)
|
ldi yl, LOW(netInterfaceData)
|
||||||
ldi yh, HIGH(netInterfaceData)
|
ldi yh, HIGH(netInterfaceData)
|
||||||
rcall NETMSG_ValueWriteResponse ; (R16, R17, R18, R19, R20, R21, R23, R24, R25)
|
bigcall NETMSG_ValueWriteResponse ; (R16, R17, R18, R19, R20, R21, R23, R24, R25)
|
||||||
sbiw xh:xl, 1
|
sbiw xh:xl, 1
|
||||||
pop r16 ; buffer num
|
pop r16 ; buffer num
|
||||||
rcall NET_Interface_AddOrReleaseOutMsg ; (R16, R17, R18, X)
|
bigcall NET_Interface_AddOrReleaseOutMsg ; (R16, R17, R18, X)
|
||||||
Main_SendValueResponse_end:
|
Main_SendValueResponse_end:
|
||||||
ret
|
ret
|
||||||
; @end
|
; @end
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ BaseTimer_Init: ; setup timer for IRQ every 100ms
|
|||||||
ldi r17, (baseTimerModuleData_end-baseTimerModuleData)
|
ldi r17, (baseTimerModuleData_end-baseTimerModuleData)
|
||||||
rcall Utils_FillSram
|
rcall Utils_FillSram
|
||||||
|
|
||||||
rcall systemSetupTimer0
|
bigcall systemSetupTimer0
|
||||||
sec
|
sec
|
||||||
ret
|
ret
|
||||||
; @end
|
; @end
|
||||||
@@ -92,7 +92,7 @@ BaseTimer_Run:
|
|||||||
BaseTimer_Run_loop: ; for every timer tick
|
BaseTimer_Run_loop: ; for every timer tick
|
||||||
push r24
|
push r24
|
||||||
push r25
|
push r25
|
||||||
rcall onSystemTimerTick
|
bigcall onSystemTimerTick
|
||||||
pop r25
|
pop r25
|
||||||
pop r24
|
pop r24
|
||||||
sbiw r25:r24, 1
|
sbiw r25:r24, 1
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ NET_Interface_Init:
|
|||||||
mov xh, yh
|
mov xh, yh
|
||||||
ldi r17, NET_IFACE_SIZE
|
ldi r17, NET_IFACE_SIZE
|
||||||
clr r16
|
clr r16
|
||||||
rcall Utils_FillSram ; (R17, X)
|
bigcall Utils_FillSram ; (R17, X)
|
||||||
|
|
||||||
push yl
|
push yl
|
||||||
push yh
|
push yh
|
||||||
@@ -243,7 +243,7 @@ NET_Interface_ResetStats:
|
|||||||
adiw xh:xl, NET_IFACE_OFFS_PACKETSIN_LOW
|
adiw xh:xl, NET_IFACE_OFFS_PACKETSIN_LOW
|
||||||
ldi r17, ((NET_IFACE_OFFS_ERR_MISSED_HIGH+1)-NET_IFACE_OFFS_PACKETSIN_LOW)
|
ldi r17, ((NET_IFACE_OFFS_ERR_MISSED_HIGH+1)-NET_IFACE_OFFS_PACKETSIN_LOW)
|
||||||
clr r16
|
clr r16
|
||||||
rcall Utils_FillSram ; (R17, X)
|
bigcall Utils_FillSram ; (R17, X)
|
||||||
out SREG, r15
|
out SREG, r15
|
||||||
pop r15
|
pop r15
|
||||||
ret
|
ret
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
NETMSG_Common_AddUidToBuffer:
|
NETMSG_Common_AddUidToBuffer:
|
||||||
push xh
|
push xh
|
||||||
push xl
|
push xl
|
||||||
rcall Utils_ReadUid ; (R16, X)
|
bigcall Utils_ReadUid ; (R16, X)
|
||||||
pop xl
|
pop xl
|
||||||
pop xh
|
pop xh
|
||||||
st X+, r18
|
st X+, r18
|
||||||
@@ -68,7 +68,7 @@ NETMSG_AddNextMsgIdToBuffer:
|
|||||||
NETMSG_CheckUidInMsg:
|
NETMSG_CheckUidInMsg:
|
||||||
push xl
|
push xl
|
||||||
push xh
|
push xh
|
||||||
rcall Utils_ReadUid
|
bigcall Utils_ReadUid
|
||||||
pop xh
|
pop xh
|
||||||
pop xl
|
pop xl
|
||||||
ld r16, X+
|
ld r16, X+
|
||||||
|
|||||||
Reference in New Issue
Block a user