avr: removed old GUI code, renamed gui2 to gui
This commit is contained in:
56
avr/modules/lcd2/gui/generic/rootwidget.asm
Normal file
56
avr/modules/lcd2/gui/generic/rootwidget.asm
Normal file
@@ -0,0 +1,56 @@
|
||||
; ***************************************************************************
|
||||
; copyright : (C) 2026 by Martin Preuss
|
||||
; email : martin@libchipcard.de
|
||||
;
|
||||
; ***************************************************************************
|
||||
; * This file is part of the project "AqHome". *
|
||||
; * Please see toplevel file COPYING of that project for license details. *
|
||||
; ***************************************************************************
|
||||
|
||||
#ifndef AQH_AVR_GUI2_ROOTWIDGET_ASM
|
||||
#define AQH_AVR_GUI2_ROOTWIDGET_ASM
|
||||
|
||||
|
||||
; ***************************************************************************
|
||||
; defines
|
||||
|
||||
; RootWidget in flash
|
||||
.equ ROOTWIDGET_OFFS_BEGIN = WIDGET_SIZE
|
||||
.equ ROOTWIDGET_OFFS_APP_LO = ROOTWIDGET_OFFS_BEGIN+0
|
||||
.equ ROOTWIDGET_OFFS_APP_HI = ROOTWIDGET_OFFS_BEGIN+1
|
||||
.equ ROOTWIDGET_SIZE = ROOTWIDGET_OFFS_BEGIN+2
|
||||
|
||||
|
||||
|
||||
; ***************************************************************************
|
||||
; code
|
||||
|
||||
.cseg
|
||||
|
||||
|
||||
|
||||
; ---------------------------------------------------------------------------
|
||||
; @routine RootWidget_GetApp @global
|
||||
;
|
||||
; @param Z byte address of object (for LPM!)
|
||||
; @return R19:R18 byte address pointer to GuiApp
|
||||
; @clobbers none
|
||||
|
||||
RootWidget_GetApp:
|
||||
bigcall OBJ_IsObject ; (none)
|
||||
brcc RootWidget_GetApp_ret
|
||||
adiw zh:zl, ROOTWIDGET_OFFS_APP_LO
|
||||
lpm r18, Z+
|
||||
lpm r19, Z
|
||||
sbiw zh:zl, ROOTWIDGET_OFFS_APP_LO+1
|
||||
sec
|
||||
RootWidget_GetApp_ret:
|
||||
ret
|
||||
; @end
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user