ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > Unfinished Requests

Noisemaker

(1/2) > >>

nhk220:
I would like to have a program that runs on XP that will generate a musical tone form 1-3 seconds in length at random time intervals that I can specify.  E.G. random beeps from 2 to 9 minutes.  It would be nice if it would run behind any other programs running at the time.  Cheers

mouser:
some questions:

does it matter what tone? random tone? fixed tone?

you want to be able to say, generate a tone every 7 minutes that lasts for 2 seconds, or you want to say, generate a tone ever x minutes (where x can change and be random from 2 to 9 minutes) of random duration that can range from 1-3 seconds.

what a strange request - mind telling us what it is to be used for?

skrommel:
 :huh: Noisemaker waits ... minutes, plays random 1-3 second notes for ... minutes.

Fearful of the new terrorist act, I still post this solution to the request.

Download and install AutoHotKey from www.autohotkey.com. Save the script as Noisemaker.ahk and doubleclick to run.

Skrommel



--- ---;Noisemaker.ahk
; Waits ... minutes, plays random 1-3 second notes for ... minutes
;Skrommel @2005

#Persistent

IN:
InputBox,in,Noise,Start playing in ... minutes:
If in<1
  Goto,IN

FOR:
InputBox,for,Noise,Play for ... minutes:
If for<1
  Goto,FOR

in*=60000
for*=60000
SetTimer,START,%in%
Return

START:
SetTimer,START,Off
SetTimer,STOP,%for%
Loop
{
  Random,duration,1000,3000
  Random,frequency,200,10000
  SoundBeep,%frequency%,%duration%
}

STOP:
SetTimer,STOP,Off
ExitApp

zridling:
Oh man, am I going to have some devious fun with this. "Dang, Boss, looks like you've got the latest Sasser worm! I'm going to need your credit cards and all your available cash to fix it."
 :)

nhk220:
As I reread my first post I see that I didn't explain my need very well the first time.

I need to generate a tone for 1-3 seconds, once every few minutes. The time inteval between tones needs to vary, and I need to be able to specify the extremes on the time delay interval: it might be from 1-3 minutes one time and 5-20 minutes the next.

The tone can be the same tone (one easily heard) or it can vary as well. 

The program needs to run until I stop it, so if it could monitor for a keypress, that would be nice, or I can just stop it from the task bar as I did with ahk.

Thanks so much.

Cheers

Navigation

[0] Message Index

[#] Next page

Go to full version