MENU

Fun & Interesting

Bare-Metal MCU #6: Compilers, Assemblers, and Friends

Mitch Davis 25,540 lượt xem 4 years ago
Video Not Working? Fix It Now

This is the sixth video in a journey from Arduino to STM8. The goal is to begin with Arduino, which is a popular platform to serve as a starting point. I'll then break it down into a fundamental level, and then apply those fundamentals to other microcontrollers, such as the STM8.

This video focuses on what a compiler does to translate C code to machine code, and also touches on some other tools that are necessary to compile and upload a program to ATMEGA328 without arduino IDE!
-------------------------------------------
Install AVR-GCC for Mac: brew tap osx-cross/avr
brew install avr-gcc

Install AVR-GCC for Linux (Debian): apt-get install gcc-avr

Download AVR-GCC (WINAVR) for Windows: sourceforge.net/projects/winavr/files/WinAVR/
--------------------------------------------

AVR Instruction Set Datasheet: http://ww1.microchip.com/downloads/en/devicedoc/atmel-0856-avr-instruction-set-manual.pdf

ATMEGA328P Datasheet: http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-7810-Automotive-Microcontrollers-ATmega328P_Datasheet.pdf

ATMEGA328 Datasheet:
http://ww1.microchip.com/downloads/en/DeviceDoc/ATmega48A-PA-88A-PA-168A-PA-328-P-DS-DS40002061A.pdf

Comment