About These PagesPalm E

This set of pages has scientifically oriented freeware available for download, and discusses Palm OS program development for the beginner.

The freeware is six released application and one tool kit. Their descriptions follow.

Writing your own Palm OS applications is discussed below for those who wish learn how to:

New Web Applications


When you are not near your Palm but can get on the internet, versions of the following application are now avaiable:

Try them out and if like what you see, bookmark them in your browser.
More of applications will be converted for internet access.

Freeware


GreatCircle Application Version 2.0   Bld:404
Bld:404 -- Major update. More accuracy, units and decimal digits.
Bld:331 -- Allow From/To locations in different databases.
Bld:316 -- An update for OS4/5 compatibility.
Bld:315 -- Allows multiple databases.
Bld:309 -- Bug fix in From:/To:
Bld:307 -- Version 1.3 is updated to work with GeoDB Version 1.1.

GreatCircle works in conjunction with GeoDB to display distance and bearing between two Earth locations.
Manual location data input is also allowed.

Version 2.0 is a major update aimed at the Geocaching user. Featuring location input with pen and database, higher accuracy with more choice of units and precision.


GreatCircle Main Display. GreatCircle displays the following data:
  • latitude and longitude of two earth locations -- selected from a GeoDB database or manually entered.
  • The great circle distance between the locations in either: kilometers, nautical miles, miles, meters or feet; and a selection value precision.
  • The great circle bearing angle from the 'From' locations to the 'To' location.

If you would like to learn more about GreatCircle, Click Here to read the documentation which comes in the application archive.

The GreatCircle Application Download

Version 2.0 Bld:404 is available. If you would like to try it you may Download GreatCircle. It is freeware offered for your enjoyment.
Please read gc.html (which is in the gc20.zip archive) using your internet browser, for instructions on installation and program usage.


GeoDB Application Version 1.1   Bld:704
Bld:402 -- Minor bug fix.
Bld:316 -- An update for OS4/5 compatibility.
Bld:315 -- Allows multiple databases.
Bld:309 -- Import/Export from memo added.
Bld:704 -- 2007 North American daylight savings rules.

GeoDB Data Display. GeoDB is a database application that holds earth location data. It makes the locations available to be imported into applications.
GeoDB stores the following data:
  • Latitude and longitude of an Earth location, stored to high precision.
  • The time zone data in the form of time offset from Greenwich.
  • The elevation.
  • The rules for computing daylight time.

Version 1.1 allows locations to be organized into multiple databases.
You can build these databases on your Palm by importing comma separated value (CSV) memos from the Palm's MemoPad and/or by installing pre-made database that you have already made or obtained from others.

By storing ones favorite locations in GeoDB it is a trivial task to change the reference for Earth & Sun, GeoMagneticInfo, or any of the three stored location in RiseSet. An additional feature provides the computation of Daylight Time when a location is imported. GeoDB returns the state of daylight time to the importing application.

Its is also easy to compute great circle distances with GreatCircle and GeoDB.

All three of the geographic Palm applications below will import location data from GeoDB.
GeoDB may be used by other Palm application authors who wish to take advantage of a high precision location database.

To assist in making databases GeoDBData.zip is included in this distribution.
A much more complete set of data and tools for creating GeoDB database is available for download. It is GeoDB Tools. See its discussion below.

If you would like to learn more about GeoDB, Click Here to read the documentation which comes in the application archive.

The GeoDB Application Download

Version 1.1 Bld:702 is now available. If you would like to try it you may Download GeoDB. It is freeware offered for your enjoyment.
Please read geodb.html (which is in the geodb11.zip archive) using your browser, for instructions on installation and program usage.

NOTE: The GreatCircle application has been affected by the update of GeoDB to V1.1. If you have GreatCircle V1.2 installed in your Palm OS please update it now!


GeoDB Tools Version 1.0   Bld:402
Bld: 402 -- Minor change to csv2gdb to truncate long file names.
Bld: 331 -- Europe database is included.
Bld: 330 -- Original version.

GeoDB Data Tools are an adjunct to Palm OS GeoDB application.

The GeoDB Data Tools archive provides world wide location data and GeoDB databases, as well as PC tools to work with GeoDB and with GPS devices.

The provided databases include over 700 world wide locations in both text, CSV form, and 9 ready to install GeoDB databases.

The provided PC tools are four PC applications to:

If you would like to learn more about GeoDB Tools, Click Here to read the documentation which comes in the archive.

The GeoDB Tools Download

Version 1.0 Bld:402 is now available. If you would like to try it you may Download GeoDB Tools.
It is freeware offered for your enjoyment.
Please read geodbtools.html (which is in the geodbtools10.zip archive) using your browser, for instructions about the data and program usage.


Earth&Sun Application Version 2.0   Bld:340
Bld:340 -- A minor Palm GUI update.
Bld:320 -- A bug fix update.
Bld:316 -- Changes to improve OS4 compatibility

Earth&Sun 1X Map Display Earth&Sun is a program for the Palm OS to show the Sun Illuminated area of the Earth. It will also display:
  • The latitude and longitude of an Earth location.
  • The time zone at that location, based on only longitude not civil boundaries.
  • The current time at that location based on the above time zone.
  • The sunrise, sunset times, and day length at that location.
  • The great circle distance between two locations on the earth.
Earth&Sun 4X Map.

Version 2.0:

Because of time zone irregularities some will consider Earth&Sun to fall into the category of "fun and games". With well over 100,000 downloads to date, Earth&Sun has been well accepted.
We hope you find Earth&Sun useful and enjoy it in any event.

If you would like to learn more about Earth&Sun, Click Here for the description which comes in the program archive.

The Earth&Sun Application Download

Version 2.0 Bld:340 is now available. If you would like to try Earth&Sun you may Download Earth&Sun. It is freeware offered for your enjoyment.

You must read earth&sun.html (which accompanies earth20.prc in the earth20.zip archive) for instructions on installation and program usage.


Earth&Sun Color Application Version 2.0C   Bld:340
Bld:340 -- A minor Palm GUI update.
Bld:320 -- A bug fix update.
Bld:318 -- Brighter colors.

Earth&Sun 1X Map Display Earth&Sun Color is for Palm OS users who have a color capable handheld.
This version will run in any Palm OS 3.5 and greater, but you should use the above monochrome V2.0 if you do not have a color handheld. V2.0C requires considerable more Palm memory than V2.0.

The Earth&Sun Color Application Download

Version 2.0C Bld:340 is now available. This requires Palm OS 3.5 and greater.
If you would like to try Earth&Sun Color you may Download Earth&Sun Color. It is freeware offered for your enjoyment.
You must read earth&sun.html (which accompanies earth20c.prc in the earth20c.zip archive) for instructions on installation and program usage.


RiseSet Application Version 2.1   Bld:316
Bld:316 -- An update for OS4/5 compatibility.

RiseSet Moon Display


The RiseSet Application is a program for the Palm OS to compute the rise, transit and set times for the Sun and the Moon. Any date and user location may be specified. The programs stores three locations for quick access to favorite locations on the earth.


RiseSet has good accuracy for visual sighting. The actual sun times should be within a few seconds of the time shown. The moon times are given to the second, but the actual time could be ± a minute.



The program also gives: RiseSet Sun Display

Version 2.1 is compatible with GeoDB.

If you would like to learn more about RiseSet and changes to Version 2.1, Click Here for the documentation which comes in the program archive.

The RiseSet Application Download

Version 2.1 Bld:316 is now available. If you would like to try it you may Download RiseSet. It is freeware offered for your enjoyment.
You must read riseset.html (which is in the risest21.zip archive), using your browser for instructions on installation and program usage.


GeoMagnetic Info Application Version 1.3   Bld:344
Bld:344 -- Added ability to select the active Geomagnetic Model.

GeoMagnetic Info Display GeoMagnetic Info is an application for the Palm OS to compute the magnetic declination, inclination, and magnitude for any location on Earth.
It displays:
  • the magnetic declination,
  • the magnetic inclination, and
  • the magnetic intensity at the specified latitude and longitude.

A magnetic compass reading can be corrected to the direction relative to true north by adding the declination to the compass reading.

If you still have GeoMagnetic Info Version 1.0 in your Palm you should replace it with this new version for use with RiseSet version 2.1. See the following description for an explanation of this new version.

The Version 1.3 is compatible with GeoDB.

If you would like to learn more about GeoMagnetic Info Click Here for the description which comes in the program archive.

The GeoMagnetic Info Application Download

Version 1.3 Bld:344 is now available. If you would like to try GeoMagnetic Info you may Download GeoMagnetic Info. It is freeware offered for your enjoyment. You must also download new Geomagnetic Models discussed in the next paragraph.
Read geomaginfo.html in the 2010GeomagModels.zip archive for instructions on installation and program usage for GeoMagnetic Info.

New 2010 Geomagnetic Models

Geomagnetic Models are published, and accurate for a 5 year period. To-date only WMM-2010 and IGRF-2010 are available.

You must Download the newest available models. Instructions (geomaginfo.html) are enclosed in this .zip archive.


Formula Calculator Application Version 1.1   Bld:340
Bld:340 -- Added Clear Regs command (clear all registers)
Bld:335 -- Added scientific notation and 15 digit precision.

FormulaCalc Display FormulaCalc is a general purpose calculator which accepts algebraic formulas and computes their values. The formulas:
  • Use common algebraic expressions with the normal multiply before add rules.
  • Can have up to 26 inputs from stored data.
  • Can store results in up to 26 storage locations.
  • Can use trigonometric, logarithmic, and other algebraic and control functions.
  • Input can be by pen graffiti or from a Memo Pad memo.

It can be used as a simple calculator, or one to compute complicated routines which can be stored in a memo of the Palm OS Memo Pad.

If you would like to learn more about FormulaCalc Click Here for the description which comes in the program archive.

The FormulaCalc Application Download

If you would like to try FormulaCalc you may Download FormulaCalc.
It is freeware offered for your enjoyment.
Read FormulaCalc.html for instructions on installation and program usage which accompanies frmclc11.prc in the frmclc11.zip archive.



Palm OS Program Development


Palm OS Program Development with PRC-Tools for the Beginner

Program development for the Palm OS is surprisingly easy for a C programmer, with the exception of floating point. But even that is easy once you find out what to do.

Best of all the compiler is free software.

I am using Windows 98, so everything I say about the operating system and directories applies to that platform.

Installing PRC-Tools

Before you can write your own Palm applications you need a compiler. The installation of the PRC-Tools compiler for the Palm turns out to be not as trivial a task as one might wish for. Here are detailed instructions to install PRC-Tools Version 2.1.

Creating your First Program

  1. Read Andrew Howlett's PRC-Tools Tutorial. It is excellent! (Thanks Andrew.)

  2. Use his text2hex.c as a basis of your first program. You should change the resources, and text printing etc.

  3. Use the documentation you can get from Palm OS. It will be located somewhere in the ....OS document directory.

  4. You can get additional help by download freeware programs which include their software. The notable ones for getting started which I have used are: Digi-Guppie, Battery Meter, Neko.

  5. Much more information can be found in the pilot.programmer.gcc newsgroup.

Using Floating Point

First you can use GNU C++ type double instructions just as with any C program for the Intel processors. In particular you can cast integers and longs to doubles, vise versa. However, you cannot use sprintf and some other I/O instructions. The Palm OS does not support conversion of double to strings with 'normal' GNU C++ functions. The other problem is that Palm OS does not have support for many floating point and transcendental functions.
Specifics
  1. StrPrintF. First we should discuss printf() and sprintf(). You cannot use them, but you can use the PalmOS function:
    SWord  StrPrintF(CharPtr s, const Char* formatStr, ...). Be sure to: #include <System/StringMgr.h>
    This does simple sprintf conversions with: %d, %i, %u, %x and %s with the only format specification of l (long). In particular do not use conversions of the form "%02d" (It works with PalmOS 3.0 but not earlier versions). Thus it does not do doubles.

  2. MathLib. It is hard to believe that if you use floating point instructions that you won't need a math library. So you should get it to have available. Get MathLib -- created by Rich Hoebner (Thanks Rich).
    To use it you simply: #include "MathLib.h" in your program and compile: mathlib.c with your program.
    MathLib and an example of its use is available (See downloads below).

  3. System/NewFloatMgr.h. For floating point computation using only the Palm OS routines, you must include a special header: #include <System/NewFloatMgr.h>. But I stress that you only need this need when you are making your own floating point routines. And if you are using the older GCC compllier -- Not PRC-Tools.
    This is provided with the headers in both GNU and PalmSDK ..../system/include directories after you install them. BUT, in some distributions the supplied System/NewFloatMgr.h is faulty. It would appear that someone saved it from a wordprocessor and mangled the line structure. However, Mike Kit (Thanks Mike -- we needed that) posted a properly formatted one on the pilot.programmer.gcc newsgroup (See downloads below). Download it and put it in ..../GNU/mk68k-palmos-coff/include/PalmOS/System.
    Once that is done you should be able to compile specialized floating point.

    When you look in NewFloatMgr.h you will see some intriguing looking function calls, but you can't use most of them unless you create specialized routine.
    The best thing to do is it stick to what you normally use in C++ and create your own conversion routines or the ones provided here and by other developers, and use MathLib for most floating point functions.

    If you would like to investigate creating your own floating point routines which require NewFloatMgr.h you should get EasyCalc found on most Palm software archives. It comes with complete source and a number of routines requiring NewFloatMgr.h. Also http://www.lispme.de/lispme/gcc/tech.html has some interesting examples.

  4. My Conversion Routines.

    I created two sets of floating point routines to convert: double to string, and string to double. These routines are discussed next and a complete program using these routines is available for download below.

    1. Double to String. There are two versions of this conversion. One is for fixed point notation, and the other is for scientific notation. The prototypes are:
      void doubleToStr(CharPtr str, double flpNumber, Int numFractDigits), and
      void doubleToStrScientific(CharPtr str, double flpNumber, Int numFractDigits).

      Given a string to put the result, the double to convert, and the number of fractional digit to display -- it will return the string which represents the double. doubleToStr() is of the format: ddd.fff, and doubleToStrScientific() is of the format: d.fffexx.
      Click here to view doubleToStr routines.

    2. String to Double. There are two versions of this conversion. One allows input of fixed point notation, and the other allows fixed and scientific notation. The prototypes are:
      double strToDouble(CharPtr str), and
      double strToDoubleScientific(CharPtr str).

      Given the string convert each returns a double which represents the string. strToDoubleScientific() allows input of either ddd.fff and ddd.fffexx
      Click here to view strToDouble routines.

Floating Point Related Download Files

Creating Your Own Shared Library

These examples only compile with the old GCC Palm Compiler m68k-palmos-coff-gcc V0.5.0. A version for Prc-Tools will be available here soon.

The following Example Shared Library archive -- exshlib.zip -- is a set of 12 files to help you create your own shared library for the Palm.

exshlib.zip contains a discussion of how to create a shared library and a set of two C programs: a shared library and a calling application, along with the make files and an auxiliary program. This should be enough information for you to created your own shared library.


This page was last updated on August 20, 2009

There have been visitors to this page since January 10, 1999.

Comments to David

Back Icon Go to the Public Service Page

Bray Coat-of-Arms David W. Bray, Potsdam, NY 13676