| ??? 12/17/03 15:20 Read: times |
#60847 - RE: Christmas Responding to: ???'s previous message |
erik malund :
You should get some ideas from the PCA cookbook (address in links <---) mahmood Elnasser: There is no difference if you use C language or assembly language, you have to use the timers on the chip which need same initialization and interrupts with either language. I designed 4 tone ambulance siren recently and used 2 timers, one timer interrupt generates the tone, the other timer interrupt changes the reload value of the first timer according to a sine lookup table generated by excell and pasted into the compiler, to modulate the frequency of the tone. Wail : 600 - 1600 Hz 12 cycles per minute Yelp : 600 - 1600 Hz 180 cycles per minute Piercer 600 - 1600Hz 800 cycles per minute Horn : 1600Hz fixed . I made four functions Wail, Yelp, Piercer and horn, when you call one function it initializes the timer 1 interrupt according to the frequencies shown above. It was fun, especially for I used my evaluation board for the first time. No hardware to build and worry about, just start experimenting with the software. and then you So no one gonna help me Sir, you are VERY wrong. Erik |



