AdvancedHMI Software

General Category => Open Discussion => Topic started by: halosome on September 27, 2019, 08:00:30 PM

Title: Decimal on number displayer, SevenSegment2 and Odometer
Post by: halosome on September 27, 2019, 08:00:30 PM
My PLC use integer for float (x10), for example 123 means 12.3

I tried to manipulate SevenSegment2 and Odometer and they seem to be unable to display 12.3; The digitalPanelMeter can show 12.3 by setting decimalPosition to 1.

Anything I have missed? Or is there any around way?

Thanks
Title: Re: Decimal on number displayer, SevenSegment2 and Odometer
Post by: Archie on September 27, 2019, 09:45:50 PM
On the Odometer after entering a PLC address in PLCAddressValue, you expand it down to set ScaleFactor to 0.1
Title: Re: Decimal on number displayer, SevenSegment2 and Odometer
Post by: halosome on September 28, 2019, 12:50:16 PM
Thanks it works!

There is another question, is it possible if i click the MomentaryButton, and it change a bit in an integer of a PLC address? Some thing like a PLC address to be 40001:10?

Title: Re: Decimal on number displayer, SevenSegment2 and Odometer
Post by: Archie on September 28, 2019, 12:53:35 PM
In Modbus your device must support function code 22 (bit mask write)
Title: Re: Decimal on number displayer, SevenSegment2 and Odometer
Post by: halosome on September 28, 2019, 01:51:43 PM
It's Productivity P2000 PLC. I am not sure if it support bit mask write. But if it supports, how can AHMI run code 22? I checked but don't see any method under ModbusTCPCom related to code numbers.
Title: Re: Decimal on number displayer, SevenSegment2 and Odometer
Post by: Archie on September 29, 2019, 07:28:05 AM
I am not sure if it support bit mask write. But if it supports, how can AHMI run code 22?
Whenever the driver is told to write a single bit within a word (e.g. 40001.0), it uses function code 22.