Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Controling Shelly relays

As part of a Labview program that I have written for control of our two Victron Solar sytems I also need to control some Shelly relays for addtional function. Each of the Shelly relays is controlled using its unique IP addess with on/off commands appropriate. Thoughts were to use an event structure which works fine with the pushbuttons but I want to be able to activate the relays depending on battery state of charge, time of day etc. Problem I have is that the event structure does not seem to generate an event from a a property node or local variable. Tried the (signalling) property node and went around in circles. Grateful if someone could offer some thoughts, thanks.

Labview Version 8.5
Labview Version 8.6
Labview Version 2014
0 Kudos
Message 1 of 4
(143 Views)

You should learn a bit more about state machines. Rather than trying to activate a button which then activates an event frame which then does what you want to do, you can put the actual action to control the relay in a state and then put this state name in the state machine queue in both your UI button event and when your communication with the relevant device detects that this action is needed.

Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 2 of 4
(127 Views)

Thanks for your blunt answer,

Labview Version 8.5
Labview Version 8.6
Labview Version 2014
0 Kudos
Message 3 of 4
(109 Views)

@jack1 wrote:

Thanks for your blunt answer,


It wasn't my intention to be blunt. There are many state machine architectures and the one I usually use when it involves user interface handling is the JKI State Machine. It takes a little experience to get acquainted with working with state machines but once you understand the principle it is extremely powerful and flexible.

Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 4 of 4
(103 Views)