fixed return values.

This commit is contained in:
Martin Preuss
2025-04-21 00:36:07 +02:00
parent b2a087c959
commit 16a6bb08b5

View File

@@ -124,10 +124,14 @@ MotionLight_OnPacketReceived:
breq MotionLight_OnPacketReceived_report
cpi r16, CPRO_CMD_VALUE_SET
breq MotionLight_OnPacketReceived_set
MotionLight_OnPacketReceived_clcRet:
clc ; unexpected msg
ret
MotionLight_OnPacketReceived_report:
rcall CPRO_ReadValue ; (none)
mov r16, r18
or r16, r19
breq MotionLight_OnPacketReceived_clcRet ; zero value, ignore
rcall motionLightHasSource ; (r16, r24, Y)
brcs MotionLight_OnPacketReceived_turnOn
ret