Home » Projects » Electronics Projects » Arduino Sleep Modes and RFI

Arduino Sleep Modes and RFI

arduino sleep modes

Several folks suggested that I try putting my Arduino to sleep in an effort to reduce RFI with my relay controlled antenna switch. So, here are some experiments with Arduino sleep modes.

Most micro-controllers have sleep modes, which you can use mainly to reduce power consumption. While “sleeping”, your device shuts down some of your systems and does not run your code. Putting your Arduino to sleep is easy. Your challenge is how to “wake it up” when needed, especially remotely. In my case, I want to put the Arduino to sleep until I send a serial port command.

Arduino sleep modes are described here. You can see these modes range from “Idle” (least aggressive) to “Power Down” (most aggressive). With Idle, your Arduino just shuts down its CPU. But the real benefit of Idle is that it leaves the serial port active. If you send a command, wake up is immediate and easy.

arduino sleep modes

On the other hand, Power Down shuts off all of the clocks and oscillators, which are the source of my RFI. However, it leaves the hardware interrupts pins active. So, by connecting your serial RX line to the Interrupt, you can wake up when you send a command.

In this post, I will describe my experience with Idle, the simplest of the Arduino sleep modes. In the top picture above, you can see the spectrum of 12 to 24 MHz with the Arduino running next to the antenna control box. I am using a small loop sniffer around the digital pin leads. Everything is pretty RFI silent, except for some hash around 22 MHz which is coming from something else in my lab.

So, simply putting the CPU clock to sleep silences the Arduino.

Arduino Sleep Modes – Exploring Idle

Or, does it? Well, no. If you connect (open) your serial port, tons of RFI shows up, as you can see in the lower picture above. So, Idle mode reduces RFI only when the serial port is not connected.

Still, this might help if you only connect when you want to actually send a command or receive data back. Normally, I just leave my control software connected to the antenna switch. I will experiment with disconnecting unless actually in use. That might do the job. Also, in a later post I will check out the full “power down”.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.