3.3V AVR Arduinos for SPI Displays

Most SPI displays are 3.3V. Level converters or voltage dividers or at least series resistors are required.

My hand-made shield with level converters is rather clumsy, so I looked for 3.3V AVR Arduinos.

I have ordered several candidates, they have not yet arrived, so no experience yet, but I'd like to share some links:

Seeeduino-V4.2

ProMini ATmega328P 3.3V

ProMini ATmega328P 3.3V

CP2102 Module + Pro Mini Module Atmega328 3.3V

Micro USB ATmega32U4 Pro Micro 3.3V

Additions are welcome!

My clumsy shield, I use it for tests with e-paper displays:

I have two older Seeeduinos v328 and v3.0. I can highly recommend them. They work absolutely fine at 3.3V and 16MHz. In fact I seldom select 5V GPIO.

The extra headers were unique when I bought mine. Many 5V Uno clones have extra headers now.
But the 3.3V operation is the best feature.

I always use shields. This means I can swap between Seeeduino, Zero, Nucleo, ...
I prefer to solder electronics onto Protoshields or pcb. Breadboards are untidy.

Yes, I could solder level-shifters onto a Protoshield but life is easier at 3.3V in the first place.

Oh, and I have put LogicGreen modules onto a Protoshield with female headers. So I can swap shields onto the LGT8F328P (which I run at 3.3V).

David.

I once decided to create connector shields for all of my displays (for tests with u8glib and u8g2). Guess what is always included on such a shield... yes, a 74HC4050 for level shifting. So each display can be tested with any Arduino Standard board.

To complete the list of 3.3V boards, The feather 32u4 is also a 3.3V board (Adafruit Feather 32u4 Basic Proto : ID 2771 : $19.95 : Adafruit Industries, Unique & fun DIY electronics and kits).

Oliver

I got my 3.3V AVR Arduinos. But I run into problems.

The Pro Micro is fine, download works. Not yet tried with my displays.

The Seeeduino V4.2 does not work in my environment, because of a driver issue:
Seeeduino V4.2 Windows USB Driver?

Download to the ProMini does not work:

Arduino: 1.8.3 (Windows 10), Board: "Arduino Mini, ATmega328P"

Sketch uses 22682 bytes (79%) of program storage space. Maximum is 28672 bytes.
Global variables use 1469 bytes (71%) of dynamic memory, leaving 579 bytes for local variables. Maximum is 2048 bytes.
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x43
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x43
Problem uploading to board.  See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

I tried with 2 different USB to Serial devices CP2102 and 2104.

Any suggestions to solve my issues?

Remember that most 3.3V boards will be 8MHz and the bootloader will run at 57600 baud.

My v328 and v3.0 Seeeduinos both have FTDI bridge chips and came with Duemilanove bootloaders.
After all, these boards were made before the Uno was released.
I simply installed the Uno bootloader. It is smaller and runs at 115200 baud.

You either add a specific Seeeduino entry to your boards.txt or choose the "most similar" official board.

David.

david_prentice:
Remember that most 3.3V boards will be 8MHz and the bootloader will run at 57600 baud.

I guessed that could be the reason for the issue. But how to fix it? Do I need to edit boards.txt or load another package for 3.3V ?

Found it, found entry "Arduino Pro or Pro mini", with selectable voltage and speed.

It seems my Seeeduino V4.2 came with ATmega16u2 not programmed for Arduino. Maybe need Flip to program it. I loaded the package for Seeed-Studio, so I have the board selectable. But so far no COM port for it.

The 16u2 should appear as a COM port in Device Manager.

If not, you would program it

david_prentice:
The 16u2 should appear as a COM port in Device Manager.

If not, you would program it

I had to program it. It is now a COM port Arduino/Genuino UNO. But this does not work with Seeeduino V4.2.
There should be some optiboot.hex in the Seeeduino package, but this is missing.

The story goes on. The Seeeduino V4.2 was at a reduced price (half price), but still no bargain. Not recommended in my opinion.

Now that it has a working COM port, just call it Uno. Select Uno in the IDE. Burn bootloader with an external programmer.

All Uno sketches should build out of the box. You have a 16MHz crystal.
Just flip the switch for 3.3V or 5V operation.

Yes, I know that the mega328P is out of spec for 16MHz and 3.3V. I can assure you that it works fine.

I saw that the v4.2 was a bargain. ...... until you added the delivery cost.
Since it is offered cheap, perhaps there is a hardware problem. If it is just bootloader omission, Seeed could have programmed it before sale. They are a proper company. Not like the usual Lingerie websites that sell electronics on the side.

David.

david_prentice:
Now that it has a working COM port, just call it Uno. Select Uno in the IDE. Burn bootloader with an external programmer.

Its easier to ask here than go searching: how do I burn bootloader. With my USB to serial converters (CP2102,2104) ?

You attach an external programmer to the 3x2 ICSP header (i.e. the SPI header)

I presume that you have an ATMEL-ICE or an USBASP.
You can always use another Arduino running the ArduinoISP sketch.

Select the 'Programmer' type in IDE.
Select 'Burn Bootloader' in IDE

Remove external programmer. Dig deep hole. Bury programmer.
Your 'Uno' is fully functional.

As a general rule, you never need to attach an external programmer to an Arduino.
The Bootloader(s) are already programmed before you open the box.

David.

Today is set for hard learning; not one of my best days.

I have no programmer for AVR, except other Arduinos; I try with UNO clone.

I found ArduinoISP, compiled, downloaded and run it.

I connected the ICSP connections, swapped MISO/MOSI on the second try (I really should know that), with pin 10 of source UNO to reset to the target.

I selected "Arduino as ISP" as programmer, and hit "Burn Bootloader".

I got:

Arduino: 1.8.3 (Windows 10), Board: "Arduino/Genuino Uno"

avrdude: Expected signature for ATmega328P is 1E 95 0F
         Double check chip, or use -F to override this check.
Error while burning bootloader.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Seems I need to look for tutorial; I had seen somewhere already; Google knows.

Go on. There are plenty of ArduinoISP tutorials.

And one of the most obvious steps would be to connect MOSI to MOSI
The ArduinoISP is Master. The target AVR is Slave.

I am gobsmacked by someone with experience would announce that they connect MOSI to MISO

There are only six wires involved. It should not be difficult.

David.

You're right. This happens on such days. MOSI to MOSI, MISO to MISO, of course, as one is master, the other slave.

I took an other Arduino UNO clone as master, with yellow PCB, one that worked fine so far:

And now: "Done burning bootloader."

Thank you, you saved my day.

Jean-Marc

But even with the burned bootloader, download does not work.

(And I tried with bootloader for UNO and for Seeeduino V4 (change Board before Burn)

Arduino: 1.8.3 (Windows 10), Board: "Seeeduino V4(Atmega328P)"

Sketch uses 24050 bytes (74%) of program storage space. Maximum is 32256 bytes.
Global variables use 1684 bytes (82%) of dynamic memory, leaving 364 bytes for local variables. Maximum is 2048 bytes.
Low memory available, stability problems may occur.
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x46
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x46
Problem uploading to board.  See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Maybe I would need replace boot code in ATmega16u2, but don't know how, and don't know which hex file to take.

New question: is there similar method to use one Arduino to download a full program to a second Arduino?

I have seen commands for avrdude somewhere, go searching once more.

I strongly recommend that you use a Uno bootloader and select Uno board in the IDE.

I have no idea what your boards.txt entry for Seeeduino 4.2 says.
You could always copy-paste it to your message.

But most importantly, it will specify baud rate and the bootloader that it expects.

You have just created a Uno "clone". So call the board "Uno"

The whole world knows a Uno. And what to expect.

David.

I thought I made it clear that I tried both, UNO with UNO bootloader, and Seeeduino with its bootloader.

Both produce the same errors on download. Seeeduino was just the last test I made.

I throw these Seeeduinos in a corner of some drawer; no need to waste more time, as I have working 3.3V Mini and Micro clones. There may come I time with spare time for this "challenge".

Go on. It would take 30 sec to paste the Seeduino entry from the boards.txt file.

david_prentice:
Go on. It would take 30 sec to paste the Seeduino entry from the boards.txt file.

##############################################################

atmega328.name=Seeeduino V3.0(Atmega328P)

atmega328.bootloader.tool=avrdude
atmega328.bootloader.unlock_bits=0x3f
atmega328.bootloader.lock_bits=0x0f
atmega328.build.core=arduino
atmega328.build.board=AVR_DUEMILANOVE
atmega328.upload.tool=avrdude
atmega328.upload.maximum_size=30720
atmega328.upload.maximum_data_size=2048
atmega328.build.mcu=atmega328p
atmega328.build.variant=standard
#atmega328.build.core=arduino

atmega328.bootloader.low_fuses=0xff
atmega328.bootloader.high_fuses=0xda
atmega328.bootloader.extended_fuses=0x05
atmega328.build.f_cpu=16000000L

atmega328.upload.protocol=arduino
atmega328.upload.speed=57600
atmega328.bootloader.file=atmega/ATmegaBOOT_168_atmega328.hex

##############################################################

mega2560.name=Seeeduino Mega 2560

mega2560.upload.tool=avrdude
mega2560.upload.maximum_data_size=8192

mega2560.bootloader.tool=avrdude
mega2560.bootloader.low_fuses=0xff
mega2560.bootloader.unlock_bits=0x3f
mega2560.bootloader.lock_bits=0x0f

mega2560.build.f_cpu=16000000L
mega2560.build.core=arduino
#mega2560.build.variant=mega
mega2560.build.variant=mega

mega2560.build.board=AVR_MEGA2560

mega2560.upload.protocol=wiring
mega2560.upload.maximum_size=253952
mega2560.upload.speed=115200

mega2560.bootloader.high_fuses=0xd8
mega2560.bootloader.extended_fuses=0xfd
mega2560.bootloader.file=stk500v2/stk500boot_v2_mega2560.hex

mega2560.build.mcu=atmega2560

##############################################################

V4.name=Seeeduino V4(Atmega328P)

V4.upload.tool=avrdude
V4.upload.protocol=arduino
V4.upload.maximum_size=32256
V4.upload.maximum_data_size=2048
V4.upload.speed=115200

V4.bootloader.tool=avrdude
V4.bootloader.low_fuses=0xff
V4.bootloader.high_fuses=0xde
V4.bootloader.extended_fuses=0x05
V4.bootloader.unlock_bits=0x3f
V4.bootloader.lock_bits=0x0f
V4.bootloader.file=optiboot/optiboot_atmega328.hex

V4.build.mcu=atmega328p
V4.build.f_cpu=16000000L
V4.build.board=AVR_UNO
V4.build.core=arduino
V4.build.variant=standard

##############################################################

Lotus.name=Seeeduino Lotus

Lotus.upload.tool=avrdude
Lotus.upload.protocol=arduino
Lotus.upload.maximum_size=32256
Lotus.upload.maximum_data_size=2048
Lotus.upload.speed=115200

Lotus.bootloader.tool=avrdude
Lotus.bootloader.low_fuses=0xff
Lotus.bootloader.high_fuses=0xde
Lotus.bootloader.extended_fuses=0x05
Lotus.bootloader.unlock_bits=0x3f
Lotus.bootloader.lock_bits=0x0f
Lotus.bootloader.file=optiboot/optiboot_atmega328.hex

Lotus.build.mcu=atmega328p
Lotus.build.f_cpu=16000000L
Lotus.build.board=AVR_UNO
Lotus.build.core=arduino
Lotus.build.variant=standard

##############################################################

Lite.name=Seeeduino Lite

Lite.upload.tool=avrdude
Lite.upload.protocol=avr109
Lite.upload.maximum_size=28672
Lite.upload.maximum_data_size=2560
Lite.upload.speed=57600
Lite.upload.disable_flushing=true
Lite.upload.use_1200bps_touch=true
Lite.upload.wait_for_upload_port=true

Lite.bootloader.tool=avrdude
Lite.bootloader.low_fuses=0xff
Lite.bootloader.high_fuses=0xd8
Lite.bootloader.extended_fuses=0xcb
Lite.bootloader.file=caterina/Caterina-Leonardo.hex
Lite.bootloader.unlock_bits=0x3F
Lite.bootloader.lock_bits=0x2F

Lite.build.mcu=atmega32u4
Lite.build.f_cpu=16000000L
Lite.build.vid=0x2341
Lite.build.pid=0x8036
Lite.build.usb_product="Arduino Leonardo"
Lite.build.board=AVR_LEONARDO
Lite.build.core=arduino
Lite.build.variant=leonardo
Lite.build.extra_flags={build.usb_flags}

##############################################################

@Jean-Marc,

Sorry, I missed your reply.

The V4 entry looks absolutely normal to me. i.e. it is exactly like the standard Uno entry.

Since you have installed 16u2 firmware on the 16u2 chip and Uno bootloader on the 328p chip, it should look like a Uno.

If you copy the Uno vid, pid entries, the COM port should be flagged as a Uno too.

Personally, I would just select Uno in the IDE.
But selecting V4 should work exactly the same. (except that the COM port might not be named)

If in doubt, I would just use avrdude from the command line. It should be easy to spot where anything goes wrong.

The most important lesson with bootloaders is: Use the Arduino IDE to Burn Bootloader
It looks after the fuses and lock bits.

David.

David

Thank you for the response.

I put this issue aside, but can't stop thinking about it.
Fact is, I have no idea about how bootloaders work.
There seems to be a bootloader in the device, that comes with the chip and is active until a new bootloader is programmed into the device.
I assume, the original bootloader is still there, and can be re-activated.

I have checked the loopback test on the Seeeduino V4.2, echo is ok.
I have programmed the bootloader several times, without error message.
But program download does not work.

One interesting symptom is the three short blinks of the LED on reset.
Could it be that the orignal bootloader is still active, and the programmed bootloader just doesn't get started?

I read about attaching a capacitor on the reset line for programming, would this help?
What happens if the some fuse value is wrong; there is a difference between UNO and Seeeduino.

Maybe the device bootloader just does not accept the programmed bootloader as valid.

Jean-Marc