Making your own ATtiny (model) police light



Jan Henrik has designed a multi-functional police light for model cars using Atmel’s ATtiny tinyAVR (25/45/85) microcontroller (MCU).

The project – which recently surfaced on Instructables – features several “animations” or sequences that can be easily changed by simply pressing a button on the circuit board.

“It has two channels, which can be controlled with PWM,” Henrik explained.

“This allows us to add serval animations or police light flashing sequences. The maximum rated current per channel is 500mA, [enabling] us to control high power LEDs, LED stripes or old light bulbs.”

Aside from Atmel’s ATtiny MCU, key project components include:

  • Two buttons (off/on)
  • Two resistors (1kOHM)
  • Two resistors (220kOHM)
  • Two resistors (450OHM)
  • Two diodes (1N4007 or Equal)
  • Terminals with screws
  • One 8 pin IC holder
  • Two BC548 (or Equal)
  • Un-isolated wire
  • One circuit board

As you can see in the circuit board layout above, the two output channels are on pins 0 and 1 (PWM outputs), while pins 3 and 4 are designated as input pins for the buttons.

To program the ATtiny, Henrik used an Arduino Uno with a shield, although as he points out, a simple breadboard will suffice.

On the software side, Henrik wrote two separate programs for the police light. The first is easier to understand and alter, while the second features German and American police light sequences, along with a more responsive menu.

Interested in learning more? You can check out the DIY ATtiny police light official Instructables page here.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s