RDLP_ROMToken(3)

NAME
RDLP_ROMToken - find a ROM token on a PalmOS device

LIBRARY
libpconn

SYNOPSIS
#include <palm.h>
#include <pconn/pconn.h>
int
RDLP_ROMToken(PConnection *pconn, uword cardno, udword token, udword *data_ptr, uword *data_len);

DESCRIPTION
Palm devices appear to have “ROM tokens”, which are essentially named pointers. The most useful token that the author is aware of is ‘snum’, which indicates the location of the serial number, on those Palm devices that have a serial number that can be read in software (e.g., Palm III).

To read the serial number, you must first call RDLP_ROMToken to find the location and length of the serial number, then call RDLP_MemMove to actually read the serial number.

cardno specifies the memory card on which to look. This is usually 0.

token specifies the four-character identifier (first letter in the most-significant eight bits) of the ROM token to look for.

data_ptr will be filled in with the starting address of the data that the token refers to.

data_len will be filled in with the length of the data that the token refers to.

RETURN VALUE
RDLP_ROMToken returns 0 if successful, or a negative value otherwise.

SEE ALSO
libpconn(3), DlpRPC(3), RDLP_MemMove(3).