AdvancedHMI Software
General Category => Support Questions => Topic started by: Gruber on April 16, 2014, 07:14:14 AM
-
Hello together,
i am new here and also new in VB.
I tryed to get the advancedHMI runnig with Twincat 2.
After some Problems i got it runnig.
Now my Problem:
When i create a project
MomentaryButton with
PLCAddressClick .butten
PLCAddressVisible .light
My TwinCATComm1 has the ip from the PLC ,TargetAMSNetID and the Port.
When i start the Project the Click works and Change states in my PLC but the visible dont.
The same when i try the tutorial from the web with a Counter.
So it seems that i can send data to the PLC but not recieve any data from the plc.
My System ist the following.
Twincat 2 on a CX1020 with TwinCAT OPC UA Server.
My working System ist a local PC with Win7 VisualBasicStudioExpress2013 and AdvancedHMIBeta361
I hope someone can help me.
Thanks
-
Does the PC that you are running AdvancedHMI on have TwinCAT installed? If so, that is the problem. The TwinCAT router captures the responses from the PLC and prevents them from getting to AdvancedHMI.
See a more detailed explanation here:
http://advancedhmi.com/forum/index.php?topic=159.0 (http://advancedhmi.com/forum/index.php?topic=159.0)
-
No the TwinCat is only on the CX not on the local PC.
-
If the PC never had TwinCAT installed on it, then you will have to install Wireshark to capture the packets. You will need to look at the AMS packets and see what port they go to.
-
Ok i run the Program now but i dont know what to do with These informations...
192.168.115.64 is the CX
192.168.115.80 is the local PC
forgotten to activate the ports
so here is the new Image
-
I see the Writes, but I do not see an ADS Read
-
So i have no idea why there are only write packets and no read packets. Have i forgotten soemthing? Do you have an idea?
I take a jpg of my Debugging protocol
-
Add a BasicLabel to your form and put a valid variable name in the PLCAddressValue property
-
Sry i dont really know what you mean.
Can you write me an example?
-
Ok i found it.
I placed a Basic Label and in the PLCAdressValue i wrote ".day"
This is a word-variable (Global variable) where i save the Name of the current day.
Start Debugging and still the same.
-
Now do a Wireshark capture with the BasicLabel. Start Wireshark before starting AdvancedHMI. There are some initial route configurations I need to see. Then you should see the read packets 2-3 tines per second.
-
Ok ist done. But there are only packets when i start hmi after the start only when i press a button in the hmi.
see the protocol...
-
I think I found the problem. Open TwinCATComm.vb and go to line 418 and change it to this:
Private Sub PollUpdate(ByVal sender As System.Object, ByVal e As System.EventArgs)
'If m_DisableSubscriptions Then Exit Sub
If True Or (sender Is GetType(System.Timers.Timer)) Then
-
I checked the latest unreleased version and this is what line 418 should be:
If TypeOf (sender) Is System.Timers.Timer Then
-
Ok ist runing now .
Thanks for your help
-
Hello,
I read your post and I think you have successfully connect twincat software and advancedhmi. Please can you help me how to connect this two software, I don't have any idea how this things works. I had read many threads/forums and video on youtube and all of it not works. I think its outdated. The version of my twincat is v2.11.2241 and AdvancedHMIBetav323.
Any of your help is very appreciated.
Thank you,
Niño
-
I read your post and I think you have successfully connect twincat software and advancedhmi. Please can you help me how to connect this two software, I don't have any idea how this things works. I had read many threads/forums and video on youtube and all of it not works. I think its outdated. The version of my twincat is v2.11.2241 and AdvancedHMIBetav323.
Thank you,
Niño
First off, start with the latest version of AdvancedHMI, which is 3.61
What is your system configuration? Is the TwinCAT runtime on a CX controller, another PC, etc? Are you running AdvancedHMI on a different PC than you are using to program TwinCAT?