Home AMX User Forum NetLinx Studio

Offsite Debugging and G3 Web Control Problem


I have a remote site at which there is a Netlinx based control system. There is a G3 web control page that mimics one of the local AXT panels. If I open up the G3 panel online AND start debugging in Studio to watch some variables, a devchan group of buttons on the web control panel starts flashing somewhat randomly with nothing in the code to turn those buttons on, and I also lose some variable text buttons.

The only thing that stops this once it starts is to re-upload the code and the G3 panel design.

The only thing that comes to mind is that three DEFINE_COMBINEs exists in DEFINE_START combining the three devices used of two local AXT panels and the G3 web panel with a virtual panel, referred to in the code. I've heard of strage things occuring as a result of device combinig, but I can't see why in this case.

Any thoughts come to mind? If you need any more detail about the system, ask and I'll post it.

Thank you!!


  • DHawthorneDHawthorne Posts: 4,584
    I would take the DEFINE_COMBINE out of start up, and replace them with a COMBINE_DEVICES for the web panel in an online event, likewise un-combining it in an offline event. Typically for this kind of thing, I only combine the web panel and the virtual, then stick that virtual and the physical panel in an array, using the array references instead of discrete panel references for my code. That way events and notifications to the virtual are harmless, and still act on the physical panel. When the web panel goes online, it combines with the virtual, and when it goes off, the master isn't still trying to send and receive to it.

    You could still just reference the virtual by combining it to the physical panel, but your online event would then have to break that combine, then combine all three. Likewise, the offline event would have to break the combine, then re-combine the physical panel. It would happen fast enough as to be transparent to the user.
  • TurnipTruckTurnipTruck Posts: 1,485
    Are the COMBINE_DEVICES statements additive? Meaning if I combine devices 1, 2 and 3 and then uncombine number 3, do 1 and 2 stay combined? Likewise if 1 and 2 are combined, then 1 and 3 are combined, are 1,2 and 3 now combined?

    Thank you.
  • DHawthorneDHawthorne Posts: 4,584
    You can't uncombine a single device, the uncombine statement only takes one argument, the name of the virtual, and uncombines everything that was combined with it in one shot. So if you want a dynamic set of combined panels, you must uncombine them all,then re-combine the ones you wish to stay combined. It happens very fast, you can't tell the panel lost it's combine for the millisecond the operation takes to complete.
  • TurnipTruckTurnipTruck Posts: 1,485
    Thank you, very helpful.

    Is there an "IF" statement for checking a device's online status?

    Something like


    This would be helpful after an uncombine affects several devices.

  • DHawthorneDHawthorne Posts: 4,584
    I thought I saw a code snippet somewhere showing a built-in online test, but I didn't jot it down. I've always just tracked it myself in online/offline events and set a flag.
  • dchristodchristo Posts: 177
    Is there an "IF" statement for checking a device's online status?

    You can use the DEVICE_ID to determine if a device is online:
    IF(Device_ID(dvDevice) <> 0)
       // Device is Online

Sign In or Register to comment.