Printing Solution for Mobile printing on HP printers
Introduction
The Personal Digital Assistant or PDA was introduced to replace the bulky paper organizers that people have long carried around. The PDA is a tiny, fully functional computer that you can hold in one hand. PDAs can even hold your downloaded e-mail and play music. The only feature lacking is facility to Print.
HP has enabled such embedded devices to have printing functionality by releasing an SDK called the Appliance Printing Development (APDK). Using the APDK, developers can write their own device drivers for the HP DeskJet series of printers, targeting their host system. Thus, non-PC devices such as palmtops, web TV terminals, watches, digital cameras, cell phones, and handheld PCs can make use of HP printers.
APDK contains a minimum set of codes, but is not a complete driver - it serves as the basis for creating a very small yet functional printer driver. To extract a complete device driver, a developer has to code for some functionality in the targeted platform.
This document will discuss about the APDK, Palm Printing functionalities, and the issues in creating a printer driver for the Palm using APDK.
Need For APDK
Before the APDK technology was introduced, non- PC devices had to connect to the Printer through a PC. For example, in a Digital Camera, the digital content had to be transferred to a PC in order to take printouts. Now, non-pc devices can connect to HP DeskJet printers directly without the help of a PC, due to the introduction of the HP APDK.
Objectives of APDK
Small driver size
To meet the needs of small memory footprint devices.
Portability
To enable quick deployment on all kinds of devices.
Extensibility
To allow for future enhancements.
Features & Performance
To provide the proper balance of print quality, speed and feature support, given the current size and portability constraints.
Overview of APDK
The APDK final product is designed to accept pre-formatted, 24-bits RGB raster data and/or ASCII text, convert it to a high-quality, printer-ready data stream, and send it to an HP printer via a host-implemented I/O mechanism. The SDK also helps to provide the necessary structure and controls for a given print job, and enables the system (through an API) to perform various printer maintenance activities, (e.g. cleaning the printer pens).
The SDK is primarily responsible for converting device-independent data into a device-dependent, printer-optimized stream of bytes. Because the conversion process for color inkjet printers is quite complicated, it is important to not change device-independent portions of the SDK code.
If the target platform doesn't have a pre-existing printing functionality, then the user has to put in extra effort on the application software on the target platform to support printing. He must then write the printer driver for that platform
The following diagram clearly gives the flow when printing using APDK

Developers Implementation
To run the driver, four public classes are used (not all classes are used for each driver). There is one global function, used to determine the properties of the current version, and one auxiliary object used only for debugging purpose.
Classes
- SystemServices
- PrintContext
- Job
- Font
Auxiliary Objects
- Scripter
Global Function
- Version
Abstract Class "System Services" To Be Implemented By Host System Interface.
System Services is an abstract base class that requires implementation of various routines by the host environment in order to compile.
InitDeviceComm: InitDeviceComm is a method included in the base class whose function is to ensure that communication can be established with the printer, and the printer can be identified. InitDeviceComm must be called from the derivative SystemServices constructor.
DisplayPrinterStatus: DisplayPrinterStatus is a method implemented in the derivative class that allows communication of the driver status (errors, conditions requiring user intervention, etc.,) to user interfaces provided by the host.
ReadDeviceID: ReadDeviceID is a method implemented in the derivative class for retrieving the raw DeviceID string from the printer. ReadDeviceID is dependent on the type of communications protocol used, (1284, USB, or other methods.) If access to the printer's DeviceID is not possible due to I/O issues on the host system, have this function return BAD_DEVICE_ID to allow proper operation of the printer driver's error handling system.
SystemServices - This object encapsulates functionality that must be supplied by the host system, including memory management and I/O, clock access, user notification, etc. The abstract base class must be instantiated in a host-specific derived class, where the system code is hooked up to the required driver entry points. The only reference to this object in API-calling code should be to its constructor and destructor, which must be invoked prior to and after all other driver calls.
SystemServices is an abstract base class; the developer has to derive a class from Systemservices, and in that class every method in System Services has to be implemented.
Let ProtoServices be a class derived from System Services. The implementation of the methods is shown in the following.
PrintContext -This object serves two purposes. First, it encapsulates knowledge about all devices supported in available driver components. It can be queried at runtime to determine the capabilities of the attached device. Second, it allows for setting optional parameters of a print job, such as media size and margins, use of color and data-resolution, etc.
Job -This object receives processes and transmits data to be printed by one device on successive pages. The PrintContext and Job together form the core of the driver.
Font- This object is used to control printer fonts when sending ASCII data. (Printer fonts are beneficial in cases where the system lacks a reasonable font engine, or other cases.)
Parallel 1284 versus USB
If USB will be the print solution I/O method, the printer driver must be informed by setting the flag IOMode.bUSB to TRUE in the constructor of the derivative SystemServices class. The drivers produced by the Hewlett-Packard Print Driver SDK require this information due to I/O and error handling differences between USB and parallel /1284 connectivity.
Bi-directional versus Uni-Directional
Hewlett-Packard strongly recommends using bi-directional communication (bi-di) instead of uni-directional communication (uni-di) when implementing print solutions with this SDK. Bi-directional communication provides complete communication between the user and the printer, and enables plug and play capability, which provides seamless identification and use of Hewlett-Packard DeskJet printers without any input from the user.
If a uni-directional I/O method is the only option, the driver can still be used although the user will not have the advantage of the printer-to-host system communication for troubleshooting. In this situation, the host system will need to prompt the user to report the model they will be printing to before initiating a print job. The hosting system is responsible for storing this printer model to prevent further prompting from the user again.
In normal bi-directional communication, Initdevicecomm tries to establish contact with the printer when the SystemServices class is created. If successful, the model number is saved for later use. When the PrintContext is created, the pointer for the SystemServices class will be used to check if the model number has been previously saved. If it was, bi-directional communication has been achieved.
Sample of Calling Code
This is the code that acts as an interface between the Host System and HP Internal codes.
A Sample code that gets Text as an input and send the Text to HP API Functions.
Steps involved in the Process
- Creation of a SystemServices object is the first time communication with the printer is attempted, and entry points required by the core code are mapped. The class SystemServices is abstract, so reference is made here to the derived class containing the implementation for this platform.
- Check that operator new succeeded. The code set presumes no throw/catch capability in the local compiler; so all errors in constructors are signaled by the value of constructor_error, which the caller must check. "Hard" errors have values greater than zero (NO_ERROR). Values less than zero are warnings, which permit execution to continue; however, the user should be alerted to them.
- This step involves setting up the PrintContext for the job, which contains all the information about the print modes, paper type and size, etc. The constructor sets defaults for all necessary options, and defines the printer model being used based on information gathered by SystemServices constructor.
- The Job object handle. Data will be sent through this object.
- If the Printmode sent to this function is not accepted to a specific printer, then set the max printmodecount as the printmode.
- Get the fonts available for the printer. APDK supports four standard font types they are Courier, LetterGothic, CGTimes and Univers.
- Font object settings are done here.
- The data is sent here. Errors may include conditions such as printer out of paper, offline, etc.
Steps involved in the Process
- PageHeight is given in pixel-rows. For a default page with a vertical printable area of 10 inches and effective resolution of 300 d.p.i, this value would be 3000
- PageWidth is given in pixels per row. Note that this value is constant across the Job; it must not exceed the maximum width for the target paper-size. (In this example using defaults, this would be assumed to be 2400 for LETTER size paper with 8 printable inches at 300 d.p.i.) All rows of data must be padded with white space (RGB value 0xFFFFFF).
- The size of a row in the byte-array is given as PageWidth*3, because each pixel is represented as 3 bytes in the required RGB24 format.
- The Job object handles one continuous sequence of rasters on successive pages. Data will be sent through this object.
- This function causes the page to be ejected, and resets various internal counters.
Recording a Script
Developers can utilize the script recording device in order to communicate with Hewlett-Packard when debugging, problem solving, or quality testing.
- The first step in producing a script is to decide on the mechanism for storing it, and the format to be used. The easiest way to produce a script is to write the data to a file on local storage using standard "fopen/fwrite" commands. If such storage is available, the code included in the SDK will be sufficient. The data can be written in either binary or ASCII form; the binary form will produce smaller files and run faster. Hewlett-Packard has encountered some systems where a storage disk is not available and the only means of capturing data is to use printf commands that are sent to a terminal window. In this case the base-class scripting code has to be overridden (in the derivative SystemServices class). The code can be copied as is from the base-class routines, replacing every file-writing call (fwrite, fputc, etc.) with a display call (printf), and avoiding the fopen/fclose calls in the methods OpenDebugStreamR and CloseDebugStreamR. In order to capture the data from the terminal wi ndow, the ASCII format must be used. (This is why the ASCII option has been provided.) Thus the code that needs to be overridden is in the AsciiScripter subclass of Scripter, found in the file script.cpp.
- The second step is for the calling code to invoke the SystemServices methods InitScript and EndScript. InitScript, as usual, should be called after the SystemServices object is constructed and before any other API calls are made. InitScript takes two parameters: the name of the script file to be created on disk (ignored in the diskless implementation), and a flag that is TRUE if ASCII format is to be used. EndScript should be called after everything else has finished and been cleaned up, except of course for destruction of the SystemServices object. Both these calls should be conditionally compiled into the calling code, so that they only occur in debug builds.
- The final step is to compile all the code with the symbol CAPTURE defined, and with the files in the "debug" subdirectory included in the build. Note that CAPTURE should not be defined in any production builds, as performance will be severely degraded.
How to make the driver
Minimum Host System Requirement
Hardware
- A development system of the developer's own choosing (such as a PC running Windows NT, etc.)
- A supported Hewlett-Packard DeskJet printer.
- Parallel or USB Cable (IEEE STD 1284-1994 compliant recommended).
Software
C ++ compiler, linker and standard libraries supporting string and other functions and platform specific libraries.
CPU Bandwidth
CPU Bandwidth needs depend on the type of printing support required as well as what other operations are occurring in the system at print time.
For graphics support:
A 100 MHz Pentium class processor.
For simple, ASCII-only text support:
A low-end processor.
Available Memory
Code & static tables (50 - 120K).
Run-time buffer space (25 - 60K, possibly 120K for high-res 6 color).
To build the driver
A Skeletal Makefile is needed to compile the core source files or any IDE.
- For Windows, VC++ can be used to build the source codes.
- For PalmOS, Code Warrior can be used.
Printers and Features Supported
The following features are supported by the APDK and apply to all printer families and family members:
- 24-bit RGB input.
- Multiple Paper Sizes (Letter, A4, Legal). A6 size is supported from APDK 2.4
- Grayscale (Black-Only) Mode.
- Comprehensive Error Handling & Notification.
Printer family derivatives are available on the market and should be considered to have similar feature functionality as other members of their family type. (8xx Series Only - The scope of this Series does NOT include the older 850C, 855C, 870C or 890C printers.)
The following HP Deskjet printers have been included in the printers supported by HP APDK 3.0
- 24-bit RGB input.
- Deskjet 656
- Deskjet 825 & 845
- Deskjet 920
- Deskjet 940 & 948
- Deskjet 995
- Deskjet 1125C
- Deskjet 1220C
- Photosmart 100
- Photosmart 1115
- Photosmart 1215
- Photosmart 1315
- CP 1160
- CP 1700
- Apollo P2500
- Apollo P2600.
The following Hewlett-Packard DeskJet printers are not supported by this SDK:
- 400 series
- 700 series
- 850C, 855C, 870C or 890C
Any non-Hewlett-Packard printers, or Hewlett-Packard non-DeskJet printers (including OfficeJet LaserJet and PhotoSmart printers) are also not supported by this SDK.
Print Quality
The quality of printed output can vary widely in the thin-client environment, due to host limitations. Some factors that can affect quality are:
- The presence of a scalable font engine in the thin client host.
- The use of internal printer fonts where possible.
- Composite black printing on single pen printers (DJ400, DJ600).
- The quality of document to be printed.
- The quality, scaling, and compression of document images.
- Anti-aliasing and other algorithms designed to make text look good on a screen.
To justify the Print Quality of the APDK driver, let us take a sample of the original image and the scanned image of the output of the APDK driver for the same.


Print Modes
The Print Mode is based on the resolution and no of inks used. The number of print modes for each printer type is given by the GetModeCount function in PrintContext. Typically, there is a default color mode and a grayscale mode; other modes with special properties such as high-resolution photo quality are available for certain printer models. In some cases, the developer must choose between features such as device-based text and photo quality. This is accomplished by selecting the mode (Print Context member SelectPrintMode,) and then querying with PrinterFontsAvailable. Every mode has a string identifier (for potential use in a user interface) given by GetModeName.
When bi-directional communication with the printer is available, the PrintContext constructor selects a default mode based on the installed pen. (The default mode is the "lowest" or fastest mode still compatible with the pen.) In order to override this setting, (possibly due to selected user preferences or unavailable bi-directional communication,) the SelectPrintMode method is provided in PrintContext.
SelectPrintMode takes a zero-based index. By convention, index 0 always refers to the Grayscale mode GRAYMODE_INDEX=0). Index 1 DEFAULTMODE_INDEX refers to the "normal" color mode; other values up to
New methods added in APDK 3.0 :
Use PRINTMODE_VALUES *GetPrintModeSetting() to determine the quality, mediatype, colormode, and device text settings for the current print mode.
DRIVER_ERROR SetPenSet(PEN_TYPE ePen) allows the caller to specify the pen set in the printer in uni-di mode.
Resolution
Effective graphical output resolution depends on the PrintMode selected for the attached Printer model. In this SDK, two resolutions can be selected: 300 d.p.i. (dots per inch,) or 600 d.p.i., (the latter being used only for various "Photo/Best" modes.) To determine the acceptable resolution for the currently selected printer and mode, call the PrintContext function, EffectiveResolution. Remember that the calls must be in the appropriate order, or the results will not be valid. For example, if SelectDevice and/or SelectPrintMode are called after EffectiveResolution, the result of the EffectiveResolution call will no longer be valid.
Miscellaneous Features Supported
Apart from printing, APDK supports many other features.
PhotoTray Selection
If a printer, like the DJ 9xx series, has a PhotoTray support used for printing, the user can select the option of PhotoTray installed so that output can be extracted in the PhotoSize Paper.
Cleaning the Print Cartridges
If the APDK driver produces a grimy output, it may be due to a cartridge problem. To clean the Print Cartridges, the user needn't go to the service center. APDK provides a API Function called PerformPrinterFunction to clean the Print Cartridges. The developer can make use of the API to provide the end user with this option.
Debugging a Driver With Scripts
The APDK has been instrumented so that when a debug flag (build define "CAPTURE" is set, all API calls along with their data are recorded in what Hewlett-Packard calls a script. From this script, a large class of problems can be immediately found that would otherwise take a very long time to debug.
HP's Support to know the printer driver quality
Hewlett-Packard strongly encourages developers to email the printer driver output (script files) back to Hewlett-Packard for print quality review and recommendations based on the results; this service is offered at no charge. Hewlett-Packard can then work with the developer to identify print quality issues and correct them.
To submit the script files, log on to the SPP website (http://www.hp-developer-solutions.com) using the user assigned login name and password, and send an email titled "Script Files", with the attached script files. Be sure to include user name, email and phone number in the email, should Hewlett-Packard need to make direct contact. Hewlett-Packard may verify the correctness of the printing sequence, paying particular attention to the following
- Valid API calls
- Correctness of the calling sequence
- Any significant print quality issues
- Artifacts
- Output correctness
Limitations
- In order to achieve each of the SDK design objectives (small driver size, portability, etc.,) the finished printer driver will not, and cannot be as full featured as Hewlett-Packard's corresponding Windows driver. Size and portability are the main restrictions that limit the features provided in this kind of driver.
- Only the InkJet series is supported in this SDK.
Printing Support in Palm
Until recently, Palm-Sized devices did not support the printing functionality. This means that the developer has to put in additional effort to bring printing functionality in Palm. There are two ways printing can be done in palm-sized devices. They are
- 1. Printing Indirectly via a Desktop.
- 2. Printing directly to a printer
Printing Indirectly via a Desktop
If users don't have a serial or USB port printer or don't want to purchase a cable, they can "print" by transferring data to the desktop computer. This computer must run some sort of terminal emulation software, like ClarisWorks (Mac or Windows) or HyperTerminal (Windows 95/98/2000). Users can transfer the data through any techniques available and save the output to a file that a particular printer can understand on the desktop, to be printed later if required. For example, *.pcl is a file recognized by HP Printers. Alternatively, users can set the terminal emulation software to a "transfer" mode where it just transfers the incoming information directly to a printer. Therefore, although it is an inelegant solution, users can actually print to any printer connected to the desktop without any special cabling whatsoever.
Why Print from the Palm?
The necessity may arise in a number of cases. For example, the user's job may involve visiting customers in the field, or working at trade shows, and he may need to print out an order or a receipt on a portable printer. The user may also be a doctor doing rounds in a hospital, a delivery truck driver, a field service representative, or one of the many other mobile workers in today's workforce. The printing feature may also be useful for users who work in the office but use software on the Palm device that has no desktop counterpart.
What can be printed from the Palm?
Users can print information from the built-in Palm databases - memos, schedules, address book information, to-do lists, expenses, emails (from both the Palm Mail and iMessenger applications) and clipboard contents. Users can also print from any applications that enable the printing functionality.
Implementation of Indirect Method of Printing
Printing indirectly via a desktop pc from the palm is implemented as follows:
When the user presses the print option in the palm application, the data to be printed is stored in a palm database. The HotSync Application, which is a Desktop Application, is used to connect the desktop and handheld. It starts synchronizing the palm and desktop by running the Conduit that is registered to it. The Conduit is responsible for the transfer of data from the handheld to desktop and vice-versa. HotSync is an application that runs in the desktop, which monitors the serial port for communication between the conduit and the handheld. A conduit is a plug-in module for the HotSyncŪManager application, which transfers data between a Palm Powered Thandheld and a desktop computer.
When a user puts a Palm OS device in its cradle and presses the HotSync button, the handheld application begins communicating with the desktop conduit. Then the data is written to a .pcl (Printer Control language) file that a HP Printer can recognize. The .pcl file is given to the HP DeskJet printer for printing through HP APDK driver for windows.
The Flow of operations when synchronizing data between palm and PC.

An Overview of Conduits
A conduit is a plug-in module for the HotSyncŪManager application, which transfers data between a Palm Powered Thandheld and a desktop computer. The HotSync Manager runs the conduits that have been installed on the user's desktop computer when the user places a handheld into the cradle and presses the HotSync button. Conduits are typically designed to synchronize or back up data from a specific handheld application database. You can develop conduits with any of the suites that make up the Conduit Development Kit (CDK) for Windows from Palm.
Development System Requirements
To develop conduits with the C/C++ Sync Suite, your development system must be equipped with the following:
- Microsoft Windows operating system- 95, 98, 98 SE, ME, 2000 or NT 4.0
- One of the following development environments:
- Microsoft Visual C++ 6.0
- Metrowerks CodeWarrior Professional:
- Release 5 with IDE 4.0 and patch 5.3
- Release 6 with IDE 4.1
- At least 82 Mbytes of free disk space (space required by the complete CDK 4.02 installation) and the minimum amount of RAM required by your development environment
- A Palm Powered T handheld with cradle and software for testing, or the Palm OS Emulator
Implementation of function that reads palm database and writes to a file
An Overview of HotSync Manager
HotSync is an application running in the desktop that gets activated when the hotsync button in the handheld is pressed. It starts synchronizing the palm and desktop by running the conduit that is registered to it. It also does some backup operations.
What Happens When a Synchronization Occurs
User pushes the HotSync Button.
The handheld sends an "Are you there" message out the serial port until the HotSync Manger on the desktop notices that someone is knocking.
HotSync synchronizing starts
The HotSync Manager negotiates a baud rate with the handheld and begins communication. It reads the user ID and name from the handheld and tries to find a corresponding HotSync user. If it doesn't find one, it prompts on the desktop for the user to select one or to create a new one.
For each database on the handheld, the HotSync Manager tries to
The user gets the message: Connecting with the desktop. HotSync retrieves from the handheld a list of all databases and their creators.
Databases that don't have a corresponding conduit but that have the backup bit set get added to the list to be backed up by the Backup conduit. Remaining databases are ignored completely.
3.0 or later-Sync Manager installs new database
The Install conduit gets called to install databases.
The HotSync Manager determines whether a fast sync is possible (if this is the same desktop machine last synced with) or whether a slow sync is required (if it is different).
Conduits can take advantage of a fast sync by only reading from the handheld records marked as modified; nonmarked records won't have changed since the last sync. Install conduit gets run and new applications are installed.
The user gets notified that syncing has now starte
The HotSync Manager starts the iteration through its list of conduits based on their priority code (as specified when the conduit was registered).
The HotSync Manager finishes with the conduit prior to ours. The HotSync Manager prepares to sync.
Our conduit gets loaded
The HotSync Manager checks the conduit's version number
GetConduitVersion is called and returns the conduit's version number.
The HotSync Manager gets the conduit name so that is can display information in the Status dialog.
GetConduitName is called and returns the name of the conduit.
The HotSync Manager prepares to sync by passing the synchronization off to the conduit.
OpenConduit gets called, and the conduit's DLL gets loaded into memory. It is told whether to do a fast sync, a slow sync, a copy from handheld to desktop, a copy from desktop to handheld, or nothing. When OpenConduit returns, it has completed the task.
The HotSync Manager runs the remaining conduits.
The HotSync Manager backs up modified databases that don't have a corresponding conduit but do have the backup bit set.
Sync complete.
The Backup conduit gets called.
Registering and Unregistering Manually Using CondCfg
CondCfg is an application that uses the Conduit Manager. This application displays all the registered conduits and allows you to register conduits, change registered information, and delete conduits.
Required conduit entries
The following entries are required to register a conduit:
Conduit
The name of the conduit DLL. If this entry doesn't include a directory, the name must be found in the HotSync directory or current PATH; otherwise, it should include the full pathname to the DLL. (Generally, you keep your DLLs in the HotSync directory.) If your conduit is written using Java, this entry should be "JSync.DLL", a C++ shim that translates between C++ and Java.
Creator
The four-character creator ID of the database(s) your conduit is responsible for. Your conduit will be called during a HotSync only if an application with this creator ID exists on the handheld.
Directory
In the HotSync directory, each user has a subdirectory. Within each user's directory, each conduit has its own directory where it can store files. This string specifies the conduit's directory name.
Optional entries
The optional entries are more numerous. They include the following:
File
A string specifying a file (if the string doesn't include a directory, it is assumed to be within the conduit's directory). This is intended to be the local file that the conduit will sync the handheld against. However, your conduit is not restricted to using only this file (some conduits may need to read/write multiple files on the desktop).
Information
A string that provides information about your conduit. This string can be used to resolve conflicts. If more than one conduit wants to handle the same creator ID, an installation tool could display this string and ask the user which conduit should be used for syncing.
Name
A string that is the user-visible name of the conduit.
Priority
A value between 0 and 4, this controls the relative order in which conduits run. Conduits registered with a lower priority run before conduits registered with higher priorities. If you don't set this value, the HotSync Manger uses a default value of 2 for your application.
Remote DB
A string specifying a database name on the handheld. This string is provided for you to use in your conduit when it runs; your conduit isn't required to use it, however.
Username
The name of the user for which this conduit is installed. Note that this entry is not currently used.
Printing Directly to a Printer
This section gives a brief idea of how printing directly to a printer from palm can be done.
"Launch Code" is an important term in palm applications. Launch codes are a means of communication between the Palm OS and the application (or between two applications). An Application launches when it receives a launch code.
The printer driver for the palm is an application which launches when it receives a predefined launch code named sysAppLaunchCmdExgReceiveData that notifies the driver that it should receive incoming data (can be character or byte stream) from some other application.
Palm Applications that need printing functionality can send the launch code to the driver and use its functionality by invoking the system manager function called SysAppLaunch. Thus the driver gets activated and sends the stream of data to the printer using the API functions TextOut if text to be printed or SendRasters if image to be printed. There is no additional effort for the developer to represent the data in PrinterControl Language(PCL), Since HP's internal code does this. This way printing functionality can be achieved in palm.
However, printing directly from palm through APDK might need some converters due to the following issues.
I/O Port Conflicts between Palm and APDK
The printer driver depends on the underlying Operating System (OS) to provide basic access to whatever I/O port is connected to the printer.
Any non-Hewlett-Packard printers, or Hewlett-Packard non-DeskJet printers (including OfficeJet, LaserJet and PhotoSmart printers) are also not supported by this SDK.
Among Deskjet Printers, only the following printers are supported by this SDK.
- 600 series
- 800 series except 850C, 855C, 870C or 890C
- 900 series
- 2000 series
- e-series
The commonality among these printers is that they don't accept serial data. Only Parallel or USB port is supported in these printers. From the above construct it's clear that APDK doesn't send serial data to printers.
Conflicting to this, In Palm Current communication protocols are:
- Serial communication.
- TCP/IP with a socket interface.
- Infrared. Low-level infrared support is via IrDA (Infrared Data Association).
- A higher-level object exchange is provided that allows exchanging information between Palm devices and other devices using an industry-standard object exchange. This object exchange currently runs only over IRDA, although other ways of exchanging information may be provided in the future.
Palm Connectivity Issues
Infrared.Infrared printers are not supported by APDK. There are several devices on the market, which are "IR-to-parallel" adapters, which essentially convert any printer into an IrDA printer. This is the perfect solution for the office environment, where you have one printer serving multiple Palm users. Just attach one of these to your printer, and every one of them can print using this IR to the printer, while at the same time the pass-through port allows the existing parallel connection to continue.
Parallel.Most current LaserJet and InkJet printers have a parallel input using a standard Centronix connector; some, especially smaller portable printers, have unique, miniturized, parallel connectors. Palm devices have only serial output and IrDA. To do this you need a "serial-to-parallel" converter. This is not to be confused with a simple cable. You can find parallel cables with a 25-pin connector that looks like (indeed, physically it is) a serial connector on one end and a Centronix connector on the other. If it sells for less than $20, it is not a serial-to-parallel converter but rather a simple parallel cable. Serial to parallel converters sells for more like $50-$100.
NOTE: Printers with bi-directional parallel ports, including the HP720C, are not compatible with serial-to-parallel printer cables.
USB.Many newer Palm handhelds and many newer HP printers have a USB input. Generally it is not possible to print to a USB printer from a palm without a special USB hub-like device in-between, since both these deices are slaves.
Conclusion
HP has paved the way for the embedded devices to have printing functionality through its APDK. In some cases, due to the issues mentioned above, we may need some sort of converters or infrared sensors while developing the driver for palm. Thus, the Palm has an additional feature. HP APDK can be used to develop printer driver for almost every embedded device.
References
- You can download the APDK open source and its documentation for free from http://www.hpapdk.com
- The Complete Documentation for palm can be downloaded from http://www.palmos.com/dev/
- The Conduit Development Kit for various environments is available as free fromhttp://www.palmos.com/dev/tech/conduits/

