Author Topic: atmega128 customization for 3.3v operation.  (Read 3275 times)

0 Members and 1 Guest are viewing this topic.

pratikshinde

atmega128 customization for 3.3v operation.
« on: March 15, 2013, 03:28:02 AM »
Hello,

I have a ATMega128A board ( details http://www.nex-robotics.com/products/microcontroller-developement-boards/avr-development-boards/atmega128-development-board-mini.html ),

I have burned bootloader on it, and successfully used for my projects, now I want to use a 3.7v li-ion battery to run this board, I have tested that also my board works fine on battery too, However in datasheet and some online sources I read that running 16MHz @ 3.3v is beyond specification and can produce undesired results.

So I found that I have to compile wiring bootloader for 8MHz, I read from few posts and which files should be modified and compiled again,
I have read in this post http://forum.wiring.co/index.php/topic,63.msg241.html#msg241

But I do not know how to compile the boot loader  :(
Please give me some suggestions, or any forum post from which I can follow steps.

Do I need to change fuses on ATMega128?
Do I need to do any changes in my sketches ?

Any help in this regard is highly appreciated.
Thanks

bhagman

Re: atmega128 customization for 3.3v operation.
« Reply #1 on: March 19, 2013, 08:55:24 AM »
This will require some effort.  If possible, you should contact the company that made the board to help you with building the new bootloader to work with the Wiring Framework.

To reprogram that board, you'll need to use the internal RC oscillator (running @ 8MHz) as I think that it has a 14.7456MHz external crystal.

Here are the makefile settings for the .mk file in the booladers/build folder for Wiring.  E.g. ATMega128A.mk

Code: [Select]
## ATmega128A-8MHz
atmel-128a-8MHz: HARDWARE = ATmega128A_8MHz
atmel-128a-8MHz: MCU = atmega128a
atmel-128a-8MHz: BOOTLOADER_ADDRESS = 1F800
atmel-128a-8MHz: F_CPU = 8000000
atmel-128a-8MHz: HW_DEFS_H = defs-wiring-v1-mega.h
atmel-128a-8MHz: EXTRACFLAGS = -DBOOT_USART=0 -DBOOT_BAUD_RATE=-57600
atmel-128a-8MHz: all
   mv $(PROJECT).hex $(PROJECT)_$(HARDWARE).hex

Here are the fuses you will need to program onto the ATmega128A:

Code: [Select]
Low: 0xA4
High: 0xD4
Extended: 0xFF


The fuses will set the '128 to use the internal RC oscillator @ 8MHz.


If you create the ATmega128A.mk file with the above information, and put it into the Wiring bootloaders/build folder, you can run make atmel-128a-8MHz in that folder to create the new bootloader.

You will have to have a version of avr-gcc installed somewhere (I think the board that made the company walked you through how to do that).


Let us know how it goes!

pratikshinde

Re: atmega128 customization for 3.3v operation.
« Reply #2 on: March 19, 2013, 02:48:28 PM »
Hello bhagman,

Quote
To reprogram that board, you'll need to use the internal RC oscillator (running @ 8MHz) as I think that it has a 14.7456MHz external crystal.

I have replaced that 14.74 MHz crystal with 16MHz, and burned Wiring bootloader from Wiring IDE using Arduino Uno with WiringISP sketch.  :)

Quote
The fuses will set the '128 to use the internal RC oscillator @ 8MHz.

I am going to use external 8MHz crystal. so I think fuses will remain same(as Wiring v1).

Quote
If you create the ATmega128A.mk file with the above information, and put it into the Wiring bootloaders/build folder, you can run make atmel-128a-8MHz in that folder to create the new bootloader.
You will have to have a version of avr-gcc installed somewhere

I will try this and let you know  :)


thanks

pratikshinde

Re: atmega128 customization for 3.3v operation.
« Reply #3 on: March 28, 2013, 06:12:21 AM »
Hello,

I have compiled the bootloader  :), (replaced existing 16MHz crystal by 8MHz) and burned it on my board using Arduino Uno by using Wiring as ISP sketch,
I have tested Blink sketch, it is working fine, however if I try to upload any other sketch, I am getting either timeout error or
Code: [Select]
avrdude: verification error, first mismatch at byte 0x0002
         0xb4 != 0x04
avrdude: verification error; content mismatch

please let me know what am I missing?
In this post you have mentioned http://forum.wiring.co/index.php/topic,63.msg241.html#msg241
that to modify defs-wiring-v1-mega.h, could you please elaborate?

Thanks.

Danniell32

Download video and MP3 youtube
« Reply #4 on: October 26, 2017, 04:46:49 AM »
<a href="https://descargar.one/watch?v=-aeizTeC8Fo">Descargar VÍDEO o MP3 Teri Hoor - Navi Jay  Latest Punjabi Songs 2017  VS Records</a><br>VS Records Presents Teri Hoor Official Music Video.Download / Listen Full Audio FromRaunka - https:/</br>
<a href="https://descargar.one/watch?v=vrIv6baf6JE">Descargar VÍDEO o MP3 Capitulo 27 Protagonistas de Nuestra Tele 2017  PDNT 2017  COMPLETO</a><br>Capitulo 27 Protagonistas de Nuestra Tele 2017  PDNT 2017  COMPLETO Grupo de WhatsApp https://chat</br>
<a href="https://descargar.one/watch?v=X48P6MzEdgY">Descargar VÍDEO o MP3 Ildo - Warna Cinta (Official Music Video)</a><br>Ildo - Warna Cinta (Official Music Video) © 2017 VMC Music Entertainment. All Rights Reserved.Fanpag</br>
<a href="https://descargar.one/watch?v=FH7kX0gbSgI">Descargar VÍDEO o MP3 This Restaurant Might be Haunted</a><br>Occurred on October 9, 2017 / Ventura, California, USA"Cronies Sports Grill is a family restaurant w</br>
<a href="https://descargar.one/watch?v=qAW3GKBTMBo">Descargar VÍDEO o MP3 Jean Teri  Raftaar  Jaz Dhami  Deep Kalsi  Zero to Infinity  Official Music Video</a><br>To Stream & Download Full Song - Google Play - http://bit.ly/2xQbwEUJioMusic - http://bit.ly/2wuBb4i</br>
<a href="https://descargar.one/watch?v=vsP91u9D6gU">Descargar VÍDEO o MP3 KOOL.P - EZE NKU (Official Video)  FT PHYNO</a><br></br>
<a href="https://descargar.one/watch?v=8LIGuyAd_X0">Descargar VÍDEO o MP3 Rastacuando  - "Conmigo evita"</a><br>Aprende a diferenciar el trigo de la paja o un ñero de un hombre de bien. Les comparto mi show del 2</br>
<a href="https://descargar.one/watch?v=NkzQNkqucR4">Descargar VÍDEO o MP3 Por Tu Amor - Alzate  Video Oficial</a><br>Por Tu Amor - Alzate  Video OficialDESCARGA GRATUITA: https://app.box.com/s/xev6531vjbqq3fk8qe4e4uf</br>
<a href="https://descargar.one/watch?v=yl00OswylRY">Descargar VÍDEO o MP3 Sat Shri Akaal England (Trailer) Ammy Virk, Monica Gill  Rel 17th Nov  Punjabi Comedy Movie 2017</a><br>Get ready for the full dose of the laughter with new upcoming Punjabi comedy movie "Sat Shri Akaal E</br>
<a href="https://descargar.one/watch?v=-sKgan-EoxM">Descargar VÍDEO o MP3 EL SUEÑO DESPUÉS DE LOS 40 / Quiero dormir como congresita colombiano</a><br>A propósito de los problemas de sueño que vienen con la edad, me propongo lanzar una campaña para no</br>
<a href="https://descargar.one/watch?v=VSFE0Ge9km0">Descargar VÍDEO o MP3 Вынесем козла(ов)? В стране дураков или... ВЫБОРЫ 2018! Гость: Вячеслав Мальцев</a><br>На Украине - новые протесты протесты. На этот раз носит  весьма подходящее название: "Вынести козла"</br>
<a href="https://descargar.one/watch?v=xyIPS-Cn89U">Descargar VÍDEO o MP3 KATALINA YA NO TIENE NOVIO Y REVELA EL PASADO CON ALEX (Esposo Legal)  PROTAGONISTAS 2017 HD</a><br></br>
<a href="https://descargar.one/watch?v=herraTMODls">Descargar VÍDEO o MP3 Así es la vida adentro de una prisión...  ALCATRAZ</a><br>La vida adentro de una cárcel de máxima seguridad es muy diferente...* Música 1: Imaginary Western -</br>
<a href="https://descargar.one/watch?v=caqbfU4hsrk">Descargar VÍDEO o MP3 Juan Manuel Santos nos cumplió todas sus promesas - La Pulla</a><br>El presidente le prometió el cielo al país en el 2010. La Pulla revisó su primer discurso para demos</br>
<a href="https://descargar.one/watch?v=iA2SRKunOJc">Descargar VÍDEO o MP3 Трудно ли быть русской Барби?</a><br>В этом видео Александр Донской познакомит зрителей с "русской барби" Татьяной Тузовой. Татьяна подел</br>
<a href="https://descargar.one/watch?v=-_Q5kO4YXFs">Descargar VÍDEO o MP3 My baby hears me for the first time and is almost moved to tears!</a><br>Follow her journey on Instagram. https://www.instagram.com/theblushingbluebird/ .Charly was born pro</br>
<a href="https://descargar.one/watch?v=hjadEgRtl5E">Descargar VÍDEO o MP3 Alex Ruíz  "Volverás A Mí" Ft. Rayito Colombiano (Video Oficial)</a><br>Video Oficial de Alex Ruiz ft Rayito Colombiano del album llamado "El Rey del Reguebanda". Composito</br>
<a href="https://descargar.one/watch?v=R0WbcOaqIa0">Descargar VÍDEO o MP3 ਤੇਰਾ ਤਾ ਧੂੰਨੀ ਤੋਂ ਵੀ ਤਾਂ ਜਾਂਦਾ</a><br></br>
<a href="https://descargar.one/watch?v=P7FprGBFhPI">Descargar VÍDEO o MP3 Akhiyan De Hanju  Full Video  Anadi Mishra  Palak Arora  Latest Punjabi Song 2017 Speed Records</a><br>Song - Akhiyan De Hanju (Full Song)Singer & Music - Anadi MishraLyrics - Palak AroraFeat Pooja Thaku</br>
<a href="https://descargar.one/watch?v=uqzdktqKlb8">Descargar VÍDEO o MP3 (PDNT 2017) Capítulo 26 Avance Pelea de Gisselle y Sebastian en Protagonistas de nuestra tele 2017</a><br>Giselle pelea con Sebastián, será que le termina? Laura O discute en la casa estudio.PDNT 2017 Capít</br>