void DialSamsung(char* phoneNumber, char* name) {
short* magicStruct; int err; int phoneDigits;
DmSearchStateType searchInfo; UInt16 cardNo = 0; LocalID dbID;
phoneDigits = StrLen(phoneNumber);
if (phoneDigits < 32 && phoneDigits > 0) {
magicStruct = (short *) MemPtrNew(214); //The magicStruct is 214 bytes.
MemSet(magicStruct, 214, 0); //Clear it out to all 0's for good measure
//(I don't know what everything is in there
//so its better to be safe.)
magicStruct[0x01] = 7; //This is a magic number that dials the phone
magicStruct[0x27] = phoneDigits; //0x27 holds the length of the phone number
//Copy the phone number into the magic struct.
StrCopy((char*)&(magicStruct[0x28]), phoneNumber); if (name) {
int nameLen = StrLen(name);
if (nameLen < 30) {
magicStruct[0x49]=nameLen;
StrCopy((char*)&magicStruct[0x4A],name);
}
}err = DmGetNextDatabaseByTypeCreator (true, &searchInfo, 'appl', 'PhAp', true, &cardNo, &dbID);
if (!err) {
emPtrSetOwner(magicStruct, 0);SysUIAppSwitch (cardNo, dbID, sysAppLaunchCmdNormalLaunch, magicStruct);
} else {
MemPtrFree(magicStruct);
}
}
}On Wednesday, March 19, 2003, at 10:05 AM, Scott Gruby wrote:
In article <[EMAIL PROTECTED]>, Richard Good <[EMAIL PROTECTED]> wrote:
In article <[EMAIL PROTECTED]>, Douglas Handy <[EMAIL PROTECTED]> wrote: Your right there was no telephony manager prior to 4.0, but the i330 uses 3.5. Handspring's sample code (dialer.c) makes calls to check if any helper application exists for voice calls. I was -hoping- something similar existed for the i330Richard,
Samsung hasn't published and SDK and their support people aren't very
helpful. The only answer I got was that they don't have an SDK. I simply
wanted to use the serial manager to talk to the built in modem...they
say this isn't possible.
It's an interesting device; I just wish they were more open with developer information. Handspring and Kyocera have some decent hooks in their smartphones to allow developers to do stuff.
-- Scott Gruby Palm OS Certified Developer Available for contract development work. [EMAIL PROTECTED] <http://www.notifymail.com/palm/>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
-- Ben Gottlieb Stand Alone, Inc. DT [EMAIL PROTECTED] www.standalone.com
-- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
