Inline ASM - Advanced AVR 3.0 Core

Channel:
Subscribers:
580
Published on ● Video Link: https://www.youtube.com/watch?v=l1EhEEQewXk



Duration: 2:20
15 views
0


Updated with better details and more high quality examples. As always the little note about inline asm found in AVR-c sucks BBC. It's copy-and-pasted content, incomplete and incompetent; 3.0 tries to be practical, precise and easy with fully tested everything and well commented code. Extended documentation can be found in section 6.47 How to Use Inline Assembly Language in C Code in GNU website. Sadly the price for not being too much dumb is to read a lot, but more sadly even if you have read everything, open-source documentations are repetitive and extremely boring and sometimes filled with the same obvious mistakes.

Inline asm can be very complicated. Just the io mapping is a headache, even though it's just a number. Avr-c has this very dumb nesting within nesting definitions for the io address, so something like PORTB that can be easily accessed in c is not as straightforward with asm. Juno Inline ASM 2.0 is actually pretty good in term of quality of examples but it lacks good comments and detailed explanations and of course it avoids using avr-c io definitions, and so making it less portable and useful and fun. For critical project, avoiding avr-c io definition is still a good idea.

1, beginner level, simple asm statements to access some cpu level instructions, such as sleep, nop and wdr.

2, intermediate level, input and output variables between c and asm.

3, advanced level, explore c, asm, compiler and hardware to create new applications and new possibilities.

It's a long long process to test out every tiny bit of thing, and to rewrite 90% of the content and 100% of the examples, but Juno Inline ASM 3.0 makes it fun and easy again to use inline asm and to develop advanced application for the future.




Other Videos By Flyandance


2023-03-18Bootloader self-program - AVR109 w/ AVROSP and avrdude - Advanced AVR 3.0 Core
2023-03-17SPM 3.0 writes to self - Advanced AVR 3.0 Core Bootloader
2023-03-16SPM 2.0 writes to self - Advanced AVR 3.0 Core Bootloader
2023-03-14You jump, ijmp - Inline asm Indirect Jump - Advanced AVR 3.0 Core Bootloader
2023-03-05yt-dlp - A ultimate guide (The result of 2 weeks of hard work)
2023-03-03True bare Minimal code - Advanced AVR 3.0 Core Bootloader Pro Part 4 Size does matters getting naked
2023-02-28Bootloader-less Pro - Advanced AVR 3.0 Core - Part 3 - SPM - App Writes to App section - programmer
2023-02-27Bootloader-less Pro - Advanced AVR 3.0 Core - Part 2 - SPM erase self destruction code
2023-02-26Inline ASM - Advanced AVR 3.0 Core - LMP read from flash Load Program Memory
2023-02-25Inline ASM - Advanced AVR 3.0 Core - Finalizing
2023-02-22Inline ASM - Advanced AVR 3.0 Core
2023-02-19Bootloader-less Pro - Advanced AVR 3.0 Core - Part 1 - GCC Sections functions attribute
2023-02-17Script cowboy - the power of one line of code
2023-02-15Bootloader Pro - Advanced AVR 3.0 Core - AVR-C 2.0 sucks BBC
2023-02-11Juno ABC - Advanced Button Core 4.0 - Sleep mode ultra low power
2023-02-07My Coffee ritual 2.0 - Simple Minimalistic - Dry milk + sugar
2023-02-03Sleep mode - Advanced AVR 3.0 - Atiny13 watchdog less than 100nA - Peripheral leakage current Button
2023-02-02Definition of good soup - Chicken Turmeric
2023-02-01Sleep mode - Advanced AVR 3.0 - 32kHz Timer2 Asynchronous mode - Atmega8 low power 8-12uA
2023-01-31Sleep mode - Advanced AVR 3.0 - 1 second timer - Atmega8 low power down + watchdog + eeprom MCU
2023-01-30Watchdog - Advanced AVR 3.1 Core - Atmega8 + EEPROM + External RC + Low power timer + MCU underclock