Difference between revisions of "Forecast Channel"
Jump to navigation
Jump to search
m |
WiibrewBot (talk | contribs) m (Robot: Cosmetic changes) |
||
Line 1: | Line 1: | ||
{{Infobox channel | {{Infobox channel | ||
| title = Forecast Channel | | title = Forecast Channel | ||
− | | image = [[ | + | | image = [[File:Forecast Channel.png|200px]] |
| desc = Weather informations | | desc = Weather informations | ||
| type = General channel | | type = General channel | ||
Line 13: | Line 13: | ||
− | http://weather.wapp.wii.com/1/076/short.bin<br> | + | http://weather.wapp.wii.com/1/076/short.bin<br /> |
− | http://weather.wapp.wii.com/1/076/forecast.bin<br> | + | http://weather.wapp.wii.com/1/076/forecast.bin<br /> |
http://news.wapp.wii.com/ displays a Red Hat Enterprise Linux Test Page. | http://news.wapp.wii.com/ displays a Red Hat Enterprise Linux Test Page. | ||
Line 56: | Line 56: | ||
} | } | ||
</source> | </source> | ||
+ | |||
[[Category:Software]] | [[Category:Software]] |
Revision as of 18:06, 10 August 2009
Forecast Channel | |
200px | |
Type | General channel |
---|---|
Peripherals | ![]() ![]() |
The Forecast channel download data packages from Nintendo servers via plain http connection.
Some examples:
http://weather.wapp.wii.com/1/076/short.bin
http://weather.wapp.wii.com/1/076/forecast.bin
http://news.wapp.wii.com/ displays a Red Hat Enterprise Linux Test Page.
File structure:
$0000 - $003F: padding (00) $0040 - $013F: rsa encrypted sha-1 signature of rest of the file $0140 - $0143: header $0144 - .....: compressed data
The compression is very simple:
- Read one byte
- For each bit of the byte, msb-to-lsb,
- if 0, copy one byte to the output
- if 1, read 16 bits msb first in v, copy n bytes at offset m from the end of the output, n=3+(v>>12), m=v & fff
Quick and very dirty C code:
i = 0x144;
j = 0;
while(i < size) {
int k;
int v = data[i++];
for(k=0; k<8; k++)
if(!(v & (1 << (7-k)))) {
result_data[j++] = data[i++];
} else {
int vv = (data[i] << 8) | data[i+1];
int nb = 3+(vv >> 12);
int off = (vv & 0xfff);
int l;
i+=2;
for(l=0; l<nb; l++) {
result_data[j] = result_data[j-off-1];
j++;
}
}
}