Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - EE_Kraig

Pages: [1] 2 3
1
Support Questions / Touch events are unresponsive
« on: September 14, 2018, 01:10:22 PM »
I'm using ModbusTCP with a touchscreen computer running Win10. When I touch a button sometimes it takes 2-3 presses before it responds. When using a mouse it works every time. It feels like main GUI thread blocking so I changed to a DataSubscriber model, it didn't make any difference. I thought it was a windows bug but I have a few other apps on other machines (not talking to a PLC) and they work fine.

Anything I can try to narrow down the problem?

2
Support Questions / Change Pilot Light color in code
« on: September 14, 2018, 01:04:58 PM »
I'm using a DataSubscriber to change a pilot light color but it's not working.

Code: [Select]
if (e.PlcAddress == "10014")
               {
                  if (e.Values[0] == "0")
                  {
                     plLowLevelA.LightColor = PilotLight.LightColors.Green;
                  }
                  else
                  {
                     plLowLevelA.LightColor = PilotLight.LightColors.Red;
                  }
               }

The code gets to this section just fine but the light color is always red.

3
Thanks! Worked for me too.

4
Clean unzip of V399w, open solution and build, no problems. I delete the MfgControl.AdvancedHMI.Controls.dll from the support folder in SolutionExplorer. Copy new dll to that folder and add back into project and Rebuild. I get errors and the Toolbox for the controls doesn't populate. I can replace the patched dll with the original (even just in WindowsExplorer) from the zip package, rebuild and all is well again.

My plan was to update to V399w and apply latest patches, it worked fine with Patch4 of the drivers.

5
Support Questions / Re: PC rebooted and wrote zeros to PLC
« on: April 18, 2017, 01:50:35 PM »
I don't think it was actually on startup but rather on shutdown. I'm guessing the PC closed the app before it tried to shutdown, or maybe it didn't and then the modbus driver freaked? Just wanted to mention it in case I was missing something.

6
Support Questions / Re: PC rebooted and wrote zeros to PLC
« on: April 18, 2017, 12:29:42 PM »
Yes and no. I have two DPMs that only write to the PLC from the control. I have three AnalogValueDisplays that write from the control and in code I do write to the same values on an event, e.g. ButtonClick.

I should add this is ModbusTCP

7
Support Questions / PC rebooted and wrote zeros to PLC
« on: April 18, 2017, 10:38:45 AM »
Last week the PC running AHMI was in the process of installing updates and rebooting and for some time it was on the "please don't turn off" Win10 screen. Somewhere during that process, it set all the PLC registers that the app writes to, to zero. Trying to understand why/when it wrote zeros and if it's a bug, intended, etc.

8
Support Questions / ModbusTCP driver invalid cast
« on: April 03, 2017, 05:25:30 PM »
OK - modbusTCPCom1.Write("00014", "1");
OK - modbusTCPCom1.Write("00014", "0");
OK - modbusTCPCom1.Write("00014", "TRUE");
ERROR - modbusTCPCom1.Write("00014", "FALSE");

The error is conversion from String to Double is not valid.

9
Support Questions / Re: SelectorSwitch graphics alignment
« on: March 30, 2017, 09:00:57 AM »
Do the SelectorSwitches appear to be a few pixels higher on the legend plate than the button?

Yes

10
Support Questions / SelectorSwitch graphics alignment
« on: March 22, 2017, 05:04:52 PM »
I have a couple MomentaryButton controls on a page and I have a couple SelectorSwitches on another page that are in the same position. I noticed that when I switch back and forth, the selector switch center point of the graphic is not the same as the button, so it looks like the switch moves a bit.

Maybe it doesn't bother anyone else but thought I'd point it out.

11
Archie,

But when I make the modification that Godra suggested in DigitalPanelMeter.vb, it works splendid and I actually prefer it that way I wouldn't mind switching the ValueScaleFactor to a divide. So what does the patch do? It would maybe be handy to be able to do either a divide or multiply scale.

12
I have been able to replicate, but only by writing to a 16 bit integer. When it converted 1 to 60000, it overflowed the integer and threw that exception. Are you writing to a DINT or INT?

The register in my PLC is a UDINT but if I try to enter anything in the DPM larger than 2147483647 (scale factor = 1) I get this error:

"Failed to write value. Value is either too large or too small for an Int32."

13
Visual Studio 2013 shows the error that EE_Kraig mentioned.

It is possible to switch "/" with "*" and use 60000 as KeypadScaleFactor, then it works (approximately line 368 inside the DigitalPanelMeter.vb):

m_ComComponent.Write(m_PLCAddressKeypad, CDbl(KeypadPopUp.Value) * m_KeypadScaleFactor)

Thanks again! KeypadScaleFactor = 60000 and ValueScaleFactor = 0.0001667 works perfectly.

14
Just unzipped latest version, dropped a DPM and used the same settings as you, error.

15
Visual Studio 2013 shows the error that EE_Kraig mentioned.

It is possible to switch "/" with "*" and use 60000 as KeypadScaleFactor, then it works (approximately line 368 inside the DigitalPanelMeter.vb):

m_ComComponent.Write(m_PLCAddressKeypad, CDbl(KeypadPopUp.Value) * m_KeypadScaleFactor

I'll try that, may work better for me. Thanks!

Pages: [1] 2 3