avr: added NET_Interface_ResetStats and call it daily.
This commit is contained in:
@@ -220,4 +220,24 @@ NET_Interface_Periodically_l2:
|
||||
|
||||
|
||||
|
||||
; ---------------------------------------------------------------------------
|
||||
; @routine NET_Interface_ResetStats @global
|
||||
;
|
||||
; @param Y pointer to start of interface data
|
||||
; @clobbers R16, R17, X
|
||||
|
||||
NET_Interface_ResetStats:
|
||||
clr r16
|
||||
std Y+NET_IFACE_OFFS_PACKETSIN_LOW, r16
|
||||
|
||||
mov xl, yl
|
||||
mov xh, yh
|
||||
adiw xh:xl, NET_IFACE_OFFS_PACKETSIN_LOW
|
||||
ldi r17, ((NET_IFACE_OFFS_ERR_BUSY_HIGH+1)-NET_IFACE_OFFS_PACKETSIN_LOW)
|
||||
clr r16
|
||||
rjmp Utils_FillSram ; (R17, X)
|
||||
; @end
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user