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.


Topics - robkwan

Pages: [1] 2
1
Support Questions / Problem with ModbusTCPCom and DataSubscriber2
« on: June 26, 2019, 06:36:44 PM »
Using AdvancedHMIv399xR1, DataSubscriber2 linked to ModbusTCPCom. I added a bunch of registers to DataSubscriber2, process the register value changes in DataSubscriber2_DataChanged. There are situation (random?) that a register value changed but the change does not pickup by DataSubscriber2_DataChanged; when this happens, DataSubscriber2_DataChanged does not report any more changes on that register but still does for other subscribed registers.

When the problem occurs, I switch to an error screen that displays some debug counters in DataSubscriber2_DataChanged and also manually read that register using modbusTCPCom.Read. The manual read reports the register value is changing but does not trigger DataSubscriber2_DataChanged because all debug counters did not change.

Any workaround?

2
Support Questions / Missing modbus drivers in toolbox pane
« on: June 07, 2019, 02:55:45 PM »
Compiled the latest AdvancedHMIv399xR1 in VS2010 with SP1. The Modbus drivers are not in the toolbox. I see the ModbusRTUCom.vb and ModbusTCPCom.vb files in the AdvancedHMI\AdvancedHMIDrivers\Modbus folder. How to get these 2 drivers to show up in the toolbox?

3
How to enter string into the basicLabel using the alphanumeric virtual keyboard?

When alpha is entered, hit the ENTER key, this error is displayed. "Failed to validate value. Conversion from string ABC to type Double is not valid.

I think the 2 tags associated with the basicLabel need to be string. How to declared a Modbus tag is for a string value?

I need to have a textbox to enter password from a virtual keyboard.

4
Open Discussion / scrollbar width
« on: March 02, 2016, 02:06:33 PM »
I need to increase the listview control's vertical scrollbar width to be useable on a touch panel without using a stylus. I am trying to avoid using 2 buttons (up/down) to simulate the scrollbar.

Any suggestion?

5
Is it possible to force a refresh on modbusTCPCom and dataSubscriber2 to get a set of fresh register values?

The application in some error handlers need to get fresh data to update the state of Windows controls. I could manually read all the registers and update the button/editbox states (code already in dataSubscriber2 change event). Is there a way to get modbusTCPCom/dataSubscriber2 to do it as if the applicable has just started?


6
Support Questions / modbusTCPCom and dataSubscriber2 optimization
« on: January 06, 2016, 12:03:23 PM »
For large number of tags and readability reasons, I used two dataSubscriber2 connected to one modbusTCPCom. The application is extreme slow and not usable, all Windows controls appear to frozen. Problem went away with one dataSubscriber2.

Is it allow to have multiple modbusTCPCom on the application, all have identical setting for the IPAddress & TcpipPort properties?

I tried on a simple application with sliders driving gauges, it seems to work. Then I can have one dataSubscriber2 for each modbusTCPCom which will have different PollRateOverride based on tag groups.

Can someone confirm multiple modbusTCPCom on the application is ok before I start update the application.

Any tip to manage large tag size.

7
Support Questions / DataSubscriber2 performance
« on: November 24, 2015, 03:32:15 PM »
Is there a performance advantage between these 2 cases:

DataSubscriber2 with 200 tags
vs.
4 DataSubscriber2 with 50 tags each

Also, want to set different pollrates for the few DataSubscriber2s, but it seems the value is hardcoded as mentioned here.
http://advancedhmi.com/forum/index.php?topic=287.msg1016#msg1016

8
Support Questions / graphicIndicator exception
« on: November 24, 2015, 11:24:00 AM »
AdvancedHMI V3.99a. I have a tabcontrol with 4 tabs. A graphicIndicator is on the 2nd tab.

If I exit the application without activate tab #2 at least once, system throws exception on exit. For testing, I moved the graphicIndicator to the tab #1 which is the default startup tab, no exception on exit.

The exception is in GraphicIndicator.vb in the Finally block.
    Protected Overrides Sub Dispose(ByVal disposing As Boolean)
        Try
            If disposing Then
                If SubScriptions IsNot Nothing Then
                    SubScriptions.dispose()
                End If
            End If
        Finally
            MyBase.Dispose(disposing)
        End Try
    End Sub

Exception details:
System.NullReferenceException was unhandled
  HResult=-2147467261
  Message=Object reference not set to an instance of an object.
  Source=MfgControl.AdvancedHMI.Controls
  StackTrace:
       at MfgControl.AdvancedHMI.Controls.GraphicIndicator.Dispose(Boolean disposing)
       at AdvancedHMIControls.GraphicIndicator.Dispose(Boolean disposing) in H:\Devel\HRS\VS\AdvancedHMI\AdvancedHMIControls\Controls\GraphicIndicator.vb:line 135
       at System.ComponentModel.Component.Dispose()
       at System.Windows.Forms.Control.Dispose(Boolean disposing)
       at System.ComponentModel.Component.Dispose()
       at System.Windows.Forms.Control.Dispose(Boolean disposing)
       at System.ComponentModel.Component.Dispose()
       at System.Windows.Forms.Control.Dispose(Boolean disposing)
       at System.Windows.Forms.TabControl.Dispose(Boolean disposing)
       at System.ComponentModel.Component.Dispose()
       at System.Windows.Forms.Control.Dispose(Boolean disposing)
       at System.Windows.Forms.Form.Dispose(Boolean disposing)
       at HRS_CAN.FormMain.Dispose(Boolean disposing) in H:\Devel\HRS\VS\HRS_CAN\FormMain.Designer.cs:line 20
       at System.ComponentModel.Component.Dispose()
       at System.Windows.Forms.Form.WmClose(Message& m)
       at System.Windows.Forms.Form.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
       at System.Windows.Forms.UnsafeNativeMethods.SendMessage(HandleRef hWnd, Int32 msg, Int32 wParam, Int32 lParam)
       at System.Windows.Forms.Control.SendMessage(Int32 msg, Int32 wparam, Int32 lparam)
       at System.Windows.Forms.Form.Close()
       at HRS_CAN.FormMain.buttonExit_Click(Object sender, EventArgs e) in H:\Devel\HRS\VS\HRS_CAN\FormMain.cs:line 546
       at System.Windows.Forms.Control.OnClick(EventArgs e)
       at System.Windows.Forms.Button.OnClick(EventArgs e)
       at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
       at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ButtonBase.WndProc(Message& m)
       at System.Windows.Forms.Button.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
       at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
       at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
       at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
       at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
       at System.Windows.Forms.Application.Run(Form mainForm)
       at HRS_CAN.Program.Main() in H:\Devel\HRS\VS\HRS_CAN\Program.cs:line 18
       at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
       at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
       at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
       at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ThreadHelper.ThreadStart()
  InnerException:


9
Support Questions / Multiple instance of modbusTCPCom
« on: November 11, 2015, 05:56:29 PM »
Application form runs PopupForm.ShowDialog() which has basicLabel mapped to PLC address. Click on basicLabel brings up virtual keypad.

I pass the modbusTCPCom component by setting to a static variable, then on PopupForm.Load, set the basicLabel.CommComponent from the static variable.

The basicLabel displays "CommComponent Property not set" when Enter is pressed on the keypad.

It should work? If not, is there a workaround other than dropping a modbusTCPCom component onto PopupForm and run another instance of Modbus server for the new TCP port.

10
Tips & Tricks / Gradient label with text
« on: November 05, 2015, 10:47:09 AM »
Anyone know of a gradient label with text that can be use in AdvancedHMI?
I'm unable to find a suitable control from the standard toolbox.

11
Support Questions / Problem with 399a ....
« on: October 30, 2015, 04:33:50 PM »
Upgraded from 398t to 399a.

The development computer is Win7 Pro 64-bit, the application runs fine.
The 2 HMI panels are Win7 Pro 32-bit, the application runs at turtle pace, not usable; click any windows' control takes over 5 mins to response or does not response at all.

The code has a few modbusTCPCom read and write in timer1_Tick event. The slow problem goes away if the timer is disabled or all the modbusTCPCom codes in the timer event are commented out; all windows' buttons and tabcontrol are responsive.

Not sure if the following 2 changes in the 399a release note have anything to do with the slow problem in the 32-bit computer.
Modbus - Writes are synchronous to avoid  SendQue full
Modbus - Improved response with Waithandle

I am unable to troubleshoot since the HMI computers do not have VS installed and they belong to the client.

I need a quick fix else will have to rollback to 398t.

Thanks

12
Support Questions / Unsigned for 3XXXX registers
« on: August 17, 2015, 05:14:07 PM »
The "U" prefix works for 4XXXX registers. But not the 3XXXX registers, error is invalid format.
Is this a bug?

13
Support Questions / Modbus PLCAddress alias
« on: August 12, 2015, 05:52:39 PM »
It is possible to enter alpha in the PLCAddressValue property, ex: Addr.TagDO.TagMWarning instead of 10001?

namespace Addr
{
    static class TagDO
    {
        public const string TagMWarning = "10001";
    }
}

14
Support Questions / multiple screens - navigation and driver
« on: July 22, 2015, 03:06:22 PM »
Need tips to handle multiple screens. The application has 4 screens; each screen has previous and next buttons to cycle the screens.

1) I am thinking of having a greeting class/screen to instantiate all 4 screens and set visible to false. After a few seconds, greeting screen goes invisible and screen1 is visible. The previous and next buttons will just change the screen visible property.

2) It seems each screen needs to have a modbusTCPCom component, no good. Is it possible to have only one for all the screens to use?

3) The HMI app runs on two computers (local and remote). The local computer can access all r/w Modbus registers, but the remote computer can only access the r Modbus registers. Is there a better way to handle this other than setting all the write PLCAddress to blank?

4) How to get the FormChangeButton control show up on the toolbar?

15
Feature Request / overload read & write functions
« on: July 20, 2015, 02:35:22 PM »
Please add additional read & write methods for integer.

Pages: [1] 2