Home | Stories | Reviews | TreoCast | Treo Store | Accessories | Software | Discussion | Mobile | About | Search
 
treocentral.com >> Products & Reviews >> Software
NS Basic/Palm

Sun Sep 24, 2000 - 2:25 PM EDT - By Scott Hanselman

C vs. BASIC

I have been programming in Visual Basic for a number of years, so the derivative of BASIC used NS Basic was very familiar.  BASIC is well known for its gentle learning curve, and once you know one style of BASIC you can become proficient in others quickly.

NS Basic Applications don't produce a complete self contained Palm Application (PRC) when they compile.  Just like Microsoft's Visual Basic, the code produced when compiling is an intermediate form that is examined at runtime.  I like to think of it as apples turning into applesauce, on its way to being apple juice. They require an 83K runtime PRC as well.  With many Pilots having 8 MBs of RAM, this isn't the big deal it once was.  Of course, all your NS Basic Apps use the same Runtime, so it's only installed once.  Separate from the runtime, NS Basic apps tend to be very small.

 Having use Sun's KJava for Palm, I expected the NS Basic Applications to run very slowly, however I was pleasantly surprised at their responsiveness.  For most data entry and reporting applications the speed is very near the speed of the built in apps.

The hypothetical example below shows the code it would take to copy a string from a database structure into a Text Field.  As you can see, NS Basic takes care of pretty much all the memory allocation and de-allocation, as well as abstracting you from much of the Palm OS' distinctions between non-movable handles to memory, and locked pointers.
 

Metrowerks C

h = MemHandleNew (StrLen (recordP.somestring)  + 1);
p = MemHandleLock (h);
StrCopy (p, recordP.somestring);
MemPtrUnlock (p);
fld = GetObjectPtr (fldSomeField);
FldSetTextHandle (fld, h);
 

Same code using NSBasic/Palm

Result = fieldSetText("fldSomeField", recordP.somestring)

Table 1: Setting a Text field to a string from a database

User Interface – Forms and Buttons

Your form layout work will be done in NS Basic's combination code and form designer development environment. The main window shows the Pilot's screen layout on the left and the “project explorer” on the right. The editor presents a Pilot's screen and a palette of controls to choose from.  You just click and drag lists, buttons, checkboxes and more from the palette to design your forms.

My initial idea was to port (write again) my application, GlucoPilot, from C to NS Basic.  However, missing from the Palette was a Table control.  The folks as NS Basic said that Pilot Tables have a few problems with them, and that makes it “hard to make it easy.”  Their goal with NS Basic was to make the environment as powerful as possible without sacrificing ease of use, and tables did just that.  I was told they would be revisiting the issue soon, but for now I should redesign my user interface given the available controls.  GlucoPilot is a very table-centric application, so I scrapped that idea, rather than re-design it.  I could have certainly replaced my table with a “master-detail” style form, with a list at the top of the form, and controls at the bottom.  NS Basic is very well suited for these kinds of applications, and much sample code is included.

Other than the tables issue, my only real complaint with the User Interface editor was that the forms you design don't EXACTLY match the result.  They are close, but not down to the pixel.  For most apps this won't be a problem, but since the Pilot only has a 160x160 screen, sometimes every pixel counts.


Figure 1: The NS Basic/Palm Desktop and the resulting app

Next Page: Dev Environ. & Conclusion >>

 
User Opinions
Thumbs Up 57% Thumbs Down 43%

Read Opinions (7)


Would you recommend NS Basic/Palm?
Yes   No  

Product Info
Details
» Name NS Basic/Palm
» Company NS Basic Corporation
» Fact Sheet & User Opinions
Availability
» Available
Pricing
» $99.95

References
Actions
» Print this page
» Digg!





Cases

Chargers

Bluetooth

Headsets

Keyboards

Memory
Protectors Cradles
Styli


More Treo Accessories

1200mAh Battery
Palm 1200mAh Battery for Treo 750, Treo 680
Extend your talk time!
Just $14.95 BUY

More Batteries
1150 mAh Battery
Palm 1150 mAh Battery for Centro, Treo 800w
More talk time!
Just $29.95 BUY

More Batteries
MicroUSB High Performance Car Charger
Motorola MicroUSB High Performance Car Charger for Treo Pro, Treo 800w
Unique lens illuminates when plugged in!
Just $14.95 BUY

More Car Chargers
Screen Protectors (3-Pack)
Smartphone Experts Screen Protectors (3-Pack) for Treo 800w
Protect your screen!
Just $15.95 BUY

More Screen Protectors
Treo Screen Protectors  (3-Pack)
Screen Protectors for Treo
Protect your screen!
Just $15.95 BUY

More Screen Protectors
SP700 Bluetooth Car Kit
Jabra SP700 Bluetooth Car Kit
Compact and versatile
Just $99.95 BUY

More Speakerphones
Tru-Tune Ultra Light Aluminum Earphones
Radius Tru-Tune Ultra Light Aluminum Earphones for Treo Pro
Fusion of Fashion and Function
Just $19.95 BUY

More Music Headphones
Innocase Holster
Seidio Innocase Holster for Treo 800w
Great way to carry and protect your cased Treo 800W
Just $29.95 BUY

More Holsters
Innocase
Seidio Innocase for Treo 800w
Superior protection
Just $29.95 BUY

More Hard Cases
BT530 Bluetooth Headset
Jabra BT530 Bluetooth Headset
Destroy unwanted sound with Noise Blackout.
Just $99.95 BUY

More Wireless Headsets
Atomic Bass Aluminum Earphones
Radius Atomic Bass Aluminum Earphones for Treo Pro
Headphones that deliver the slamming bass of hip-hop and dance
Just $39.95 BUY

More Music Headphones
INNODock Jr. Cradle
Seidio INNODock Jr. Cradle for Treo 800w
Compact and sleek, USB charging
Just $29.95 BUY

More Cradles
Retractable Micro-USB Sync & Charge Cable
Seidio Retractable Micro-USB Sync & Charge Cable for Treo Pro, Treo 800w
Compact and clutter free
Just $12.95 BUY

More Sync & Charge Solutions
 
 

Copyright 1999-2008 TreoCentral. All rights reserved : Terms of Use : Privacy Policy

TREO and TreoCentral are trademarks or registered trademarks of palm, Inc. in the United States and other countries;
the TreoCentral mark and domain name are used under license from palm, Inc.
The views expressed on this website are solely those of the proprietor, or
contributors to the site, and do not necessarily reflect the views of palm, Inc.

Explore more: Phone different | WM Experts | Crackberry | CentroSpot | Android Central
Smartphone Accessories: Windows Mobile Accessories | iPhone Accessories | Blackberry Accessories
Centro Accessories | Motorola Q Accessories | Mogul Accessories | Tilt Accessories | Nokia n95 Accessories
Pantech Duo Accessories | Verizon XV Accessories | iPod Nano Accessories | Dash Accessories | T-Mobile Shadow Accessories
Blackjack Accessories | Xperia Accessories | HTC Accessories | Touch Accessories | Instinct Accessories