[MortScript] IPTWeather_20110910 AccuWeather, My Location/Latitude, iPhoneToday/S2U2

Is IPTWeather the best weather plugin for iPhoneToday?

  • Yes

    Votes: 15 83.3%
  • No

    Votes: 3 16.7%

  • Total voters
    18
Search This thread

michoob

Retired Recognized Developer
Dec 19, 2008
1,270
65
Brussels

IPTWeather is a weather plugin for iPhoneToday (Today, .exe or Desktop.exe version) and/or S2U2.

Included My Location feature based on Sleuth's myLocation Service and/or Google Latitude location to get the weather of the location where you are!

What can IPTWeather exactly do?
  • It can display any weather icons and data in iPhoneToday
  • It can display weather condition as S2U2 and/or iPhoneToday wallpaper
  • It can display weather description as S2U2 slide text
  • It can display weather in S2U2 UserWeather
  • All displayed information is 100% customizable

Please follow the link above or below for instructions concerning:

IPTWeather on Google Code

If you like my work, you can buy me a beer :D:

Donations: Luke-ro, aiiro x 2. THANK YOU!

Some screenshots (for the S2U2 screen, I've used a QVGA wallpaper on a WVGA screen, that's why it is not full screen, but you can remake some other wallpapers...):
20100611064907s.jpg
505111.jpg


Some screenshots using manageIPTWLocation.mscr:
screenshot1nq.png

20110515213042.png
20110515213022.png


userOnUpdateScript.mscr files to add custom features:
Humidity icon in iPhoneToday (included in IPTWeather_20100708 and up)

What's new in the latest version which is IPTWeather_20110910:
  • Corrected iPhoneToday icon shifting when sun has set and before midnight.
  • Corrected bug that manage location might not be able to connect or detect active connection.
  • Added option IPTWuseS2U2wallpaperForBackground = -1 to show current weather in iPhoneToday wallpaper


Weather icons for S2U2 (to have the weather icon in the bottom left corner):
Icons are in png format with transparent background, and numbered 1, 2, ..., 8, 11, 12, ..., 44 (without the 0 before one digit numbers).
Standard icon pack:


Spil icon pack:


MysticGenius' icon pack:


Sketchy_Glow_S2U2_Weather_Icons_v2 icon pack resized to suit QVGA/WQVGA screens (by [URL=http://forum.xda-developers.com/member.php?u=1746631]Revhead):[/url]

Fullscreen weather icons for S2U2 (to have the weather icon fullscreen instead of having it in the bottom left corner):
You will need to set IPTWtodayForecastInS2U2Wallpaper=0 and use only IPTWtomorrowForecastInS2U2UserWeather=1 or -1 to use these fullscreen icons over any wallpaper of your choice, or even without any wallpaper.
Icons are in png format with transparent background, and numbered 1, 2, ..., 8, 11, 12, ..., 44 (without the 0 before one digit numbers). Please rename the icon 0.png to 1000.png.
These icons have been found on sv0911's topic.
Patrick013's fullscreen icon pack:


sv0911's Burning Sun WVGA 480x800 or QWVGA 240x400:


sv0911's Nightcoloured WVGA 480x800 or QWVGA 240x400:


sv0911's Fantasy Flash WVGA 480x800 or QWVGA 240x400:


sv0911's Platinum Weather WVGA 480x800 or QWVGA 240x400:


 
Last edited:

j101399j

Senior Member
Aug 5, 2008
1,176
57
Dallas, TX
A few issues, the values in weather.ini are not competly self explanatory; so please explain

From the weather.ini file

[User settings]
--> IPTWaccuWeatherMetric=1 What do I change this to, to make standard and not metric?
--> IPTWaccuWeatherLocation=EUR|FR|FR012|PARIS Where do I get this info so I see my location?
--> IPTWdelayHours=2 Is this how long between updates?
--> IPTWdelayMinutes=0 Is this how long between updates?
--> IPTWinternetConnection=wap SFR How do I find this setting, which one do I use?
IPTWdisconnectOnExit=1
IPTWcurrentWeatherIcon=0
IPTWcurrentWeatherPage=0
IPTWforecastStartIcon=4
IPTWforecastStartPage=0
IPTWiconsExtension=bmp
IPTWgoToAccuWeatherQuestion=Go to accuweather.com ?
IPTWstartText=Tap to start
IPTWofflineMode=0
IPTWmondayText=Mo:
IPTWtuesdayText=Tu:
IPTWwednesdayText=We:
IPTWthursdayText=Th:
IPTWfridayText=Fi:
IPTWsaturdayText=Sa:
IPTWsundayText=Su:
 

michoob

Retired Recognized Developer
Dec 19, 2008
1,270
65
Brussels
will this work with the stand alone exe? or does it have to be with the today plugin?

I guess it should also work with the standalone iPhoneToday exe version, since I'm not using any function specific to the Today screen, but just the ReloadIcon and ReloadIcons feature of iPhoneToday 1.3.
 

j101399j

Senior Member
Aug 5, 2008
1,176
57
Dallas, TX
Ok, I've added a FAQ in the first post to answer to your questions. :)

Cool, that is what I figured each locations were for. However, I am having an issue getting it to work and I think it is with the location. Say I want weather for Sacramento, CA (USA). Here is the URL:
http://www.accuweather.com/us/ca/sacramento/94203/...
What is the location code? Is it us|ca|sacramento|94203 or us/ca/sacramento/94203?

I don't have TF3D, so I can't use MTP. So this is the only option.
------------------------

Here is how I have it setup, but it just sits there. I also use MEdia Net (AT&T); that setting worked for the old other weather icon program. Here is my weather.ini file

Code:
[User settings]
IPTWaccuWeatherMetric=0
IPTWaccuWeatherLocation=us/ca/sacramento/94203
IPTWdelayHours=2
IPTWdelayMinutes=0
IPTWinternetConnection=MEdia Net
IPTWdisconnectOnExit=1
IPTWcurrentWeatherIcon=0
IPTWcurrentWeatherPage=3
IPTWforecastStartPage=3
IPTWforecastStartIcon=4
IPTWiconsExtension=bmp
IPTWgoToAccuWeatherQuestion=Go to accuweather.com ?
IPTWstartText=Tap to start
IPTWofflineMode=0
IPTWmondayText=Mo: 
IPTWtuesdayText=Tu: 
IPTWwednesdayText=We: 
IPTWthursdayText=Th: 
IPTWfridayText=Fi: 
IPTWsaturdayText=Sa: 
IPTWsundayText=Su: 
[Script settings]
IPTWregRoot=HKCU
IPTWregKey=Software\iPhoneToday\AccuWeather
 

j101399j

Senior Member
Aug 5, 2008
1,176
57
Dallas, TX
Ok, I've figured out you have to search your location code on AccuWeather.com International and not on AccuWeather.com which is only for the US...

So for Sacramento in California, the location code is NAM|US|CA|SACRAMENTO

Using that worked!!!! However the website is frustrating, everytime I try and get the vofr for other US cities, since I am in the US, it forces me back to the normal site. Well at least I know where to look; thank you very much

[edit]
Ok I think I fingured it out, just a few tests then I will post
 
Last edited:

BOBO_01

Senior Member
Nov 23, 2007
116
31
AccuWeather Icons

Hello,

I have made some AccuWeather Icons...
Enjoy.
 

Attachments

  • AccuWeather.png
    AccuWeather.png
    18.1 KB · Views: 5,510
  • 16.png
    16.png
    18.2 KB · Views: 5,504
  • 26.jpg
    26.jpg
    3.3 KB · Views: 57

chancer63

Senior Member
Jul 13, 2008
352
61
OnePlus 8 Pro
I have two answers and two questions:

- I only want to use WLAN so I left the internet connection entry empty, it works.
- Yes, it works with the exe- version of iPT.

Questions:

- Is it possible to integrate S2U2 like in moesfeld's yahoo- version?
- I tried to use weather icons from moesfeld, they seem to be disordered, show the wrong weather. Is there another order for the AccuWeather- icons?

THX & CU
 

michoob

Retired Recognized Developer
Dec 19, 2008
1,270
65
Brussels
@chancer63: since I don't use S2U2, I don't know if I'll make a version for it, but I'll take a look if I find some time.
For the icons, you cannot use icons used for Yahoo! Weather as the ones from moesfeld, because there are not the same as the ones for AccuWeather... these icons were done by Bluemetalaxe and he doesn't have time to remake 40 new weather icons, sorry.
 

michoob

Retired Recognized Developer
Dec 19, 2008
1,270
65
Brussels
Ok, I've taken a look at UserWeather in S2U2.
It seems you can display only one icon and forecast.
Which one do you want? The current forecast?

I may display for instance the current forecast icon, with a text below showing current temperature, current RealFeel®, current weather description, high temperature, high RealFeel®, low temperature, and low RealFeel®.
Something like that is ok for you?
2° (4°), Mostly Cloudy | Hi 3° (2°) / Lo 0° (-3°)

Perhaps the text will be too long... I don't kown.

Just tell me exactly what you want and I'll give it a try ;).
 

BOBO_01

Senior Member
Nov 23, 2007
116
31
Day and Night icons?

Hello michoob,

Is it possible to change the script so, that day and night icons are displayed?
 

Attachments

  • Hail-Day.jpg
    Hail-Day.jpg
    9.5 KB · Views: 23
  • Hail-Night.jpg
    Hail-Night.jpg
    9 KB · Views: 17

michoob

Retired Recognized Developer
Dec 19, 2008
1,270
65
Brussels
I have found it myself. :)
Enclosed is a new config.xml and the day and night icons.
-> Replace
-> Enjoy

Well done!

By the way, I'm working on a new version with many new stuff, to be released next week.

I'll also include an optionnal IPTWnightIconSuffix setting in the weather.ini file so that configuring different icons for night forecasts is easier than editing the config.xml.
 

j101399j

Senior Member
Aug 5, 2008
1,176
57
Dallas, TX
2 recommendations, add a script killer and reg lock
Code:
RemoveNotifications(\iPhoneToday\IPTWeather\iPhoneTodayAccuWeather.mscr")

Here is the reg lock code:
At the start of the script add this:
Code:
#Lock reg
("HKLM","Software\iPhoneToday","lockRegistry",1)

And at the end put this
Code:
#Unock reg
("HKLM","Software\iPhoneToday","lockRegistry",0)

This way if another code is running, things don't get screwed up, and if you accidently hit the button many time, you don't end up with 20 or 30 scripts running.
 

michoob

Retired Recognized Developer
Dec 19, 2008
1,270
65
Brussels
I don't see the point of having a script killer for iPhoneTodayAccuWeather.mscr script, since this script is only run by the user and since it is written in the MortScript manual:
4.3 Multiple instances and aborting scripts
MortScript can run in multiple instances, but only once for each script.
If an already running script is run a second time, an open dialog of that script (e.g. Choice,
Message, ...) will be activated. If the script doesn't show any windows, nothing will happen.

As for the lockRegistry thing, is it an iPhoneToday feature?
What will it change to add this entry?
Perhaps I should have a wait loop like that before updating the iPhoneToday registry, but this would work only if the other code running and using iPhoneToday uses this kind of loop too:
Code:
While (("HKLM","Software\iPhoneToday\lockRegistry") <> 0)
  Sleep(1000)
EndWhile
#Lock reg
("HKLM","Software\iPhoneToday","lockRegistry",1)
#Update iPhoneToday registry
#... and unlock reg at end
("HKLM","Software\iPhoneToday","lockRegistry",0)

Perhaps I'm wrong, so please explain me. :p
 

j101399j

Senior Member
Aug 5, 2008
1,176
57
Dallas, TX
Looking back at your script, the kill is not needed, so please ignore that part. As for the lock, it is only needed if someone is running multiple scripts that edit the icons. For example, if this is running and then the battery script starts, they can cause some wierd icon changes and mess up the icons and notes. It is not needed, but just an idea


[edit] Yes, competly ignore the lock and kill parts. I did not fully understand your scripts and these 2 things will only mess things up.
 
Last edited:

Top Liked Posts