Hi John - the temperature representation of '60F' (or '15.6C') is formatted in the data as it arrives from Weather Underground. If you want to strip out the temperature units character, you could do it with a simple Python script and save the modified value to an Indigo variable. I can explain further if needed.
- Code: Select all
import re # import regex
dev = indigo.devices[12345678] # the source weather device ID
line = re.sub('([0-9]+)[F|C]', '\g<1>', dev.states['foreText1']) # the pattern match, see below
indigo.variable.updateValue(12345678, line) # the destination variable ID
The pattern match:[0-9]+ <== One or more digits
( ) <== Create a capture group to remember the digits
[F|C] <== Either 'F' or 'C'
\g<1> <== Replace with the digits we remembered
dev.states['foreText1'] <== The source text.
Thunderstorms during the morning will give way to cloudy skies this afternoon. High 23.1C. Winds E at 10.1 to 15 mph. Chance of rain 90%.
Becomes:Thunderstorms during the morning will give way to cloudy skies this afternoon. High 23.1. Winds E at 10.1 to 15 mph. Chance of rain 90%.