Machine Automation Forum
A forum addressing machine automation solutions for the complete machine lifecycle. Including offers like Machine Advisor, Modicon PLC/PacDrive, Lexium or Preventa. Discuss and share knowledge on offers relating to cloud-based service platforms, machine localization and monitoring, industrial operations control, motion products as well as safety function!
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-10-31 03:42 AM
@LeTomas,@FedericoM,@Bastian_Schmitz
Hello,
Has any one succeeded on reading registers 3020,3000 for PM5110 with ESME Using M241 PLC MODBUS.
i configured my M241 SL2.
The data access type set to function code 03 for read only
1.The master MODBUS IO SCANNER is showing running.
2.the generic bus shows an orange triangle
When I set my data access type to function code 16 the orange triangle turn to running and bus runs
but I still could not see any voltage values reading.
see attachment.
thanks
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-10-31 03:58 AM
Hi @kasmic_mike
I have played with one of the PM5xxx in our lab with the M262.
Please check the example project in the next link:
https://schneider-electric.box.com/s/lhuus6bvlcivkmkbxvqsn9fc26c26ffa
In the project you will see that I have used the FC03 along with some function that i have done to convert the 2 word to real.
Check if this example works on your side with the M241, then change/add another channel to access to the registers that you want and be careful with the length of the variables.
Best regards,
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-11-02 07:44 AM
Hello,
there are to tricks to reach good result.
From modbus.org >
Registers are addressed starting at zero. Therefore register numbered 1 is addressed as 0.
To read voltage registers starting from register 3020 via M241 Modbus IO scanner you need to ask for number of register minus one to ask register address so 3019 = 16#0BCB.
The reason of your error is that Voltage value is FLOAT32 what is in 2 registers.
If Modbus request is moved by one register you ask not valid data and get Exception answer.
The second is that PM5000 and M241 use different word order in FLOAT32 so you have to swap WORDs to get correct result.
To that reason you get nice example and function FC_FLOAT32_REAL from Leandro Tomas Ahumada.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-11-03 08:25 AM
thanks @Marian_Pavlik @LeTomas
your guidance was really helpful. I was able to read register for voltage, I used the excel float32 to real at above link to confirm reading.https://ckm-content.se.com/ckmContent/sfc/servlet.shepherd/document/download/0691H00000EF0hoQAD
Am now working on the swapping WORDs. then display them on HMI
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-10-31 03:58 AM
Hi @kasmic_mike
I have played with one of the PM5xxx in our lab with the M262.
Please check the example project in the next link:
https://schneider-electric.box.com/s/lhuus6bvlcivkmkbxvqsn9fc26c26ffa
In the project you will see that I have used the FC03 along with some function that i have done to convert the 2 word to real.
Check if this example works on your side with the M241, then change/add another channel to access to the registers that you want and be careful with the length of the variables.
Best regards,
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-10-31 05:05 AM
thanks i am going to check through the example critically. however if you have some examples with LD blocks or literature it will guide me through. because am not so good with the structured programme.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-11-02 07:44 AM
Hello,
there are to tricks to reach good result.
From modbus.org >
Registers are addressed starting at zero. Therefore register numbered 1 is addressed as 0.
To read voltage registers starting from register 3020 via M241 Modbus IO scanner you need to ask for number of register minus one to ask register address so 3019 = 16#0BCB.
The reason of your error is that Voltage value is FLOAT32 what is in 2 registers.
If Modbus request is moved by one register you ask not valid data and get Exception answer.
The second is that PM5000 and M241 use different word order in FLOAT32 so you have to swap WORDs to get correct result.
To that reason you get nice example and function FC_FLOAT32_REAL from Leandro Tomas Ahumada.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-11-03 08:25 AM
thanks @Marian_Pavlik @LeTomas
your guidance was really helpful. I was able to read register for voltage, I used the excel float32 to real at above link to confirm reading.https://ckm-content.se.com/ckmContent/sfc/servlet.shepherd/document/download/0691H00000EF0hoQAD
Am now working on the swapping WORDs. then display them on HMI
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-04-26 12:41 AM
Hi!
Very useful the excel. Do you have a version of it for reading some energy (4 registers) parameters?
Many thanks in advance!
Link copied. Please paste this link to share this article on your social media post.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.