It is currently December 15th, 2019, 6:34 am

Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

Help with creating, editing & fixing problems with skins
PigeonMaster
Posts: 2
Joined: January 8th, 2019, 11:52 am

Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

PigeonMaster » January 8th, 2019, 12:15 pm

Hi guys, I'm having some trouble. As you might have seen, yahoo api for weather no longer works, so it seems I must replace it with weather.com. From what I read it might not be an easy task or not possible, I'll provide everything I can to be able to fix it.

Here's a link to the skin: https://www.deviantart.com/fallingtitan/art/Moto-Widget-Clock-temp-date-etc-1-715539432?ga_submit_new=10%3A1510941105

Here's the part of the code regarding the weather:

Code: Select all

;================================================

[MeasureWeather]
Measure=Plugin
Plugin=WebParser
URL=https://query.yahooapis.com/v1/public/yql?q=select * from weather.forecast where woeid in (select woeid from geo.places(1) where text="#WeatherLocation#") and u="#WeatherUnit#"
RegExp=(?siU).*<yweather:location .* city="(.*)" country="(.*)" region="(.*)"/>.*<yweather:condition .* code="(.*)" date=".*" temp="(.*)" text="(.*)"/>

UpdateRate=(60*5+2)

FinishAction=[!Update] [!Update]

[MeasureWeatherCurrentCity]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=1

[MeasureWeatherCurrentRegion]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=3

[MeasureWeatherCurrentCode]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=4

Substitute="":"3200"

[MeasureWeatherCurrentTemp]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=5

[MeasureWeatherCurrentDesc]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=6

;================================================

Here's the part in variables that references the weather:

Code: Select all

[Variables]
Scale=1.00

Color=255, 255, 255

WeatherLocation=SPXX0507
WeatherUnit=c
;c for Celcius, f for Fahrenheit.

Here's a screenshot of the Rainmeter log:
Image

That's all I can think of, if there's anything else needed please tell me and I'll add it, I've tried some other skins but none other than this one really fit my dekstop, so if I can get this one fixed I'll be immensely grateful! Thanks in advance.
User avatar
balala
Rainmeter Sage
Posts: 9267
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

balala » January 8th, 2019, 12:49 pm

First please try to follow what eclectic-tech has described here. He rewrote an Enigma Weather skin, which previously worked with Yahoo Weather, to work with Weather.com.
If you can't figure out what and how to do, to get it working, a bit later I'll try to help you to rewrite the skin. But first please try to figure it out by yourself.

A small addition: truly the WeatherUnit variable (defined into the [Variables] section), should have to be either m (metric - for temperatures in Celsius degrees), or i (imperial - temperatured in Fahrenheit), not c or f, as described.
PigeonMaster
Posts: 2
Joined: January 8th, 2019, 11:52 am

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

PigeonMaster » January 8th, 2019, 5:26 pm

balala wrote:
January 8th, 2019, 12:49 pm
First please try to follow what eclectic-tech has described here. He rewrote an Enigma Weather skin, which previously worked with Yahoo Weather, to work with Weather.com.
If you can't figure out what and how to do, to get it working, a bit later I'll try to help you to rewrite the skin. But first please try to figure it out by yourself.

A small addition: truly the WeatherUnit variable (defined into the [Variables] section), should have to be either m (metric - for temperatures in Celsius degrees), or i (imperial - temperatured in Fahrenheit), not c or f, as described.
Hi, thank you for your response. Unfortunately, I haven't been able to fix it by myself :? . From what I'm seeing (I might be 100% wrong I don't really know how to manipulate code) each (.*) refers to a string index which gets the data from the xml file of the weather.com page? Basing me on that and the eclectic-tech response in the Enigma thread I tried to do it like this:

Code: Select all

;================================================

[MeasureWeather]
Measure=Plugin
Plugin=WebParser
URL=https://wxdata.weather.com/wxdata/weather/local/#CurrentCode#?cc=*&unit=#unit#&dayf=6
RegExp=(?siU)<dnam>(.*)</dnam> <obst>(.*)</obst> <loc id="SPXX0507">(.*)</loc> <tmp>"(.*)"</tmp> <part p="d"><t>(.*)</t></part>

UpdateRate=(60*5+2)

FinishAction=[!Update] [!Update]

[MeasureWeatherCurrentCity]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=1

[MeasureWeatherCurrentRegion]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=3

[MeasureWeatherCurrentCode]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=4

Substitute="":"3200"

[MeasureWeatherCurrentTemp]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=5

[MeasureWeatherCurrentDesc]
Measure=Plugin
Plugin=WebParser
URL=[MeasureWeather]
StringIndex=6

;================================================
But alas, it did not work. Log gives me a RegExp matching error (-1) if that helps.

I've also changed the "c" in Variables to "m" just in case.
User avatar
balala
Rainmeter Sage
Posts: 9267
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

balala » January 8th, 2019, 6:36 pm

PigeonMaster wrote:
January 8th, 2019, 5:26 pm
I've also changed the "c" in Variables to "m" just in case.
No, not this is the problem. If you're using a non existent value for a variable (like c in this case), Rainmeter replaces it with the default value for that variable (in this case i).
I rewrote the code, here is it. Just copy and paste it, replacing the code you already have:

Code: Select all

[Variables]
@include=#@#Variables.ini
CurrentCode=SPXX0507
Unit=m
RoundBarMeasure=DriveUsage
;The measurement for the bar around the clock. Options are:
;CPUUsage
;RAMUsage
;Battery
;Seconds
;Minutes
;Hours
;DriveUsage
;Volume

[Rainmeter]
Update=1000
AccurateText=1
DynamicSkinWindow=1
RightMouseUpAction=[!SkinCustomMenu]
ContextTitle=Settings
ContextAction=["#@#Variables.ini"]
ContextTitle2=----
ContextTitle3=24-hour time
ContextAction3=[!WriteKeyValue MeasureTime Format "%H:%M"] [!Refresh]
ContextTitle4=12-hour time
ContextAction4=[!WriteKeyValue MeasureTime Format "%#I:%M"] [!Refresh]
ContextTitle5=Use metric units
ContextAction5=[!WriteKeyValue Variables WeatherUnit "c"] [!Refresh]
ContextTitle6=Use imperial units
ContextAction6=[!WriteKeyValue Variables WeatherUnit "f"] [!Refresh]
ContextTitle7=----
ContextTitle8=CPU usage
ContextAction8=[!WriteKeyValue Variables RoundBarMeasure "CPUUsage"] [!Refresh]
ContextTitle9=RAM usage
ContextAction9=[!WriteKeyValue Variables RoundBarMeasure "RAMUsage"] [!Refresh]
ContextTitle10=Battery
ContextAction10=[!WriteKeyValue Variables RoundBarMeasure "Battery"] [!Refresh]
ContextTitle11=Seconds
ContextAction11=[!WriteKeyValue Variables RoundBarMeasure "Seconds"] [!Refresh]
ContextTitle12=Minutes
ContextAction12=[!WriteKeyValue Variables RoundBarMeasure "Minutes"] [!Refresh]
ContextTitle13=Hours
ContextAction13=[!WriteKeyValue Variables RoundBarMeasure "Hours"] [!Refresh]
ContextTitle14=Drive usage
ContextAction14=[!WriteKeyValue Variables RoundBarMeasure "DriveUsage"] [!Refresh]
ContextTitle15=Volume
ContextAction15=[!WriteKeyValue Variables RoundBarMeasure "Volume"] [!Refresh]
ContextTitle16=----
ContextTitle17=Rainmeter options...
ContextAction17=[!SkinMenu]

;================================================

[MeasureWeather]
Measure=WebParser
UpdateRate=900
Url=http://wxdata.weather.com/wxdata/weather/local/#CurrentCode#?cc=*&unit=#Unit#&dayf=1
RegExp=(?siU)<weather ver=".*">.*<ut>(.*)</ut>.*<loc id="#CurrentCode#">.*<dnam>(.*)</dnam>.*<tmp>(.*)</tmp>.*<t>(.*)</t>

[MeasureTempUnit]
Measure=WebParser
Url=[MeasureWeather]
StringIndex=1

[MeasureWeatherCurrentCity]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=2

[MeasureWeatherCurrentTemp]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=3

[MeasureWeatherCurrentDesc]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=4

;================================================

[MeasureTime]
Measure=Time
Format=%#I:%M

[MeasureDay]
Measure=Time
Format=%a

[MeasureDate]
Measure=Time
Format=%#d

[MeasureMonth]
Measure=Time
Format=%b

;================================================

[MeasureSeconds]
Measure=Time
Format=%#S

MinValue=0
MaxValue=60

[MeasureMinutes]
Measure=Time
Format=%#M

MinValue=0
MaxValue=60

[MeasureHours]
Measure=Time
Format=%#H
MinValue=0
MaxValue=60

;================================================

[MeasureBattery]
Measure=Plugin
Plugin=PowerPlugin
PowerState=Percent

[MeasureRAMUsage]
Measure=PhysicalMemory

[MeasureCPUUsage]
Measure=CPU

[MeasureVolume]
Measure=Plugin
Plugin=Win7AudioPlugin

;================================================

[MeasureDriveUsageRaw]
Measure=FreeDiskSpace

Drive=#Drive#:
InvertMeasure=1

[MeasureDriveTotalRaw]
Measure=FreeDiskSpace

Drive=#Drive#:
Total=1

[MeasureDriveUsage]
Measure=Calc
Formula=MeasureDriveUsageRaw/MeasureDriveTotalRaw

;================================================

[Background]
Meter=Shape
Shape=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*160) | StrokeWidth 0 | Fill Color #Color#, ((256*0.25)-1)
Shape2=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*152) | StrokeWidth 0
Shape3=Combine Shape | Exclude Shape2
Shape4=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*152) | StrokeWidth 0 | Fill Color 0, 0, 0, ((256*0.50)-1)

[RoundBar]
Meter=Roundline
MeasureName=Measure#RoundBarMeasure#
StartAngle=(Rad(270))
RotationAngle=(Rad(360))
LineStart=(#Scale#*(160-8))
LineLength=(#Scale#*160)
LineColor=#Color#
Solid=1
X=(#Scale#*(320*0.5))
Y=(#Scale#*(320*0.5))
AntiAlias=1

;================================================

[WeatherCurrentIcon3200]
X=((#Scale#*(320-24-12)-[WeatherCurrentTemp:W])/2)
Y=(#Scale#*(72-12))
DynamicVariables=1

[IncludeWeatherCurrentIcons]
@Include=#@#WeatherCurrentIcons.ini

[WeatherCurrentTemp]
Meter=String
MeasureName=MeasureWeatherCurrentTemp
MeasureName2=MeasureTempUnit
InlineSetting=Face | Roboto
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=LeftCenter
Text=%1°%2
X=(#Scale#*(24+12))r
Y=(#Scale#*12)r
AntiAlias=1

;================================================

[Time]
Meter=String
MeasureName=MeasureTime
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*64)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 100
InlineSetting5=Case | Upper
StringAlign=CenterCenter
X=(#Scale#*160)
Y=(#Scale#*160)
AntiAlias=1

;================================================

[Date]
Meter=String
MeasureName=MeasureDate
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*20)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 400
InlineSetting5=Case | Upper
StringAlign=CenterCenter
X=(#Scale#*(320*0.5))
Y=(#Scale#*248)
AntiAlias=1

[Day]
Meter=String
MeasureName=MeasureDay
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=RightCenter
X=([Date:X]-(#Scale#*16))
Y=r
AntiAlias=1
DynamicVariables=1

[Month]
Meter=String
MeasureName=MeasureMonth
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=LeftCenter
X=([Date:X]+[Date:W]+(#Scale#*16))
Y=r
AntiAlias=1
DynamicVariables=1
I added the provided weather code (SPXX0507), so the skin should have to work. Does it?
angstypotato
Posts: 2
Joined: November 27th, 2019, 2:16 am

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

angstypotato » November 27th, 2019, 2:18 am

Thanks so much for this.

I've had this skin for some time, but the weather feed stopped working for me as well.

This code works, but is there something I need to do in order to make the weather icons work again?
balala wrote:
January 8th, 2019, 6:36 pm
No, not this is the problem. If you're using a non existent value for a variable (like c in this case), Rainmeter replaces it with the default value for that variable (in this case i).
I rewrote the code, here is it. Just copy and paste it, replacing the code you already have:

Code: Select all

[Variables]
@include=#@#Variables.ini
CurrentCode=SPXX0507
Unit=m
RoundBarMeasure=DriveUsage
;The measurement for the bar around the clock. Options are:
;CPUUsage
;RAMUsage
;Battery
;Seconds
;Minutes
;Hours
;DriveUsage
;Volume

[Rainmeter]
Update=1000
AccurateText=1
DynamicSkinWindow=1
RightMouseUpAction=[!SkinCustomMenu]
ContextTitle=Settings
ContextAction=["#@#Variables.ini"]
ContextTitle2=----
ContextTitle3=24-hour time
ContextAction3=[!WriteKeyValue MeasureTime Format "%H:%M"] [!Refresh]
ContextTitle4=12-hour time
ContextAction4=[!WriteKeyValue MeasureTime Format "%#I:%M"] [!Refresh]
ContextTitle5=Use metric units
ContextAction5=[!WriteKeyValue Variables WeatherUnit "c"] [!Refresh]
ContextTitle6=Use imperial units
ContextAction6=[!WriteKeyValue Variables WeatherUnit "f"] [!Refresh]
ContextTitle7=----
ContextTitle8=CPU usage
ContextAction8=[!WriteKeyValue Variables RoundBarMeasure "CPUUsage"] [!Refresh]
ContextTitle9=RAM usage
ContextAction9=[!WriteKeyValue Variables RoundBarMeasure "RAMUsage"] [!Refresh]
ContextTitle10=Battery
ContextAction10=[!WriteKeyValue Variables RoundBarMeasure "Battery"] [!Refresh]
ContextTitle11=Seconds
ContextAction11=[!WriteKeyValue Variables RoundBarMeasure "Seconds"] [!Refresh]
ContextTitle12=Minutes
ContextAction12=[!WriteKeyValue Variables RoundBarMeasure "Minutes"] [!Refresh]
ContextTitle13=Hours
ContextAction13=[!WriteKeyValue Variables RoundBarMeasure "Hours"] [!Refresh]
ContextTitle14=Drive usage
ContextAction14=[!WriteKeyValue Variables RoundBarMeasure "DriveUsage"] [!Refresh]
ContextTitle15=Volume
ContextAction15=[!WriteKeyValue Variables RoundBarMeasure "Volume"] [!Refresh]
ContextTitle16=----
ContextTitle17=Rainmeter options...
ContextAction17=[!SkinMenu]

;================================================

[MeasureWeather]
Measure=WebParser
UpdateRate=900
Url=http://wxdata.weather.com/wxdata/weather/local/#CurrentCode#?cc=*&unit=#Unit#&dayf=1
RegExp=(?siU)<weather ver=".*">.*<ut>(.*)</ut>.*<loc id="#CurrentCode#">.*<dnam>(.*)</dnam>.*<tmp>(.*)</tmp>.*<t>(.*)</t>

[MeasureTempUnit]
Measure=WebParser
Url=[MeasureWeather]
StringIndex=1

[MeasureWeatherCurrentCity]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=2

[MeasureWeatherCurrentTemp]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=3

[MeasureWeatherCurrentDesc]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=4

;================================================

[MeasureTime]
Measure=Time
Format=%#I:%M

[MeasureDay]
Measure=Time
Format=%a

[MeasureDate]
Measure=Time
Format=%#d

[MeasureMonth]
Measure=Time
Format=%b

;================================================

[MeasureSeconds]
Measure=Time
Format=%#S

MinValue=0
MaxValue=60

[MeasureMinutes]
Measure=Time
Format=%#M

MinValue=0
MaxValue=60

[MeasureHours]
Measure=Time
Format=%#H
MinValue=0
MaxValue=60

;================================================

[MeasureBattery]
Measure=Plugin
Plugin=PowerPlugin
PowerState=Percent

[MeasureRAMUsage]
Measure=PhysicalMemory

[MeasureCPUUsage]
Measure=CPU

[MeasureVolume]
Measure=Plugin
Plugin=Win7AudioPlugin

;================================================

[MeasureDriveUsageRaw]
Measure=FreeDiskSpace

Drive=#Drive#:
InvertMeasure=1

[MeasureDriveTotalRaw]
Measure=FreeDiskSpace

Drive=#Drive#:
Total=1

[MeasureDriveUsage]
Measure=Calc
Formula=MeasureDriveUsageRaw/MeasureDriveTotalRaw

;================================================

[Background]
Meter=Shape
Shape=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*160) | StrokeWidth 0 | Fill Color #Color#, ((256*0.25)-1)
Shape2=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*152) | StrokeWidth 0
Shape3=Combine Shape | Exclude Shape2
Shape4=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*152) | StrokeWidth 0 | Fill Color 0, 0, 0, ((256*0.50)-1)

[RoundBar]
Meter=Roundline
MeasureName=Measure#RoundBarMeasure#
StartAngle=(Rad(270))
RotationAngle=(Rad(360))
LineStart=(#Scale#*(160-8))
LineLength=(#Scale#*160)
LineColor=#Color#
Solid=1
X=(#Scale#*(320*0.5))
Y=(#Scale#*(320*0.5))
AntiAlias=1

;================================================

[WeatherCurrentIcon3200]
X=((#Scale#*(320-24-12)-[WeatherCurrentTemp:W])/2)
Y=(#Scale#*(72-12))
DynamicVariables=1

[IncludeWeatherCurrentIcons]
@Include=#@#WeatherCurrentIcons.ini

[WeatherCurrentTemp]
Meter=String
MeasureName=MeasureWeatherCurrentTemp
MeasureName2=MeasureTempUnit
InlineSetting=Face | Roboto
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=LeftCenter
Text=%1°%2
X=(#Scale#*(24+12))r
Y=(#Scale#*12)r
AntiAlias=1

;================================================

[Time]
Meter=String
MeasureName=MeasureTime
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*64)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 100
InlineSetting5=Case | Upper
StringAlign=CenterCenter
X=(#Scale#*160)
Y=(#Scale#*160)
AntiAlias=1

;================================================

[Date]
Meter=String
MeasureName=MeasureDate
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*20)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 400
InlineSetting5=Case | Upper
StringAlign=CenterCenter
X=(#Scale#*(320*0.5))
Y=(#Scale#*248)
AntiAlias=1

[Day]
Meter=String
MeasureName=MeasureDay
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=RightCenter
X=([Date:X]-(#Scale#*16))
Y=r
AntiAlias=1
DynamicVariables=1

[Month]
Meter=String
MeasureName=MeasureMonth
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=LeftCenter
X=([Date:X]+[Date:W]+(#Scale#*16))
Y=r
AntiAlias=1
DynamicVariables=1
I added the provided weather code (SPXX0507), so the skin should have to work. Does it?
xenium
Posts: 422
Joined: January 4th, 2018, 9:52 pm

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

xenium » November 27th, 2019, 10:40 am

angstypotato wrote:
November 27th, 2019, 2:18 am
This code works, but is there something I need to do in order to make the weather icons work again?
The wxdata feed from weather.com is the problem.
Some weather data may be missing for certain locations such as the icon for example.
What is your location code ?
angstypotato
Posts: 2
Joined: November 27th, 2019, 2:16 am

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

angstypotato » November 30th, 2019, 5:47 am

Thanks, code is USNY0996.
xenium wrote:
November 27th, 2019, 10:40 am
The wxdata feed from weather.com is the problem.
Some weather data may be missing for certain locations such as the icon for example.
What is your location code ?
xenium
Posts: 422
Joined: January 4th, 2018, 9:52 pm

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

xenium » November 30th, 2019, 7:39 am

angstypotato wrote:
November 30th, 2019, 5:47 am
Thanks, code is USNY0996.
Replace the old code with this:

Code: Select all

[Variables]
@include=#@#Variables.ini
CurrentCode=USNY0996
Unit=i
RoundBarMeasure=DriveUsage
;The measurement for the bar around the clock. Options are:
;CPUUsage
;RAMUsage
;Battery
;Seconds
;Minutes
;Hours
;DriveUsage
;Volume

[Rainmeter]
Update=1000
AccurateText=1
DynamicWindowSize=1
RightMouseUpAction=[!SkinCustomMenu]
ContextTitle=Settings
ContextAction=["#@#Variables.ini"]
ContextTitle2=----
ContextTitle3=24-hour time
ContextAction3=[!WriteKeyValue MeasureTime Format "%H:%M"] [!Refresh]
ContextTitle4=12-hour time
ContextAction4=[!WriteKeyValue MeasureTime Format "%#I:%M"] [!Refresh]
ContextTitle5=Use metric units
ContextAction5=[!WriteKeyValue Variables Unit "m"] [!Refresh]
ContextTitle6=Use imperial units
ContextAction6=[!WriteKeyValue Variables Unit "i"] [!Refresh]
ContextTitle7=----
ContextTitle8=CPU usage
ContextAction8=[!WriteKeyValue Variables RoundBarMeasure "CPUUsage"] [!Refresh]
ContextTitle9=RAM usage
ContextAction9=[!WriteKeyValue Variables RoundBarMeasure "RAMUsage"] [!Refresh]
ContextTitle10=Battery
ContextAction10=[!WriteKeyValue Variables RoundBarMeasure "Battery"] [!Refresh]
ContextTitle11=Seconds
ContextAction11=[!WriteKeyValue Variables RoundBarMeasure "Seconds"] [!Refresh]
ContextTitle12=Minutes
ContextAction12=[!WriteKeyValue Variables RoundBarMeasure "Minutes"] [!Refresh]
ContextTitle13=Hours
ContextAction13=[!WriteKeyValue Variables RoundBarMeasure "Hours"] [!Refresh]
ContextTitle14=Drive usage
ContextAction14=[!WriteKeyValue Variables RoundBarMeasure "DriveUsage"] [!Refresh]
ContextTitle15=Volume
ContextAction15=[!WriteKeyValue Variables RoundBarMeasure "Volume"] [!Refresh]
ContextTitle16=----
ContextTitle17=Rainmeter options...
ContextAction17=[!SkinMenu]

;================================================

[MeasureWeather]
Measure=WebParser
UpdateRate=900
Url=http://wxdata.weather.com/wxdata/weather/local/#CurrentCode#?cc=*&unit=#Unit#&dayf=1
RegExp=(?siU)<head>.*<ut>(.*)</ut>.*<tmp>(.*)</tmp>.*<icon>(.*)</icon>

[MeasureTempUnit]
Measure=WebParser
Url=[MeasureWeather]
StringIndex=1

[MeasureWeatherCurrentTemp]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=2

[MeasureWeatherCurrentCode]
Measure=WebParser
URL=[MeasureWeather]
StringIndex=3

;================================================

[MeasureTime]
Measure=Time
Format=%#I:%M

[MeasureDay]
Measure=Time
Format=%a

[MeasureDate]
Measure=Time
Format=%#d

[MeasureMonth]
Measure=Time
Format=%b

;================================================

[MeasureSeconds]
Measure=Time
Format=%#S

MinValue=0
MaxValue=60

[MeasureMinutes]
Measure=Time
Format=%#M

MinValue=0
MaxValue=60

[MeasureHours]
Measure=Time
Format=%#H
MinValue=0
MaxValue=60

;================================================

[MeasureBattery]
Measure=Plugin
Plugin=PowerPlugin
PowerState=Percent

[MeasureRAMUsage]
Measure=PhysicalMemory

[MeasureCPUUsage]
Measure=CPU

[MeasureVolume]
Measure=Plugin
Plugin=Win7AudioPlugin

;================================================

[MeasureDriveUsageRaw]
Measure=FreeDiskSpace

Drive=#Drive#:
InvertMeasure=1

[MeasureDriveTotalRaw]
Measure=FreeDiskSpace

Drive=#Drive#:
Total=1

[MeasureDriveUsage]
Measure=Calc
Formula=MeasureDriveUsageRaw/MeasureDriveTotalRaw

;================================================

[Background]
Meter=Shape
Shape=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*160) | StrokeWidth 0 | Fill Color #Color#, ((256*0.25)-1)
Shape2=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*152) | StrokeWidth 0
Shape3=Combine Shape | Exclude Shape2
Shape4=Ellipse (#Scale#*160), (#Scale#*160), (#Scale#*152) | StrokeWidth 0 | Fill Color 0, 0, 0, ((256*0.50)-1)

[RoundBar]
Meter=Roundline
MeasureName=Measure#RoundBarMeasure#
StartAngle=(Rad(270))
RotationAngle=(Rad(360))
LineStart=(#Scale#*(160-8))
LineLength=(#Scale#*160)
LineColor=#Color#
Solid=1
X=(#Scale#*(320*0.5))
Y=(#Scale#*(320*0.5))
AntiAlias=1

;================================================

[WeatherCurrentIcon3200]
X=((#Scale#*(320-24-12)-[WeatherCurrentTemp:W])/2)
Y=(#Scale#*(72-12))
DynamicVariables=1

[IncludeWeatherCurrentIcons]
@Include=#@#WeatherCurrentIcons.ini

[WeatherCurrentTemp]
Meter=String
MeasureName=MeasureWeatherCurrentTemp
MeasureName2=MeasureTempUnit
InlineSetting=Face | Roboto
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=LeftCenter
Text=%1°%2
X=(#Scale#*(24+12))r
Y=(#Scale#*12)r
AntiAlias=1

;================================================

[Time]
Meter=String
MeasureName=MeasureTime
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*64)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 100
InlineSetting5=Case | Upper
StringAlign=CenterCenter
X=(#Scale#*160)
Y=(#Scale#*160)
AntiAlias=1

;================================================

[Date]
Meter=String
MeasureName=MeasureDate
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*20)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 400
InlineSetting5=Case | Upper
StringAlign=CenterCenter
X=(#Scale#*(320*0.5))
Y=(#Scale#*248)
AntiAlias=1

[Day]
Meter=String
MeasureName=MeasureDay
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=RightCenter
X=([Date:X]-(#Scale#*16))
Y=r
AntiAlias=1
DynamicVariables=1

[Month]
Meter=String
MeasureName=MeasureMonth
InlineSetting=Face | #Font#
InlineSetting2=Size | (#Scale#*14)
InlineSetting3=Color | #Color#
InlineSetting4=Weight | 300
InlineSetting5=Case | Upper
StringAlign=LeftCenter
X=([Date:X]+[Date:W]+(#Scale#*16))
Y=r
AntiAlias=1
DynamicVariables=1
Last edited by xenium on November 30th, 2019, 2:48 pm, edited 1 time in total.
User avatar
JelleDekkers
Posts: 24
Joined: September 27th, 2017, 6:32 pm

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

JelleDekkers » November 30th, 2019, 1:35 pm

Oh hey I can make a new one for you that uses Dark Sky instead.
User avatar
balala
Rainmeter Sage
Posts: 9267
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Original creator no longer active, help me fix the weather for this skin? (Moto Widget Clock)

balala » November 30th, 2019, 1:53 pm

xenium wrote:
November 30th, 2019, 7:39 am
Replace the old code with this:
Two comments related to the posted code:
  • The Unit variable within the [Variables] section should be either m (metric - temperatures for example expressed into Celsius degrees), or i (imperial - temperatures in Fahrenheit degrees), but certainly not f. The reason it works even with Unit set to f is that if none of m or i is used, the site uses the default setting, which is i, so it returns the temperatures in Fahrenheit degrees.
  • A DynamicSkinWindow option, used into the [Rainmeter] section doesn't exist. It actually is DynamicWindowSize.
Yes, I suppose you've copied these from the previously posted code, but I just saw them and had to say these. From the same reason, I also used and posted a DynamicSkinWindow option into my last posted code.