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 - andrew_pj

Pages: 1 2 [3] 4 5 6
31
Support Questions / Re: ObjectDisposedException
« on: May 06, 2015, 08:55:59 PM »
Thanks Archie.
The form is actually like a pop-up window.
And I close by clicking default close button on top right of the form.

After testing I noticed that the "MaximumHoldTime" of "BasicButton" is 3000 (default).
So when I click the button, the value may be held for 3 seconds.
If the value remains (not returned to 0 yet), and I close the form, the error appears.

Best regards,
Andrew

32
Support Questions / ObjectDisposedException
« on: May 06, 2015, 04:15:10 AM »
I am using AdvancedHMIBetaV398g, and communication with ModbusTCP.
Scenario:
I have GraphicIndicator. Clicking this indicator, showing form.
Code: [Select]
Private Sub GraphicIndicator1_Click_1(sender As Object, e As EventArgs) Handles GraphicIndicator1.Click
        AdvancedHMI.BAV01.Show()
    End Sub

The form contains BasicButton. Clicking button, it writes 1 to 412288.
Function works fine. But after closing the form, ObjectDisposedException occur.
Please advise the solution.
Thank you.

Best regards,
Andrew

33
Support Questions / Re: Microsoft Visual Basic 2010 Express
« on: May 04, 2015, 09:06:28 PM »
Thanks for the link.

34
Support Questions / Re: Microsoft Visual Basic 2010 Express
« on: April 30, 2015, 05:06:35 AM »
Dear Pal,

Does upgrading with SP1 solve the problem?


Best regards,
Andrew

35
Support Questions / Microsoft Visual Basic 2010 Express
« on: April 30, 2015, 02:56:42 AM »
Dear Archie,

Just downloaded AdvancedHMIBetaV398g.
But it can't be opened with Microsoft Visual Basic 2010 Express.

The last version I used AdvancedHMIBetaV397e, can be opened with MV Basic 2010 express.
Any plan to downgrade?
Thank you.


Best regards,
Andrew

36
Support Questions / OpcDaCom - InvalidCastException
« on: February 12, 2015, 12:43:05 AM »
Dear Archie,

I am using AHMI version 3.97e.
Got an error "InvalidCastException" on OpcDaCom.vb (Refer to attachment for details)
This occurs when I close the program by calling Application.Exit()
Please advise, Thank you.


Best regards,
Andrew

37
Support Questions / Re: Modbus Ethernet OPC Server
« on: February 11, 2015, 10:46:01 PM »
I don't know exact details on the Iconics OPC server and all OPC servers seem to be different in one way or another. But just a couple guesses, it my be getting confused with the Topic and group being the same name. Also I would expect the PLCAddressValue to be a Modbus address such as 40001

Dear Archie,

As you suggested, I tried to declare only in Group section.
Then try adding prefix "BF2" (which is my group name) before the tag name.
And out of the blue, it works!

For PLCAddressValue, it isn't Modbus Address because address has been declared in OPC Server.
Please refer to attachment for details.

Thanks for helping.


Best regards,
Andrew

38
Support Questions / Re: Modbus Ethernet OPC Server
« on: February 11, 2015, 10:20:00 PM »
Is the OPC Server on the same PC or is it a remote OPC server? Any reason you are using OPC instead of the native ModbusTCP driver?

It is on the same PC.

In my previous projects, I have been using this Modbus Ethernet OPC Server.
So, just wondering if it is possible to integrate AHMI with Modbus Ethernet OPC Server.

FYI, using ModbusTCP everything is working properly.
However, the drawback is on %MD, as I mentioned in my previous thread.
There should be extra conversion to %MW in my PLC.

How does the naming work for OCPComDA?


Best regards,
Andrew

39
Support Questions / Modbus Ethernet OPC Server
« on: February 11, 2015, 10:02:01 PM »
Dear all,

Have anyone ever used AdvancedHMI with ICONICS Modbus Ethernet OPC Server 3.53?
I am using WAGO PLC and trying to use OpcDaCom in AHMI.

Basically, with ICONICS Graphics software, this is already working properly.
However, I want to try using AHMI, but not familiar on how to implement with OpcDaCom.
Please refer to attachment for details.
Thank you.


Best regards,
Andrew

40
Support Questions / Re: DOUBLE WORD - WAGO PLC Modbus TCP
« on: February 03, 2015, 10:00:22 PM »
Hi Archie,

I think it is uncommon to use %MD in modbus.
So, it should be converted to %MW internally in PLC before going to modbus.
Sorry for the mess.


Best regards,
Andrew


41
Support Questions / Re: DOUBLE WORD - WAGO PLC Modbus TCP
« on: February 03, 2015, 03:17:42 AM »
When using a double word, you have to put an L in front of the address. Try L414690

Try that and doesn't work. It's still showing 16256.

42
Support Questions / DOUBLE WORD - WAGO PLC Modbus TCP
« on: February 02, 2015, 10:37:22 PM »
Dear all,

Does anyone know how to handle DOUBLE WORD (%MD)?
I am using version AHMI 3.97e and WAGO 750-881.
I am able to communicate + read & write data between WAGO and AHMI.

However, when using %MD, unexpected result occurs.
It will show very large data, described in the following scenario:

I modify value of %MD1200 = 1
Then, in AHMI, the value is showing 16256 at address 414690.
I expect to get 1 in AHMI, which is the case when I modify %MW1000 = 1
In AHMI, the value is showing 1 at address 413289.

Please refer to attachment for more details.
Thank you.


Best regards,
Andrew

43
Support Questions / Re: MessageListByValue and ModbusTCP
« on: February 02, 2015, 08:20:40 PM »
Sorry, I was typing faster than I was thinking. When reading L40001, then bit 40002.0 will represent 65536 because it is shifted by 16 bits. So your alarms numbers would be like this:

40002.0 = 65536
40002.1 = 131072
40002.2 = 262144
etc.

It does the trick.

Quote
The problem with this method is that if 2 alarms are active at the same time, then you will get an unknown message.

However, this doesn't work for my case because it is possible for alarms to come at the same time.
Even if using 1 address (e.g 40001), it should be able to display more than 1 alarm/message.
MessageListByValue only can display 1 message according to the message value.

So in this case, the alarm mapping should be done in PLC,
and then use queue/timer to display the list of active alarms by modifying the address (specified in MessageListByValue).

Hope there will be more features for MessageListByValue in the next version.
Thank you.


Best regards,
Andrew

44
Support Questions / Re: MessageListByValue and ModbusTCP
« on: January 29, 2015, 05:07:11 AM »
Ok, so you're really doing a message by bit. There may be one trick that can get you more alarms. If you use the address L40001, it will give you a 32 bit read that spans over 40001 and 40002

So let's say you use 40002.0, then the alarm number would be 256

Sorry Archie, I am unable to understand what you mean.
I tried to change the address to L40001, then when i change 40002 into 1 (meaning 40002.0 becomes TRUE).
It generates unknown alarm. In fact according to my alarm list, value 256 should generate Alarm 8.
Please correct me if i'm wrong.

So I was trying to do different method.
Mapping all my list of alarms into 1 modbus address using DataSubscriber.
Putting all the bits condition into array-of-boolean, if certain bit is TRUE or even FALSE, it will generate ALARM or ALARM NORMAL message.

Code: [Select]
Private Sub DataSubscriber1_DataChanged(ByVal sender As System.Object, ByVal e As MfgControl.AdvancedHMI.Drivers.Common.PlcComEventArgs) Handles DataSubscriber1.DataChanged
        Dim arrBool(15) As Boolean
        Dim temp As Integer
        Dim iCtr As Integer

        If e.PlcAddress = "413388" Then
            temp = e.Values(0)

            For iCtr = 15 To 0 Step -1
                arrBool(iCtr) = 0
                If temp > (2 ^ iCtr) - 1 Then
                    arrBool(iCtr) = 1
                    temp = temp - (2 ^ iCtr)
                End If

                If arrBool(iCtr) = 1 Then
                    ModbusTCPCom1.Write(465535, iCtr * 2 + 1)
                ElseIf arrBool(iCtr) = 0 Then
                    ModbusTCPCom1.Write(465535, iCtr * 2 + 2)
                End If

            Next iCtr
        End If
End Sub

Sadly, this is not working.
Basically I successfully map all bits of my alarm into array.
But because the MessageListByValue only gets the last number from the specified address (465535), finally it only generates 1 message.

I was thinking about allocating the message numbers into queue in for loop, then using timer to generate in sequence.
But before i go too far, i would try to get advise from you.
Maybe more efficient solution than my brute force.
Thank you.


Best regards,
Andrew

45
In the DataChanged event, it will return the address and value in the PlcComEventArgs object (e). So you can do this to determine which value is returned:

if e.PlcAddress="414940" then
   Me.Text="The value for 414940 is " & e.values(0)
elseif e.PlcAddress="414942" then
.
.
end if


Thankss, that is a lot better way to do.

Code: [Select]
Private Sub DataSubscriber2_DataChanged_1(ByVal sender As System.Object, ByVal e As MfgControl.AdvancedHMI.Drivers.Common.PlcComEventArgs) Handles DataSubscriber2.DataChanged
        ' temp = 414940
        Dim temp As Integer

        ' temp2 = 414942
        Dim temp2 As Integer

        If e.PlcAddress = "414940" Then
            temp = e.Values(0)
        ElseIf e.PlcAddress = "414942" Then
            temp2 = e.Values(0)
        End If

End Sub

Pages: 1 2 [3] 4 5 6