Problems with Modicon MSTR instruction

P

Thread Starter

Peter Elliot

Hi, I'm trying to communicate from a Modicon Momentum M1E processor's Ethernet port to a Modbus slave (address 4) via a '174 CEV 300 10' gateway. I can communicate to the PLC from a Modbus master (if I reconfigure the gateway), but have not been able to work out the format of the MSTR instruction required to have the PLC as the master. Please can you advise me as to the form of the MSTR instruction I will need to write from a PLC (192.168.0.50) via the gateway (192.168.0.60) to the modbus serial slave address 4. The gateway is configured for the serial side of the communications, but I don't know what MSTR code I should be using. Any help would be appreciated.
Regards, Peter Elliot
P.S. I'll compile a help sheet if I ever get this going...
 
D
Hi Peter, Set the MSTR block top node registers as follows: register 1: Function code 1=write data 2=read data register 2: Error status register 3: Number of registers to be transferred register 4: Beginning register in group to be transferred (a value of 3=40003) register 5: set to 0104 hex high byte: Must be set to a 1 low byte: Map Index byte=4 (slave address) register 6: 192 dec. register 7: 168 dec. register 8: 0 dec. register 9: 60 dec. register 10: not used register 11: not used Hope this helps. Dave
 
P

Peter Elliot

Hi Dave, Thanks for the reply. I managed to get to the same solution...after tracking down some additional information. (I'm working without manuals - always the easy way to go ;-) Thanks again. Peter.
 
Actually, the programming software for the PLC should be able to tell you all about it. ProWORX NxT has a register editor that shows you all of the memory addresses and how to configure them for either TCPIP or Modbus Plus. The MSTR function code should be 1 for a write and 2 for a read. I've set this kind of communications up before, it's fairly easy. What programming software are you using?

CK
 
Top