Welcome to the Cumulus Support forum.
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4018) - 28 March 2024
Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4018) - 28 March 2024
Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
Current Conditions Audio
Moderator: daj
- PaulMy
- Posts: 3777
- Joined: Sun 28 Sep 2008 11:54 pm
- Weather Station: Davis VP2 Plus 24-Hour FARS
- Operating System: Windows8 and Windows10
- Location: Komoka, ON Canada
- Contact:
Current Conditions Audio
A little script http://www.komokaweather.com/weather/meteo_audio.html (still a work in progress) borrowed from F1LXJ Serge at Météo d'Annoeullin dans les Hauts-de-France http://f1lxj.fr/weather/index.htm and http://www.meteo-saint-brevin.fr/
Enjoying,
Paul
Enjoying,
Paul
Last edited by PaulMy on Mon 11 Sep 2017 2:57 pm, edited 2 times in total.
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
- mcrossley
- Posts: 12694
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: For those with poor eyesight
Very good Paul. I think you need to replace the decimal points with the word 'point' though - certainly for UK English is is interpreting the decimal as a full stop and putting a long pause in.PaulMy wrote:A little script http://www.komokaweather.com/weather/meteo_audio.html (still a work in progress) borrowed from F1LXJ Serge at Météo d'Annoeullin dans les Hauts-de-France http://f1lxj.free.fr/weather/index.htm and http://www.meteo-saint-brevin.fr/
Enjoying,
Paul
E.g. change "16.3 degrees celsius" to "16 point 3 degrees celsius"
- PaulMy
- Posts: 3777
- Joined: Sun 28 Sep 2008 11:54 pm
- Weather Station: Davis VP2 Plus 24-Hour FARS
- Operating System: Windows8 and Windows10
- Location: Komoka, ON Canada
- Contact:
Re: For those with poor eyesight
Correct Mark, I noticed that for English and I assume it was not a problem with the original French, but how? It is a webtag processed script.
I had not yet shown the French version as the French accented words did not download correctly but got an update from Serge that I will try.
Paul
I had not yet shown the French version as the French accented words did not download correctly but got an update from Serge that I will try.
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
- mcrossley
- Posts: 12694
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: For those with poor eyesight
If you are creating the 'text' in PHP, then where you use the appropriate tag use a str_replace(). Eg. using made up variables...
edit: Though the ' point ' string would be better as a variable then you can localise it easily.
Code: Select all
$text = "The temperature is $temp degrees celsius"
to...
$text = 'The temperature is ' . str_replace('.', ' point ', $temp) . ' degrees celsius';
- mlj1
- Posts: 63
- Joined: Mon 26 Dec 2011 8:14 pm
- Weather Station: Davis Vantage Pro2 Plus
- Operating System: Windows 7 SP1
- Location: Saint-Brevin les Pins, France
- Contact:
Re: For those with poor eyesight
Hi Paul and everybody,
Thank you for your interrest for our weather audio pages.
After trying poor quality mp3 audio messages generators, I found responsivevoice and tried their API with Serge F1LXJ.
It is by far the best quality audio obtained right now, but our audio pages need the responsivevoice website to be up in order to work, since the script use to call routines on it. We allready got an issue for a few days when their website was down.
Your help will be appreciated to provide us well formated English sentences with the right words. And for the time and data formats as well.
We will follow your work with interrest.
Note the French Female voice is excellent on a Windows PC but a little agressive on Ipad or Iphone.
http://www.meteo-saint-brevin.fr/audio.htm
http://www.meteo-saint-brevin.fr/infos.htm
Best regards,
Marcel
Thank you for your interrest for our weather audio pages.
After trying poor quality mp3 audio messages generators, I found responsivevoice and tried their API with Serge F1LXJ.
It is by far the best quality audio obtained right now, but our audio pages need the responsivevoice website to be up in order to work, since the script use to call routines on it. We allready got an issue for a few days when their website was down.
Your help will be appreciated to provide us well formated English sentences with the right words. And for the time and data formats as well.
We will follow your work with interrest.
Note the French Female voice is excellent on a Windows PC but a little agressive on Ipad or Iphone.
http://www.meteo-saint-brevin.fr/audio.htm
http://www.meteo-saint-brevin.fr/infos.htm
Best regards,
Marcel
Marcel Le Jeune F6DOW, Saint-Brevin les Pins, Pays de la Loire, France
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
- mcrossley
- Posts: 12694
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: For those with poor eyesight
Paul, there is lots you could around this to make it more 'human' , for instance...
Code: Select all
if ($sunshine == 0) {
$text += "There has been no sunshine so far today.\n";
} else {
$text += "The sun shine so far today is " . str_replace('.', ' point ', $sunshine) . " hours.\n";
}
if ($rainfall == 0) {
$text += "There has been no rainfall so far today.\n";
} else {
$text += "The rain so far today is " . str_replace('.', ' point ', $rainfall) . " millimeters.\n";
}
- mlj1
- Posts: 63
- Joined: Mon 26 Dec 2011 8:14 pm
- Weather Station: Davis Vantage Pro2 Plus
- Operating System: Windows 7 SP1
- Location: Saint-Brevin les Pins, France
- Contact:
Re: For those with poor eyesight
Hi Mark,
The problem is the actual script is in html and I don't know how to convert it in PHP to apply the suggestions you gave to Paul.
Best regards
The problem is the actual script is in html and I don't know how to convert it in PHP to apply the suggestions you gave to Paul.
Best regards
Code: Select all
<body>
<h3><img src='favicon.ico'> Météo Saint-Brevin - Bulletins audio</h3><hr><br>
<script src="https://code.responsivevoice.org/responsivevoice.js"></script>
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<center>
<img src="images/grundig512.jpg"><br /><br>
<textarea id="text" style="height:1px;display:none;">
Voici les derniers relevés de Météo Saint-Brévin.
Effectués le <#time format="dddd d mmmm"> à <#time format="h'h'nn">.
La température est de <#temp> degrés avec un ressenti de <#apptemp> degrés.
Le taux d'humidité est de <#hum> pour 100.
La pression atmosphérique est de <#press> hecto pascals; et la tendance barométrique est : "<#presstrend>".
Le vent venait du secteur <#currentwdir>. à une vitesse de <#wlatest> kilomètres par heure.
La plus forte rafale du jour était de <#wgustTM> kilomètres par heure, à <#TwgustTM format="h'H'nn">.
La base théorique des nuages se situe, à : <#cloudbase>.
Le nivau de pluie du jour est de <#rfall> millimètres par mètre carré.
Lever du soleil aujourd'hui à <#sunrise format="h'h'n">. Et coucher du soleil à <#sunset format="h'h'n">.
Merci pour votre attention.
Le prochain bulletin sera disponible dans quelques minutes.</textarea>
</textarea>
<textarea id="text1" style="height:1px;display:none;">
Here is the latest weather report from Meteo Saint-Brevin.
Released today at <#time format="h' 'nn">.
Temperature is <#temp>° celsius, feeling like <#apptemp>°.
It was <#temptrendenglish> over the last three hours.
Humidity is <#hum> %.
The atmospheric pressure is <#press> hectopascals;
And barometric pressure trend is : "<#presstrendenglish>" .
The wind is blowing from a bearing of <#bearing>°; with a speed of <#wlatest> Km/h.
And the strongest gust today was <#wgustTM> Km/h at <#TwgustTM format="h' 'nn">.
The theorical cloud base is : <#cloudbase>.
The rain level today is <#rfall> millimeter per square meter.
Actually, the Davis station forecast shows : <#wsforecast>.
Sunrise today at <#sunrise format="h' 'n">, and sunset at <#sunset format="h' 'n">.
Thank you for your attention.
The next report will be available in a few minutes.
</textarea>
<input
onclick="responsiveVoice.speak($('#text').val(), 'French Female');"
type="button"
value="Cliquez ici pour écouter le dernier bulletin de Météo Saint-Brevin"
/>
<p></p>
<input
onclick="responsiveVoice.speak($('#text1').val(), 'US English Male');"
type="button"
value="Click here to listen to the latest report from Météo Saint-Brevin"
/>
</body>
Marcel Le Jeune F6DOW, Saint-Brevin les Pins, Pays de la Loire, France
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
- mcrossley
- Posts: 12694
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: For those with poor eyesight
Ah, if you don't have PHP then it is a little more complex. You will have to put the variables into some javascript and get that to generate the final text in the clients browser. Something like this (untested - only the English is done, my French isn't that good!)...
Code: Select all
<body>
<h3><img src='favicon.ico'> Météo Saint-Brevin - Bulletins audio</h3><hr><br>
<script src="https://code.responsivevoice.org/responsivevoice.js"></script>
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<center>
<img src="images/grundig512.jpg"><br /><br>
<textarea id="text" style="height:1px;display:none;">
Voici les derniers relevés de Météo Saint-Brévin.
Effectués le <#time format="dddd d mmmm"> à <#time format="h'h'nn">.
La température est de <#temp> degrés avec un ressenti de <#apptemp> degrés.
Le taux d'humidité est de <#hum> pour 100.
La pression atmosphérique est de <#press> hecto pascals; et la tendance barométrique est : "<#presstrend>".
Le vent venait du secteur <#currentwdir>. à une vitesse de <#wlatest> kilomètres par heure.
La plus forte rafale du jour était de <#wgustTM> kilomètres par heure, à <#TwgustTM format="h'H'nn">.
La base théorique des nuages se situe, à : <#cloudbase>.
Le nivau de pluie du jour est de <#rfall> millimètres par mètre carré.
Lever du soleil aujourd'hui à <#sunrise format="h'h'n">. Et coucher du soleil à <#sunset format="h'h'n">.
Merci pour votre attention.
Le prochain bulletin sera disponible dans quelques minutes.
</textarea>
<textarea id="text1" style="height:1px;display:none;"></textarea>
<input
onclick="responsiveVoice.speak($('#text').val(), 'French Female');"
type="button"
value="Cliquez ici pour écouter le dernier bulletin de Météo Saint-Brevin"
/>
<p></p>
<input
onclick="responsiveVoice.speak($('#text1').val(), 'US English Male');"
type="button"
value="Click here to listen to the latest report from Météo Saint-Brevin"
/>
<script>
var text1 = 'Here is the latest weather report from Meteo Saint-Brevin. Released today at <#time format="h' 'nn">. ';
text1 += 'The temperature is ' + (<#temp> % 1 == 0 ? parseInt(<#temp>) : <#temp>) + '° Celsius, feeling like (<#apptemp> % 1 == 0 ? parseInt(<#apptemp> : <#apptemp>) + '°. ';
text1 += 'The temperature has been <#temptrendenglish> over the last three hours. ';
text1 += 'Humidity is <#hum> %. ';
text1 += 'The atmospheric pressure is <#press> hectopascals; ';
text1 += 'And the pressure trend is <#presstrendenglish>. ';
if (<#wlatest> == 0) {
text1 += 'The wind is currently calm. ';
} else {
text1 += 'The wind is blowing from a bearing of <#bearing>°; with a speed of ' + (<#wlatest> % 1 == 0 ? parseInt(<#wlatest>) : <#wlatest>) + ' Km/h. ';
}
text1 += 'And the strongest gust today was ' + (<#wgustTM> % 1 == 0 ? parseInt(<#wgustTM>) : <#wgustTM>) + ' Km/h at <#TwgustTM format="h' 'nn">. ';
text1 += 'The theorical cloud base is : <#cloudbase>. ';
if (<#rfall> == 0) {
text1 += 'It has not rained so far today. ';
} else {
text1 += 'The rainfall today is ' + (<#rfall> % 1 == 0 ? parseInt(<#rfall>) : <#rfall>) + ' millimetres. ';
}
text1 += 'The Davis station forecast shows : <#wsforecast>. ';
text1 += 'Sunrise today at <#sunrise format="h' 'n">, and sunset at <#sunset format="h' 'n">. ';'
text1 += 'Thank you for your attention. ';
text1 += 'The next report will be available in a few minutes.';
document.getElementById('text1').innerText = text1;
</script>
</body>
- mlj1
- Posts: 63
- Joined: Mon 26 Dec 2011 8:14 pm
- Weather Station: Davis Vantage Pro2 Plus
- Operating System: Windows 7 SP1
- Location: Saint-Brevin les Pins, France
- Contact:
Re: For those with poor eyesight
Thank you very much Mark !
I will try that as soon as possible.
Will it be possible in the English part of that script to include some code in form of strreplace to replace the decimal point in a value by the word point (ie 21 point 2 degrees in place of 21.2 degrees) ?
I will try that as soon as possible.
Will it be possible in the English part of that script to include some code in form of strreplace to replace the decimal point in a value by the word point (ie 21 point 2 degrees in place of 21.2 degrees) ?
Marcel Le Jeune F6DOW, Saint-Brevin les Pins, Pays de la Loire, France
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
- mlj1
- Posts: 63
- Joined: Mon 26 Dec 2011 8:14 pm
- Weather Station: Davis Vantage Pro2 Plus
- Operating System: Windows 7 SP1
- Location: Saint-Brevin les Pins, France
- Contact:
Re: For those with poor eyesight
Really sorry Mark !
I copied your script in a test page here
http://www.meteo-saint-brevin.fr/voice/audio.htm
and unfortunately, the button for English message gives no sound.
Could you please have a look and tell me what I did wrong ?
Thank you in advance
I copied your script in a test page here
http://www.meteo-saint-brevin.fr/voice/audio.htm
and unfortunately, the button for English message gives no sound.
Could you please have a look and tell me what I did wrong ?
Thank you in advance
Marcel Le Jeune F6DOW, Saint-Brevin les Pins, Pays de la Loire, France
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
- mcrossley
- Posts: 12694
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: For those with poor eyesight
Hi Marcel, it looks like Cumulus hasn't processed the page - it still has the web tags in it.
I'll look at doing the 'point' stuff...
I'll look at doing the 'point' stuff...
- mcrossley
- Posts: 12694
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: For those with poor eyesight
And there was at least one error in the code before, still untested, but looks better to my eye.
Just the script this time...
Just the script this time...
Code: Select all
var text1 = 'Here is the latest weather report from Meteo Saint-Brevin. Released today at <#time format="h' 'nn">. ';
var english = {};
var point = ' point ';
english.temp = replacePoint(<#temp>, point);
english.apptemp = replacePoint(<#apptemp>, point);
english.wlatest = replacePoint(<#wlatest>, point);
english.wgustTM = replacePoint(<#wgustTM>, point);
english.rfall = replacePoint(<#rfall>, point);
text1 += 'The temperature is ' + english.temp + '° Celsius, feeling like ' + english.apptemp + '°. ';
text1 += 'The temperature has been <#temptrendenglish> over the last three hours. ';
text1 += 'Humidity is <#hum> %. ';
text1 += 'The atmospheric pressure is <#press> hectopascals; ';
text1 += 'And the pressure trend is <#presstrendenglish>. ';
if (<#wlatest> == 0) {
text1 += 'The wind is currently calm. ';
} else {
text1 += 'The wind is blowing from a bearing of <#bearing>°; with a speed of ' + english.wlatest + ' Km/h. ';
}
text1 += 'And the strongest gust today was ' + english.wgustTM + ' Km/h at <#TwgustTM format="h' 'nn">. ';
text1 += 'The theorical cloud base is : <#cloudbase>. ';
if (<#rfall> == 0) {
text1 += 'It has not rained so far today. ';
} else {
text1 += 'The rainfall today is ' + english.rfall + ' millimetres. ';
}
text1 += 'The Davis station forecast shows : <#wsforecast>. ';
text1 += 'Sunrise today at <#sunrise format="h' 'n">, and sunset at <#sunset format="h' 'n">. ';
text1 += 'Thank you for your attention. ';
text1 += 'The next report will be available in a few minutes.';
document.getElementById('text1').innerText = text1;
function replacePoint(val, str) {
return (val % 1 === 0 ? parseInt(val) : val).toString().replace('.', str);
}
- PaulMy
- Posts: 3777
- Joined: Sun 28 Sep 2008 11:54 pm
- Weather Station: Davis VP2 Plus 24-Hour FARS
- Operating System: Windows8 and Windows10
- Location: Komoka, ON Canada
- Contact:
Re: For those with poor eyesight
I wish I could participate in the testing learning but not at home for a few more hours... I will give it a try then.
Paul
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm
- mlj1
- Posts: 63
- Joined: Mon 26 Dec 2011 8:14 pm
- Weather Station: Davis Vantage Pro2 Plus
- Operating System: Windows 7 SP1
- Location: Saint-Brevin les Pins, France
- Contact:
Re: For those with poor eyesight
Thank you Mike
Sorry for my mistake in a previous script which was not processed by Cumulus. Ooooops !
After correcting the issue, the button did not give the message in English in the loudspeaker.
After insterting your last script, it speaks now.
As you will listen by visiting
http://www.meteo-saint-brevin.fr/audio.htm
the temperatures and maximum gust are truncated.
It does not say 21 point 7 degrees but 21 degrees.
On an other hand, i would appreciate to have the barometric pressure truncated (1013 hPa instead of 1013,47 hPa)
All in your script is new for me and I enjoy learning.
Thanks again
Sorry for my mistake in a previous script which was not processed by Cumulus. Ooooops !
After correcting the issue, the button did not give the message in English in the loudspeaker.
After insterting your last script, it speaks now.
As you will listen by visiting
http://www.meteo-saint-brevin.fr/audio.htm
the temperatures and maximum gust are truncated.
It does not say 21 point 7 degrees but 21 degrees.
On an other hand, i would appreciate to have the barometric pressure truncated (1013 hPa instead of 1013,47 hPa)
All in your script is new for me and I enjoy learning.
Thanks again
Marcel Le Jeune F6DOW, Saint-Brevin les Pins, Pays de la Loire, France
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
Davis VP2+, D-Link wifi IP webcam DCS2130
http://www.meteo-saint-brevin.fr
-
- Posts: 1777
- Joined: Sat 17 Dec 2011 11:55 am
- Weather Station: Davis Vantage Pro2
- Operating System: Windows 11 x64
- Location: Dorset - UK
- Contact:
Re: For those with poor eyesight
Really like this!
The male voice reminds me of the shipping forecast we have in the UK: https://youtu.be/oguCxlZ94Ho?t=119
The male voice reminds me of the shipping forecast we have in the UK: https://youtu.be/oguCxlZ94Ho?t=119