Hi folks,
I am working on Palm 5.x series,using CW 8.0 IDE for development.
The device is also a Palm 5.x device.

I have written an application that opens the USB port when the device is on the 
cradle, send some data to a PC side USB application, and receive data from PC 
side USB application.
P.S.: I have a restriction that I am not supposed to use Hotsync.

1)For opening a port:
I use SrmExtOpen() to open the port.
The port constant I have used is serPortCradlePort . (I'm supposed to use this 
because any other would mean I'm using hot sync for USB.
I am using a SrmOpenConfigType structure with the field "function" ,initialised 
as the creator id of my application.

Can somebody verify till this point if I'm on the right track?Is the port 
constant correct?For USB on the cradle ,is the configuration that I'm doing 
correct?

Well, SrmExtOpen() suceeds .But on the PC-side application,which is using 
libUSB-Win32 library , just doing an SrmExtOpen() doesnot suffice. I need to do 
an arbitrary SrmSend() with 18 bytes(USB descriptor size) to actually make 
usb_find_devices() on the PC side succeed!But here again, SrmSend() gives the 
error "serErrTimeOut ",but the PC side is able to open the port!

Can somebody explain to me , why this additional SrmSend() is required to open 
the port is required,although the send fails?And also, whether the data being 
sent will actually get in the USB descriptor on the PC side?

2)For sending some data to the PC from the device:
After having done SrmExtOpen() followed by an SrmSend(), I do an SrmSend() with 
some data to be sent to PC. It comes out with an error serErrTimeOut all the 
time!!
Can somebody please explain the typical scenarios wherein an SrmSend() can 
timeout? I couldnt find any documentation for this.
Any of you sharing your experience with using Serial Manager would be useful..

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

Reply via email to