Lookout

cancel
Showing results for 
Search instead for 
Did you mean: 

In Lookout 5.0, is there a simple way to have a (client) PushButton control write a hard-coded value into a writable data member in another (server) process?

All I want to do is set a pre-determined Modbus holding register to a pre-determined value by having the operator press a button.

I have been able to do this using extra Pot control in the client. I created a connection from the Pot.Value member to an
IF(pushbutton, myvalue, Pot.Value)
expression and then set the Remote Position Source of the Pot to the server data member I want to update.

This seems to work, but begs two questions...

1) Is there a simpler way to just set a value?

2) What is the difference between the Pot remote source and the Pot value data member?
0 Kudos
Message 1 of 3
(2,947 Views)


Hi,

A simpler way is:

Modbus1.40001 = IF(PushButton1, myValue, Modbus1.40001)

Here, as you can see, when the PushButton is not pressed, we just write the current value of the Modbus register back to itself -- thus not really changing anything.

BTW, Pot Remote versus Local in a nutshell tells us where the value of the Pot resides. A remote source sets the value of the Pot to the remote source's value. So, as you discovered: if a Pot's remote source is connected to say Modbus.40002, the Pot will reflect this Value. Whenever the 40002 reister changes, Pot's current value changes to reflect that. Whereas a local (non-remote) Pot's value is whatever the Pot is set to on the Panel. Lookout's Online Help goes into much detail describing this; c
heck it out.

Hope this helps.

Rgds,

Khalid 🙂


0 Kudos
Message 2 of 3
(2,947 Views)
Doesn't this cause the server process to be dependent on a control in a client process now? How would I reference a Pushbutton control in a client process, if an instance of the client may or may not be running from more than one workstation?

BTW, I understand that the Remote Source says that the value is kept remotely. I also understand that a "Writable" value source allows the operator to change the remote value by manipulating the pot in the client process. What I was refering to was the confusion between the pot displaying and "changing the value of the remote data member" and the pushbutton's "changing the value of the pot" (which incidentally changes the value of the remote data member).

This just seems odd to me.

Is there not a "pushbutton li
ke" control that just writes the value? I mean, a text-entry control allows you to manipulate a remote data member directly. There is no control that could do this with a click?
0 Kudos
Message 3 of 3
(2,947 Views)