Home
Prox / RFID
Verichips
Ladder Logic
[interfacing] †
Tube Joints
Key Code From Photo
SolveSpace (3d CAD)
SketchFlat (2d CAD)
Photographs
Miscellany
Resume / Consulting
Contact Me

LDmicro Forum - PWM with two different frequencies.

(you are viewing a thread; or go back to list of threads)

PWM with two different frequencies. (by Magno Medeiros (Brasil))
Hello, please someone help me to create a program that sends time with PWM frequency of 20khz, time issues with PWM frequency of 40khz. time of 5 seconds for each frequency. is attached what I tried to do, but measuring with ossciloscópio see that emits only a frequency of 20 kHz.
Wed Nov 25 2015, 07:51:31, download attachment analise do funcionamento PWM (PIC) v3.ld
(no subject) (by MGP)
Better? ;)
Wed Nov 25 2015, 14:49:33, download attachment analisedofuncionamentoPWMPICv4.ld
(no subject) (by Magno Medeiros (Brasil))
Thank you very much for your help, but unfortunately I could not do what I wanted. Intended to make a circuit to issue various sound frequencies to scare sparrows of my house, but I see on the oscilloscope that is never generated more than one frequency, although did a test by placing a piezoelectric membrane to listen to the sounds and noticed that there is a change in tone (2kHz and 4khz) experienced at various frequencies, has not worked. Still I am very grateful for your help.
Thu Nov 26 2015, 13:58:49
(no subject) (by MGP)
I do not understand fully what you want, but in this example, you can not hear frequencies of 20 and 40kHz.
Maybe a drawing of the signals will help.
Fri Nov 27 2015, 05:48:24
(no subject) (by Magno Medeiros (Brasil))
Hello friend MGP,
I know I can not hear such a high frequency, so that I said I did tests on other frequencies 1 and 2 kHz, 2 and 4khz, 4:08 khz to try to see with an oscilloscope switching frequency in PWM output, but in no tests leave the two frequencies, only one can be seen on the oscilloscope, what I saw was a change in the pulse width. I did these tests at low frequency whereas if it worked, would be also good at high frequencies. Please find attached a circuit sketch.
Thanks again for your help.
Fri Nov 27 2015, 12:26:11, download attachment For MGP.png
(no subject) (by Magno Medeiros (Brasil))
I mean: see the signal on an oscilloscope and listen on a piezo membrane, so the low frequencies. After tested change to other high frequencies that the sparrows can hear
Fri Nov 27 2015, 12:35:05
corrected KHZ (by Magno Medeiros (Brasil))
corrected KHZ
Fri Nov 27 2015, 12:41:12, download attachment For MGP.png
(no subject) (by MGP)
You're right, the only thing you do with it is to change the duty cycle_
It's also not working when you change the dutycycle to zero before changing the PWM frequency.
Maybe a bug, I'll look at it when I have time to work around it.
Perhaps Jonathan knows more about this.
Sat Nov 28 2015, 06:28:22
(no subject) (by Magno Medeiros (Brasil))
Ok MGP friend, I understanding! Anyway thank you for your dedicated time to reach these conclusions.
Sat Nov 28 2015, 13:11:39
Post a reply to this comment:
Your Name:
Your Email:
Subject:
(no HTML tags; use plain text, and hit Enter for a line break)
Attached file (if you want, 5 MB max):