Re: Re: Newbie: Whats up with PalmOS Databases

2003-01-11 Thread kcorey
On Sat, 2003-01-11 at 02:07, Joe Biron wrote:
 So I'm wondering how this simple app will play out as a database. Is it 2
 databases? One for the exercise names and one to track the sets? and would I
 store the record index

You could do it as two databases, or you could put all the records in
one database, and use categories to differentiate between them.

 And one more question - do records need to be of a uniform size? Looking at
 the API it seems that I can put a variable amount of information in a
 record. Is this true? What if I put a variable size array right in a record?
 Can I do that? Obviously I'd need to store the size somewhere in the
 beginning of the record.

Records are simply piles of bits.  They can be variable length.  You
define the functions that are called to sort and access the records, so
its up to you what form they take.

Setting up a comparison callback for the first time is a bit of a pain,
but it gives you a huge amount of flexibility.

 Just trying to get a handle on things (no pun intended). I was a bit
 disappointed with the PalmOS Companion documents. No big-picture overview.
 Can anyone recommend a good resource?

I've gotten a *lot* of help from the O'Reilly book Palm Programming by
Neil Rhodes and Julie McKeehan. I've not read the others, so I can't
compare them.

-Ken







-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Re: Interesting alternative to tabs...

2003-01-11 Thread kcorey
On Sat, 2003-01-11 at 00:23, Matthew Bevan wrote:
  Why not use a popup list box on upper right corner?
  See Pref application to have an idea.
 
 Because this is a modal dialog, there is no space there for me to put it.

In general, wouldn't it be a good idea to follow the interface examples
of the operating system as much as possible?

So why make it a modal dialog? Why not make it a regular dialog? This is
not as crazy as it might first sound.

On a Windows/Mac/Linux box, there's a huge difference between a modal
and a non-modal dialog.  The rest of the applications don't get events,
the display can be frozen, etc.

It seems to me that on a Palm Pilot, the difference to the user is
simply the decoration around the box.

Alternatively, if it *must* be a modal dialog, try out the preferences
dialog on a tungsten (not the OS 5 Simulator which uses the old style). 
It uses pushbuttons as the tabs, and a listbox of items to select.  tap
on a pushbutton, and the list changes.  Tap on a list item, and the
control panel for that item is displayed.

-Ken






-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



RE: Allocate more than 64K of heap memory

2003-01-11 Thread Ron Nicholson
To allocate more than 64k of heap memory, why not just ask for a
very large bitmap, and let the system allocate the memory for you?

myBitmapPtr = BmpCreate ( /* big enough dimensions */  );
if (myBitmapPtr) {
memPtr  = BmpGetBits(myBitmapPtr);
// etc.

This seems to work under both OS 4.1 and 5.  The system will never
know that you're using bitmap memory for stuff that'll never be
displayed.

Ron Nicholson
HotPaw
   http://www.hotpaw.com/rhn/hotpaw

--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/



Small text on Sony hires and in OS 5

2003-01-11 Thread RaNo
Hello!
How to draw a small text (low density) on Sony hires?
How to draw a small text (low density) in OS 5?
(so that twice as much text fits in one line)


--
Radoslaw Nowak, RNS::
www.ranosoft.com/palm


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Allocate more than 64K of heap memory

2003-01-11 Thread Aaron Ardiri
 To allocate more than 64k of heap memory, why not just ask for a
 very large bitmap, and let the system allocate the memory for you?
 
  myBitmapPtr = BmpCreate ( /* big enough dimensions */  );
  if (myBitmapPtr) {
  memPtr  = BmpGetBits(myBitmapPtr);
  // etc.
 
 This seems to work under both OS 4.1 and 5.  The system will never
 know that you're using bitmap memory for stuff that'll never be
 displayed.

the code i have does exactly the same thing 
it just doesn't have the bitmap wrapper around it.

---
Aaron Ardiri   [EMAIL PROTECTED]
CEO - CTO  +46 70 656 1143
Mobile Wizardry http://www.mobilewizardry.com/




-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Allocate more than 64K of heap memory

2003-01-11 Thread Aaron Ardiri
 Then you should be worried about using this approach on a Palm OS 
 5.x device.  You are creating the chunk, but the system thinks it 
 owns it.  At the very least, this means that the system won't clean 
 up after your application after it quits or crashes and you don't 
 free the chunk yourself.  But there could be other problems, too, 
 with the system thinking that it owns the chunk and not you.

its a potential problem if you dont call free when your app exits :)
but, horace isn't going to forget that now is he? :) its a solution
that works; its not fool proof.. but, it works *g*

i am sure it may need modification at a later date, but, at least
you have a function for doing it. when it needs to be changed, we 
can just change the function.

---
Aaron Ardiri   [EMAIL PROTECTED]
CEO - CTO  +46 70 656 1143
Mobile Wizardry http://www.mobilewizardry.com/


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Convert Palm App to WindowsCE App

2003-01-11 Thread Steve Jerrett
Unfortunately, they do not mention ARM or Palm OS 5.0 on their site (you 
have to get to the tutorial to find this out). They do seem to utilize 
Cygwin B20, PRC Tools 2.0 and the Palm SDKs 3.1-4.0.

Chris Tutty wrote:
This keeps coming back to APPFORGE.  It truly seems to have the control,
So, are there more to look at?



I think www.penright.com is another tool that fits your requirements.

Chris Tutty





--
Steve Jerrett
Systems Analyst
City of Columbia, MO


--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/



RE: Newbie: Whats up with PalmOS Databases

2003-01-11 Thread Jeff Wheeler
Joe Biron wrote:
 I was a bit disappointed with the PalmOS Companion 
 documents. No big-picture overview. Can anyone recommend 
 a good resource?

- Palm OS Programming for Dummies (Liz O'Hara, John Schettino)
It's out of print and was written before OS4. However, I found it to be a
great introduction.

- Palm OS Programming Bible (Lonnon Foster)
More in depth than the dummies book.

Both give good examples of the Palm database concept and how to use them.

Go to amazon.com and search for something like Palm OS Programming, then
read the reviews to find something that you think will suit your needs.

Jeff
 





-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Re: Idea for a Tungsten App?

2003-01-11 Thread Stringer
Subject: Re: Re: Idea for a Tungsten App?
From: Aaron Ardiri [EMAIL PROTECTED]

  I don't have a Tungsten handy, but I thought
  I read that holding down the middle button of
  the 5-way navigator launches the launcher?
 
 Well it does, much of the time, but doesn't seem to be quite the same
 action as pressing the silkscreen button.  If the application (usually a
 game) blocks the hard keys from the system, then this doesn't work 
 any more.
 
 Send an e-mail to the game developer telling them they are
 not Tungsten-T compatible!  Ask them when they are
 going to fix it!

we override the 5-way navigator holding down feature in our 3D engine.
mainly cause you use the select button to blast your enemies apart. i
am sure the % of users being annoyed for the app jumping out to the 
launcher while trying to frag someone is greater than those wanting
to use the 'holding' feature to exit the app :)


Perhaps it should be part of the Palm OS UI guidelines:
Display and service an [exit] button when your program doesn't 
support the 5-way exit option.

Roger Stringer
Marietta Systems, Inc.  (www.RF-TP.com)


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



RE: Query regards programming on PDA

2003-01-11 Thread Stringer
Subject: Query regards programming on PDA
From: Sameer Khan [EMAIL PROTECTED]

I thought it would be interesting if there were development tools 
on the PDA itself, so that one could write programs on the 
handheld and compile /execute them. 
Please do let me know if such developments tools exist.


The Design Wizard for our PDE software resides on the Palm OS
unit, which allow you to VERY quickly create (and test) business
applications (Inventory, Order Entry, Delivery, etc).
You can download an Evaluation version from our web site,
or from PalmGear or Handango.
PDE also comes with a pre-built conduit.

Roger Stringer
Marietta Systems, Inc.  (www.RF-TP.com)


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Does stream on Tungsten?

2003-01-11 Thread kcorey
Hi All,

I've got my code successfully compiling against OS5, and when it's run
checking for the existence of the Sound Stream Feature Set, and then
playing a sampled sound during gameplay in the simulator.  This works
like a peach.

The Palm OS 5 documentation I have, however, says that you must check
for the Sound Stream Feature Set using this code:

UInt32 version; 
Err err; 
  
err = FtrGet(sysFileCSoundMgr, sndFtrIDVersion, version); 
if (err) {   
// Sound Stream Feature Set not present 
   if (err == ftrErrNoSuchFeature) {
FrmCustomAlert(errAlert,No Stream Manager., , );
   } else {
FrmCustomAlert(errAlert,Some other problem!, , );
   }
} else { 
// The Sound Stream Feature Set is present. 
   FrmCustomAlert(errAlert,It's here., , );
}

On the simulator, I get 'It's here.'.  On the real Tungsten/T, I get No
Stream Manager errors.

Anyone else see this behavior?  What's the right thing to check
for...OS5?

Anyone know?

-Ken


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: CW compiler

2003-01-11 Thread Jan Slodicka
One more remark:
__lmul__ calls appear only after optimization level 2 is selected. Debug
version and optimization level 1 contain correct muls instructions.
I would qualify it as an optimizer bug.

Acc. to the CW settings dialog it might concern common subexpression
elimination.
How can we change optimization level in the code? (Or better optimization
techniques used.) I could not locate this information among CW pragmas.

Jan Slodicka

(CONST_BITS == 13)

- Original Message -
From: Keith Rollin [EMAIL PROTECTED]


 Just a data point here.

 I tried compiling the sources you posted.  However, you didn't
 provide the value of CONST_BITS you were using.  It looks like your
 snippets are from jidctint.c, so I used the value from that file
 (13).  In both of your examples, I got the direct muls version, not
 the __lmul__ version.

 However, neither did I get the constant #-1730 to show up in my
 disassembly, so perhaps my value of CONST_BITS is incorrect.  The
 difference might also be because of the simpler (extracted) code I
 was using, compared to your using the entire function.

 -- Keith Rollin
 -- Palm OS Emulator engineer



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Any help in synchronisation

2003-01-11 Thread Ezekiel Sunday
I am palm developer who uses Appforge 2.0 to develop my applications.
Sometimes when i do synchronisation i do get this error:unable to open
handheld database

is there any better way i can get this done

-Original Message-
From: Matt Graham [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 10, 2003 16:31
To: Palm Developer Forum
Subject: Re: How do I draw text?


x-precedence:bulk

Eric Marsh wrote:
 I'm using a custom draw function to populate cells in a table. I know 
 how to set up the callback function but being relatively new to Palm 
 programming I don't seem to be able to find any functions that can
draw 
 text as a bitmap.

use WinDrawChars()

pass the top-left of the rectangle pointer as the x,y 
coordinates.

matt


-- 
For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/

--
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Convert Palm App to WindowsCE App

2003-01-11 Thread Palm Dev Forum
Chris,

Very interesting.  Thanks.  In comparison to appforge, it costs around the
same for the dev system, depending on specials and competitive upgrades.
It's runtime costs $70 verses free for palm and $10 for PPC per install.  It
uses C language as it's true programming language vs VB.  It has many more
tools in it's IDE that are not in a CW or MS Visual IDE (appforge uses MS VB
for it's IDE) to assist in RAD.  It's very nice and targets more platforms
(namely, WIN 32, for laptops, tablets, etc.).  It has a nicer way of using
the screen configurations of the different devices in one project - Very
nice feature.

Thanks, now the decision is getting harder.  Any more multiplatform dev
systems?

I'm going to make a comparison chart and post it somewhere, as this info
just doesn't seem to be collected in one place.


Gary Gorsline
Easy Business Software
== End of Message ==

- Original Message -
From: Chris Tutty [EMAIL PROTECTED]
To: Palm Developer Forum [EMAIL PROTECTED]
Sent: Saturday, January 11, 2003 12:57 AM
Subject: Re: Convert Palm App to WindowsCE App


 From: Palm Dev Forum [EMAIL PROTECTED]
  This keeps coming back to APPFORGE.  It truly seems to have the control,
 the
 (snip)
 
  So, are there more to look at?
 
 I think www.penright.com is another tool that fits your requirements.

 Chris Tutty


 --
 For information on using the Palm Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Modal Form without a frame?

2003-01-11 Thread Ben Combee


I've never used LstPopupList(), but I don't suspect it can handle list items
that are both bitmaps and labels, though please correct me if I'm wrong.


It you do an custom drawing routine for your list, you can put whatever you 
want in as the list items.  You will be limited to the space the OS 
allocates for each visible item, but if you can live with an 12 pixel 
height per item, then its a good solution, especially if you have less than 
11 items to pick from and thererfore can avoid the scroll arrows.

--
Ben Combee [EMAIL PROTECTED]
CodeWarrior for Palm OS technical lead
Palm OS programming help @ www.palmoswerks.com 


--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/


Re: CW compiler

2003-01-11 Thread Ben Combee
At 18:54 2003-1-11 +0100, you wrote:

One more remark:
__lmul__ calls appear only after optimization level 2 is selected. Debug
version and optimization level 1 contain correct muls instructions.
I would qualify it as an optimizer bug.

Acc. to the CW settings dialog it might concern common subexpression
elimination.
How can we change optimization level in the code? (Or better optimization
techniques used.) I could not locate this information among CW pragmas.


It probably is an optimization issue -- the optimizer is currently mainly 
tested on 32-bit int platforms, so they may not have caught something that 
results in over-promotion.

To just turn off subexpression elimination, you can use

#pragma opt_common_subs off

Try this and see if it helps.  I'll report this issue to our optimizer guys 
and see what we can do.

--
Ben Combee [EMAIL PROTECTED]
CodeWarrior for Palm OS technical lead
Palm OS programming help @ www.palmoswerks.com 


--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/


Re: Convert Palm App to WindowsCE App

2003-01-11 Thread Ben Combee


The recent Java thread on Palm and PPC targeting, as with old threads,
didn't come up with any conclusive opinions of paths that lead to the
ability of a single source compiling to the different platforms for Java.  I
think the problem here is no common IDE for Java that targets the Palm and
PPC.


CodeWarrior Wireless Studio, PDA Edition, supports J2ME programming, 
including support for Sun's JVM on Palm OS, and several of the VM's on 
Pocket PC.  We've not pushed it very much for Java development on Palm OS, 
due to the limitations of 68K-based Java virtual machines, but it does 
work, and it supplies a RAD environment for J2ME development, while using a 
common IDE with the CodeWarrior for Palm OS tools.

--
Ben Combee [EMAIL PROTECTED]
CodeWarrior for Palm OS technical lead
Palm OS programming help @ www.palmoswerks.com 


--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/


Differences Simulator/Tungsten?

2003-01-11 Thread Tilo Christ
Hello!

I have received numerous reports from owners of Tungsten T 
and NX70V devices that my gaming framework crashes their 
devices. I do not own a real device, but use the Simulators 
(Palm Release and Debug, Sony Clie Release). Even the Debug 
simulator reports no problems with my code (not even a 
direct screen access or anything). Is there anything that is 
more true to the original? Ben Combee mentioned a Tungsten 
simulator for members of the PluggedIn program, but since I 
am not a hardware developer I am not going to get it :-((
I only use OS functionality in the application in question. 
The only exception being a conversion of a bitmap from V2 to 
V3 (the intention here is to enable the use of the same 
hires bitmap resources on Sony Clie and OS5). For this I use 
the same procedure as the BitmapRsc1 sample code does.

Any help will be greatly appreciated. If some kind soul with 
a working debugger and an OS5 device could download the 
framework at www.tilo-christ.de/razor and pinpoint the 
location of the crash this would be highly appreciated.

Cheers,
Tilo


--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/


Cold boot on Tungsten/T doesn't reset everything

2003-01-11 Thread Rob Larson
I've gotten my /T into a knot that cold boot doesn't reset.  Used to be that
I could go to console mode, import some files, start debugging mode, crash,
reset, and restart debugging mode.  Now, even if I don't run my crashing
software, I have to cold boot every time to get to debugging mode.

I'm using PalmDebugger V3.6d7 and a serial cradle.

I've tried to run the battery down to nothing, but that doesn't change
anything.  I'm about to try opening the case to disconnect the battery for a
while in hopes that lack of power will reset whatever the problem is.  I
suppose I could send it in for warranty repair, but if the problem is my
software, then it'll just happen again.

Any advise (don't write buggy software?) would be appreciated.



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



Re: Convert Codepage 932 (Japanese) to Unicode

2003-01-11 Thread James Barwick
Be aware.

Once CP932, always CP932...even in UTF-8.
The UTF8 bytecode is a representation of the character in CP932.
Don't expect that you can go from CP932 to UTF8 to EUC_JP.  Ain't goin'
to happen.

Check out a program called JCode.  It might help you.  I'm running 
into the problem where Linux/Unix is not totally CP932 capable.  I
represent everything as UTF-8...So, all's ok.  But, I can't expect
to convert UTF-8 to CP932 on Unix.  That ain't going to work either.

The PALM handheld is EUC_JP (I'm pretty posstive of that).  When I enter 
japanse on the handheld, sometimes Windows has a problem because the 
character is not in the default CP932 character set (get's converted to ?'s).

Sometimes this happensI am working on this problem.  May be implementing 
JCode in my conduits (I write in Java/Unicode conduits).  I explicitely write 
specify the character set on each of my palms (Japanese, Chinese, Latin, 
Korean, etc.)...so, if you're using Java, then you're set...

You can possibly convert JCode to C if you need to be in C and implement your 
own Unicode conversion routines for a C conduit.

Good luck!

On Fri, 10 Jan 2003 13:23:42 -0500, Sebastian Voges wrote
 Hi Brian
 Brian Rhodes [EMAIL PROTECTED] wrote in message
 news:108398@palm-dev-forum...
 
  Does anyone have any experience converting Japanese characters on the Palm
  to Unicode characters on the PC?
 
  Do I need to just bite the bullet and make my own mapping table?
 
 If you do the conversion on the Windows Desktop, all necessary 
 functions are already provided by the Windows API Look up 
 MultiByteToWideChar/WideCharToMultiByte calls and Unicode and 
 Character Set Functions.
 
 If you want to map on the palm you are on your own...
 
 Regards,
 Sebastian
 
 -- 
 For information on using the Palm Developer Forums, or to 
 unsubscribe, please see http://www.palmos.com/dev/support/forums/





-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



RE: Newbie: Whats up with PalmOS Databases

2003-01-11 Thread dennis
 Joe Biron wrote:
 I was a bit disappointed with the PalmOS Companion
 documents. No big-picture overview. Can anyone recommend
 a good resource?
 ...
 - Palm OS Programming Bible (Lonnon Foster)
 More in depth than the dummies book.

I can also recommend the Foster book.  I've used several others and I found
this book to be the most useful.

The new edition covers 5.0, though I bought the first edition because it
includes a CD of itself (with example code).

Dennis Leas
---
[EMAIL PROTECTED]



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/



RE: Allocate more than 64K of heap memory

2003-01-11 Thread Ken Krugler
Then you should be worried about using this approach on a Palm OS 5.x =
device.  You are creating the chunk, but the system thinks it owns it.  =
At the very least, this means that the system won't clean up after your =
application after it quits or crashes and you don't free the chunk =
yourself.  But there could be other problems, too, with the system =
thinking that it owns the chunk and not you.


AFAIK, for all current versions of Palm OS, a chunk with ID = 0 is 
left alone by the OS. So as Keith notes there's the issue of this 
memory being permanently lost (until a hard reset) if your code fails 
in some manner, but I'm pretty sure there aren't any issues with the 
OS trying to do something to the chunk behind your back.

-- Ken
--
Ken Krugler
http://www.krugler.org
+1 530-265-2225

--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/


Re: Convert Codepage 932 (Japanese) to Unicode

2003-01-11 Thread Ken Krugler
Brian Rhodes [EMAIL PROTECTED] wrote in message
news:108398@palm-dev-forum...



  Does anyone have any experience converting Japanese characters on the Palm

 to Unicode characters on the PC?


  Do I need to just bite the bullet and make my own mapping table?

If you do the conversion on the Windows Desktop, all necessary functions are
already provided by the Windows API
Look up MultiByteToWideChar/WideCharToMultiByte calls and Unicode and
Character Set Functions.


Or you can download the mapping tables from www.unicode.org and write 
the small amount of code required to do the conversion, or you can 
use the ICU code/data that's available as open source from IBM.

If you want to map on the palm you are on your own...


Only if you're running on pre-4.0 devices. On 4.0 and later, 
TxtConvertEncoding supports conversion from the device encoding to 
UTF-8, UTF-16LE, UTF-16BE, and UCS-2.

-- Ken
--
Ken Krugler
http://www.krugler.org
+1 530-265-2225

--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/