On Thu, 2010-02-04 at 23:02 +0200, Gert van den Berg wrote: > Thanks... Someone with more than 5 minutes of *nix programming > experience... ;) I actually hoped that a Perl script might be > possible, but that seemed unlikely... (My C coding needs exercise and > is usually restricted to microcontrollers...) > My C is the other way up to yours - the lowest level I've written C for is my Microware OS-9 (68020) and Flex-09 (6809) systems - and I haven't written 6809 C for a very long time. However, what are we trying to do? I'm asking because I'm not sure its being achieved. In particular, you *must* use execve() to pass the changed permissions along to a child process (in this case to wine.exe). Then somebody would need to dig into Wine to know whether it passes them on to the program we're asking it to run, since that's where they are needed. Is this something that would be better handled by other methods, i.e. by changing the device file permissions? The obvious ways are, in ascending order of difficulty: 1) Add the user(s) where Wine is run to the lp group. 2) run chmod on the relevant device files at boot time. On a RedHat system this is simply done by adding chmod uga+rw /dev/lp* /dev/parport* to the end of /etc/rc/d/rc.local 3) modify the UDEV rules to give world access to the relevant device files as they are created. This means adding a local rules file to /etc/udev/rules.d to set the device file permissions. Is there a driver involved, and if so, can its code be moved into some userspace program or DLL and can the Oscilloscope program be modified to use it? Martin