How to read individual bits from holding registers of VFDs in OCMC Configuration ? , I've tried typing the address like that 403201:0 or 403201.1 but it doesn't work .
How to read individual bits from holding registers of VFDs in OCMC Configuration ? , I've tried typing the address like that 403201:0 or 403201.1 but it doesn't work .
Thanks for clarifying, I just assumed you were using a brand specific driver but Modbus should be fine and is well used by many others.
In MBTCP you are correct in that adding :1 to 16 extract the bit,
and the MBTCP driver has some settings related to how bits are managed, witch can make things slightly confusing when doing a direct bit reference, but i guess you have already sorted that out since you are using them in animations.
By default Swap bytes are turned on, witch reverses the bit order, and by default it will start on bit 1 (not 0).
But you mention that it works for you on your memory words, but not the holding registers (?), could it be that it identifies those as another datatype? Perhaps the value you try to access is in a format not supporting bit references. (older versions did not support 64 bit datatypes, but that should be ok in versions 2020 R2 and above).
Check in the diagnostics what it displays if you retrieve the full register (without the ':x')
The alternative is to bring in the full integer value in to a tag in InTouch and do the bit-masking here.
Ether by a discrete IO tag, referring to the integer value, getting the bit here.
Or by a data change script that copies the correct bit value to a memory tag
Then you set up alarming on this additional tag.
Not the ideal solution, but if everything else fails, its at least an option.
I am not personally experienced with the Schneider VFD so perhaps there are some special cases here.
Perhaps someone here on the forum has more knowledge on how this is done.
Reviewing the documentation for the MBTCP driver could also gain some insights on how this is managed.
https://docs.aveva.com/bundle/sp-cdp-drivers/page/192116.html
(older pdf version)
https://gcsresource.aveva.com/support/OIServer-RME/2020/OIMBTCP.pdf
Reaching out to techsupport might also be an alternative to see if they have some better ideas.
Thank you a lot ,
The problem was in the configuration of reading bits (as it was kept at default as you mention : Swap Bits were checked and the order is B1 B2 .. B16 ) So I need to swap when type the item reference .
For example
If I need to read bit 0 from the holding registers of VFD I need to type the address in this way ( XXXX : 16)
If I need to read bit 2 , I need to type the address in this way ( XXXX : 14)
If I need to read bit 15 , I need to type the address in this way ( XXXX : 1)
OR I can change the configuration by unchecking swap .
I'll go ahead in the first way I mention so not to rebuild the animation I've done .
Thank you again .
Great! I'm glad you got it sorted out!
Thanks for providing the feedback and present the final solution that worked for you.
Have a great day!
Great! I'm glad you got it sorted out!
Thanks for providing the feedback and present the final solution that worked for you.
Have a great day!