Computer Sound Program

I need a short little code to produce a high pitched sound (frequency) from my computer. I used to be able to write this code but I have long since forgotten. It can be in BASIC or any other programing language but I will also need a link to download the software to run the code. I need a program code that won’t lock up my computer but will continue to run this high pitched sound until I choose to stop it. Any assistance will be appreciated.

Example of code needed:

10 Sound = 20000
20 goto 10

This is very very old BASIC I know, but I don’t have any software to run it and I am not even sure if it is the correct code or not.


Why not just download a freeware or shareware midi file editor, create a file, choose the musical note you want and give it an a length as long as you want it. Then simply play the midi file. :shock:

I’m not sure that will do what I want it to… I need a very very very high pitch frequency that will be very difficult for the human ear to hear it, but after about 20-30 minutes of your ear hearing this you will physically be able to feel this god awful sound. Can Midi do that?

You’d need to play a note around 50 octaves above middle C to reach the threshhold of human hearing. I have no idea if midi editors give you that much flexibility.

I’m wondering whether your speakers would be able to reproduce 20kHz reliably even. I believe that the BASIC code you have will work. You’ll need to find a copy of BASIC somewhere though…and that might not run so well on Win2k and above. Maybe Visual Basic can do this as well?

I don’t know, but my old 486 without external speakers could do the job very very well. Adn I am not even sure it was 20khz that I used… Anyway, I don’t know how to use Visual Basic… I am really not concerned about the software so long as someone can give me a link to download a simple program to run this thing in the right language…

Maybe I could write a short DOS program for you in C and compile it — that is if I can get near a PC.

I could scream “EEEEEEEEEeeeeeeeeeeeeeek” into a microphone for you

Alright, nevermind, thanks for trying! I have decided to drop this idea and work on something else. Thanks everyone!

:smiling_imp: Why tie this sound to your computer? :smiling_imp:

You could build a simple oscilator circut using a 555 timer chip and maybe two or three other parts that should not run you more than $200NT. Since we are not aiming for high fideltiy here, a cheap 1 or two inch speaker should do the trick.

It produces an annoying enough sound before it cuts out! I drove my classmates crazy in the highschool lunch room.

Buy one of those spring loaded bread boards for less than 100NT and you can build a whole host of fun gizmos when you get bored with it.

Building simple projects from schematics are both easy and fun. Just like connecting the dots.

I’ll look for a simple schematic and a free basic editor while I’m browsing the web. Remember. You are building a code practice oscillator, not an annoying machine.

Thank you but, as I said forget it, I have decided to do something else.

Moderator please delete or lock this thread. Thank you.