gerard
Topic Author
Posts: 3
Joined: 18 Jul 2022, 12:09
Answers: 0

Input long JSON messages

02 Nov 2022, 09:59

Hello,

I am programming an application using CODESYS CODESYS V3.5 SP18 Patch 2. The application must receive JSON messages of length 700 bytes using TCP/IP. But the application does not catch these messages. How can I solve that?
I attach my code (jpg).
Thank you
Attachments
2.jpg
2.jpg (203.04 KiB) Viewed 1557 times
1.jpg
1.jpg (361.32 KiB) Viewed 1557 times
0.jpg
0.jpg (311.83 KiB) Viewed 1557 times
 
User avatar
dirk
KUNBUS
Posts: 1760
Joined: 15 Dec 2016, 13:19
Answers: 1

Re: Input long JSON messages

04 Nov 2022, 11:36

Hi gerard,
Your application sounds exciting. KUNBUS has no shares in application development via Codesys, so I can only help you to a limited extent.
If I were you, I would leave Codesys out for the moment and check if the data arrives at the RevPi.
You can execute the following command to enable an incoming connection on port 8080:
ncat -l -p 3000 > /tmp/json.txt
On the sending device, you can run the following command:
nc -w 3 <RevPi IP> 3000 < json.txt
 
User avatar
dirk
KUNBUS
Posts: 1760
Joined: 15 Dec 2016, 13:19
Answers: 1

Re: Input long JSON messages

22 Nov 2022, 13:54

Hi gerard have you thought about posting your question Codesys Forge?
https://forge.codesys.com/neighborhood
 
gerard
Topic Author
Posts: 3
Joined: 18 Jul 2022, 12:09
Answers: 0

Re: Input long JSON messages

30 Nov 2022, 17:42

I checked that my application receives the JSON message sent from Hercules but not from other software. This problem occurs running the application on the RevPi and also with the Codesys virtual PLC.

I will post my question in the forum that you suggest, thank you very much
 
User avatar
dirk
KUNBUS
Posts: 1760
Joined: 15 Dec 2016, 13:19
Answers: 1

Re: Input long JSON messages

06 Dec 2022, 08:43

Hi gerard, thanks for your positive feedback and good luck in the future.

Who is online

Users browsing this forum: No registered users and 0 guests