I work the TModBusRTUDriver, TPLCBlock and TSerialPortDriver and I would like to read UINT64 (Unsigned long integer 64bit) values from TPLCBlock.
How can I do it?
Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
What's you PascalSCADA version and what's your environment (Delphi/Lazarus)?
If are you using Lazarus with development version of PascalSCADA, set the property TTagBlock.TagType to pttQWord, and use SwapBytes, SwapWords and SwapDWords to get the correct value.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
I work the TModBusRTUDriver, TPLCBlock and TSerialPortDriver and I would like to read UINT64 (Unsigned long integer 64bit) values from TPLCBlock.
How can I do it?
Thanks.
Please Sir.
What's you PascalSCADA version and what's your environment (Delphi/Lazarus)?
If are you using Lazarus with development version of PascalSCADA, set the property TTagBlock.TagType to pttQWord, and use SwapBytes, SwapWords and SwapDWords to get the correct value.
If you are using Delphi, note that it don't have QWord (unsigned int64) type.
I use Delphi 2007 with PascalScada 0.73.
Is there a solution about it?
No Sir. I tried to define a QWord type using this:
type
QWord = 0 .. 18446744073709551615;
But this generates a compiler error.
On Delphi the nearest setting is TagType = pttInt64.
2014-12-08 17:01 GMT-02:00 Lefteris leftmtps@users.sf.net:
--
The best regards,
Fabio Luis Girardi
PascalSCADA Project
http://sourceforge.net/projects/pascalscada
http://www.pascalscada.com
No Sir. I tried to define a QWord type using this:
type
QWord = 0 .. 18446744073709551615;
But this generates a compiler error.
On Delphi the nearest setting is TagType = pttInt64.
Can you reproduce this error?
I get error:
[DCC Error]: E2011 Low bound exceeds high bound
The same error here. This is why Delphi can't support QWord.
Ok, Thanks a lot!