10-10-2011, 07:49 PM
Macro TcpSocket help
TCP/IP server and client
|
10-10-2011, 07:49 PM
Macro TcpSocket help
10-08-2017, 01:12 AM
Is there a way for the server to output the content that is send from the client.
To be more specific, if the CLIENT sends the string "test" to the SERVER, then let the SERVER render a messagebox with contents "test" if the received string is "test". SERVER CODE Function dialog_TcpSocket_server \Dialog_Editor CLIENT CODE Function dialog_TcpSocket_client \Dialog_Editor
10-08-2017, 06:05 AM
In the example test_TcpSocket_func2 is used out. Does it not work when out replaced with mes?
10-08-2017, 04:37 PM
I am sorry, you are right the function is called serverside, it works.
But now I want to test it from outside by using an android smartphone, I used tasker to create a simple HTTP-post. I think you can't give much feedback on this because it's about sending an http-post from outside QM's scope (and it involves android). But any tip you can give is very welcome. (If someone else has experience with this, your feedback is very welcome!) But I get the below output (and below error in tasker (android app)): I needed to send some string, so I send "%BLUE" which is the blue-tooth status ("on" or "off") EDIT: SORRY, forgot to mention the following error which happens when I send the above HTTP-post in tasker (see above android screenshot) Quote:17.34.40/Variables doreplresult: |%BLUE| -> |off| EDIT2: When I set the content type to "text", I now get the correct response in QM (output = "off"). But I still get the error: /E Input/Output error for http://192.168.0.189:5032: java.net.SocketTimeoutException Maybe just accept it as it is (ignore it?). Any feedback (if possible) is still welcome!
10-08-2017, 07:53 PM
Here the same. With Content Type text/plain my QM server receives the text.
But Tasker always shows that error. Maybe server's response is incorrect. Tried this response, does not work. Don't know what it should be. e15res="HTTP/1.1 200 OK[]Connection: close[]"
10-08-2017, 08:09 PM
Solved. The response must end with two line breaks.
e15res="HTTP/1.1 200 OK[][]"
10-08-2017, 09:15 PM
Example response for GET request:
e15res="HTTP/1.1 200 OK[]Content-Type: text/plain[]Content-Length: 4[][]DATA" Tasker will save DATA in the specified file.
10-08-2017, 09:17 PM
10-08-2017, 11:05 PM
THANK YOU!!!
|
« Next Oldest | Next Newest »
|