Hmm. So you are in trouble then. It's not so complicated if you have not to implement the whole damn hotsync protocol, just open the usb on the device and try to connect from the pc side.

As I said - dig through archives for ideas, I'm pasting some post below. On the other side - if you want not to use the palm usb dll you must make a driver (windows) and I don't know what (macos) - some generic style and simple one, to handle the communication.

Look at the sample, but it's windows and uses hotsync usb drivers (at first glance)

For those that are interested, I have been able to write
a few bytes to my M500 over USB using the code below.

I have had "more correct" results with the Handspring
version (which I have documented in the handspring-forum).
Anyway, maybe this will help someone who can then
take this further...

(I'm using CPP Builder 5 and the 98DDK)

GB

// Cheating method, ... get the guid from regedit.


// Stolen via Regedit.exe: #define symbolLinkName "\\\\.\\0000000000000034#{a5dcbf10-6530-11d2-901f-00c04fb951ed}\\PIPE04"


HANDLE deviceH = INVALID_HANDLE_VALUE; BOOL success; unsigned long nBytes; BULKUSB_CONNECTION_INFO info; char buf[32] = "your data here";


// Open the device to make sure it is available. deviceH = CreateFile(symbolLinkName, GENERIC_READ|GENERIC_WRITE, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, // no SECURITY_ATTRIBUTES structure OPEN_EXISTING, // No special create flags 0, // No special attributes NULL); // No template file

if(deviceH == INVALID_HANDLE_VALUE)
   return;

// Check if the device has a connection open  >>THIS FAILS!
success = DeviceIoControl(deviceH,
                          IOCTL_BULKUSB_GET_CONNECTIONS,
                          &info,
                          sizeof(info),
                          &info,
                          sizeof(info),
                          &nBytes,
                          NULL);

//if(success)  >>SEND DATA ANYWAY (works!)
   success = WriteFile(deviceH, buf, strlen(buf), &nBytes, NULL);

CloseHandle(deviceH);

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

Reply via email to