Skip to content

Instantly share code, notes, and snippets.

@darconeous
Created September 23, 2024 23:45
Show Gist options
  • Save darconeous/1381158681b2527213012825baae2acc to your computer and use it in GitHub Desktop.
Save darconeous/1381158681b2527213012825baae2acc to your computer and use it in GitHub Desktop.
fatal error: avr/iom1608.h: No such file or directory
/opt/homebrew/Cellar/avr-gcc@12/12.2.0_3/avr/include/avr/io.h:577:33: fatal error: avr/iom1608.h: No such file or directory
/opt/homebrew/Cellar/avr-gcc@12/12.2.0_3/avr/include/avr/io.h:577:33: fatal error: avr/iom808.h: No such file or directory

If you ended up here, I think you likely got an error like what is pictured above. For some reason your avr-gcc library doesn't include the header files for the ATTiny1608 or ATTiny808 processors. But the good news is you can just download a few files (like from here) drop them in the right place and then everything will work.

Assuming the same directory as the examples above...

  • Put iom1608.h into /opt/homebrew/Cellar/avr-gcc@12/12.2.0_3/avr/include/avr/
    • If you are getting this file from the official atpack, its in xc8/avr/include/avr/iom1608.h.
  • Put crtatmega1608.o into /opt/homebrew/Cellar/avr-gcc@12/12.2.0_3/avr/lib/avrxmega3/
    • If you are getting this file from the official atpack, its in gcc/dev/atmega1608/avrxmega3/crtatmega1608.o.
  • Put libatmega1608.a into /opt/homebrew/Cellar/avr-gcc@12/12.2.0_3/avr/lib/avrxmega3/
    • If you are getting this file from the official atpack, its in gcc/dev/atmega1608/avrxmega3/libatmega1608.a.

atpack

You can find the atpack here:

http://packs.download.atmel.com/Atmel.ATmega_DFP.2.1.506.atpack

Note that it is just a ZIP file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment