Tag Archives: AVR

Vegard Wollan on AVR Freaks and early data books

In the fourth episode of my interview with Vegard Wollan, the co-inventor of the AVR MCU alluded to the passionate following that Atmel and its 8-bit chip have developed.


I can personally attest to this. When one of my pals said he was “going off the reservation” to solve an AVR problem, I thought he meant he was going to use a certain competitor’s microcontroller. Turns out, he was simply referring that he was headed to Atmel’s AVR Freaks forum to get an answer, rather than put in a support ticket or use our knowledge base. What delighted me was when he said, “I would rather jump off a bridge than use a [competitor] part.” Simple as that.

Atmel recently rolled out a redesigned site for the die-hard community, which incorporates both feedback and testing provided by the users themselves. Aside from the new look, the site will utilize a much more robust infrastructure and web technologies to provide users with an enhanced experience. (For those seeking an avid community built around the Atmel | SMART ARM-based products, you can check out AT91.com.)

What I loved about the interview is how Vegard explained it was his college experience that convinced him of the value of a strong user community. We all remember those 3:00am dorm sessions where we would discuss the meaning of life. Vegard noted that Atmel would provide servers and gifts and anything else we could do to support the user community.

The co-inventor also brought along a few copies of the first AVR data book. I was amused to see this post on the AVR Freaks forum, by a user that did not know what a “data book” was. Boy, that makes me feel old! See sonny, back when the Earth was still cooling and dinosaurs roamed the fields, engineers didn’t do everything at their fingertip on the intertube. Companies, much like Atmel, would take all their datasheets and bind them up in this thing called a printed book. I have to admit, it was a great day when I tossed my 500 pounds of databooks in the dumpster. Bless the Internet, it made life so much better.

Vegard-Wollen_holding-AVR-databook-draft

Vegard Wollan holds up the draft version of the May 1995 AVR databook.

Of course, that draft was only a checkplot for the real book. The video also shows Vegard holding up the final version of the AVR databook that us old-timers so frequently depended on. How we would have killed for the modern microcontroller selector guide!

Vegard-Wollen_holding-AVR-databook-final

Here, Vegard Wollan holds up the actual printed data book from May 1995, the first release of the famous AVR microcontroller to the world. They had to make some changes so this databook has parts listed that Atmel never actually produced, and was missing some other parts. Those 4-months printed book lead times were a killer for everybody.

So there you have it, folks. With billions of chips in the wild, a following of over 290,000 AVR Freaks and nearly 100,000 forum posts around the topic annually, it’s safe to say we’ve come a long way since the earliest days of the 8-bit microcontroller. If you’re not already a member of the growing AVR Freaks community, be sure to head on over to the newly-updated site and join today!


Watch out for those snake robots!

Every engineer loves robots, it’s one of the few disciplines that mechanical, electrical, and software engineers all admire. There is a class of robots called snake robots due to their means of locomotion resembling the way a snake works. One such robot , Wheeko, was recently unveiled by the folks at NTNU, the Norwegian University of Science and Technology, the self-same place that Vegard Wollen, the inventor of the AVR microcontroller chip, attended before starting at Atmel.

Wheeko-snake-robot-NTNU

Wheeko, a snake robot developed at the Norwegian University of Science and Technology.

When I asked a Norwegian co-worker if Wheeko might have Atmel microcontrollers in it, he was not sure about Wheeko, but pointed out and earlier robot at NTNU, the Anna Konda was run by eleven mega128 AVR chips.

The Anna Konda was intended as a fire-fighting robot that could crawl through burning or collapsed buildings. There are other applications as well, anywhere that a robot has to work in confined spaces.

So whether Wheeko goes to Mars or his little sister crawls through your veins, you can bet there will be a snake robot in your future.

Vegard Wollan reflects on AVR and Arduino

In this segment of my chat with Vegard Wollan, the co-inventor of the AVR explores the symmetry between the highly-popular microcontroller and the Arduino development board.

Personally, one of the great moments was when Vegard revealed that the entire AVR product line was meant from the start to be easy-to-use. This began with the instruction set, the architecture and continues to this day with things like Atmel Studio 6 integrated development environment (IDE), Atmel Spaces collaborative workspace, and Atmel Gallery, the place where you can find thousands of code samples and tutorials.

Vegard-Wollen_Paul-Rako_AVR-ease-of-use

Vegard Wollan gestures to the AVR schematics as he explains to Paul Rako how ease of use was a primary design goal from the start.

So it is only natural that Arduino was built on this foundation to make their great ecosystem of development boards and their wonderful IDE. You can see Vegard truly appreciates and respects how Massimo Banzi made the entry into AVR programming even easier for both technical and non-technical folks alike.

Today, AVR 8-bit MCUs (as well as Atmel 32-bit ARM®-based MCUs) power a variety of Arduino’s easy-to-use boards including:

  • Arduino Uno: The most “standard” board currently available, the Uno is based on the ATmega328
  • Arduino Yún: The Yún is a microcontroller board based on the ATmega32u4 (datasheet) and the Atheros AR9331.
  • Arduino Nano: The Nano is a small, complete, and breadboard-friendly board based on the ATmega328.
  • Arduino Mega 2560: The version of the Mega released with the Uno, this version features the ATmega2560, which has twice the memory, and uses the ATmega 8U2 for USB-to-serial communication.
  • Arduino Leonardo: Based on the ATmega32u4, the Leonardo is a low-cost Arduino board, featuring the same shape and connectors as the Uno board but with a simpler circuit.
  • Arduino Micro: The Micro is based on the ATmega32u4, developed in conjunction with Adafruit.
  • Arduino Esplora: Derived from the Arduino Leonardo, the Esplora is a ready-to-use, easy-to-hold controller based on the ATmega32u4.
  • Arduino LilyPad: Powered by an ATmega32u4, the LilyPad is designed for wearables and e-textiles, allowing for the board to be sewn into fabric and similarly mounted power supplies, sensors and actuators with conductive thread.
  • Arduino Due: Based on an Atmel ARM Cortex®-M3 processor-based MCU — also known as the SAM3 MCU — the Due board is ideal for home automation projects and can run up to 96MHz.
  • Arduino Wi-Fi Shield: Built for Wi-Fi applications, the Arduino Wi-Fi shield is powered by the Atmel AVR UC3 MCU and an H&D wireless module, and provides developers a powerful Wi-Fi interface.
  • Arduino Zero: The board is powered by an Atmel SAM D21 MCU, which features a 32-bit ARM Cortex® M0+ core.

If you haven’t had the chance to tune-in to all of Vegard’s 1:1 interviews with the Atmel Analog Aficionado, you can check ’em out here.

ATmega328P inside the Nexus Q

Talking to one of my Google buddies at the eFlea, he mentioned that there is an ATmega328P inside the Google Nexus Q media streaming device. I asked what it did and he explained there is a row of LEDs around the device and Google wanted those LEDs to light and flash in sequence the second you applied power. A perfect application for a Flash microcontroller that boots in microseconds.

I was concerned that this was a Google secret until a quick check on the Internet showed a post over at the great folks from iFixit. It verifies that there is an ATmega328P inside the Nexus Q, and you can even see the Atmel logo in the picture.

ATmega328P-Nexus-Q

The Atmel ATmega328P is used to flash the LEDs around the periphery of the Google Nexus Q. It’s the bigger chip at the top right (courtesy iFixit).

The fantastic MegaCube hits Kickstarter

The Maker community has grown up, and respectively, requires a development platform to match. As many of you may already know, the Arduino has been the development platform of choice for many Makers throughout the world. The brains and heavy-lifting behind it is an Atmel AVR microprocessor. As a result, MEGADOM Electronics Inc. and DomCo Electronics, Inc. have teamed up and brought you just that: The grown-up Arduino, the MegaCube.

photo-main

At a first glance, the MegaCube looks a lot like a desktop PC processor; in fact, it is an ATmega2560 with all ancillary components onboard including a 5V LDO. At 1.8” x 2.1” in size, it’s the smallest Arduino-compatible development board, with an ATmega2560. Looking to get it going? All you need is a USB to serial TTL bridge such as an FTDI cable or In Circuit Serial Programmer (ICSP), such as the Atmel AVRISP mkII.

What sets the MegaCube apart from the original Arduino Mega and its clones is not only it’s minute size, but also that each of the one hundred pins of the 2560 are broken out for use. This includes the clock pins and additional general purpose I/O pins. It also works as a great stepping-stone for developers wanting to take the leap from Arduino to Atmel Studio. The MegaCube can act as either an Arduino or a full-featured Atmel development kit.

As opposed to the traditional Arduino platform which uses an asymmetrical pin lay-out, the MegaCube has a symmetrical layout. All pins are on a 0.1” grid and can be easily used with proto or vector board. This 0.1” grid also serves the dual purpose of making this dev kit socketable and thus embeddable permanently or temporarily.

1a4e5e507ee165e2e0bb0a7487a5c4bb_large

Too many times, I have whipped up a quick proof of concept, which I would have liked to have kept intact without permanently tying up my Arduino; something in which MEGADOM Electronics has thought of as well. They created a “shield” system not all that dissimilar to the Arduino platform. They have two of them out now, with more in the works — one is the eBOSS (Embedded Break-Out Shield System) and the other is the BOSS (Break-Out Shield System). The eBOSS is at the core of this concept. You can easily solder the eBOSS into your proof of concept and then just socket the MegaCube into it.  This way, when you need your MegaCube for a different project, you don’t have to destroy your current project to use it. Rather, you can simply unplug the MegaCube board from the eBOSS and plug it into another eBOSS attached to a different project. I can envision the eBOSS also being used in finished products, where the product comes with an eBOSS and is offered as a complete solution with a MegaCube or without one offered at a lower price point, with the purchaser using his or her own MegaCube.

MEGADOM’s chief engineer, Mike Dombrowski, also has a demo in the works for putting multiple programs on the MegaCube. For instance, if you are using the ATmega328-based Arduino Uno platform, you could put up to eight full Uno programs on the MegaCube. By using a unique ID chip attached to each eBOSS, the MegaCube would be able to determine which program to run, making it a snap to switch between projects. Dombrowski’s demo switches between a robotic arm and a Bluetooth Remote controlled tank without reprogramming the firmware.The robotic arm using the eBoss and the MegaCube is on MEGADOM’s Kickstarter project video. Rumor has it MEGADOM is going to be selling the robotic arm as a kit as well!

The eBOSS

The other shield system MEGADOM created is the BOSS. The BOSS was created to allow those new to Arduino to use a MegaCube as if it were an original Arduino Mega, because the BOSS is the same size and footprint as the original Arduino Mega (ATmega1280, an AVR based high-performance, low-power Atmel 8-bit AVR RISC-based microcontroller combines 128KB ISP flash memory, 8KB SRAM, 4KB EEPROM, 86 general purpose I/O lines, 32 general purpose working registers) and gives you access to only the same pins as the Mega. The creator tells me the BOSS will have an R3 footprint in final release versions. This allows the MegaCube to dock with the BOSS giving you the standard Arduino footprint and use standard Arduino shields with the MegaCube. Once again, it’s a great launching platform for engineer or Makers that want to prototype and prove in their design before embedding it into a project full-time or in a more pertinent fashion.

The eBOSS, with a MegaCube takin' a ride

The MegaCube and its shields were created to bring the Atmel ATmega 2560 [Atmel AVR based Microcontrollers] to the forefront of the budding Maker Movement. It unleashes more flexibility in a platform that is smaller and can be socketed and embedded into projects. As you can see, the MegaCube has a promising future with the Arduino Community and it’s already spawning similar designs on the Arduino Forums. To find out more about the MegaCube go to the MegaCube’s Kickstarter campaign or the MEGADOM homepage.

All tiny AVR parts in a spreadsheet

I just made a spreadsheet of all the tinyAVR parts. All my pals love the MCU selector guide, but I have a lot of analog dinosaur buddies that prefer a spreadsheet to a web-based interface. You can sort the data and this spreadsheet has the filter box on the columns, so you can sort out things you care about and exclude the things you don’t. The spreadsheet fits on a 24-inch display, and you can print it out on a single B-sized sheet and use it as an infographic.

ATtinyAVR-product-line_2014-08-20

This screenshot shows how all the tinyAVR parts will fit on one 11×17 ledger-sized or B-sized sheet of paper.

I started with an Excel dump of the selector guide after adding every single parameter to the search. I then took all the tinyAVR parts, and rearranged the columns, throwing out the irrelevant ones. I also combined the automotive parts with the basic parts. That added two columns for automotive temp and automotive Vcc range. Adding 2 columns to remove 13 rows seemed like a good deal. The part name links to the product page on our website.

I made a column for each package. That took a long time. Semiconductor companies think of a part as the silicon die, with the package being almost irrelevant. We systems folk know the package might be the most important thing. I tried to put the smaller packages on the left, with those big ol’ DIP (dual-inline plastic) parts on the right side. There is a second sheet in the spreadsheet that shows all the parts by number and there I put the package size, in mm. In both sheets, the package name links to the definition page on our website.

ATtinyAVR-product-line_2014-08-20_sheet-2

The second sheet of the spreadsheet shows all the tinyAVR parts by number. I put the exact package size on this page.

Besides the packages and package size, I also spent a long time getting pricing. My buddy Wayne Yamaguchi requested this, and he is absolutely right, price is the most important spec of any part, and I hate when it takes 5 clicks to find it. These prices are a bit sketchy. All I did was click on the “Buy” link and select a handful of parts from each family, and then looked at the Digi-Key price, in 1000s. I put in the highest and lowest of the few I selected, but this is by no means scientific or dispositive, as the lawyers would say. What I should do is put the price in the “Package” column, so you know what the package is and what price we charge, but many parts are in the same package but have two Vcc ranges, so there is no unique way to encode this and keep the spreadsheet on one printable page. Maybe I can blow out the second page to show every orderable part number and its price and specs. Always time to do it over, never time to do it right.

The major thing I want to add is the OrCAD 9.2 footprint name for the packages. I am afraid to do this now, since we have all been burned by narrow-DIP/wide-DIP and narrow -SOIC/wide-SOIC and what pin numbering to use on SOT parts, so that will have to wait for next time. If anyone has a proven definitive list of the OrCAD footprints, please let me know. paul.rako[yeah, the at sign]atmel.com

You can highlight all the parts and use the “Data>Sort” function to order them any way you want. I did it by Flash memory size and part name. You can also use the little filter boxes on each column to include or exclude, or even put in a logical range with equal or less than or all the other things. Its not exactly grep or regular expressions, but it can get the job done helping you to find the right part.

Spreadsheet-filter-function

Excel filter boxes let you select just the parameters you care about.

I am told this spreadsheet works OK in Open Office/Libre. My pal Dave asked that any columns that are filtered be lit up red, but that takes a macro, and the VB macro may not work in Open Office, we are checking for that. Meanwhile, check there are 36 part families or that the little filter box does not have 3 pixels different to show the filter is on.

Microscopically-differerent-filter-icon

When you have filtered a column, it is almost impossible to tell, since the only indication is the icon makes this 3-pixel change.

Weasel weasel, CYA CYA, legal boilerplate—this is a hobby job, not an official Atmel document. If the selector guide had it wrong, it is wrong here too. I made my own mistakes too. And I already told you the pricing and the tiny1634 stuff was dicey. What I am hoping is that I can get some community support where you point out the errors, and tell me what to add. paul.rako[yeah, the at sign]atmel.com I also ask that you send this URL link to your pals, instead of just emailing the spreadsheet. That way the bosses will see you like this, and I can have the time to keep working on it.

Hans-Camenzind_tinyAVR-spreadsheet

If Hans Camenzind, the inventor of the 555 timer chip was still alive, he might have a copy of the tinyAVR spreadsheet up on his office wall. I miss Hans, at least he came to my Analog Aficionados party one year, before we lost him to the Grim Reaper.

 

ATmega8 powers this pool cleaning robot

Pools are great, especially in these summer months. Cleaning them, however, not so much. A Maker by the name of David Gironi has simplified this process by powering an automated pool cleaner with an Atmel ATmega8-controlled timer.

avr_atmega_pool_cleaner_robot_01

James Hobson over at Hackaday alerted us to Gironi’s Atmel-powered cleaning unit. After the Maker’s store-bought pool cleaning unit failed, in true DIY fashion he decided to employ some technology to fix the robot on his own. The project is broken down into two parts, the ATmega8-based timer and the underwater cleaning robot.

avr_atmega_pool_cleaner_robot_power_03

According to the Maker, the ATMega8-powered timer alternates between a “working” and “pause” periods. As a result, Gironi can run the robot at a predetermined interval of days, for any designated time period, i.e. 30 minutes. The out-of-water timer is responsible for converting 220VAC to low voltage DC for the robot. Apart from the timer, the robot itself features two motors. One of the motors pumps the water through the unit to filter it, the other to maneuver the cleaner under the surface.

To delve deeper in the Maker’s design, head over to his in-depth blog piece here.

Making decisions with ATtiny85

A Maker by the name Vicor8o5 was frequently finding himself struggling with important decisions. Instead of toiling over making the right choice, he chose to turn to technology to help him out. He devised this clever tool to aid him in the daily decision making process.

FDJD942HYAE71ZS.MEDIUM

To fix his issue, Victor8o5 set out to make the Decision Box, which makes as its name suggests, makes decisions for you by either showing a green or a red light. Outlined in a recent Instructables post, the Maker started with a small wooden cube and hollowed out a space for the technological components in the center. He wired his circuit, including a red/green light and an ATtiny85.

F1YHTR7HYAE735C.LARGE

The code uploaded to the ATtiny85 uses a random function to produce either a red or green light. After running a test of 80 random decisions, Victor8o5 ended up with 44 reds and 36 greens. Even though that sounds like an elementary school math problem, it’s a solid distribution for this handy device!

The next time you find yourself stuck on ordering grande or venti coffee at Starbucks, head over to his original Instructables post to learn how you can make your own device.

 

 

ATmega1284 powers Stubby the Hexapod

Powered by Atmel’s ATMega1284 microcontroller (MCU), Stubby the Hexapod was originally inspired by the unstoppable replicators found in the expansive SG-1 universe.

Designed by the Big One, Stubby started out as a simple 2DOF version, although it quickly morphed into a 3DOF iteration with a full inverse kinematics engine.

“What sets it apart from other hexapods is that it a) is controlled controlled by a single AVR chip (ATMega 1284), including movement and PWM,” The Big One explained in a recent HackADay project page.

“[It] is [also] designed in such a way that it can be driven by very cheap, micro servos (I am currently using $2, 9 gram servos). [Plus, Stubby] has a wooden (MDF) frame cut on a scroll saw [and] is designed with budget in mind; you can make one for around $150 worth of supplies and minimal simple tools.”

The completed project features three 9g servos per leg, all controlled with an AVR-based custom board and an XBee interface to an old Playstation controller.

“You can move in any direction on the XY axis, translate the body on the XYZ axis and roll the body on the XYZ axis,” the BigOne added.

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

ATmega88PA drives this One-Armed Bandit

More than 30 years ago, “vagrearg” learned 6802 microprocessor programming on a dev-kit system. After a few weeks of tinkering, vagrearg designed a One-Armed Bandit (slot-machine) program on 7-segment displays.

“If I remember correctly, the dev-kit had 6 displays in a matrix, 4 to display address and 2 for data, and an 4×5 keyboard matrix for input and a speaker,” he explained in a recent blog post.

“Any user-code could take over the system and do whatever. The program was written in 6802 assembly and took up 2..3kByte of memory.”

Earlier this month, vagrearg was feeling nostalgic and decided to reconstruct the One-Armed Bandit with the following components:

“Two hours of soldering later I had a board capable of reliving old memories. The system runs on 3xAA batteries which should last for about 24 hours of continuous play. The batteries hold several months when the system is in sleep mode,” he said.

“No real optimization has been performed to reduce power consumption. A later version may revisit that part in the firmware, especially sleep-mode power reduction could be improved.”

On the software side, the One-Armed Bandit is capable of implementing the following features:

  • 

Four reels with symbols
  • Random positioning
  • Animated reel movement
  • Sound when reels are moving
  • Hold any reel
  • Start rolling/subtract credits
  • Detect winnings/add credits
  • Bonus button (double cost/win)
  • Music
  • Scrolling text
  • Sleep mode

“Music is generated by the AVR processor using a timer to toggle an output-pin. This has the advantage that it can run asynchronously from the rest of the code,” vagrearg added. 

”The timer is also useful to generate the correct pitch over several octaves. The melodies are then simple tables with a pitch and a duration.”

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