Jump to content

Recommended Posts

Posted

Hi, i have s silly problem with mouses in a house and i heard that ultrasound frequency: 15 - 33 kHz konst and sound 90 - 100 dB anoying them.

How can i make this program ?

 

#RequireAdmin
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <SliderConstants.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("Form1", 440, 219, 688, 348)
$Slider1 = GUICtrlCreateSlider(8, 40, 422, 45, $TBS_NOTICKS)
GUICtrlSetLimit(-1, 200, 0)
GUICtrlCreateLabel("Frequency kHz ( 0-200 kHz )", 16, 16, 140, 17)
GUICtrlCreateLabel("Sound in dB ( 0-200 dB )", 18, 93, 120, 17)
$Slider2 = GUICtrlCreateSlider(8, 116, 422, 45, $TBS_NOTICKS)
GUICtrlSetLimit(-1, 200, 0)
$startBtn = GUICtrlCreateButton("Start", 16, 176, 75, 25)
$stopBtn = GUICtrlCreateButton("Stop", 104, 176, 75, 25)
GUISetState(@SW_SHOW)


While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEnd

 

Posted

How to make this frequency in kHz + - with slider and dB + - with slider too ? So when i press start to my speakers start to produce that frequency and when i moving slider frequency or sound goes up or down.

Posted (edited)

I think you can make it very easy with 555 timer ic and a few extra components. It will work with 9v pp3 Battery. You don't need to depend your computer for this task. After all, selecting a good speaker is the key in this project. 

Edited by kcvinu
Spoiler

My Contributions

Glance GUI Library - A gui library based on Windows api functions. Written in Nim programming language.

UDF Link Viewer   --- A tool to visit the links of some most important UDFs 

 Includer_2  ----- A tool to type the #include statement automatically 

 Digits To Date  ----- date from 3 integer values

PrintList ----- prints arrays into console for testing.

 Alert  ------ An alternative for MsgBox 

 MousePosition ------- A simple tooltip display of mouse position

GRM Helper -------- A littile tool to help writing code with GUIRegisterMsg function

Access_UDF  -------- An UDF for working with access database files. (.*accdb only)

 

Posted

I would walk around the pawn shop with a tuner and find two old-ass pieces of electronics that sweep those frequencies with their degraded coils.  Throw them in a fireproof box in the attic and cycle power to them periodically?

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Posted
while 1

beep(random(0x25 , 0x7FFF , 1) , random(5000, 10000 , 1))

wend

 

beeps between 15-32.7 kHz, lasting between 5 and 10 seconds, for eternity.

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Posted (edited)

also, to add to mine.  Once you drop below about 150hz on my laptop the speaker will squeal and the tone will wobble.   There will no doubt be a combination of "degraded speaker + overdriving" that will let you get away with a single input rather than having to sweep the frequencies yourself, mine doesnt catch the whole range (tops out around 25 kHz) but it is multi tonal and annoying as balls. 

It also helps to teach others 'frequency'

beep(1, 1000) = 2 tones squealed

beep(2, 1000) = 4 tones squealed

beep(7, 1000) = 14 tones and you start hearing the wobble as it begins to sound like alternating tones instead of a stop/start

beep(12 , 1000) = 24 tones is roughly the point where i lose distinct tones

Edited by boththose

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Posted

my laptop speaker will hit the 32.7 k Hz max, the tone emitted when sending the ultra low tones is capping at 25.   Apparently every configuration will fail with slight differences when being overdriven, but i just started watching an educational video on the subject, hopefully i learn something.

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Posted

How do you know your speaker can output 32.7Khz? What are you using to measure the output of it?

 

If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.
Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag Gude
How to ask questions the smart way!

I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from.

Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays.  -  ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script.  -  Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label.  -  _FileGetProperty - Retrieve the properties of a file  -  SciTE Toolbar - A toolbar demo for use with the SciTE editor  -  GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI.  -   Latin Square password generator

Posted

or buy some glue traps

sorry it's friday

Hehe, i tried with glue, i was have glue on paper on whole house in every corner and i see mouse get arround it. 3 weeks and he didnt catch, i even try with many foods and no success.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...