From: Wolfgang D. <wol...@da...> - 2016-08-30 18:07:52
|
On 2016-08-30 19:15, Michel Talon wrote: > Jeronimo Pellegrini wrote: >> I was wondering if it's possible to have a Maxima server listening >> over some TCP port, and speaking some protocol. >> >> Is this possible? I would guess so, since Slime seems to do that. >> If it is possible, where is it documented? > > --------------------------------------------------------------------- > It is possible and this is the way wxmaxima and so on communicate > with maxima. > You can start with maxima -s and then play communicating with the > socket using netcat. It's the other way round: Maxima is the *client*, not the server. So *first* start netcat in server mode on port 1234: nc -l 1234 (or your program, which must be a server). *Then* start Maxima as client, with the option -s 1234 to connect to the Server on port 1234: maxima -s 1234 And then the server can submit maxima commands (for example you in your terminal Window using netcat as server) and the Maxima client will compute them and return the results. (Can a Maxima client connect to a port on another computer? It does not seem so...) > Probably you need to strip the prompts (%i1) (%o1) etc. Yes, it would be nice, if Maxima would have the possibility to communicate in a more computer parseable way. Best regards, Wolfgang |