maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Nokia N900 (https://talk.maemo.org/forumdisplay.php?f=44)
-   -   n900 loud alarm sound (https://talk.maemo.org/showthread.php?t=91388)

tfj 2013-09-16 18:11

n900 loud alarm sound
 
I want to write a simple Python script that can
cause the n900 to sound an alarm, probably as loud
and piercing a shriek as possible - I'd like to be
able to hear it from 500 feet away outdoors.

I imagine there are several layers of ways to produce
such a sound; would you please sketch a bare outline
of these different methods, so I can read-up
and compare?

Thanks,
TFJ

sixwheeledbeast 2013-09-16 18:27

Re: n900 loud alarm sound
 
If you explain what you are trying to do, there maybe something fit for purpose in the repos already.

rotoflex 2013-09-17 08:08

Re: n900 loud alarm sound
 
aplay plays an audio file at 100% volume, so just use aplay to play an audio file that's recorded as loud as you want. Be aware that you can damage the speakers.

tfj 2013-09-23 19:17

Re: n900 loud alarm sound
 
Quote:

Originally Posted by sixwheeledbeast (Post 1374624)
If you explain what you are trying to do, there maybe something fit for purpose in the repos already.

I'd like to be able to make the n900 howl on command
(from a Python script).
Say my script (running in the background) receives
word that a tornado is approaching - n900, sound the
alarm!
I'm not sure Maemo alarm-clock or ring-tone modules
will be of much help.
I'm looking at the APIs for alsa and pulseaudio;
python also has audio modules, which may better suit
me.

Maybe someone familiar with simple ways to sound a
loud n900 alarm, can point these out, giving me a head-start.

tfj 2013-09-23 19:19

Re: n900 loud alarm sound
 
Quote:

Originally Posted by rotoflex (Post 1374742)
aplay plays an audio file at 100% volume, so just use aplay to play an audio file that's recorded as loud as you want. Be aware that you can damage the speakers.

Er, could you give some tips on how not to pulverize the piezos?

sixwheeledbeast 2013-09-23 21:51

Re: n900 loud alarm sound
 
Quote:

Originally Posted by tfj (Post 1376309)
I'd like to be able to make the n900 howl on command
I'm looking at the APIs for alsa and pulseaudio;

I'd be more interested on the API for the tornado?
I could see something like this being useful to people in certain areas of the world.

Take a look at the sources for ade's cooktimer.
It's python and it calls a full volume alarm sound.

http://maemo.org/packages/view/cooktimer

rotoflex 2013-09-24 16:02

Re: n900 loud alarm sound
 
Quote:

Originally Posted by tfj (Post 1376310)
Er, could you give some tips on how not to pulverize the piezos?

The only advice is to record the sound at the volume you want to have it played back on the N900.

I use aplay in a script that plays clock chimes every 15 minutes. It turns out that aplay's volume-setting attributes were never implemented, so it plays a file at whatever volume it's recorded at. I had to use Audacity to reduce the recorded volume of the audio files very low, as aplay just blasts them out regardless of what the N900's speaker volume is set at.

phap 2013-09-25 05:27

Re: n900 loud alarm sound
 
rotoflex: you mind to share this script ? (and I would not be surprised if you heard about plum village, but nevermind...)

tfj 2013-10-01 15:47

Re: n900 loud alarm sound
 
[QUOTE=rotoflex;1376447]The only advice is to record the sound at the volume you want to have it played back on the N900.

Has Nokia specified a maximum volume (by some standard) for the speakers?

tfj 2013-10-01 15:52

Re: n900 loud alarm sound
 
[QUOTE=sixwheeledbeast;1376338]I'd be more interested on the API for the tornado?

Well my script would just receive a signal and trigger the n900, I
haven't gotten that far yet.


All times are GMT. The time now is 12:57.

vBulletin® Version 3.8.8