User Tools

Site Tools


Installing a low-pass filter

Installing a low-pass filter is a good idea to reduce radio noise and lower the cpu usage. To install a low-pass filter, use an Atmel ATTiny25, ATTiny45, or ATTiny85 microcontroller and flash it using the plight-firmware package. Follow these easy steps:

Get an Atmel ATTiny45 microcontroller. Take the DIL version. Thats the version with vertical pins which fits into standard 2,54mm breadboards, which you probably use if you like your life. Better buy more than one, they are really cheap. Someday you will probably need them, if you place more Raspberry Pis in your house.

Get five 1K (=1000) Ω resistors per RPi. Again, just take more, like 20 or so. You will need this stuff sometime and 20 of them cost the same like turning the key in your car once.

Switch off your Pi and pull out the power adapter. Do ALL the wiring only if your Pi is not powered. That's nothing about saving you from electric shocks. That's because you may damage your Pi if you do wiring while it's on or just powered.

Wire the parts up like shown on the pilight-firmware Github page: Pay attention to the direction, the small ATTiny45 label (or some other writing) on top of the microcontroller must be positioned like on the wiring scheme ( Some ATTiny45 have a small dot on the corner where the RESET 24 GPIO pin sits.

Get a cup of coffee.

Check the wiring, really, check it again. Wrong wiring could damage your Pi.

Start your Pi. If it doesn't start anymore, you probably got the wiring wrong.

Install pilight-firmware if you didn't yet:

sudo apt-get install pilight-firmware

Flash the ATTiny45, that's the part where you tell the ATTiny45 microcontroller, which work it should do. In this case filter some radio noise. Do the flashing with the following command:

sudo pilight-flash -f /etc/pilight/pilight_firmware_t45_v3.hex

Restart the pilight service:

sudo service pilight restart

Your ATTiny45 is flashed and should work. Test if receiving radio signals still works, by firing up “pilight-receive”. Be sure that the pilight service is up and running, else pilight-receive won't work.

Now if you press buttons on a transmitter, the signals should show up. If no signals show up while you press buttons, you maybe got the wiring wrong or the flashing did not work. Check these steps and try again.

It's always a good idea to reboot your Raspberry Pi after changes like this, to check if all still works well after a reboot. Else you probably need to do some debugging work a month later when you reboot the pi and nothing works.

The receiver should be less sensitive now. You can see it if you use pilight-receive. There are not that much wrong signals anymore if you press one of the buttons of your transmitter. And the CPU usage is much less compared to the usage without a low-pass filter. The CPU usage should drop to about a tenth compared to the usage without a low-pass filter.

low-pass_filters.txt.txt · Last modified: 2015/11/27 21:09 (external edit)