Red Lion Internal Tag to PLC tag

laserweld

Member
Join Date
Oct 2014
Location
Cleveland, OH
Posts
23
I could use some help programming a red lion HMI. What I am looking to do is have page where a set up guy can insert 10 parameters that would be saved and password protected so an operator can not change these parameters. I already have this page made. I am thinking the best way is to use internal bits. So on this setup page I will have the 10 parameters all with their own internal bit. These parameters will be saved and written to matching PLC bits (1 bit per parameter) when a button on the HMI, I'll call it "save" is selected. The matching PLC bits to my internal bits will have their own bits on another page that can be changed by the operator at any time. I do not want the internal bits to change if an operator changes the PLC bit so the setup guy can go back to his screen and load the original bits that were set initially by hitting the "save" button. I'm not sure the easiest way to do this. Not sure if there is a complex expression to use to achieve this or if there is an easier way to do it. Thanks
 
If I'm understanding you correctly, you could have 2 sets of 10 bits, 1 set controlled only by the HMI buttons, and the other that will, on hitting your save button, be written to with the values from the first set. You could do it with a for loop to iterate through an array of flags or just write out a block setting each bit equal to it's partner.
 
So for the 1 set of 10 bits that the operator could control. Those bits are bits going directly to the PLC. So for example if the operator enter 1.15, 1.15 goes to that bit in the PLC. The other set of bits that I want to be on the setup page that an operator will not be able to access, I would like that to be 10 bits that load into the other set of 10 bits when the "save" button is pressed. So if the operator enters 1.15 into lets call bit 1, and the setup screen had 1.10 in bit 1, bit 1 in the PLC will now change to 1.15 but bit 1 in the setup screen will still be 1.10. If the save button is now pressed again in the setup page, value of bit 1 (1.10) in the setup page will go to bit 1 in the operator screen therefore changing the PLC bit back to 1.10.

I am trying to convert an AB HMI to a red lion HMI. I do not have the AB HMI screen software. On the AB screen they are using a recipe menu to adjust part parameters. I would like to duplicate that on the red lion.
 
I'm assuming you have imported your PLC tags into your HMI program, and that they allow external read/write. In your button code, you can write something like the following:




plc bit 1 = hmi bit 1
plc bit 2 = hmi bit 2

...

plc bit 10 = hmi bit 10


OR if you define your tags as arrays you could do something like this:
int i = 0
for (i=0,i++,i<10)
plcbit=hmibit




Your setup tags will remain unaffected by any changes the operator can make, your operator will be able to change the bits they're supposed to when they need to, and any changes made and saved to the setup tags will overwrite the changes made by the operator.
 
I tried programming my save button as shown above PLC bit 1 = HMI bit 1, and I get a message "the expression has side effects" The PLC bit 1 works on my HMI and I can change the value if I enter a value on the HMI. Any idea why I would be getting this message when trying to write that code?
 

Similar Topics

The alarms ticker has the ability to show when an alarm is active and when an alarm is unacknowledged. Does anyone know if I can access the...
Replies
5
Views
6,198
While they came up quickly with a fix for the alarm date issue quickly I will have to drive around for a week or so, burning up a lot of fuel...
Replies
4
Views
268
From the Red Lion website, after some customer enquiries in the last week or so... Rev. March 25, 2024 [18:30] Just thought it might help a...
Replies
9
Views
280
How do you install update on Red Lion Crimson ver 3.1. Do I just need to run the exe file on the host server?
Replies
1
Views
113
Hello All, I need the ability to remotely reboot a Red Lion CR3000 HMI. Due to some graphics issues when the database is updated the HMI must be...
Replies
4
Views
228
Back
Top Bottom