In this tutorial I will explain how to program the Arduino Uno with Atmel Studio 7 without using a programmer / debugger. I also take the time to write a simple blink program that you can upload.

All you need for this tutorial is Atmel Studio 7, an Arduino Uno and the Arduino IDE.

Nguồn:https://dantrithegioi.com/

47 Comments

Heybat

February 13, 2020

You got the whole story wrong boy! There id no point in comapring atmel studio with arduino. I personally used avr studio and code vision for programming avr micros. Now i use arduino almost all the timr for developing a prototype.then if i feel it worht the effort i design a pcb and put an atmel micro on it and it most cases i put an arduino board inside a project. Arduino is designed for prototyping and is excellent on it.

Reply

Osama Afridi

February 13, 2020

Worked 100%, you made my day, thanks alot😊

Reply

hossein fathbag

February 13, 2020

very Thanks

Reply

The Musterion Of Rock

February 13, 2020

Does this method still mean that the millis() function, and therefore interrupts are enabled, even if it's programmed in embedded C in Atmel Studio?

Reply

Tswoshman 001

February 13, 2020

Where did you det AVR dude from ? Why don´t you make links down here ? Another usless video !

Reply

Anas

February 13, 2020

I wanted to ask if it is possible to code arduino in assembly? ( Masm/mips)

Reply

Tptab Putab

February 13, 2020

Super Video … Thanks

Reply

DNA iQ Sound Labs.

February 13, 2020

Thank You! This video is of great help to the lab!

Reply

GoffyLuku sjgs2

February 13, 2020

I have a problem . So when i do build solution and go to tools to run arduino everything goes well even with the code but when I upload it to the Arduino uno it only blinks for a while and after nothing happens .Any suggest?

Reply

andymouse123

February 13, 2020

I think this is something ATMEL should be SHOUTING about as it promotes there IDE but thankfully you have, and very well done …cheers!

Reply

anuj

February 13, 2020

@joop Brokking: thank you so much i was able to do that for my Arduino Uno via Keil uvision 5. I would really appreciate if you can help me same with my STM32F411RE nucleo board and Freedom frdm-kl25z board. Please advise., Also how did you get an information regarding PORTB on arduino that 0B00100000 is high and 0B11011111 is low? also what does DDRB 0B00100000 does?

Reply

Josué Herrera

February 13, 2020

Exactly what I was looking for. Wanted to use my arduino nano, but didn't want to use arduino IDE. Most other tutorial only use the atmega chip in a breadboard; also not what I was looking for. Thank you.

Reply

Amr Sae'ed

February 13, 2020

thank you very much ♥♥♥

Reply

andymouse123

February 13, 2020

great stuff! I just followed your instructions and all went fine cheers!!!…are all studio's functions now available please?…also they don't seem to keen on telling you this do they? maybe they would like you to buy ICE.

Reply

arifbustani

February 13, 2020

Very useful. Thanks.
I have a question. I need to develop an application where an analog channel is acquired continuously and data streamed to a PC via USB. I believe I need a minimum of a dual core microcontroller that can have DMA channel to shift the acquired data to on board memory on continuous basis. Another core running in parallel will deterministically access the data from DMA stream it to USB channel. Is it possible to do that with any off the shelf MC boards available for makers. Thanks in advance.

Reply

DriverSteve

February 13, 2020

Why does the order of functions placed in the code matter in ATmel Studio 7 when it doesn't matter in Arduino IDE? Are they not using the same compiler?

Reply

thierry de groot

February 13, 2020

bedankt man! goede video

Reply

Suyash Rai

February 13, 2020

Great video. Thanks! 🙂 .. for those whose current arguments show error, here's the updated one:

-C"C:Program Files (x86)Arduinohardwaretoolsavr/etc/avrdude.conf" -v -patmega328p -carduino -PCOM3 -b115200 -D -Uflash:w:"$(TargetDir)$(TargetName).hex":i

Change the com port accordingly.

Reply

James Kalenga

February 13, 2020

Great job. Found it useful

Reply

Bob Lewis

February 13, 2020

Biggest problem: no Linux version! Why? Because Atmel decided to use MS studio! DOH! WHEN are generic chip makers going to learn? Open platforms are required to further the use of otherwise OS agnostic chips! STOP restricting the market … PLEASE!

Reply

Axel Haar

February 13, 2020

Hi Joop,
have you tested the external tool with teh latest arduino version 1.8.8? After I updated my arduino version from 1.8.0 to 1.8.8 an update of the external tools are needed.!
No the tool is located at C:Program FilesWindowsAppsArduinoLLC.ArduinoIDE_1.8.19.0_x86__mdqgnx93n4wtthardwaretoolsavr/bin/avrdude.exe
The arguments are -C"C:Program FilesWindowsAppsArduinoLLC.ArduinoIDE_1.8.19.0_x86__mdqgnx93n4wtthardwaretoolsavr/etc/avrdude.conf" -v -patmega328p -carduino -PCOM6 -b115200 -D -Uflash:w:"$(ProjectDir)Debug$(TargetName).hex:"i
However, there is still something not correct, the code is not uploaded, ot even a try. Just nothing in the output window, no signs on the board (TX/RX LEds etc.)
Does it work for you?
regards,
Ulrich.

Reply

Igor T

February 13, 2020

this is not efficient, you must to write more code than in arduino ide to do the same job, instead of simplify things, this is more complicated, the key is simplicity that is why arduino is so popular.

Reply

Rasmus Haun

February 13, 2020

Nice video (:
I have a question:
If you have PORTB = B00000011; // = 3
then what is the difference between PORTB |= (1 << 5); And PORTB |= (3 << 5); ?? (: I think (3 << 5); means move all the bits 5 places to the left? but what about (1 << 5);? I am a bit confused (:

Reply

Miguel Defares

February 13, 2020

Joop when will you do a few Arduino ESP32 tutorials?

Reply

Mister X

February 13, 2020

Hi.
I recently wanted to do the same trick on my own, but decided to first look for a ready solution and immediately found your video. The solution works, thank you.
Permit me a small correction — you suggest the Debug subdir in the command line parameters, but this won't work for Release builds (and this is probably why some readers weren't able to do the trick).
Instead I suggest the following path:
-Uflash:w:"$(TargetDir)$(TargetName).hex":i
It works for both Debug and Release builds — tested.
Thanks again.

Reply

Schichlem rompel

February 13, 2020

i try right now to follow the step but it is not working, on the ouput i am getting: "avrdude.exe: can't open input file DebugGPIO_AVR.hex': No such file or directory" and can read from file 'DebugGPIO_AVR.hex' failed

Reply

Douglas Thomson

February 13, 2020

Nice. Thanks for this.

Reply

MAYANJA GYAVIIRA

February 13, 2020

Thank you sir for that very useful information.
Could you please help us make a video on how to send data atmega328p to IOT by SIM800l module?

Reply

Vera Regensburg

February 13, 2020

Thank you very much! It works nice!

Reply

Kuo Yang

February 13, 2020

what code needs to be like if I connect to the arduino mega in this video? Thank you

Reply

Vasudev Mr

February 13, 2020

why wont this method work on nano ??

Reply

Kuo Yang

February 13, 2020

Hi there, nice video and very useful. I have a question for the atmel ice debugger. Does it need to connect to arduino all the time for programming uploading? or just use usb to connect the arduino? If the debugger is connected to the arduino, is it necessary to connect arduino to pc by usb or not? really confused. Thank you

Reply

DailyWalk365

February 13, 2020

Well, I am almost 51 and you have done me a great service. I have been looking for a couple days on how to set up my Arduino projects in either AmtelStudio or PlatformIO, both of which does not give error free ways of getting it to work with a basic Uno board. This video was indeed the answer with AmtelStudio the winner for me (thanks to you). I am now a subscriber as well. Thank you sir. I wish you great success.

Reply

TheGamerCoder

February 13, 2020

How to get my own Arduino uno(clone) f_CPU?

Reply

Bulbapc

February 13, 2020

Thank you very much sir didn't found a better tutorial 🙂

Reply

Ali Ismail

February 13, 2020

it works dude , that 's cool

Reply

Gabriel Official

February 13, 2020

Does the setup work for ATmega32?

Reply

Ivan Ivanovič

February 13, 2020

Thank you

Reply

Maxim Hort

February 13, 2020

-C"C:Program Files (x86)Arduinohardwaretoolsavr/etc/avrdude.conf" -v -patmega328p -carduino -PCOM6 -b115200 -D -Uflash:w:"$(ProjectDir)Debug$(TargetName).hex":i

Reply

Terry Oliver

February 13, 2020

Thank you very much for taking the time to document this procedure. Very good video.

Reply

Daniel Octavio Abreu Quéliz

February 13, 2020

My Arduino resets when i boot the program on it with Atmel Studio, but the program doesn't works insted my arduino keeps the last program (programed by Arduito IDE) after the reset. Any help? (Sorry for my english)

Reply

aryan singh

February 13, 2020

when i am trying to upload the code to arduino nothing happens. why is that?

Reply

letmein

February 13, 2020

Great explanation! Now, let me try it.

Reply

Joseph Chua

February 13, 2020

Do you need the programmer/debugger to use atmel IDE?

Reply

pe6o991

February 13, 2020

Looking at the GUI(even the name gives it out :D) it's a "rebranded" Visual Studio with Atmel's toolchain. Since I'm very familiar with VS i might switch

Reply

Aakash

February 13, 2020

this method DOES NOT WORK with Arduino ide downloaded from WINDOWS STORE, please make sure that u are using the one downloaded from official Arduino website.

Reply

Subhranil Das

February 13, 2020

thank you man ….

Reply

Leave a Reply