Thanks dougy83 i would defently be willing to donate to charity if thats what you want, I just need to confirm with you what your code is doing so i can be sure it is applicable to my project.
Ill try and explain what is i need ,
First i need to generate a loud tone the oscilates at 500Hz and at a freq of 2.3kHz, I would also require you to explain to me how to adjust these frequency's, It must be on a timer so that the battery pack can last a few days, I have the hardware made and ready to go i also have a programmer and pic12f683 ready to go.
I appreciate your help immensely and cant wait to here back from you.
You have specified 2 frequencies: 500 & 2300Hz. Are these to be emitted at the same time, is one to modulate the other, or differently?
Please post a drawing of the waveform you're after (or explain it better).
Also, you've mentioned that the thing runs on a battery pack. What is the capacity and voltage. Also, what sort of speaker are you using. This info is required to work out the current consumption of the device and consequent working life.
Battery pack consits 4 AA bateries and the speaker will be 8Ω 0.5w,
Im working on recording the sound so i can figure out the exact frequencies required cheers.
You may need a large battery pack for it to last any decent length of time.
e.g. if you're using a 2A.Hr 4.5V pack, driving an 8ohm speaker using a squarewave (50% on/off timing for 0.6W output power) for 5 seconds with a 30 second break, the lifetime will be in the order of 49Hrs.
To increase the battery lifetime you may:
* Decrease the output power (reduce the tone duty cycle to < 50%)
* Decrease time the tone is on
* Increase time the tone is off
* Increase battery size.
I would also suggest changing the configuration of your speaker driver from emitter-follower to common-emitter to increase the output power for a given current. It will only require 1 extra resistor for this.
That recording sounds a bit more complex than a single 2300Hz tone. The dominant frequency is more like 3kHz. I don't think you'll be happy with a constant beep.
Those calls are more like 0.33seconds each, which will greatly increase the battery life.
It might be possible to digitise the recording to output something a little closer. I'll have a think about it.
Also, is there any driver for your choice of components?
You realise that fox callers can be bought for around US$30, right?
That recording sounds a bit more complex than a single 2300Hz tone. The dominant frequency is more like 3kHz. I don't think you'll be happy with a constant beep.
Those calls are more like 0.33seconds each, which will greatly increase the battery life.
It might be possible to digitise the recording to output something a little closer. I'll have a think about it.
Also, is there any driver for your choice of components?
You realise that fox callers can be bought for around US$30, right?
The unit must be compact, Also i will be producing 400 of these units most of which will be disposed of.
400 units @ 30 usd will not be viable when the components to make these units will be $11 Au each plus programming expensises, If you could replicate the sound provided great.
Look forward to your response.
A had a go at digitising the signal, have a listen to the attached wav file. The first sound is the original, in 16 bits, while the rest are differently encoded into 1 bit. Choose one for your device.
The recordings are:
y 'original right channel
yzc ' zero-crossing
yzcd ' zero-crossing of dy/dt
yzci ' zero-crossing of integral(y)
yds01 ' delta-sigma, step size = 0.01
yds02
yds03
yds04
yds05
yds06
yds07
yds08
yds09
yds10
yds15
yds20
yds25
yds30
yds35
yds40
yds45
I know the tone code is of no use for this project, but as I've already written it, perhaps someone can make use of it. It produces a runtime-setable tone on the CCP1 pin.
A had a go at digitising the signal, have a listen to the attached wav file. The first sound is the original, in 16 bits, while the rest are differently encoded into 1 bit. Choose one for your device.
The recordings are:
y 'original right channel
yzc ' zero-crossing
yzcd ' zero-crossing of dy/dt
yzci ' zero-crossing of integral(y)
yds01 ' delta-sigma, step size = 0.01
yds02
yds03
yds04
yds05
yds06
yds07
yds08
yds09
yds10
yds15
yds20
yds25
yds30
yds35
yds40
yds45
I just posted that wav file so that you could choose a single chirp/squark out of the 20 in the wav. You can't choose the first chirp, as it's the original in 16-bits (for comparison).
I just posted that wav file so that you could choose a single chirp/squark out of the 20 in the wav. You can't choose the first chirp, as it's the original in 16-bits (for comparison).
That code will only produce the single tone that you first requested. I haven't posted the code to play back the recording yet.
Sorry are we going back to a single chirp or a we trying to duplicate the Rabbit in duress sound file i uploaded.
From what i understand there are multiple tones being generated in that sound file or is it one tone with a different sound waves ? "Sorry if i sound stupid"
I understand that is the first code i asked for i still think your a genius for writting that in such short amount of time
That was a rabbit? I assumed it was a bird. Anyway, the wave file I uploaded is a single chirp encoded multiple times using different parameters. Some sound good & some sound crap. I was just asking for you to choose the one that sounded best to you.
From what i understand there are multiple tones being generated in that sound file or is it one tone with a different sound waves ? "Sorry if i sound stupid"
It's good to see fellow Ozzie's in this post anyway about once a month I hold a fox shooting on my farm and the only thing we use is a fox whistle, in the last 3 years we got 26 fox's and with that the young lamb slaughter by fox's has declined to near nothing. Besides afterwards it always a good time with the bonfire and a few beers so why take the fun away by trying to use an electronic device. For me the true Oz spirit will never die.......
It's good to see fellow Ozzie's in this post anyway about once a month I hold a fox shooting on my farm and the only thing we use is a fox whistle, in the last 3 years we got 26 fox's and with that the young lamb slaughter by fox's has declined to near nothing. Besides afterwards it always a good time with the bonfire and a few beers so why take the fun away by trying to use an electronic device. For me the true Oz spirit will never die.......
Maybe you should get fox meat into the mainstream market the same way as they have for kangaroo meat. We could probably get rid of the need for so many cattle and sheep if you culled/processed the feral animals around here. Foxes, rabbits/hares, cats, possums, koalas, drop bears...
wired4au said:
Im strugling to pick one of those tones but lets try tone 9 (not counting first tone)