matthew7047
Before I get to deep in this project I would like some advice! I could do this project by other means but would like to utilize Open PLC because I think by developing the system in open plc I can have others maintain it easier than say in Node Red, C++ or Python.  I want to use a raspberry pi5 as a site controller and have it communicate to nodes in the field where the IO of the connected nodes perform actions like read tank levels via a ttl to RS485 converter.  Other nodes will open and close valves to prevent overflow of the tanks. Other nodes will control VFD pumps and adjust the speed of the pumps.  Other nodes will read flow rates on turbine meters and shut down systems when the error between flow meters indicates there is a leak. additional node structures will be to get data on moisture content from sensors, I will also be getting pressure data from low sections of hose.  due to the distance between nodes I will have to use LORA or Cellular data to insure that the communication between nodes in maintained. How much of this has been done before?  Is there a limit to the number of nodes ( I believe I will have 16 to 18 nodes for the project). is there a suggestion for hardware as I have used RP-2040-zero boards, Pi Pico, Arduino, ESP32 and ESP8266 in the past so I have some of these laying round for development.   I have recently designed circuit boards for these microcontrollers but have built any of these yet and due to cost I want to limit the number of different microcontrollers.     Sorry I know there is a lot of information here and I realize success can only be achieved if I follow the advice of those with experience in open PLC.  
Reply 0 0
thiagoralves
Do you want to program the nodes using OpenPLC as well or just the pi5 site controller? For the site controller, there is no limit to the amount of nodes you can have, except for the protocol limit, which in case of Modbus is 247. You should be fine with 16 to 18 nodes, but maybe you will have more stability using Modbus TCP instead of Modbus RTU if you can.
Reply 0 0
matthew7047
I will utilize OpenPLC if it is capable of handling the task.  I will have to use ModbusRTU because the individual sensors are modbusRTU.  So I will attach them thru a to TTL to RS485 converter.   What hardware runs OpenPLC with the most reliability?   Arduino nano’s use less power but I have enough power from the solar panels and batteries to handle any of these devices.    
Reply 0 0
thiagoralves
You cannot add slaves on Arduino boards. Slaves only works with the Linux runtime, so a Raspberry Pi should be your best bet. There are several raspberry pi-based industrial controllers out there that should work very well for your application. A barebones Raspberry Pi is not suitable for industrial application due to lack of noise immunity.
Reply 0 0
matthew7047
I can't communicate between the Arduino boards and the modbus devices? It was my plan to use them and then send the data to the gateway after it was parsed.  As far as noise are you talking about noise on the wifi? I was going to communicate thru an external RF device like LORA or utilize a cellular board. if I couldn't get them to work I would use a cradlepoint or similiar cellular modem.  If I can write the code to communicate thru the arduino extension will it allow me to connect thru a modbus TTL to RS485 converter?  Am I pushing the limits here?  
 
A few other questions if I may!   do you have a location where your storing PSM's for use by the community?  
 
I see a few sample programs on this site and in github but I wondered if there was another site where you had more difficult programs, and documentation?  
 
thank you!  
Reply 0 0
thiagoralves
No, Arduino boards cannot act as Modbus Master, just slave. If you write the code for Modbus Master on an Arduino Extension, then sure, it will work. By noise I mean electrical noise in any industrial environment that can cause the bare microcontroller to reset, crash or even burn.
 
PSMs are used only with the Linux runtime, there is no use for them on Arduino boards. I don't have a specific place, but many users have posted their example programs here in the forum. For official documentation, check the Autonomy website.
Reply 0 0
Reply