Logic Machine Forum
LM, EGX150 and PM simulator - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Gateway (https://forum.logicmachine.net/forumdisplay.php?fid=10)
+--- Thread: LM, EGX150 and PM simulator (/showthread.php?tid=4174)



LM, EGX150 and PM simulator - SigmaTec - 04.08.2022

Hi all,

I want to know if it is possible, via a script, to use LM as a Modbus slave of an EGX150 gateway (Schneider). My project is to simulate an iEM3155 powermeter and to send power values to EGX150 so that it sends them in TCP/IP to another system.

I found a script on the forum, but it is adapted to KNX objects: this is not my case, I have virtual objects in LM.

Thank's in advance for your help.
Have a good end of week.

Dominique


RE: LM, EGX150 and PM simulator - admin - 04.08.2022

There's no difference which object range is used - standard or virtual.


RE: LM, EGX150 and PM simulator - SigmaTec - 04.08.2022

(04.08.2022, 12:40)SigmaTec Wrote: Hi all,

I want to know if it is possible, via a script, to use LM as a Modbus slave of an EGX150 gateway (Schneider). My project is to simulate an iEM3155 powermeter and to send power values to EGX150 so that it sends them in TCP/IP to another system.

I found a script on the forum, but it is adapted to KNX objects: this is not my case, I have virtual objects in LM.

Thank's in advance for your help.
Have a good end of week.

Dominique

Ok Admin,

so I may not have the right script. 
Can you tell me one that will allow me to carry out my project? 
LM (simulate a Powermeter as iEM3155) -> EGX150 (gateway) -> Product reading Egx150
I may not have the right script. Can you tell me one that will allow me to carry out my project? LM (simulate a Powermeter) -> EGX150 (gateway) -> Product reading Egx150
All the best
Dominqiue


RE: LM, EGX150 and PM simulator - admin - 04.08.2022

This is the script: https://forum.logicmachine.net/showthread.php?tid=181
But it will be rather complicated because meters use 4/8 byte values which require multiple registers to store them.


RE: LM, EGX150 and PM simulator - SigmaTec - 04.08.2022

(04.08.2022, 13:16)admin Wrote: This is the script: https://forum.logicmachine.net/showthread.php?tid=181
But it will be rather complicated because meters use 4/8 byte values which require multiple registers to store them.

Thank's dear admin,

if I understand this script correctly, it initializes registers starting from 0. If I force the registers to 3000, 3002 and so on, I get an "out of bounds"!

Any idea for me?


RE: LM, EGX150 and PM simulator - SigmaTec - 05.08.2022

Dear admin,

maybe I misspoke, excuse me please...

My need is the following :
With an Lua script, I have to write register's values in an EGX150 gateway, as if LM was a Powermeter.

My objets :
"0/0/1" = "3000" (register name 1, float32)
"0/0/2" = "3204" (register name 1, int64)
and so on...
"1/0/1" = 32 (register 1 value)
"1/0/2" = 22000 (register 2 value)
and so on...

EGX150 : @IP 192.168.1.104
LM : @IP192.168.1.49, slave ID 101
Modbus TCP port : 502


Could you teach me how to do this please ?

Thank's and have a good day.

Dominique