For the first part (sending the request) I could simply use [netsend], but how do I get the response from the server back into pd? [netreceive] is not appropiate here.
I thought of using the [system] object calling wget, but than again, how do I get wget's output back into pd?
Ideas welcome! m@rc
I read:
I thought of using the [system] object calling wget, but than again, how do I get wget's output back into pd?
I use guenther's [shell] for such things, see the g00gle* and warnoise stuff here http://test.pilot.fm/pd/patches/misc/ for an idea.
HTH
x
Look at [shell] in the GGEE library! It sends and returns to/from the shell.
d.
Marc Boon wrote:
For the first part (sending the request) I could simply use [netsend], but how do I get the response from the server back into pd? [netreceive] is not appropiate here.
I thought of using the [system] object calling wget, but than again, how do I get wget's output back into pd?
Ideas welcome! m@rc
I don't have an answer for this, but the idea of a external that creates a two-way socket could be very useful (eg for a full OSC spec implimentation that involves receiving queries and sending replies back..) I'm sure for a host for other things. Netsend and netreceive make sense as network versions of send and receive, but a [socket] or something would be much more flexible for more complex network stuff.
Any ideas on the subject?
B.
Marc Boon wrote:
For the first part (sending the request) I could simply use [netsend], but how do I get the response from the server back into pd? [netreceive] is not appropiate here.
I thought of using the [system] object calling wget, but than again, how do I get wget's output back into pd?
Ideas welcome! m@rc
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://iem.at/cgi-bin/mailman/listinfo/pd-list
You could use one of the language externals, like Python or Ruby. Then you'd also have access to google libraries etc.
Or perhaps.... you could do something with [netreceive]. If you set up port 80 to be forwarded to it or something like that. I'm not too familiar with network stuff, so I can't be of more help.
Or.... maybe.... you could use something that writes to a textfile, which you can then access with anyone of a number of textfile reader externals. The textfile would be like a data pipe or buffer or whatever they call it.
Just a few ideas.
-Ian
Marc Boon wrote:
For the first part (sending the request) I could simply use [netsend], but how do I get the response from the server back into pd? [netreceive] is not appropiate here.
I thought of using the [system] object calling wget, but than again, how do I get wget's output back into pd?
Ideas welcome! m@rc
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://iem.at/cgi-bin/mailman/listinfo/pd-list
hi
[netclient] from maxlib ( http://www.akustische-kunst.org/puredata/maxlib/ )works in both ways, sending data to server and receive data from it. i tried the same thing and it worked technically, but instead of getting the index.html-file i always got a html-file with an error-msg like 'bad request'. i don't know much about the http-protocol, but it seems you have to send a quite accurately 'formulated' request to get the data you want. may you try to connect from your brwoser to [netserver] (also from maxlib) in order to see how such a request-msg looks like. i always failed, but you may will be luckier than me. if so, let me know.
cheers roman
----- Original Message ----- From: "Marc Boon" marcboon@dds.nl To: pd-list@iem.at
For the first part (sending the request) I could simply use [netsend], but how do I get the response from the server back into pd? [netreceive] is not appropiate here.
I thought of using the [system] object calling wget, but than again,
how do I
get wget's output back into pd?
Ideas welcome! m@rc
PD-list@iem.at mailing list UNSUBSCRIBE and account-management ->
Roman Haefeli wrote:
hi
[netclient] from maxlib ( http://www.akustische-kunst.org/puredata/maxlib/ )works in both ways, sending data to server and receive data from it. i tried the same thing and it worked technically, but instead of getting the index.html-file i always got a html-file with an error-msg like 'bad request'. i don't know much about the http-protocol, but it seems you have to send a quite accurately 'formulated' request to get the data you want. may you try to connect from your brwoser to [netserver] (also from maxlib) in order to see how such a request-msg looks like. i always failed, but you may will be luckier than me. if so, let me know.
I ended up using [shell], sending it the name of a shell script as a message. The shell script first calls wget to do the actual http request, and then does some testing on the return value before sending the response to stdout, which is then picked up by [shell] again.
This way, I can put the various wget options in this external shell script, and do all my error checking before sending the result back to pd. Makes it more flexible and robust. It also allows me to easily test (and modify) my http access script outside of pd.
Thanks for all your input! m@rc
Hello,
Sorry when we didnt anounce before. We use for PD Webserver (especially Zope/Plone) interconnection the
iemxmlrpc lib (author thomas grill iem)
(I checked it in now in puredata externals under iem projects) and put a releases at the moment here http://puredata.org/Members/ritsch/temporary/
The trick is pd behaves as an (is a) xmlrpc server and you can send messages to receiver in pd and request for messages of receivers. So its easy to get info from pd and dont need pd connect to any other application, Also there is a feature to send whole patches to pd and let pd execute them (be careful...)
Also a better synthax is used for message encapsulation, so xmlrpc takes over all the communication needs for secure data transmission. (Maybe just a better netsend/netreceive).
I just develop a project pd as radiostudio controllable over CMS systems (Plone/Zope) with students.
mfg Winfried
Am Sonntag, 6. März 2005 13:53 schrieb Marc Boon:
Roman Haefeli wrote:
hi
[netclient] from maxlib ( http://www.akustische-kunst.org/puredata/maxlib/ )works in both ways, sending data to server and receive data from it. i tried the same thing and it worked technically, but instead of getting the index.html-file i always got a html-file with an error-msg like 'bad request'. i don't know much about the http-protocol, but it seems you have to send a quite accurately 'formulated' request to get the data you want. may you try to connect from your brwoser to [netserver] (also from maxlib) in order to see how such a request-msg looks like. i always failed, but you may will be luckier than me. if so, let me know.
I ended up using [shell], sending it the name of a shell script as a message. The shell script first calls wget to do the actual http request, and then does some testing on the return value before sending the response to stdout, which is then picked up by [shell] again.
This way, I can put the various wget options in this external shell script, and do all my error checking before sending the result back to pd. Makes it more flexible and robust. It also allows me to easily test (and modify) my http access script outside of pd.
Thanks for all your input! m@rc
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://iem.at/cgi-bin/mailman/listinfo/pd-list