Avrutils: Instructions for AVR Assembly Functions

Nerd Ralph drafted some simple instructions for programming lightweight AVR assembly functions.


Although I’ve been programming in AVR assembler for a few years now, it has taken me a while to learn inline asm. I still prefer writing in plain asm, but inline asm is the only way I’ve found to call assembler functions from C without having to follow the standard calling convention. The sample code at the start of this post defines a function named eelog that takes a single parameter passed in r26 (the low byte of the X register).

Read more.

Source code can be found on GitHub.

Join 4,000+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

Learn “How Computers Work” with Bill Gates, Ladyada and more – From Code.org !

CircuitPython in 2018 – Python on Microcontrollers is here!

Have an amazing project to share? Join the SHOW-AND-TELL every Wednesday night at 7:30pm ET on Google+ Hangouts.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Follow Adafruit on Instagram for top secret new products, behinds the scenes and more https://www.instagram.com/adafruit/

Maker Business — Prototyping PCBs with Particle, a guide from a pro in the field #makerbusiness

Wearables — Learn about stretch

Electronics — Even lower power!

Biohacking — Nectome’s Brain Preservation and Backup Service Plan

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !

No Comments

No comments yet.

Sorry, the comment form is closed at this time.