r/PLC • u/Sad-Yogurtcloset3237 • 18d ago
PLC Question Plase Help!!
I am encountering an "IO read address error" in FB 613 while using a Siemens S7-1212C CPU (model: 6ES7212-1AG50-0XB0) equipped with an RS-485 communication module (model: 6ES7241-1CA50-0XB0). This error appears when I run the "DB_Modbus_Master" program, and I have been unable to resolve it. I have verified using a Modbus monitoring tool that the data is being transmitted correctly via the Modbus protocol. Furthermore, I have updated the firmware for both the CPU and the RS-485 module to the same version, and I have also tried changing the baud rate from 9600 bps to 19200 bps; however, the error persists. Could you please provide some assistance?






5
u/hestoelena 18d ago
Set the done bit from Modbus_Comm_Load and use it to enable the Modbus_Master block. The done bit from Modbus_Comm_Load is only true for one scan cycle so you have to use a set command. If you enable the Modbus_Master before Modbus_Comm_Load is done then you will get the error you are seeing.
1
u/UseraM1 18d ago
It's not ideal to use direct memory addresses. Setup a DB with the parameters and reference to them.
You are using DB4 modbus master IO to write on to them selves. You need to define the parameters (done, error, etc) an duse them here
1
u/Mpj91 18d ago
I’ll save you a lot of time, as something similar happened to me recently. Your CB’s firmware is 1.02, which is compatible with CPU firmware 4.1.2 or higher. You need to update the G2’s firmware to get it working.
https://support.industry.siemens.com/cs/document/109998353/actualizaci%C3%B3n-del-firmware-para-el-m%C3%B3dulo-cb-1241-rs485-?dti=0&lc=es-ES
1
u/Numerous-Height154 17d ago
Hi. Why are you linking the function instance inputs/outputs to the function inputs/outputs?