Home

Awesome

PRismino

PRismino

Introduction

The PRismino is the 3rd generation robotics platform of the Swiss Federal Institute of Technology in Lausanne, Switzerland robotics club: Robopoly. It's based on the Arduino Leonardo and is made to be easily solderable as new members of the club often use it as their first soldering experience.

Characteristics

The PRismino uses the same micro-controller as the Arduino Leonardo: the ATmega32U4 which features 32KB of flash memory, 2.5KB of SRAM and 1KB of EEPROM. It runs at 16MHz, has 12 10-bit analog inputs and 4 timers: 8-bit, 2 16-bit and one a 10-bit with multiple channels each.

The board size is exactly 50 by 50mm in order to be produced as cost effectively as possible with the Seeedstudio Fusion service. Because of the board size restriction and the awkward Arduino SPI port placement it was not possible to adopt the true Arduino Leonardo pinout, the Arduino Pro pinout was just as good.

Electronic components are bought from Mouser and the connectors from 4uConnectors.

The kit

It is intended to be part of a kit named Kit PRisme comprising of the Robopoly Shield, the Power Board and various sensors and accessories to build a mobile platform in order to participate at the different challenges organised by the robotics club through the academic year.

The name

The PRismino name comes from Plateforme Robotique in french and isme was added for PRisme as it was easier to pronounce. Then ino was added with the 3rd generation as it became an Arduino (but the Arduino name is copyrighted) and also because prismino means small prism in italian.

Electrical schematic and PCB

Electrical schematic PCB

Assembly

Robopoly members are supposed to solder all components themselves, except for the very difficult ones such as the micro-controller and USB connector which the Robopoly committee takes care of, as such the PRismino is sold disassembled. This is also the reason why the components are so sparely placed on the PCB and the smallest SMD components are of 0805 package.

The assembly of the PRismino is documented on the Robopoly's website.

Bootloader

Before programming the PRismino has to be loaded with a bootloader that allows its program memory to be rewritten via the USB interface. The bootloader has to be loaded in the memory via an ISP programmer. Another Arduino/PRismino board that already has the bootloader can be programmed to act as an ISP programmer with the Arduino as ISP program.

A custom bootloader based on the Arduino Leonardo bootloader has been made, it has to be loaded via the stand-alone ISP programmer which can be found in the Robopoly workroom.

As the PRismino is 100% compatible with Arduino Leonardo software (as they use the same micro-controller) one can use the same bootloader as there's essentially no difference between the custom and Arduino Leonardo bootloaders.

The project for the stand-alone ISP programmer for the bootloader uploading has also been published.

Installing

The install process is the same as Arduino Leonardo install.

Programming

The programming is done with the Arduino IDE, as PRismino is basically an Arduino it's fully compatible with Arduino libraries. Use the Arduino programming documentation for reference,

Additionally to the Arduino libraries the PRismino has its own library to complement its function set in order to use the Robopoly Shield effectively.

In order to use the PRismino library they have to be downloaded and copied to the respective folders (which varies with the operating system), see the official guide on how to add libraries to Arduino IDE.

Atmel Studio

Programming can also be done with Atmel Studio, the official tool to program AVR micro-controllers (Windows only), to set up the programming environment for Arduino boards on Atmel Studio follow these instructions. It has the main advantage of being capable of simulating the code, compiling without including Arduino libraries and programming in Assembly.

Timer usage

One can override the timer functions, but the original functions won't be usable or work as intended if timer configurations are changed.

Pinout

You may use this diagram for reference, but note that the PRsimino is not an exact copy of Arduino Leonardo and not all elements are present or in the same place on the PRismino board.

Arduino Leonardo pinout diagram

Low-level programming

To manage pins more efficiently, instead of using the Arduino digitalRead() and digitalWrite() functions which add quite some overhead you may toggle the respective registers directly.

For example to toggle the LED pin which is on the pin 13, but physically on the pin 7 of port C (PC7) you can use:

// set pin as output by setting the DDR (Data Direction Register) of the corresponding pin to 1 (output)
DDRC |= (1 << 7);
// set pin value to 1 (logical high) to turn the LED on
PORTC |= (1 << 7);
// set pin value to 0 (logical low) to turn the LED off
PORTC &= ~(1 << 7);

Component list

ComponentReferenceQuantity
PCB1
Micro-controllerATMEGA32U4-AU1
Oscillator (16MHz)1
22pF 0805 capacitor for oscillator2
100nF, 20V min, 0805 capacitor2
10uF, 20V min, 0805 capacitor2
Micro USB B female plug4UCON-200131
22ohm 0805 resistor for USB2
SMD LED 08052
1K 0805 resistor for LED2
Button1
10K 0805 resistor for button1
6 female pins4UCON-005272
8 female pins4UCON-005312
Male USB A to male micro USB B cable1
1uF 0805 UCAP capacitor1
DC Plug1
5V regulatorNCP11171
2x3 male pins (SPI)4UCON-009891

There are two types of footprints for the micro-controller on the PCB, the QFN is small enough to fit inside the TQFP footprint

CAD files

The CAD file is in Google Sketchup format. Generated with eagleUp, a plugin that exports the board from Eagle CAD and imports it to Google Sketchup.

All additional files needed to generate the board are in the Robopoly Eagle CAD library and SketchUp files project.

Version log

2.0 (2014-07-24)

1.0 (2013-07-08)

Licence

The PRismino is published under Creative Commons Attribution Share-Alike license.

Creative Commons License