Add ugui stuff for device tests
@@ -1,22 +1,13 @@
|
||||
APPNAME = BootExtract
|
||||
ICONTEXT = "VZBootEX"
|
||||
APPID = Bdmp
|
||||
APPNAME = TstSuite
|
||||
ICONTEXT = "HWTests"
|
||||
APPID = TstS
|
||||
|
||||
SRCS = bootloaderExtractor.c
|
||||
SRCS = testSuite.c ugui.c
|
||||
|
||||
# Tool locations
|
||||
ifeq ($(PALM_OS_TOOLCHAIN),)
|
||||
$(error PALM_OS_TOOLCHAIN not defined)
|
||||
endif
|
||||
|
||||
ifeq ($(PALM_OS_RESOURCE_TOOLS),)
|
||||
$(error PALM_OS_RESOURCE_TOOLS not defined)
|
||||
endif
|
||||
|
||||
CC = $(PALM_OS_TOOLCHAIN)/m68k-palmos/gcc295/gcc/gcc-cross -palmos3.5
|
||||
BUILDPRC = $(PALM_OS_TOOLCHAIN)/tools/build-prc
|
||||
PILRC = $(PALM_OS_RESOURCE_TOOLS)/pilrc
|
||||
OBJRES = $(PALM_OS_TOOLCHAIN)/tools/obj-res
|
||||
CC = m68k-palmos-gcc -palmos3.5
|
||||
BUILDPRC = build-prc
|
||||
PILRC = pilrc
|
||||
OBJRES = m68k-palmos-obj-res
|
||||
|
||||
# File names
|
||||
RESFILE = $(APPNAME).rcp
|
||||
@@ -30,8 +21,6 @@ CFLAGS = -O2 -g $(DEFINES) $(INCLUDES)
|
||||
|
||||
# Makefile targets
|
||||
|
||||
all:
|
||||
|
||||
.S.o:
|
||||
$(CC) $(TARGETFLAGS) -c $<
|
||||
|
||||
|
Before Width: | Height: | Size: 190 B After Width: | Height: | Size: 190 B |
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 98 B After Width: | Height: | Size: 98 B |
43
hwTestSuite/testSuite.c
Normal file
@@ -0,0 +1,43 @@
|
||||
#include <PalmOS.h>
|
||||
#include <PalmCompatiblity.h>
|
||||
#include <stdint.h>
|
||||
#include <ugui.h>
|
||||
|
||||
uint8_t* framebuffer;
|
||||
|
||||
|
||||
void uguiDrawPixel(UG_S16,UG_S16,UG_COLOR){
|
||||
|
||||
}
|
||||
|
||||
void testerInit(){
|
||||
framebuffer = *((uint8_t*)0xFFFFFA00);//lssa
|
||||
KeySetMask(~(keyBitPageUp | keyBitPageDown |
|
||||
keyBitHard1 | keyBitHard2 |
|
||||
keyBitHard3 | keyBitHard4 ));
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
Bool testerFrameLoop(){
|
||||
|
||||
}
|
||||
|
||||
void testerExit(){
|
||||
|
||||
}
|
||||
|
||||
DWord PilotMain(Word cmd, Ptr cmdBPB, Word launchFlags){
|
||||
Bool running = true;
|
||||
testerInit()
|
||||
|
||||
while(running){
|
||||
running = testerFrameLoop();
|
||||
usleep(333333);//30 fps
|
||||
}
|
||||
|
||||
testerExit();
|
||||
return(0);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
ICONFAMILY "icon_1.bmp" "icon_2.bmp" "icon_4.bmp" "icon_8.bmp"
|
||||
SMALLICON "icon_sm.bmp" // icon for P3 list view
|
||||
|
||||
APPLICATION ID 1 "Bdmp"
|
||||
VERSION ID 1 "1.03"
|
||||
APPLICATION ID 1 "TstS"
|
||||
VERSION ID 1 "1.00"
|
||||
8237
hwTestSuite/ugui.c
Executable file
1052
hwTestSuite/ugui.h
Executable file
63
hwTestSuite/ugui_config.h
Executable file
@@ -0,0 +1,63 @@
|
||||
#ifndef __UGUI_CONFIG_H
|
||||
#define __UGUI_CONFIG_H
|
||||
|
||||
/* -------------------------------------------------------------------------------- */
|
||||
/* -- CONFIG SECTION -- */
|
||||
/* -------------------------------------------------------------------------------- */
|
||||
|
||||
//#define USE_MULTITASKING
|
||||
|
||||
/* Enable color mode */
|
||||
//#define USE_COLOR_RGB888 // RGB = 0xFF,0xFF,0xFF
|
||||
#define USE_COLOR_RGB565 // RGB = 0bRRRRRGGGGGGBBBBB
|
||||
|
||||
/* Enable needed fonts here */
|
||||
#define USE_FONT_4X6
|
||||
//#define USE_FONT_5X8
|
||||
//#define USE_FONT_5X12
|
||||
//#define USE_FONT_6X8
|
||||
//#define USE_FONT_6X10
|
||||
//#define USE_FONT_7X12
|
||||
//#define USE_FONT_8X8
|
||||
//#define USE_FONT_8X12_CYRILLIC
|
||||
//#define USE_FONT_8X12
|
||||
//#define USE_FONT_8X12
|
||||
//#define USE_FONT_8X14
|
||||
//#define USE_FONT_10X16
|
||||
//#define USE_FONT_12X16
|
||||
//#define USE_FONT_12X20
|
||||
//#define USE_FONT_16X26
|
||||
//#define USE_FONT_22X36
|
||||
//#define USE_FONT_24X40
|
||||
//#define USE_FONT_32X53
|
||||
|
||||
/* Specify platform-dependent integer types here */
|
||||
|
||||
#define __UG_FONT_DATA const
|
||||
typedef uint8_t UG_U8;
|
||||
typedef int8_t UG_S8;
|
||||
typedef uint16_t UG_U16;
|
||||
typedef int16_t UG_S16;
|
||||
typedef uint32_t UG_U32;
|
||||
typedef int32_t UG_S32;
|
||||
|
||||
|
||||
/* Example for dsPIC33
|
||||
typedef unsigned char UG_U8;
|
||||
typedef signed char UG_S8;
|
||||
typedef unsigned int UG_U16;
|
||||
typedef signed int UG_S16;
|
||||
typedef unsigned long int UG_U32;
|
||||
typedef signed long int UG_S32;
|
||||
*/
|
||||
|
||||
/* -------------------------------------------------------------------------------- */
|
||||
/* -------------------------------------------------------------------------------- */
|
||||
|
||||
|
||||
/* Feature enablers */
|
||||
#define USE_PRERENDER_EVENT
|
||||
#define USE_POSTRENDER_EVENT
|
||||
|
||||
|
||||
#endif
|
||||
@@ -1,71 +0,0 @@
|
||||
#include <PalmOS.h>
|
||||
//#include <PalmCompatibility.h>
|
||||
//#include <System/DLServer.h>
|
||||
|
||||
|
||||
static Boolean StartApplication(void);
|
||||
static void EventLoop(void);
|
||||
|
||||
|
||||
static Boolean MyHandleEvent(EventType* event){
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/////////////////////////
|
||||
// EventLoop
|
||||
/////////////////////////
|
||||
|
||||
static void EventLoop(void){
|
||||
EventType event;
|
||||
Word error;
|
||||
|
||||
do{
|
||||
EvtGetEvent(&event, 1);
|
||||
|
||||
if(!SysHandleEvent(&event)){
|
||||
if(!MenuHandleEvent(0, &event, &error)){
|
||||
if(!MyHandleEvent(&event)){
|
||||
FrmDispatchEvent(&event);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
while(event.eType != appStopEvent);
|
||||
}
|
||||
|
||||
/************************************************************/
|
||||
/** global init and cleanup */
|
||||
static Boolean StartApplication(void) {
|
||||
|
||||
/* Mask hardware keys */
|
||||
KeySetMask(~(keyBitPageUp | keyBitPageDown |
|
||||
keyBitHard1 | keyBitHard2 |
|
||||
keyBitHard3 | keyBitHard4 ));
|
||||
|
||||
SysRandom(TimGetTicks());
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static void StopApplication(void){
|
||||
|
||||
|
||||
}
|
||||
|
||||
/////////////////////////
|
||||
// PilotMain
|
||||
/////////////////////////
|
||||
|
||||
DWord PilotMain(Word cmd, Ptr cmdBPB, Word launchFlags){
|
||||
if (cmd == sysAppLaunchCmdNormalLaunch){
|
||||
if(StartApplication()){
|
||||
EventLoop();
|
||||
StopApplication();
|
||||
}
|
||||
}
|
||||
return(0);
|
||||
}
|
||||
|
||||