avr/apps/ma_light: adapted to latest changes. works now.
This commit is contained in:
@@ -64,7 +64,7 @@ AppMotionLight_OnPacketReceived_set:
|
||||
AppMotionLight_OnPacketReceived_clcRet:
|
||||
clc ; unexpected message
|
||||
ret
|
||||
AppMotionLight_OnPacketReceived_setRGBW:
|
||||
AppMotionLight_OnPacketReceived_setRGBW: ; "setValue nodes/XXXXXXXX/MALRGBWVALUE GRWB"
|
||||
sts appMotionLightColor, r18
|
||||
sts appMotionLightColor+1, r19
|
||||
sts appMotionLightColor+2, r20
|
||||
@@ -72,25 +72,23 @@ AppMotionLight_OnPacketReceived_setRGBW:
|
||||
rcall appMotionLightStartTimer ; immediately ON with new color (r16)
|
||||
rcall appMotionLightTurnOn ; (r16, r17, r18, r19, r20, r21, r23)
|
||||
rjmp AppMotionLight_OnPacketReceived_sendAck
|
||||
AppMotionLight_OnPacketReceived_setOnTime:
|
||||
AppMotionLight_OnPacketReceived_setOnTime: ; "setValue nodes/XXXXXXXX/MALONTIME n" (n in 1/10 secs)
|
||||
sts appMotionLightOnTime, r18
|
||||
sts appMotionLightOnTime+1, r19
|
||||
rjmp AppMotionLight_OnPacketReceived_sendAck
|
||||
AppMotionLight_OnPacketReceived_setSource1:
|
||||
AppMotionLight_OnPacketReceived_setSource1: ; setValue "nodes/XXXXXXXX/MALSOURCE1 0xVVNN" (VV=value id, NN=node addr)
|
||||
sts appMotionLightSources, r18 ; peerAddr
|
||||
sts appMotionLightSources+1, r19 ; valueId
|
||||
rjmp AppMotionLight_OnPacketReceived_sendAck
|
||||
AppMotionLight_OnPacketReceived_setSource2:
|
||||
AppMotionLight_OnPacketReceived_setSource2: ; setValue "nodes/XXXXXXXX/MALSOURCE2 0xVVNN" (VV=value id, NN=node addr)
|
||||
sts appMotionLightSources+APP_MOTIONLIGHT_SOURCE_SIZE, r18 ; peerAddr
|
||||
sts appMotionLightSources+APP_MOTIONLIGHT_SOURCE_SIZE+1, r19 ; valueId
|
||||
AppMotionLight_OnPacketReceived_sendAck:
|
||||
push xl
|
||||
push xh
|
||||
mov r16, r22 ; src address
|
||||
ldi r23, NETMSG_CMD_VALUE_SET_ACK
|
||||
clr r17
|
||||
rcall Main_SendValueResponse ; (clobbers all, including Y)
|
||||
rcall appMotionLightWriteConfToEeprom
|
||||
rcall appMotionLightWriteConfToEeprom ; (r16, r17, X)
|
||||
pop xh
|
||||
pop xl
|
||||
sec
|
||||
|
||||
Reference in New Issue
Block a user