seth350
Member
I have never used a RedLion HMI before, but I am fixing to. I have three identical yet separate processes where each will have its own RedLion C3000 HMI programmed in Crimson 3.1.
The environment these will be in is acidic and eventually, they will need to be replaced. I want to make that replacement process as easy as possible.
My theory is that instead of making three separate projects that the techs will need to keep up with, I instead want to create one project and have the internal tags needed for the process to be configurable at runtime to point to different tags in a PLC.
Hang on....hear me out.
This will be configured in a password protected portion of the HMI where a tech can select which machine the HMI is controlling. This selection would write a number (1,2,3) to an internal tag in the HMI. A Save button would execute a script to change the IP address and reboot.
Theoretically, I should be able to point different PLC tags to a single internal tag based on what machine the HMI is setup to control. I figured I would use a background process and write some script that simply compares the value of the selection tag, and calls the program to change the pointers to the internal tags.
I am not sure if this is possible, I have tried to simulate it in Crimson 3.0 but it doesn't seem to run programs in background? Theoretically, it seems possible, I am just not sure what kind of performance impact it would have.
*Edit: I set the program to be called on "Tick" and it works. The "Background" setting had me thinking it was called automatically and continuously.
The environment these will be in is acidic and eventually, they will need to be replaced. I want to make that replacement process as easy as possible.
My theory is that instead of making three separate projects that the techs will need to keep up with, I instead want to create one project and have the internal tags needed for the process to be configurable at runtime to point to different tags in a PLC.
Hang on....hear me out.
This will be configured in a password protected portion of the HMI where a tech can select which machine the HMI is controlling. This selection would write a number (1,2,3) to an internal tag in the HMI. A Save button would execute a script to change the IP address and reboot.
Theoretically, I should be able to point different PLC tags to a single internal tag based on what machine the HMI is setup to control. I figured I would use a background process and write some script that simply compares the value of the selection tag, and calls the program to change the pointers to the internal tags.
I am not sure if this is possible, I have tried to simulate it in Crimson 3.0 but it doesn't seem to run programs in background? Theoretically, it seems possible, I am just not sure what kind of performance impact it would have.
*Edit: I set the program to be called on "Tick" and it works. The "Background" setting had me thinking it was called automatically and continuously.
Code:
//background program
if (selection == 1) {
PointToMachine1();
}
if (selection == 2) {
PointToMachine2();
}
Code:
//PointToMachine1()
//internal tag ......... plc tag
ActTemperature = m1ActTemperature
SetTemperature = m1SetTemperature
//PointToMachine2()
//internal tag ......... plc tag
ActTemperature = m2ActTemperature
SetTemperature = m2SetTemperature
Last edited: