Category Archives: Engineering Perspectives

Ai.Frame is an open source robot

The open source Ai.Frame – which recently surfaced on Kickstarter – is a versatile miniature robot powered by an Atmel-based Arduino Mini (ATmega328 MCU) paired with infrared and ultrasonic sensors.

“The robot’s sophisticated structure is designed to make motion both precise and versatile,” an Ai.Frame rep explained in a recent post.

“The Apollo [model offers] 16 degrees of freedom, while the Rex has 9. Operated by an efficient controlling system, the Ai.Frame executes your commands almost instantly.”

AI.Frame can be controlled via a smartphone or tablet, gamepad or even a wearable harness that accurately captures upper torso movements.

“As experienced engineers, we have a thorough understand of robot configuration and construction, [so] we incorporated rich body details into the Ai.Frame to simulate the structure of the human body,” said the rep.

“The Ai.Frame Apollo’s skeleton contains 109 pieces and its outer shell contains 12, while the Ai.Frame Rex consists of 98 pieces. We also made made a concerted effort to optimize the molding and screws for the strongest possible structure. Nonetheless, you can choose to either build an Ai.Frame from scratch or to have us assemble it for you.”

Additional advanced key features include:

  • Roadblock avoidance
  • Voice recognition capabilities
  • Auto standing

Interested in learning more? You can check out the project’s official Kickstarter page here.

Touchless 3Dpad gets a Matlab update

Back in May, Ootsidebox introduced the 3Dpad, a sophisticated touchless gesture control interface with a depth perception of 10cm.

The platform – which made its Indiegogo debut last month – comprises three primary components:

“To detect the proximity of the human hand or finger, we use the projected capacitive technique. This is the principle of virtually all modern touch screens – except that now we are in the air, relatively far away from the detector surface (10 cm max). So we build capacitors which are as ‘open’ as possible, using electrodes drawn on the electrode plane PCB in order to obtain a maximum ‘hand effect,’” 3Dpad creator Jean-Noël explained.

“[Meanwhile], the capacitors formed by the electrodes are part of an oscillator whose frequency is influenced by the distance of a hand. When it enters the electrostatic field, this ‘intruder’ is going to cut the field lines and divert the electrical charges. The closer the hand approaches the electrodes, the more the oscillator’s frequency increases.”

Recently, Jean-Noël told Bits & Pieces that Ootsidebox is working with Matlab to create a 3Dpad Arduino shield as a Simulink block.

“After a discussion we had with MathWorks, we decided to make the 3Dpad Arduino shield  available as a Simulink block, downloadable from MATLAB central,” he explained.

“We are convinced that this solution, which enables graphical programing, is one of the best ways to learn and experiment with Arduino.”

In addition, says Jean-Noël, the Ootsidebox team is designing a MIDI controller for electronic music built around the 3Dpad.

“It will be based on 3Dpad shield + an Atmel-based Arduino Mega,” he added. “Making a ‘virtual percussion’ system with few 3Dpad synchronized sounds good!”

Interested in learning more about the 3Dpad? You can check out the the project’s official Indiegogo page here and browse our Ootsidebox article archive here.

Why the DIY business is booming

Writing for Electronic Design, Lou Frenzel confirms that the DIY hardware business is booming.

“Over the past several  years there has be a major increase in those interested in building, hacking and playing around with electronic things,” he explains.

“There is serious interest in making robots and experimenting with the Arduino and [other] embedded computers. Electronics seems to be fun again.”

As Frenzel notes, part of this re-emergence can be attributed to the influence of the popular magazine Make by publisher O’Reilly Media, now Maker Media.

“With well over 100K readers, Make is bringing back the popularity of making stuff, electronic, mechanical, wood and otherwise. Their Maker Faire events attract thousands who can show off their latest creations and consort with other makers and learn new skills and techniques. Robots are a major focus of the DIYers,” writes Frenzel.

“Another influencer has been the push to bring more kids into engineering with the various STEM (science, technology, engineering, math) programs. STEM efforts hope to lure more students to college technical degrees to help build the U.S.’s engineering capability.”

In addition, says Frenzel, a big part of the experimentation resurgence is the availability of books supporting it.

“There have always been hobby electronic books but a new batch has helped many get started.  Some examples are Gordon McComb and Earl Boysen’s Electronics for Dummies (Wiley, 2005) and Earl Boysen and Nancy Muir’s Electronic Projects for Dummies (Wiley, 2006),” he adds.

“Even my own book, Electronics Explained (Newnes/Elsevier, 2010), has done well with the DIYers.  But the real best seller has been Charles Platt’s Make: Electronics (O’Reilly, 2009). Platt is a contributing editor to Make magazine. The book is printed in full color on quality paper and puts forth a wide range of build-it-yourself electronic projects.  All these books have one thing in common:  help a person learn electronics and have fun making electronic games, gadgets and unusually useful items.”

Interested in learning more about the DIY Maker Movement? The full text of “Make More Electronics: The DIY Business is Booming” by Lou Frenzel is available here. Readers may also want to check out our Bits & Pieces article archive on the subject here.

ATtiny85 operates (fingerprint) garage door opener

A high school sophomore known by the Instructables handle “nodcah” recently designed a DIY fingerprint scanning garage door opener powered by Atmel’s popular ATtiny85 microcontroller (MCU).

Fortunately, the DIY project isn’t limited to just garage doors, allowing Makers and tinkerers to create various types of simple motorized locks by modding the initial Instructables.

Aside from Atmel’s ATtiny85 microcontroller (MCU), key project components include:

  • 

Fingerprint scanner and JST connector
  • Serial LCD kit with Atmel’s ATmega328 MCU
  • 
PNP transistor
  • Buzzer
  • Speaker wire
  • 3D printed case
  • Copper tape
  • 5V voltage regulator
9V battery and connector
  • SPDT limit switch

“The serial LCD kit sold by Sparkfun comes with an ATmega328 MCU to control the LCD. The ATmega has extra processing power to be used for other tasks besides controlling the LCD. Because of this, we can use it as an Arduino to communicate with the fingerprint scanner, send an ATtiny85 commands, control the LCD and use a buzzer to play tones,” nodcah explained in a detailed Instructables post.

“To prevent the module from running continuously, I’ve added a limit switch to detect when the case is closed. If it’s closed, power will not be supplied to it (saves battery power).”

After gathering the above-mentioned materials, drawing the circuit and assembling the serial LCD kit, nodcah builds the circuit boards, programs the ATmega328 and ATtiny85, configures the fingerprint scanner, writes the sketch and 3D prints a basic case.

“To open the garage door I wired my module to the button that normally opens the garage. Instead of a physical connection being made, the module uses a NPN transistor to ‘press’ the button. The wires should first be measured and cut to size, leaving a little extra wire just to be safe,” nodcah added.

“Then, the hard part: soldering the wires from the button to the FPS module. The wires should next be wrapped with a generous amount of tape. To get the signal from the ATmega outside of the garage to the ATtiny inside the garage, three wires (power, ground and signal) will need to be fed through the wall. On my garage, there was a piece of wood that I just drilled right through.”

Last, but certainly not least, nodcah notes that the module’s built-in enroll feature can be used to open the garage and create personalized messages for each profile.

Interested in learning more? You can check out the project’s official Instructables page here.

Video: Atmel & Arduino power this robotic hand

A high school student known as “Gabry25” has designed a wirelessly controlled robotic hand using an Atmel-based Arduino LilyPad and an Atmel-powered Arduino Uno.

As Julian Horsey of Geeky Gadgets reports, the wireless robotic hand faithfully reproduces the movements of an accompanying glove worn on another hand.

Aside from the above-mentioned Arduino boards, key project components include:

  • Shield to connect the Xbee module
  • Robot_Shield
  • 5 Flex sensors
  • 5 resistors: 47 KΩ
  • Battery pack with 3×1.5 V batteries
  • LilyPad FTDI adapter (optional)
  • A steel structure for the palm of the hand and wood for the fingers
  • 5 servomotors
  • Fishing wires
  • 9 V Battery

“To connect the servomotors I used the Robot_Shield from FuturaElettronica, which has also a switching regulator to power the entire circuit, but you can use any shield made for that,” Gabry25 explained in a recent Instructables post.

Interested in learning more? You can check out the project’s official Instructables page here.

The “Key” to Reality

If we wanted to reduce the definition of authentication to its most Zen-like simplicity, we could say authentication is “keeping things real.” To keep something real you need to have some sort of confirmation of its identity, as confirmation is the key (so to speak).

The equation could be as follows:

Identification + Confirmation = Authentication

Confirming or validating the identity of a document, item, data, etc. is what keeping things real is all about. Some of the “things” that can be authenticated with cryptographic methods are mobile, medical, and consumer accessories; embedded firmware; industrial network nodes; and sensors, among others. Soon IoT and vehicle-to-vehicle communication will join in.

Authentication is far more important than many people realize, especially in our growing hyper-connected world that now links billions of people (and things). In cyber-land, authentication is accomplished by deploying cryptographic keys and algorithms. Keys are fundamental to keeping things real—so that is what we mean by “the key to reality.”

Key real 1

There are two primary types of Authentication: Symmetric and Asymmetric. Atmel offers secure key storage devices for both types. These two important techniques take their names directly from whether the keys on each side (i.e. the host and client sides) are the same or different.

Symmetric Authentication

If the same secret key is used on the client and on the host, then the application is symmetric, just like the name suggests. Both of the symmetric keys must be protected because if either one gets out then the security will be lost. This is perhaps analogous to having two sets of car keys. Meaning, losing either one makes it easy for a thief to drive away with your car. So, the secret keys must stay secret.

Key sym

Symmetric Keys are the Same

The identical keys on the host and client are used in mathematical calculations to test the reality of client devices. A very common mathematical calculation that is used is a hash function based upon a cryptographic algorithm (such as SHA). A hash operation produces a hash value (also called “digest”), which is a number of a specified length that is usually smaller than the numbers used as the inputs. A hash is a one-way operation, which means that the inputs cannot be recreated from the hash value.

With symmetric authentication a typical process is to challenge the client device to be authenticated by sending it a random number. The client then puts the random number challenge and a secret key into the hash algorithm to create a hash value, which is known as the “response.” Each challenge will generate a unique response.

It should be noted that cryptographers call a hash of a random number with a secret key a “Message Authentication Code” or “MAC.” The diagram below illustrates this process. Because the host key is the same on the host and client sides, the exact same calculation can run on the host. Once that happens, the hash values (“MACs”) from each can be compared. If the hash values match, the client is considered to be real. You can see that symmetric authentication is really a simple process, but it is loaded with mathematical elegance. Now let’s look at asymmetric authentication.

Hash Value 1

Hashing a Random Number with a Secret Key

 

Asymmetric Authentication.

Asymmetric keys are presented in public-private pairs. More specifically, the public and private keys are related to each other via a mathematical algorithm. An example would be the Elliptic Curve Cryptography (or “ECC”) algorithm. Only the private key has to be securely stored. Because the keys are different, asymmetric authentication cannot use the same calculate-and-compare process as symmetric.

Asymmetric requires more complicated techniques such as making digital signatures that are verified for authenticity (this is called “Sign-Verify”). An example of asymmetric authentication using ECC algorithms is Elliptic Curve Digital Signature Algorithm (or “ECDSA”).  A major benefit of the Atmel ATECC108A device is that it can be used to easily implement ECDSA sign-verify. (The steps of ECDSA are very interesting, but they will be covered in a separate article). Note that an important trade-off between symmetric and asymmetric authentication is the speed of operation. For example, authentication time for the Atmel ATSHA204A is 12ms (typical) for symmetric versus more than a second for many microcontrollers to execute an asymmetric ECDSA operation.

Getting back to the keys:   The secret keys must stay secret. If keys are the keys to authentication (i.e. reality),  then secure storage of the secret keys is the key to SECURE authentication. And that is the real point here.

So the, how is secure storage implemented? The best way is to use hardware key storage devices that can withstand attacks that try to read the key(s). Atmel CryptoAuthentication products such as the ATSHA204AATECC108A  and ATAES132 implement hardware-based storage, which is much stronger than software based storage because of the defense mechanisms that only hardware can provide against attacks. Secure storage in hardware beats storage in software every time. Adding secure key storage is an inexpensive, easy, and ultra-secure way to protect firmware, software and hardware products from cloning, counterfeiting, hacking, as well as other malicious threats.

For more details on Atmel CryptoAuthentication products, please view the links above  or the introduction page CryptoAuthentication. Future Bits & Pieces articles will take in an in-depth look at how symmetric and asymmetric authentication is accomplished.         

Microsoft Surface Pro 3 teardown reveals…

The Microsoft Surface Pro 3 is a Surface-series Windows 8.1 tablet. Making its initial debut in May 2014, the first models began shipping on June 20, 2014.

The Surface Pro 3 features a 4th generation Intel Core processor, 12-inch display, multi-stage kickstand, redesigned type cover and a battery-powered Bluetooth pen.

Recently, the iFixit crew conducted a detailed teardown of Microsoft’s latest tablet, finding Atmel’s AT24C16 two-wire serial EEPROM, as well as Atmel’s UC256L3U 256KB Flash, 32-bit AVR microcontroller.

Interested in learning more about Microsoft’s Surface Pro 3? You can check out the tablet’s official product page here and iFixit’s full teardown here.

Readers may also want to check out some other recent teardowns featuring Atmel components, including the Narrative, Xiaomi MiPad and the Black & Decker Gyro screwdriver.

Creating a SCADA system with WidgeDuino

WidgeDuino – which recently made its Kickstarter debut – is an intelligent and easily configurable Windows-based application for communication between a Microsoft Windows platform and a microcontroller based system such as an Atmel-based Arduino board.

https://www.kickstarter.com/projects/809215184/widgeduino?ref=discovery

Essentially, WidgeDuino communicates with the microcontroller system via serial protocol or TCP/IP.

“It allows simultaneous use of multiple widgets to create complete SCADA systems using simple WidgeDuino library written for [the Atmel-based] Arduino Uno,” WidgeDuino rep Shehzad Nazir explained.

“This includes, amongst others, keypad, LEDs, gauges, knobs, sliders, thermometers, tanks and buttons. Its intuitive approach to communication simplifies rapid prototyping and development of a complete automation system.”

More specifically, Widgeduino is based on Microsoft’s .NET framework, using the popular Visual Studio Windows Presentation Foundation (WPF) as its designer. It leverages National Instrument controls to enable the control of devices connected to the microcontroller system. 

As noted above, the app runs on a Windows system and supports both wired and wireless connections.

“Widgeduino comes with built-in APIs which facilitate addition of user-friendly widgets to embedded designs,” Nazir continued. “The libraries are primarily designed for communication with Arduino boards.”

Widgeduino offers two primary modes of operation:

  • Widgeduino over Serial: Serial based point-to-point (using RS232) or wireless point-to-multipoint (via Xbee 802.15.4) communication between the Widgeduino application and Arduino boards.
  • Widgeduino over Internet: IP based networking to enable Internet of Things (IoT). This mode can also be used as a hybrid (i.e. with Serial and IP protocol) to connect serial devices over internet with the Widgeduino app.

“Widgeduino simplifies the process of prototyping as it has multiple widgets that are very valuable in testing a design concept,” Nazir added.

“Once you finished with prototyping and testing with Widgeduino, you can use these widgets in your real SCADA system designs. Widgeduino provides a simple serial or ethernet interface to your microcontroller based designs, with a particular focus on Arduino boards.”

Examples of current (supported) WidgeDuino applications include:

  • 

Automation
  • Prototyping of embedded systems
  • Human Machine Interface Solutions
  • 
Robotics
  • Drones
  • Access control
  • 
RGB lighting
  • 
Motor control

Interested in learning more? You can check out WidgeDuino’s official Kickstarter page here.

ATtiny84 powers this DUO Decimal SBC



Jack Eisenmann has created a number of Atmel-based homebrew computers that we’ve covered on Bits & Pieces, including the DUO tiny, DUO portable and DUO Mega.

Recently, Eisenmann debuted the DUO Decimal, an ATtiny84 based SBC.

“[This] ATTiny84 based computer [features a] 7 segment number display and 2 buttons. [You can] use the 512 bytes of EEPROM to store program code,” Eisenmann explained in a recent project post.

 “[Plus, you can] use the 512 bytes of SRAM for program data and as a code editing buffer.”

Additional key project components include:

  • 

(x1) 7 segment number display: LA-401VD (SC56-11EWA)
  • (x2) Button: 101-TS7311T1602-EV
  • (x3) 10K ohm resistor: 291-10K-RC
  • (x1) 20K ohm resistor: 291-20K-RC
  • (x1) 330 ohm resistor (7 isolated): 4114R-1-331LF
  • (x1) 14 pin chip socket: 2-641599-4 (1825093-3)
  • (x2) 3 pin male header: 69190-403
  • (optional) 5 pin female header: 929870-01-05-RA
  • (x1) Larger capacitor: UVR1H100MDD1TA
  • (x1) Battery holder: BAT-HLD-001
  • (x1) Battery: CR2032
  • (x1) Switch: MHSS1104
  • (x1) Board
  • (x1) Fuse for preserving EEPROM between programming cycles

As HackADay’s Adam Fabio points out, Eisenmann designed an entire language for the new board.

“DUO Decimal is programmed in an interpreted language called DUO Decimal Numeric Code (DDNC),” said Fabio.

”There are 47 DDNC commands, covering everything from basic math to list manipulation. Programs can be entered through the buttons, or save your fingertips by downloading them through the AVR ISP interface. The entire C code for the DUO Decimal, including the DDNC interpreter is available on Jack’s website.”

It should also be noted that Eisenmann coded several example DDNC programs, including 6 function calculator with trigonometry, a Mandelbrot set tester and even a version of the classic of the rock-paper-scissors game.

Interested in learning more? You can check out the project’s official page here.

MIDI drum glove keeps the beat with FLORA



Known as “FLORA,” Adafruit’s wearable electronics platform is built around Atmel’s Atmega32u4 MCU. The microcontroller boasts built-in USB support, eliminating the need for pesky special cables and extra parts.

As Adafruit’s Limor Fried notes, FLORA is extremely “beginner-friendly.” Indeed, the device is difficult to accidentally destroy by connecting a battery backwards, thanks to a polarized connector and protection diodes. Meanwhile, an onboard regulator ensures even connecting a 9V battery won’t result in damage or ruined projects.

As we’ve previously discussed on Bits & Pieces, numerous Makers are using FLORA to design a wide range of creations.

Today, we’re going to be taking a closer look at a MIDI drum glove designed by Adafruit’s very own Becky Stern that is powered by the versatile Atmel-based platform. 

Aside from FLORA, key project components include:

  • 

4X small piezos
  • 
USB mini cable
  • 4X 1M ohm resistors
  • Ribbon wires
  • Glove
  • Scrap fabric

Stern kicks off the MIDI drum glove project by ironing out some fabric to match the glove, cutting four small pieces slightly larger than her fingertips and ironing a small hem on one side.

“Put your glove on and establish what spots make contact with the table, then mark those spots with a pencil. Thread your needle and double the thread over, then tie a knot at the end of the tails,” Stern explains in detailed project tutorial.

“Stitch through one of your pieces of fabric and affix it to the glove fingertip over the pencil mark with a whip stitch. Be careful not to stitch the glove finger closed! Check periodically to be sure your stitches only pierce the intended layer. Stitch halfway around the pocket, tucking the seam allowance in as you go.”

Next? Stick the piezo in the pocket, finish stitching it shut, leaving the wire sticking out towards the back of the hand. Tie off and cut the thread.

“Repeat for the other three piezo pockets, and put your glove on to double check they are tapped when you finger drum,” Stern continues.

“We found the best placement was not necessarily on the pad of the finger, for instance the thumb is around to the side and the pinky is across the first knuckle.”

Next, Stern solders the FLORA circuit, tweaks/uploads the sketch and adds MIDI support to Flora.

“Once your glove is functioning properly, it’s time to tack everything down. Put the glove on and position FLORA so that the wires don’t tug when you make a fist. Tape it down so it stays put before stitching,” she concludes.

“Use plain thread to stitch FLORA’s unused pads to the glove. On the side where all the wires come in, stitch around the wires instead of through the pads. Tack the wires in place with strategic stitches along their lengths. Remove the tape and try on your completed drum glove!”

Interested in learning more? You can check out Becky Stern’s full tutorial on Adafruit here.