0

I have succesfully (or so the ide says) burned a bootloader on an ATMega328P-PU chipset, and uploaded my sketch on it.

It appears a voltage regulation is absolutely needed, if I want to solder a pcb with the standalone chip, rather than an arduino. Is that correct? Can I build one out of my starter kits parts (assortment of transistors, diodes, zeners, resistors and capacitors)?

In the meantime, I would like to make sure the chispet is functional. Can I power it from GND/5V of an arduino? Will it take care of that power regulation?

If I can, what is the correspondance between the arduino pins, and the ATMega328P-PU pins? I have this page here : http://www.learningaboutelectronics.com/Articles/Atmega328-pinout.php referencing the chipset pinout. Am I correct in assuming there is a correspondance with the arduino pinout in the reading order of this chart, ie. :

PD0 to PD7 are Rx, Tx, digital pins 2 to 7 on the arduino, PB0 to PB5 are digital pins 8 to 13, and PC0 to PC5 are A0 to A5 on the arduino?

Thanks for reading.

1
1

Voltage regulation is needed if the voltage you are providing to the chip is outside (or can drift outside) the allowed range for the chip to operate.

At the upper limit that is 5.5V. The lower limit is 1.8V. Note that at lower voltages you can only reliably run at lower clock speeds.

If your power source is between those two voltages (say a 3.4V LiPo battery) then you don't need a regulator.

If your power source is above 5.5V (say a 9V PP3 battery [urgh]) then you definitely need a regulator.

A proper regulator is quite a complex device, and it is highly unlikely that you have the components to make one. A simple, very inefficient one, though, can be made using a resistor and a 5V Zener diode if you have one.

enter image description here

Until you have your own regulator of whatever form, yes, you can power the chip from the 5V pin of the Arduino.

The pin mapping for the chip -> Arduino IO numbers is in the file pins_arduino.h for the Uno variant in the IDE. In the top of that file is this handy drawing:

// ATMEL ATMEGA8 & 168 / ARDUINO
//
//                  +-\/-+
//            PC6  1|    |28  PC5 (AI 5)
//      (D 0) PD0  2|    |27  PC4 (AI 4)
//      (D 1) PD1  3|    |26  PC3 (AI 3)
//      (D 2) PD2  4|    |25  PC2 (AI 2)
// PWM+ (D 3) PD3  5|    |24  PC1 (AI 1)
//      (D 4) PD4  6|    |23  PC0 (AI 0)
//            VCC  7|    |22  GND
//            GND  8|    |21  AREF
//            PB6  9|    |20  AVCC
//            PB7 10|    |19  PB5 (D 13)
// PWM+ (D 5) PD5 11|    |18  PB4 (D 12)
// PWM+ (D 6) PD6 12|    |17  PB3 (D 11) PWM
//      (D 7) PD7 13|    |16  PB2 (D 10) PWM
//      (D 8) PB0 14|    |15  PB1 (D 9) PWM
//                  +----+
//
// (PWM+ indicates the additional PWM pins on the ATmega168.)
1
  • Thanks, very nice answer with additional material for me to read! :) – pouzzler Apr 12 '16 at 16:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.