GP2X Interprocess Communication


Parkydr

Developing for the GP2X since 2006
Joined
Dec 3, 2005
Messages
1,357
Website
www.parkydr.ezeedsl.co.uk
The only way I have found to do this is to use pipes, but this means I have to fork the client from the server. What I want to do is start the client separately and have it connect to the server.

Sockets are out.

Named pipes(FIFOs) don't seem to work. mkfifo function and mknod command return "operation not permitted".

I haven't tried message queues or shared memory but I don't hold out much hope as there's no ipcs command.

Has anyone managed to do this?
 
Last edited by a moderator:
Parkydr posted on Mar 2 2006 at 10:53 AM said:
Sockets are out.
(armchair programmer mode, not actually tested any of this)
Use unix domain sockets (so not tcp sockets)?
Named pipes(FIFOs) don't seem to work. mkfifo function and mknod command return "operation not permitted".

Where did you try to make these? Filesystem issue?

You could always just have the client and server create regular files in a well-known spot, and use signals (or polling) to alert eachother there's data to read, if you can't get the normal things
working.

P.
 
Last edited by a moderator:
luteijn posted on Mar 2 2006 at 10:11 AM said:
Parkydr posted on Mar 2 2006 at 10:53 AM said:
Sockets are out.
(armchair programmer mode, not actually tested any of this)
Use unix domain sockets (so not tcp sockets)?
Named pipes(FIFOs) don't seem to work. mkfifo function and mknod command return "operation not permitted".

Where did you try to make these? Filesystem issue?

On the SD card... D'oh! FAT (don't know I want to write files to NAND though).

You could always just have the client and server create regular files in a well-known spot, and use signals (or polling) to alert eachother there's data to read, if you can't get the normal things
working.

P.

Not very nice but at least that's a way forward
 
Last edited by a moderator:
Last edited by a moderator:
luteijn posted on Mar 2 2006 at 12:21 PM said:
Parkydr posted on Mar 2 2006 at 12:09 PM said:
I just tried it and FIFOs work with tmpfs.

:) just like I thought.

Did you also try using sockets (FILE/UNIX namespace, not INET) or is that also not available?

[url="http://wwwwbs.cs.tu-berlin.d...s.tu-berlin.de/user-taipan/...ce_Details.html
[/url]
[url="http://wwwwbs.cs.tu-berlin.d...s.tu-berlin.de/user-taipan/...et_Example.html
[/url]

P.


It was AF_UNIX I tried first, that gives a "no address families found" error.

and that was using the /tmp directory anyway
 
Last edited by a moderator:
Back
Top