Go Down

Topic: Whats the Bare Minimum Hardware for a Standalone Leonardo? (Read 2 times) previous topic - next topic

drbogger

I've been building home-made PCB Boards for standalone Arduino projects for about a year. I have memorized the bare-minimum schematics for a standalone atmega328 PCB, but I want to move to using the atmega32U4 so I can retire my old FTDI Cable.

Can someone please help me out by providing the bare-minimum schematics for a standalone Arduino Leonardo?

CrossRoads

I would say something like this.
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

drbogger

Awesome! Thanks!

One question though: What is the HWB / BOOT_EN for?

wanderson

New true random number library available at: http://code.google.com/p/avr-hardware-random-number-generation/

Current version 1.0.1

drbogger

Yes, I already read it in the datasheet, it forces the bootloader after reset.
But what I wanna know, in Arduino Terms, what does this do for the Arduino? Is it required? what is it required for?

CrossRoads

This is from the Leonardo Hardware page:
"Automatic (Software) Reset and Bootloader Initiation
Rather than requiring a physical press of the reset button before an upload, the Leonardo is designed in a way that allows it to be reset by software running on a connected computer. The reset is triggered when the Leonardo's virtual (CDC) serial / COM port is opened at 1200 baud and then closed. When this happens, the processor will reset, breaking the USB connection to the computer (meaning that the virtual serial / COM port will disappear). After the processor resets, the bootloader starts, remaining active for about 8 seconds. The bootloader can also be initiated by pressing the reset button on the Leonardo. Note that when the board first powers up, it will jump straight to the user sketch, if present, rather than initiating the bootloader.

Because of the way the Leonardo handles reset it's best to let the Arduino software try to initiate the reset before uploading, especially if you are in the habit of pressing the reset button before uploading on other boards. If the software can't reset the board you can always start the bootloader by pressing the reset button on the board. "

Leonardo schematic shows PE2 with a 10K to GND, part of a resistor pack.
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

coolf

I am drying some similar stuff and I thought to leave the Quarz with 16 Mhz away because the ATmega32u4 has an internal Clock of 8 MHz and i guess it`ll gonna work.

What do you think?

CrossRoads

Will need to change the fuse settings to select internal clock then.
Also, make a new boards.txt set of entries reflecting the slower clock?
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

coolf

could you give me a hint what kind of steps do i have to undertake to set the fuse and change the boards.txt

To set the internal clock:
PLL Controll Register PLLCSR= '0001010'
are there some other register to change?
Where do I have to include these Register in the code?

in the boards.txt
added:
leonardo.build.f_cpu=8000000L

in what do i have to change the low and high_fuses? or where could i find it out?

I guess i have to change the caterina/Caterina-Leonardo.hex file. How do I manage that?

best regards
coolf

CrossRoads

Umm, got me there, I've not attempted these kinds of changes yet.
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Docedison

I don't think I would either... The Internal RC oscillator isn't accurate enough for high speed comms W/O calibration. At one temp and voltage.
--> WA7EMS <--
"The solution of every problem is another problem." -Johann Wolfgang von Goethe
I do answer technical questions PM'd to me with whatever is in my clipboard

coolf

#11
May 31, 2013, 04:56 pm Last Edit: Jun 10, 2013, 05:00 pm by coolf Reason: 1
Docedison you are totally right.

I am going to order a 16 MHz Quartz Oscillator.

I would like to drop the operating Voltage to 3,3 V
I just had a look into the datasheet of Atmega32u4 and if I reduce the operating voltage do i have to change the bodlevel fuses? (i don`t get it well,Brown-out Detection on page 52 in the data sheet?) (EDIT: NO) or anything at the bootloader? (EDIT: NOT JET KNOWN).... the connection for sure. (like the teensy 2.0 http://www.pjrc.com/teensy/schematic.html)

greetings
coolf

Go Up