avr: added widget SensorWatch
shows a pictogram for a sensor and changes background color according to values received from a given sensor.
This commit is contained in:
@@ -145,6 +145,7 @@ Widget_OnTouch:
|
||||
|
||||
; check for position inside this widget
|
||||
rcall Widget_LoadDisplayRegs ; (R0-R11)
|
||||
rcall Widget_MakeAbsPos ; (R16, R17)
|
||||
rcall Widget_IsPointInRect ; (R16, R17)
|
||||
sbci r16, 0 ; r16=ff if touched inside, 0 otherwise
|
||||
|
||||
@@ -460,6 +461,7 @@ Widget_SubFlags_ret:
|
||||
|
||||
Widget_Clear:
|
||||
rcall Widget_LoadDisplayRegs
|
||||
rcall Widget_MakeAbsPos ; (R16, R17)
|
||||
rcall Widget_GetSdramPtr ; (none)
|
||||
adiw zh:zl, WIDGET_OFFS_OPTS_LO ; get OPTS low
|
||||
lpm r14, Z
|
||||
|
||||
Reference in New Issue
Block a user