This is an example of Modbus RTU communication between the S7-200 Smart PLC and the RKC MA900 Multipoint Digital Controller. This code is written in Structured Text. Can be converted for use with other PLC models quite easily or ladder logic.
Documentation for RKC MA900 Multipoint Digital Controller can be download here: "https://www.rkcinst.co.jp/english/downloads/8919/imr01h02e3/".