Searching \ for '[PIC]: how to make nice sounds' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/ios.htm?key=sound
Search entire site for: 'how to make nice sounds'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: how to make nice sounds'
2002\06\20@120534 by Richard Sloan

flavicon
face
How can you make nice tones or sounds on a small speaker connected to one pin? Is this possible? Square wave tones are very harse and not very musical. I would like to have sounds kind of similar to bleeps and blurps found in Las Vegas gambling machines.

And if I were to use say a simple R2R ladder and 8 bits how to create small good sounding "tones"?

Richard.

--
http://www.piclist.com hint: To leave the PICList
spam_OUTpiclist-unsubscribe-requestTakeThisOuTspammitvma.mit.edu


2002\06\20@121834 by Alan B. Pearce

face picon face
>How can you make nice tones or sounds on a small
>speaker connected to one pin? Is this possible?
>Square wave tones are very harse and not very musical.
>I would like to have sounds kind of similar to bleeps
>and blurps found in Las Vegas gambling machines.

>And if I were to use say a simple R2R ladder and 8 bits
>how to create small good sounding "tones"?

This question seems to be coming up regularly of late.

Go to  http://www.embedinc.com and look for the HAL example project, which
uses the PWM module on the 16F87x range to produce sounds. You will also
need the pic development files to generate it.

--
http://www.piclist.com hint: To leave the PICList
.....piclist-unsubscribe-requestKILLspamspam@spam@mitvma.mit.edu


2002\06\20@125516 by uter van ooijen & floortje hanneman

picon face
> Go to  http://www.embedinc.com and look for the HAL example project, which
> uses the PWM module on the 16F87x range to produce sounds. You will also
> need the pic development files to generate it.

Nice site, but I could not find that HAL project.

Wouter

--
http://www.piclist.com hint: To leave the PICList
piclist-unsubscribe-requestspamKILLspammitvma.mit.edu


2002\06\20@125519 by Olin Lathrop

face picon face
> >How can you make nice tones or sounds on a small
> >speaker connected to one pin? Is this possible?
> >Square wave tones are very harse and not very musical.
> >I would like to have sounds kind of similar to bleeps
> >and blurps found in Las Vegas gambling machines.
>
> >And if I were to use say a simple R2R ladder and 8 bits
> >how to create small good sounding "tones"?
>
> This question seems to be coming up regularly of late.
>
> Go to  http://www.embedinc.com and look for the HAL example project, which
> uses the PWM module on the 16F87x range to produce sounds. You will also
> need the pic development files to generate it.

Thanks for the reference, Alan.  It will be hard to find the PIC stuff from
the main web page.  Go directly to http://www.embedinc.com/pic/hal.htm.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com hint: To leave the PICList
.....piclist-unsubscribe-requestKILLspamspam.....mitvma.mit.edu


2002\06\20@131401 by Daniel Rubin

flavicon
face
For some time now I have been considering how to build a cheap relatively
high quality (~22kHz sample rate) stereo playback device using something
like a PIC12C5XX, serial flash (Atmel etc...) and serial stereo DAC (Cirrus
CS4330) plus an Amp (LM4863) or similar.   I just wanted to play a 1 or 2
second blurp of stereo, but I guess just by changing the flash it could be
longer.

This project got lost in the 'things to do' pile, but after looking at the
HAL example project referenced below I have pulled it back out.  I am now
wondering if I can replace the DAC above with the PWM output method using
in that example and some filters?  What kind of sound quality could I expect?

Thanks
- Dan

At 12:53 PM 6/20/02 -0400, you wrote:
{Quote hidden}

-- Design Devices, http://www.designdevices.com
PIC microcontroller programmers & tools, motor controllers and more!  Ebay
Deals:
http://cgi6.ebay.com/aw-cgi/eBayISAPI.dll?ViewSellersOtherItems&userid=designdevices

--
http://www.piclist.com hint: To leave the PICList
piclist-unsubscribe-requestspamspam_OUTmitvma.mit.edu


2002\06\20@132415 by Herbert Graf

flavicon
face
It is possible to do this, check up on pulse width modulation. TTYL

>
> How can you make nice tones or sounds on a small speaker
> connected to one pin? Is this possible? Square wave tones are
> very harse and not very musical. I would like to have sounds kind
> of similar to bleeps and blurps found in Las Vegas gambling machines.
>
> And if I were to use say a simple R2R ladder and 8 bits how to
> create small good sounding "tones"?

--
http://www.piclist.com hint: To leave the PICList
@spam@piclist-unsubscribe-requestKILLspamspammitvma.mit.edu


2002\06\20@151544 by Olin Lathrop

face picon face
> For some time now I have been considering how to build a cheap relatively
> high quality (~22kHz sample rate) stereo playback device using something
> like a PIC12C5XX, serial flash (Atmel etc...) and serial stereo DAC
(Cirrus
> CS4330) plus an Amp (LM4863) or similar.   I just wanted to play a 1 or 2
> second blurp of stereo, but I guess just by changing the flash it could be
> longer.

You need a total of 44K samples streaming thru your device per second, which
leaves an average of 23uS per sample.  The fastest clock for a 12C5xx is
4MHz for a 1MHz instruction rate, so you have 23 instructions per sample.
That will be tight but possibly doable.  Consider that you need to read an
external memory, write it to an external D/A, and check for the terminating
condition.

> This project got lost in the 'things to do' pile, but after looking at the
> HAL example project referenced below I have pulled it back out.  I am now
> wondering if I can replace the DAC above with the PWM output method using
> in that example and some filters?  What kind of sound quality could I
expect?

You would need hardware PWM at that frequency and resolution.  If this is a
hobby project, I would use a 16F876 because it has 2 PWM outputs.  This
processor can run at 20MHz, which yields a maximum PWM frequency of 78KHz at
8 bit resolution.  That gives you plenty of margin to use simple and easy
filters on the PWM outputs to get the roughly 10KHz bandwidth you want.  In
other words, it should work fine.

I would synchronize the sample rate with a sub-multiple of the PWM rate.
Every fourth PWM period gives you a 19.5KHz sample rate, or every third
gives you 26KHz.  You would have 64 instructions to load the PWM with the
new samples already sitting on a silver platter for that purpose, and the
rest of the PWM period to fetch the next samples.  At 19.5KHz that would be
192 instructions.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com hint: To leave the PICList
KILLspampiclist-unsubscribe-requestKILLspamspammitvma.mit.edu


2002\06\20@204848 by kben

picon face
Hi Richard,
I saw people recommend Olin's Hal project,
but, you also might want to consider Roman Black's
Pic Sound page at http://www.romanblack.com/picsound.htm

~Kevin

>How can you make nice tones or sounds on a small speaker connected to one pin?
Is this possible? Square wave tones are very harse and not very musical. I would
like to have sounds kind of similar to bleeps and blurps found in Las Vegas
gambling machines.

--
http://www.piclist.com hint: To leave the PICList
RemoveMEpiclist-unsubscribe-requestTakeThisOuTspammitvma.mit.edu


2002\06\21@071233 by Roman Black

flavicon
face
Thanks Kevin! A few people are using my PICsound
1-bit and 1.5bit system now. Has advantages over
PWM in that you only need to turn the PIC pin on/off
at each timed cycle. No PWM timing needed. It also
gives 8:1 compression compared to 8bit PWM, but does
need to be run slightly faster, generally works out
at about 4x to 5x smaller sized sound sample than
8bit PWM for similar sound quality.

If you have enough sound storage ram you can get
high quality sound using 30+kbit/second rates, it only
takes a few PIC instructions to set the output pin
hi/lo so even stereo data rates at 22kbit/sec etc
are easy on a PIC.

The encoder.exe is Dos based and runs on most dos/w95/w98
pcs with some fiddling (needs 1024/768 video).
Now this project is getting more popular I *have* started
work on a Windows version of the encoder, should be
done in a week or so. :o)
-Roman


Kevin A. Benedict wrote:
{Quote hidden}

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2002\06\21@103842 by Richard Sloan

flavicon
face
Thanks Roman! Looking forward to seeing the Windows version... hope it handles larger buffer, I remember looking at the DOS one and it did I think 64K.....

Richard.

>>  Thanks Kevin! A few people are using my PICsound
>>  1-bit and 1.5bit system now. Has advantages over
>>  PWM in that you only need to turn the PIC pin on/off
>>  at each timed cycle. No PWM timing needed. It also
>>  gives 8:1 compression compared to 8bit PWM, but does
>>  need to be run slightly faster, generally works out
>>  at about 4x to 5x smaller sized sound sample than
>>  8bit PWM for similar sound quality.

>>  If you have enough sound storage ram you can get
>>  high quality sound using 30+kbit/second rates, it only
>>  takes a few PIC instructions to set the output pin
>>  hi/lo so even stereo data rates at 22kbit/sec etc
>>  are easy on a PIC.

>>  The encoder.exe is Dos based and runs on most dos/w95/w98
>>  pcs with some fiddling (needs 1024/768 video).
>>  Now this project is getting more popular I *have* started
>>  work on a Windows version of the encoder, should be
>>  done in a week or so. :o)
>>  -Roman


>>  Kevin A. Benedict wrote:
>>  >
>>  > Hi Richard,
>>  > I saw people recommend Olin's Hal project,
>>  > but, you also might want to consider Roman Black's
>>  > Pic Sound page at http://www.romanblack.com/picsound.htm
>>  >
>>  > ~Kevin
>>  >
>>  > >How can you make nice tones or sounds on a small speaker connected to
>>  one pin?
>>  > Is this possible? Square wave tones are very harse and not very musical.
>>  I would
>>  > like to have sounds kind of similar to bleeps and blurps found in Las
>>  Vegas
>>  > gambling machines.

>>  --
>>  http://www.piclist.com hint: PICList Posts must start with ONE topic:
>>  [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads








Thanks,
Richard Sloan
__________________________________________________________
The Mind Factory INC (Canada)
(613) 825-4758 phone                (613) 825-7758 fax
Richard Sloan                       spamBeGonersloanspamBeGonespamthemindfactory.com
http://www.themindfactory.com          
* Custom MP3 Development * Low Power FM Transmitters
* Custom Smart Cards
* Music / Speech Playback Systems
* Electronic Manufacturing
* Hardware / Firmware / Software Design
* Schematic and PCB layout
* 8051, 68HC11, PIC, AVR
* MP3, FAT16/32, IR, IRDA, USB, X10, VIDEO, TCP/IP, LCD, COMPACT FLASH

* ALL PRICES QUOTED IN US$ UNLESS OTHERWISE NOTED

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2002\06\22@063303 by Roman Black

flavicon
face
Currently 256kbyte in, 256kbit out, or a full
24xx256 eeprom. I can add facility for larger files
befre the new version is done, do you need larger?
-Roman


Richard Sloan wrote:
{Quote hidden}

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics


2002\06\25@163807 by All

flavicon
face
>>
I *have* started work on a Windows version of the encoder,
should be done in a week or so. :o)
-Roman
<<

Hi , Roman . I would just like to know which windows language
and compiler you have settled upon ?

Thanks
Vis Naicker

--
http://www.piclist.com hint: To leave the PICList
TakeThisOuTpiclist-unsubscribe-requestEraseMEspamspam_OUTmitvma.mit.edu


2002\06\26@033854 by Roman Black

flavicon
face
All wrote:
>
> >>
> I *have* started work on a Windows version of the encoder,
>  should be done in a week or so. :o)
> -Roman
> <<
>
> Hi , Roman . I would just like to know which windows language
> and compiler you have settled upon ?


Hi Vis, settled on Borland C++ Builder for now at
least. Seems to be going ok. I did notice that UK mag
PC-Plus June 2002 has the full Code Warrior 5 (Pro!)
on the cover disk, $650 US worth.
-Roman

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


More... (looser matching)
- Last day of these posts
- In 2002 , 2003 only
- Today
- New search...