I called CeCreateFile("//test.txt", GENERIC_READ | GENERIC_WRITE, 0, NULL, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); and watched that connection on wireshark so I had some basis for comparison.
CeCreateFile has a command code of 0x16 and using this knowledge I believe the command code for CeRapiInvoke is 0x4C on WM5. (Which according to https://synce.svn.sourceforge.net/svnroot/synce/trunk/librapi2/src/rapi2/READMEis already taken by CeSetDatabaseInfoEx which is troubling, I think) I've attached the log of CeCreateFile in case someone wants to double check my work or like me finds it easier to compare the two side-by-side. My amateur opinion is that CeCreateFile and CeRapiInvoke look really similar on the wire and is hopefully not hard to implement for that reason. I'll try my hand at it today. -David Richardson On Fri, Jun 26, 2009 at 12:44 PM, David Richardson <docgra...@gmail.com>wrote: > I'm calling > hr = CeRapiInvoke("\\invokeme.dll", "PingBuffer", PING_BUFFER_SIZE, buffer, > &output_size, &output_buffer, NULL, 0); > > with PING_BUFFER_SIZE = 10 > > I've attached the wireshark pcap. Ignore everything before 12 seconds. I > called the identical invoke 3 times on the device. buffer should be 10 > 0xDD's. output_buffer and output_size were uninitialized and when finished > output_buffer is identical to buffer and output_size is 10 > (PING_BUFFER_SIZE). > > I'm not sending this to hand it off to you guys. I'm still looking at this > myself to see if I can implement it or figure out the command code, but I'm > sure the people on this list have more experience doing this. > > Let me know if you have any questions or want me to redo with some changes. > > -David Richardson > > > On Thu, Jun 25, 2009 at 3:44 AM, Mark Ellis <m...@mpellis.org.uk> wrote: > >> On Thu, 2009-06-25 at 00:39 +0200, David Richardson wrote: >> > >> > >> > On Wed, Jun 24, 2009 at 12:35 AM, Mark Ellis <m...@mpellis.org.uk> >> > wrote: >> > On Mon, 2009-06-22 at 22:10 +0200, David Eriksson wrote: >> > > On Wed, 2009-06-17 at 18:07 -0700, Captain Fourier wrote: >> > > > Hey, >> > > > >> > > > I have been trying to get CeRapiInvoke to work. Just using >> > the unit >> > > > tests in the release. All I get is -2147467263 as a return >> > result. >> > > >> > > 0x80004001 means "not implemented" >> > > >> > > > Is CeRapiInvoke implemented? Is it still only Stream mode? >> > > >> > > UTSL :-) >> > > >> > > Unfortunately it has not been implemented for Windows Mobile >> > 5 or newer >> > > devices. Any takers on the synce-devel list? >> > > >> > > >> > > > Thanks for your time, >> > > > Rob >> > > >> > > >> > > Best regards, >> > > >> > > David Eriksson, http://www.divideandconquer.se/ >> > > >> > >> > >> > Rob, I'll take a look at this sometime, but my time is very >> > limited at >> > the moment, so I'll need three things, the dll you're using on >> > the >> > device and the code you're using to call it, and the command >> > code for >> > CeRapiInvoke on WM5 :) >> > >> > I believe Rob was trying to execute the test located at >> > >> http://synce.svn.sourceforge.net/viewvc/synce/trunk/librapi2/tests/CeRapiInvoke/which >> has a DLL with it. >> > >> >> Ah yes, I've never noticed that there ! >> >> > If someone can briefly explain how I would go about getting the >> > command code for CeRapiInvoke on WM5, I have the necessary hardware >> > and time. >> >> Theoretically, run a small program on a windows host that just >> RapiInit's and calls the command we're interested in, and capture the >> transmission on the network interface using eg. wireshark. >> >> Of course, being MS it's rarely that straightforward, and if David is >> correct it could be a lot more complex. However, if you could use the >> test prog for CeRapiInvoke from windows and capture everything over the >> interface, we might be fortunate. >> >> > >> > I don't have anything set up to generate the call >> > on Windows to capture that code, so someone will have to find >> > it for me. >> > >> > Mark >> > >> > >> > >> ------------------------------------------------------------------------------ >> > >> > _______________________________________________ >> > SynCE-Devel mailing list >> > SynCE-Devel@lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/synce-devel >> > >> > >> > >
cecreatefile.pcap
Description: Binary data
------------------------------------------------------------------------------
_______________________________________________ SynCE-Devel mailing list SynCE-Devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/synce-devel