I am trying to update a tag with the system.tag.writeBlocking function based off a boolean true or false value when the boolean tag is true I want to update each tag to the value
This is where I am currently at
#create list of modbus tags to write on peak sp to evapcold units
paths = ["[Tippman_Tags]PH1/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH2/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH3/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH4/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH5/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH6/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH7/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH8/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH9/EU1b/Evaporator Temp Setpoint", "[Tippman_Tags]PH10/EU1b/Evaporator Temp Setpoint"]
#create list of onpeak setpoints to write to evapcold units
values = ["[Tippman_Tags]PH1/WinterMidPeakSP", "[Tippman_Tags]PH2/WinterMidPeakSP", "[Tippman_Tags]PH3/WinterMidPeakSP", "[Tippman_Tags]PH4/WinterMidPeakSP", "[Tippman_Tags]PH5/WinterMidPeakSP", "[Tippman_Tags]PH6/WinterMidPeakSP", "[Tippman_Tags]PH7/WinterMidPeakSP", "[Tippman_Tags]PH8/WinterMidPeakSP", "[Tippman_Tags]PH9/WinterMidPeakSP", "[Tippman_Tags]PH10/WinterMidPeakSP"]
This is a vision client tag, since you are writing a gateway tag change script you dont have access to these tags. As per the manual, 'Client Tags are only available to Vision resources, and are unavailable to Perspective and Gateway scoped resources'
I am also confused by your current script, I see you have a list of tag paths defined as paths, then you also have a list of tag paths defined as values, are you trying to write the values of the tags you defined in your values variable to the tags in your paths variable? You are definitely going to need to use system.tag.readBlocking in places where you need actual values,
Everything about this is invalid Python. == is used to compare two values, it's True not true for a boolean value, and that client tag Python is trying to find a variable called Winter and MidPeak and divide them. [client] is trying to get an array index stored in variable client from no given array. If you want to read a tag you need to use system.tag.readBlocking and pass in the tag as a string (or a list of strings) . Note this returns a list of QualifiedValue objects which have a value property to get their value.
But as @aaronrai24 said, client tags are Vision-scoped, inaccessible from the gateway