1 / 18

Developing/Programming PalmOS Applications CS449 Introduction to Systems Software

Developing/Programming PalmOS Applications CS449 Introduction to Systems Software. Palm Application Development & GUI Programming. C Program hello .c SayHello( MainForm );. C header file hello .h #define MainForm 1000. hello .prc PalmOS executable. Palm Resource file (GUI Elements)

avidan
Download Presentation

Developing/Programming PalmOS Applications CS449 Introduction to Systems Software

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Developing/ProgrammingPalmOS ApplicationsCS449Introduction to Systems Software

  2. Palm Application Development & GUI Programming C Program hello.c SayHello( MainForm ); C header file hello.h #define MainForm 1000 hello .prc PalmOS executable Palm Resource file (GUI Elements) hello.rcp FORM ID MainForm AT (0 0 160 160) USABLE BEGIN TITLE "Hello World" END

  3. Palm Resource file (GUI Elements) • Push buttons • Check boxes • Sliders, scrollbars • LabelsLook Up: • Form bitmaps • TextFields • Forms • Alerts • Menus • Tables • Lists/Popup • Buttons

  4. Compiling & Linking a PalmOS Application (Hello World example) (1) C Compiler m68k-palmos-gcc -c hello.c –o hello.o (2)Post-Processor m68k-palmos-obj-res hello C source code (hello.c) C Object code “Motorola 68000 binary code” m68k-palmos-gcchello.o -o hello Separate code Resources typeXXX.myfile.grc files (type=code, data, pref, rloc) C Preprocessor Header file (hello.h) (4)Build-prc Post-Linker Combine all objects into a binary .prc Palm executable Palm Executable (.prc) build-prc -t appl -o hello.prc -n “Hello” -c *.grc *.bin (3)PilRC hello.rcp UI Resource Compiler Convert .rcp to binary formatted A number of .bin files PalmOS Resource Code (hello.rcp)

  5. Without IDE (Command-line) PRC-tools: m68k-palmos-gcc (C Compiler) m68k-palmos-obj-res (gcc Post-Processor) PilRC (UI Resource Compiler) Build-PRC (PalmOS Post-Linker) Cmd-line debugger Test/Run executable: Simulator Emulator PDA (HotSync) With IDE (GUI) Good Environment to: Edit/Develop Code Build Project Run Step in/out during execution Trace/Report Built-in PRC-tools Built-in Debugger Test/Run executable: Built-in Simulator Built-in Emulator PDA (HotSync) Programming Tools Cygwin Shell PalmOS Developer Studio

  6. Cygwin Shell

  7. Palm Examples: Hello World Program GUI & Run

  8. PalmOS Developer Studio

  9. Makefile-1 • Script file to automate program compilation and linking (making) • Makefile is a list of rules and commands: target : source file(s) command(must be preceded by a tab) CC=gcc CFLAGS=-g hello: hello.c $CC $(CFLAGS) -ohello hello.c

  10. Makefile-2 PalmOS Application Makefile

  11. Examples:1.CS Calculator

  12. Example-2:IR Chat Program - Serial Communications using IR/Serial Ports

  13. Example-3:Attack Game - Serial Communications

  14. Example-4:GPad Program - Communicating over a network with TCP/IP

  15. Example-5:VFS Program – Virtual File System

  16. Example-5:VFS Program – Virtual File System

  17. Palm OS Architecture Applications User Mode Library (Managers) Memory Manager Window Manager Database Manager Comm. Manager VFS Manager … Operating System Kernel Kernel Mode Hardware

More Related