From: Jim K. <ji...@ji...> - 2004-03-11 04:23:45
|
Rolf Kalbermatter wrote: >=20 > Jim Kring [mailto:ji...@ji...] wrote: >=20 > > Regarding TortoiseCVS and piping into Plink, here is a snip > > from an email I > > got back from Ian: > >=20 > > ########### > >=20 > > My first take used the WinAPI file functions to read/write > > pipes (ReadFile and WriteFile). I now see that the Tortoise > > project has now added POSIX calls for the non-Win32 interface. > > It might be possible to use POSIX calls from msvcrt instead > > of Win32 calls from User32. >=20 > Not sure what the advantage of this would be. Win32 specific=20 > code will be in there anyway and msvcrt is just built on top=20 > of the Win32 API so you basically add another software layer=20 > to it. And last but not least msvcrt is not fully POSIX=20 > complaint so you may end up with platform differences even there. OK, then let's go with the WinAPI approach. >=20 > > Both chunks of code are in the link below (see the "run" > > function about two-thirds of the way down). I'll take a quick > > peek at using execvp() from LabVIEW. > >=20 > > <http://cvs.sourceforge.net/viewcvs.py/tortoisecvs/TortoiseCVS > > /src/cvsgui/cv > > sgui_process.cpp?rev=3D1.7&view=3Dauto> >=20 > I think the clean solution here would be rather to create a=20 > DLL which provides the same interface as that used by the=20 > Linux VIs. That will be enough problems to tackle I'm sure. > I think that the Linux VIs might use CINs (the VIs are locked). = Regardless, I think you are right, that this interface would be good to implement. = I have just created the interface VI "shells" (empty VIs) and populated = them with controls, indicators, icons, etc (all they need now is a Dll ;-). These have been committed to CVS (more info below). >=20 > Enclosed is a first version of what I have in mind. Rough and=20 > not tested yet but what I would see a possible=20 > implementation. Need yet to add the PipeOpenCmd implementation. >=20 > Rolf Kalbermatter >=20 > /* > * Pipe shared library for LabVIEW > * [snip] I have just created an opengtoolkit CVS module named "pipe". The VIs are located here: pipe/source/OGPIPE - VI TREE.vi pipe/source/OGPIPE Close Pipe.vi pipe/source/OGPIPE Open Pipe.vi pipe/source/OGPIPE Open System Command Pipe.vi pipe/source/OGPIPE Read From Pipe.vi pipe/source/OGPIPE RefNum.ctl pipe/source/OGPIPE Write To Pipe.vi And, the c_source is located here: pipe/c_source/pipe.c Regards, -Jim |