Skip to main content

Questions tagged [frequency]

Defines how often something occurs, such as pulses in a digital signal, or oscillations in a radio wave.

Filter by
Sorted by
Tagged with
15 votes
2 answers
72k views

Set PWM frequency to 25 kHz

I currently can set four PWM pins to around 31 kHz with the following code: void setup() { TCCR1B = TCCR1B & B11111000 | B00000001; // Set PWM frequency for D9 & D10: pinMode(...
user16307's user avatar
  • 237
4 votes
2 answers
26k views

Arduino constant clock output

I am controlling an ADC with my Arduino Uno. I would like the clock of the ADC to be the same frequency of the Arduino. Is there any way that I can have a constant clock output from one of the Arduino ...
Liam F-A's user avatar
10 votes
1 answer
2k views

Why is our refresh rate consistently decreasing in logging on SD card?

The current code is used to gather the state of 12 infrared beams and log them to an SD card using the real time clock to mark the time. The code uses a switch to turn the device on and off and an LED ...
JClark's user avatar
  • 103
6 votes
5 answers
951 views

Arduino-based mains frequency monitor

I'm looking to put together a simple mains frequency monitor based on the Arduino platform. The mains here are 250 V @ 50 Hz, but obviously these fluctuate slightly, which is the whole point of the ...
Ozzah's user avatar
  • 193
4 votes
3 answers
29k views

Maximum frequency of digital signal in Arduino Uno?

As Arduino Uno has a 16 MHz oscillator but while running program it has less frequency because some of the processing power is used for running the program. I have used the delay(1) but it is giving ...
chandrayaan1's user avatar
4 votes
1 answer
6k views

Generate 1.7 Mhz with PWM in Uno?

I have this code: void setup() { pinMode(11, OUTPUT); TCCR2B = 0; TCNT2 = 0; TCCR2A = _BV(WGM21); TCCR2A |= _BV(COM2A0); OCR2A = 249; } void loop() { soundBuzzer(); } void soundBuzzer(...
Hackeitos's user avatar
2 votes
2 answers
891 views

Arduino audio frequency reader

I have a simple project for my arduino : light some leds when i send a certain frequency from my smartphone through the jack output . For example , I play a simple audio file generated with a ...
Sir's user avatar
  • 23
2 votes
1 answer
110 views

Arduino Due custom platform for school and library installation

I have made a custom-development hardware for our school, where you can plug in an Arduino Due. It is mainly for driving all kind of motors and reading sensor signals. Therefore I added a custom SAM ...
Chris's user avatar
  • 23
2 votes
1 answer
291 views

Arduino-based mains frequency monitor follow-up

Following my previous question, I'm getting closer to thinking about putting together this mains frequency monitor. I would just like to do a sanity check on my electronics before I order the ...
Ozzah's user avatar
  • 193
1 vote
2 answers
2k views

How to get 38 Khz clock from Timer 0/2 in Arduino Mega 2560?

I have been trying to generate a PWM wave of 38 Khz (13 microsec= ON period , 13 microsec= OFF period). Currently I am using Timer 0 to generate the PWM wave , however i am confused as to how to ...
Boudhayan Dev's user avatar
1 vote
4 answers
3k views

Delay between multiple analogReads

I'm trying to read 4 analog inputs (1kHz speed). I changed the prescaler to 16 for my Arduino Leonardo according to this link. I then tried to read the analog pins and I used the following code to ...
Isra's user avatar
  • 95
0 votes
1 answer
239 views

Procedure for changing frequency of Nano or similar

I need to get interrupts at one of three specific rates: 1920, 2000, and 2400 per sec, at a fairly high precision (~10 ppm). I've asked about this on Electronics but I think here might be more ...
Jim Mack's user avatar
  • 235
0 votes
1 answer
4k views

Trouble with setting the PWM frequency for Arduino Due

I'm using Arduino Due and I set the analog read and write resolution to 12-bit for better resolution. Basically all I do is to vary PWM duty cycle by controlling analog DC input voltage from 0 to 3.3V....
user16307's user avatar
  • 237