Tag Archives: ATmega328

Connecting an Arduino to an old alarm panel


By adding an Arduino and Ethernet board to his existing alarm panel, one Maker was able to set up his own security alert system that notified him of events via text message. 


Like many of us, Doug Powers is the owner of a new home. Upon moving into his recently-purchased abode, he happened to stumble upon a pre-existing alarm panel mounted to the wall. Rather than having to deal with all of the time, costs and unnecessary headaches associated with setting up the system, he decided to channel his inner DIY spirit and interface it with an Arduino.

Pic123

By connecting an Uno (ATmega328) and an Ethernet breakout board to the DSC PC1550 panel, Powers was able to emulate the keypad and configure his own monitoring/alerting system that notifies him via text message whenever the alarm is triggered, armed or disarmed. The Arduino itself is directly powered by the unit’s control board, which feeds it roughly 12V. There is also a backup battery supply should the electricity ever go out.

PIc456

The new hardware is linked to the existing control board in two ways: analog pins to read and write signals for the keypad and a programable output from the control board that the Arduino uses to determine the state of the alarm.

Do you have an old DSC 1550 alarm system? Powers has made all of the source code and accompanying library available on GitHub, as well as shared a detailed overview of the project in the video below!

Designing a USB power meter stick with ATmega328


This USB stick measures supply voltage, calculates power consumption and displays it on an OLED display.


There was a time when USB drives were only for transferring data. Not anymore. The interface is increasingly being used as a power supply and charging port for an assortment of gizmos and gadgets. Take this DIY USB line power meter stick from Electro-Labs, for example. The meter is capable of measuring the supply voltage of the devices connected to the USB port or charger, calculating its power consumption, and then displaying the reading on an integrated 0.5″ OLED screen.

DIY-USB-Line-Power-Meter-Stick-Connected-to-Laptop-620x503

The board itself is built around an ATmega328. In order to keep the circuit as small as possible and reduce the number of components, the MCU runs off its internal 8MHz clock. Meanwhile, the voltage and current are measured by its built-in 10-bit ADC.

To enhance the accuracy of the measurements, an external 2.5V voltage reference IC is included as well. The current is converted to voltage on a 0.01R sense resistor and precisely amplified by an LT6106 high side current sense amplifier before being sent to the AVR’s 10-bit analog port. The stick is capable of measuring up to 2.5A. Since the OLED display requires 3.3V supply voltage, a linear voltage regulator handles the 5V to 3.3V conversion.

DIY-USB-Line-Power-Meter-Stick-Bottom-620x505

“An external 2.5V voltage reference is used to get more accurate ADC readings. Since the ADC module of ATmega328 is 10-bit, the reading resolution is 2.44mV (2.5V/1024). It is quite enough for the purpose of the circuit,” Electro-Labs writes. “The 5V line of the USB port is passed through a voltage divider network including 14K and 10K resistors to extend the readable voltage up to 6V.”

The tiny OLED communicates via an SPI interface and is driven by the U8Glib library. An Arduino sketch reads the separate ADC inputs for the voltage and current, and reveals the measurements on the display. 10 samples from each channel are averaged to filter out the noise.

“After a simple V*I power calculation, it shows up the values on the display by using the U8Glib library. The measurement is repeated every one second. The software runs in an endless loop,” the Electro-Labs crew adds.

DIY-USB-Line-Power-Meter-Stick-Chargin-Cellphone-620x501

Intrigued? You can find a breakdown of entire project, including bill of materials and its necessary code, on its original page here.

Watch a LEGO band cover Daft Punk’s ‘Da Funk’


Billed as “the world’s first robotic LEGO band,” each member of Toa Mata is made of Bionicle pieces and powered by Arduino.


Last year at this time, Italian sound artist Giuseppe Acito caught our attention with his innovative take on Depeche Mode’s anthemic 1983 single “Everything Counts.” What made it so different, you ask? The rearranged tune wasn’t performed by him, but instead by his entirely LEGO-based, ATmega328 powered band that he calls Toa Mata.

Music

Billed as the world’s first LEGO robotic group, the Toa Mata Band is controlled by Arduino Uno hooked up to a MIDI sequencer. For his latest project, Acito wired the Bionicle bunch to several servos, each driven by the Arduino.

SR

With a little programming via MIDI, the band was able to play Daft Punk’s hit song “Da Funk” using a range of instruments and synthesizers including Fender Jazz Bass, Ableton Push/Live, Coron Drum, Korg DS10 synth, Finger BassLine, Boss HC-2, Moog Animoog, and a Nintendo DS.

Pretty cool, right? Watch Acito’s Toa Mata Band recreate Daft Punk’s legendary track below! Meanwhile, you can browse some of his other work here.

VGADuino is an Arduino VGA graphic shield


This small graphic card shield lets you connect your Arduino boards to any kind of TV or monitor with RGB or AV ports. 


If you’re like Masih Vahida, the thought of having a large color display connected to your Arduino to show values, text and other information on the screen has certainly passed through your mind. With hopes of making this a reality for developers and hobbyists alike, the electronics engineer has created what he calls VGADuino. It’s a small graphic card shield that enables you to expand your Arduino project to any TV and monitor with RGB or AV ports

79bdc4c03f7b4bce54f97e4493ab1a9f_original

The shield fits nicely on an Uno (ATmega328) and is compatible with the Arduino IDE as well as any Arduino boards using pins VCC, GND, RX and TX. Moreover, it offers Arduino VGA (DB15) and AV composite ports to link to the display.

“The screen resolution is 640×480 VGA. It has 17 text lines and one text scrolling line. Each line can show up to 27 characters and the scroller line can show up to 60 characters,” Vahida explains.

8f9851b42515a76624ad1aced2d81cfa_original-1

“You can change the colors from your code and easily can show your text where ever you want on screen. The device support standard ASCII codes for English, Persian and Arabic fonts.”

Interested? Head over to its official Kickstarter campaign, where Vahida has already surpassed his $1,000 goal. With a price tag of only $29, the units are expected to begin shipping in October 2015.

Tell time (and more) on this open source, Bluetooth-enabled watch


WatchDuino2 is an inexpensive, ATmega328 based smartwatch for Makers.  


Last year, Mar Bartolome created an inexpensive, open source wristwatch based on Arduino. The aptly named WatchDuino consisted of an ATmega328, a crystal oscillator, a Nokia LCD screen and a LiPo battery with a life of about a week. As you would expect, the ultimate Maker device displayed the date and time in both analog or digital formats, and came preprogrammed with two all-time classic games, Pong and Snake.

2020371441055191391

And guess what time it is? Time for the next iteration of the popular gadget! WatchDuino2 boasts a new and improved design that Bartolome built entirely from scratch, taking some of its predecessor’s best attributes (such as its Arduino Pro Mini core) and combining them with enhanced features, namely Bluetooth. Equipped with a BLE module, the watch can now wirelessly communicate with an Android phone, allowing it to rival the likes of other commercial gadgetry.

Thanks to its pairing capabilities, the WatchDuino2 can share phone notifications (SMS, emails, calls and appointment reminders), access Twitter, Facebook and other social networks, as well as receive weather and mass transit alerts. Aside from that, users can even send battery status updates from their watch to the phone and visualize this information in graph form.

9156441439722327683

“The trick is that all of these apps also require an Android component in the WatchDuino Android companion app, doing all the heavy lifting and simply passing WatchDuino the results to display, via Bluetooth,” Bartolome explains.

Additionally, the WatchDuino2 boasts a much better user interface than its older sibling with a 128 x 64-pixel display. Much like any cellphone, a status bar sits at the top of the screen while contextual symbols located on all four corners indicate the purpose of each corresponding button on the side of its case. These functions change, of course, depending on which application a wearer is using.

“For instance, in the main menu you can move left and right, enter or exit,” the Maker writes. “On the Twitter app, you can request a reload, or navigate between tweets.”

6419201441055465385

Unlike the first version of the timepiece, the Maker 3D printed a modular strap to house the electronic components — the Arduino, battery, LiPo charger and buzzer/vibrator — within each of its links. This left only the screen and buttons enclosed inside the actual watch case.

As any Maker would say, there’s still plenty of work to be done and revisions to be made. Among those on Bartolome’s list include refining the code and app framework, reducing its form factor and improving its battery life. At the moment, WatchDuino2 can run for about 18 hours after a 20-minute charge.

Think it’s time for an easy-to-build, Arduino-based watch of your own? Head over to the project’s page to get started. WatchDuino2 has also been named a semi-finalist in this year’s Hackaday Prize.

Build a smartwatch remote for your car with Arduino


Maker controls his Honda CR-Z using a Pebble watch, an Android phone and an Arduino. 


The advent of high-tech, connected vehicles and wearable gadgetry has provided drivers with a new way to remotely unlock their doors, start the ignition and even find parking spots. Take for instance, Hyundai, whose Blue Link app now fully supports Android Wear devices and enables users to do everything from flash its headlights to call roadside assistance.

Watch

However, Mika Wee didn’t own the latest and smartest car. And so, he decided to take it upon himself to bring this functionality to his 2013 Honda CR-Z with the help of Arduino and 1Sheeld. Using his Pebble Steel watch, he was able control its hazard lights, flash its high beams and honk the horn, among a number of other things — though he could do it all from his Nexus 5 smartphone as well.

“The idea of this project is to be able to turn on/off lights (or any electrical component) of a car without being inside the car, or physically pressing dashboard buttons/switches,” Wee writes.

The Maker used a bunch of shield-based components to simplify the project, including a DFRduino (ATmega328), a 1Sheeld (ATmega162) as an input receiver to communicate with the phone, and a relay shield as the output to complete the circuit.  Aside from that, he created the watch’s menu with the help of PebbleTasker.

Test

“The next step is to find out which wire in your car does what. Now this is completely dependent on the car that you have, as every car would have a different circuit,” the Maker adds. “I used a multimeter and the help of the car’s service manual to find out which wires/relays conduct electricity when a switch/button is pressed. This tells me which wire/circuit I’m looking for. Then, I tapped relay wires into that circuit to simulate a ‘button press.’ This is not intrusive as I do not go into ECU, OBDII or CAN bus hacking. I merely simulated a ‘button press.’”

Intrigued? Head over to the project’s page on Hackster.io where Wee shares a step-by-step breakdown along with the necessary code and schematics. Watch it in action here.

AMQUMO is a Xively ambient quality monitor


Based on an ATmega328, this monitor logs ambient noise, temperature, humidity and brightness data on Xively.


Created by Davide Gironi, AMQUMO is an indoor ambient quality monitor powered by the versatile ATmega328. The DIY device works by logging the data of four environment parameters on the Xively platform: ambient noise, temperature, humidity and brightness. This information is displayed through four bi-color LEDs, labeled with an N, T, H and B, respectively.

HTN

Built on the Xively Logger ATmega328 Library, Gironi used a web-based interface to set up the network parameters and the Xively tokens. The network can be configured using a static IP, gateway, netmask or DHCP.

Aside from the ATmega328 at its core, AMQUMO is equipped with an EC28J60 Ethernet controller to handle communication, a DHT22 sensor to measure temperature and humidity, an analogic noise sensor with an electret microphone and op-amp to monitor ambient noise, and a BH1750 board to detect brightness. Ambient noise and brightness are sampled twice every second to provide instant LED feedback, while humidity and temperature have a bit slower sample rate with ambient levels computed and posted to Xively each minute.

avr_atmega_ambient_quality_monitor-atmega328

“The PCB is quite simple, it’s just a bridge board for a low cost Arduino Mini board and all the sensors board. The main board and all [of the] sensors can be, of course, designed as a single board,” Gironi notes. “The temperature and humidity sensor need to be exposed outside the main electronics board, because both the EC28J60 chip and voltage regulator heat up to almost 40°C. And to solve this issue, a step down switching regulator should be used.”

Interested? Check out the AMQUMO’s original page here.

This 3D-printed prosthetic hand features a built-in space game


This Maker duo’s 3D-printed prosthetic hand is out of this world! 


Perhaps one of, if not, most amazing things to recently come from the 3D printing world has been DIY prosthetics. These artificial limbs have grown by leaps and bounds in the last couple of years. One group helping lead the way has been e-NABLE, a global network of volunteers who are using their 3D printers to create prosthetic hands for those in need. Given the initiative’s open source nature, prostheses can now be made for a fraction of the cost of their commercial counterparts.

Game`

One of the more popular e-NABLE models has been what’s called the “Cyborg Beast.” Using this as the base for their project, Maker duo Debbie and Danny Leung decided to develop an intergalactic-looking version of their own that boasts some additional functionality. Though it may work like other 3D-printed limbs, thanks to some modifications, an Arduino Nano (ATmega328) and a few other electronics, the Cosmogony brings an entertainment console right to the palm of a user’s hand.

The Cosmogony hand has two modes: display mode and play mode. In display mode, three rainbow diffused LED lights on the palm and four RGB LED lights in the fingertips repeatedly change colors. There’s also an Adafruit 8×8 dot matrix display connected to an accelerometer, which alters images as the wearer moves their hand. Aside from that, the prosthetic can be converted into a virtual video game that employs its embedded accelerometer.

In order to play “Expand Your Universe,” a user simply moves his or her hand in the direction that they’d like the characters to go. For this game, the main characters are actually four planets moving together at the center. As the wearer advances to each stage, an asteroid from a random direction comes closer. To avoid a collision, the user must try move their hand accordingly to dodge the asteroid in an X or Y direction sensed by the accelerometer.

Fing

“The blue lights blink in the fingertips, a smiley face appears, and they spread farther apart. To proceed to the next stage a player must successfully dodge asteroids sweeping across from random directions. If a player fails to dodge an asteroid, the red lights blink in the fingertips, a sad face appears, and the player has to start over at that last stage,” its creators explain.

The hand itself is comprised of flexible NinjaFlex filament, while springs were used for the finger joints. Six strings of fiber optic lights make up spiral shaped “galaxy” on the palm, which has a compartment for the LED dot matrix on top. Housed inside the gauntlet of the hand lies the Arduino, a 9V battery and a dual-axis accelerometer.

Pretty amazing, right? Watch it in action below!

[h/t 3DPrint.com]

These lights will let you control your smart devices through gestures


LiSense uses shadows created by the human body from blocked light and reconstructs 3D human skeleton postures in real-time.


As our homes become increasingly smarter, what if we could use the light around us for more than just illumination? In other words, imagine if the light in your room could sense you waving your hand as you enter, or was able to trigger your smart coffee machine, unlock the door and turn on your entertainment center. While it sounds like something straight out of a sci-fi novel, it may soon all be possible thanks to a new project from researchers at Dartmouth University.

55ca00f1e2f3f

The team is looking to transform ubiquitous light into a medium that integrates communication with human sensing. LiSense works by decoding information made from visible light to turn everyday lighting into sensors that can then recognize and respond to what we do. This is achieved through visible light communication (VLC), which encodes data into light intensity changes at a high frequency invisible to the human eye.

Not only does LiSense use light to sense people’s movements, but it also allows them to control devices in their environment with simple gestures, employing light to transmit the information. The hope is that you will be able to gesture and engage with objects in a room via nothing more than light, similar to how you’d use a Kinect or Wii gaming system to interact with your TV.

For LiSense to track a person’s movements, the researchers built a three-meter by three-meter light-sensing testbed with five off-the-shelf Cree LEDs in the ceiling and 324 photodiodes on the floor. A total of 29 microcontrollers, Arduino Due (SAM3X8E) and Uno (ATmega328), were embedded as well. The system uses the shadows created by a person standing on the testbed to reconstruct their 3D human skeletal posture in real-time (at 60 Hz).

To get their shadow-based human sensing to work, the researchers had to overcome two critical challenges. Since multiple ceiling lights lead to diminished and complex shadow patterns on the floor, they had to devise light beacons to separate light rays from individual LEDs and ambient light. Additionally, they came up with an algorithm capable of taking the collected limited resolution, 2D shadow maps from the photodiodes in the floor and reconstructing a person’s posture in 3D.

Light

By waving your hand, LiSense lets you freely control things, play games and track behavior without the need of cameras and on-body devices. One day, the team says it may even respond to your feelings. Compared to existing methods that use wireless radio signals such as Wi-Fi to track user gestures, VLC has several appealing properties and advantages. For starters, light-based sensing is secure, doesn’t penetrate walls, and isn’t limited to classifying a pre-defined set of gestures and activities. On top of that, it’s energy efficient, operates at a bandwidth 10,000 times greater than the radio frequency spectrum, and reuses existing lighting infrastructure.

“Light is everywhere and we are making light very smart,” says Xia Zhou, lead author and researcher on the project. “Imagine a future where light knows and responds to what we do. We can naturally interact with surrounding smart objects such as drones and smart appliances and play games, using purely the light around us. It can also enable a new, passive health and behavioral monitoring paradigm to foster healthy lifestyles or identify early symptoms of certain diseases. The possibilities are unlimited.”

Sounds intriguing, right? See it all in action below, and be sure to read the team’s entire paper here.

Control an LED with your breathe


This Arduino radar lets you control the brightness of an LED with your breath.


A few months ago, Norwegian sensor developer Novelda unveiled a pair of adaptive Atmel | SMART ATSAM4E16E powered sensor modules capable of monitoring human presence, respiration and other vital information in real-time. Based on the company’s XeThru technology, they use radio waves rather than infrared, ultrasound or light, enabling them to ‘see through’ an assortment of objects ranging from lightweight building materials to blankets. These modules can even be employed to detect movement in a room, as well as measure the breath of a person, without contact.

cdrwoybwoaaa00n-1-jpg-large

With one of these boards on hand, Maker Øyvind Dahl decided to build an Arduino radar that could control the brightness of an LED with his breath. To accomplish this, he hooked the X2M200 respiration monitoring sensor up to an Arduino Uno (ATmega328). The module, which was tasked with detecting his chest movement, also required both a USB communication board and a level shifter to interface the 2.8V levels of the XeThru with the 5V of the Uno.

Dahl connected an RGB LED to the project, whose brightness faded in unison with his breathing. When he inhales, the light fades in. And when he exhales, it fades out. Beyond that, the faster that he breathes, the faster the LED will fade.

arduino-radar-breadboard-42-e1439468718498

In order to make this work, the Maker wrote his own code for the radar — which can be found on GitHub here — that would would send over the respiration data.

“Another thing I was struggling with, was type conversion. And with only an RGB LED as my output, it was a bit hard to debug,” he explains. “So I connected another Arduino with SPI, that I could use as a debugging console for a while, and got the type conversion sorted out. I parsed the data that was coming in, and used the movement-value to set the brightness of the LED.”

Arduino-radar-with-rgb-led-1024x413

Since the Arduino did not process the data quick enough, Dahl ended up adding a function to his code that would empty the buffer and sync the data each time that he fetched a new measurement.

While this is merely a prototype, there’s plenty of potential for development. Dahl says that upon completion of his “useful device,” he will share the code and detailed breakdown of the project on his site. As we await to see what the Maker comes up with, you can find his first tutorial here.