Anton Posted May 2 Report Share Posted May 2 Hi all! I need current weather and forecast in my project on Vision V350 I have read good example for Unistream https://support.unitronics.com/index.php?/selfhelp/view-article/unistream-rest-api-example But it not applicable for VisiLogic, because I can't find and Rest API function and any other samples with receiving weather data from site. Please advise how can I connect V350 to accuweather site? or may be available another way for receiving weather data from internet? Quote Link to comment Share on other sites More sharing options...
DanT Posted May 2 Report Share Posted May 2 Hi; Rest API is a functon in the UniStream Series only. V700 is a Vision Series PLC, older than the UniStream Series, and does not have/support the Rest API Function Vision Series is based on another OS technology - Microcontroller and Fixed Structure. You may have to resort to an intermediate solution - Raspberry PI( for example) to get the weather data, then Modbus the infomation into the V700 DanT Quote Link to comment Share on other sites More sharing options...
MVP 2021 Flex727 Posted May 2 MVP 2021 Report Share Posted May 2 18 minutes ago, DanT said: You may have to resort to an intermediate solution - Raspberry PI( for example) to get the weather data, then Modbus the infomation into the V700 What I have done when I must use a Vision PLC but need certain communications protocols not available in the vision line is use a UniStream USC-B3-R20 and communicate the information to the Vision PLC via MODBUS TCP, as Dan is suggesting. It's a little more expensive than a Raspberry Pi, but if you already know how to program the UniStream then it's really convenient. It will just sit on the DIN Rail alongside other components and works like a champ. Quote Link to comment Share on other sites More sharing options...
Fernando Castro Posted May 2 Report Share Posted May 2 Isn't the rest API just a request over http protocol? the authorization is done in the server, right? I mean if that is the case in theory you should be able to do it using. TCP/IP protocol. and hard coding the headers of the messages, and the responses ... I mean I don't think it will be worth the time if there is already an easier solution available but seems doable to me. Quote Link to comment Share on other sites More sharing options...
Anton Posted May 2 Author Report Share Posted May 2 Thanks for the responses guys, Additional devices is a real solution, but not applicable for this project. I want to try resolve this problem by V350 function 2 hours ago, Fernando Castro said: theory you should be able to do it using. TCP/IP protocol. I am also think about it, but not have experience of TCP/IP communication by Visio. May be you have some samples? Quote Link to comment Share on other sites More sharing options...
Fernando Castro Posted May 3 Report Share Posted May 3 23 hours ago, Anton said: Thanks for the responses guys, Additional devices is a real solution, but not applicable for this project. I want to try resolve this problem by V350 function I am also think about it, but not have experience of TCP/IP communication by Visio. May be you have some samples? Not really, there is something you could take a look at in the examples folder. I started to implement an FTP client by myself but was very tedious job and never finished. I managed to get the responses from the FTP protocol as ASCII values then, list files on the server and start the download but got stuck buffering the file and then writing it to the SD card. basically, with TCP/IP you initialize a socket through a specific port, then connect to It and then and then you can use TCP/IP raw to build the messages. If you are going to try it will help to Install a program like Wireshark to monitor the messages sent over the network, and debug what is being sent/received. As I mentioned before, it will be time consuming 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.