Go Down

Topic: Clock cycle per instructions (Read 7067 times) previous topic - next topic


I just want to know how many clock cycle it take the ATmega on the Arduino to do the instructions that make your program.

In the day of 8085, 8086, 6809, 6502  ect....   all instruction - Op-Code that some clock cycle to complete.

Example :   MOV A, B  2 clock
                INC A        4 clock
                MOV B, A   2 clock

Where can I fing this information about ATMega / Ardiuno clock cycle per instruction.  In some program / application, this knowledge will be usefull. Because every instructions take time to complete.


Exactly, look for microprocessors (AtMega328p or AtMega2560 etc) data sheet on Atmel.com
It around 350 - 500 pages docs, that include all information.


Here's a couple of posts about creating a machine language listing of your code - combined with the information Magician provided, you can figure out the cycles for your code:



Many of the avr instructions work in just one clock cycle. Here is a link to the instruction set, and clock cycles per instruction is listed starting on page 11:



Gentlement...Thank you for the info. I have a lot of reading to do and to figure things out.

I have a new question and I will make a new subject.

Go Up