Git Product home page Git Product logo

avr's Introduction

rubberduck/avr

Docker image for AVR development

This image contains all the dependencies you need for AVR development.

  • Make
  • CppUTest
  • gcc
  • avr-gcc

Build Image

docker build -t rubberduck/avr .

Run Container As Build Tool

This command will run the container and mount the current working directory to the working directory of the container. Mounting the current container means we leave the build artifacts behind on the host machine.

docker run --rm -it -v ${PWD}:/mount rubberduck/avr bash

Once inside the container, just run your makefile like you would if you had the dependencies installed on your local machine.

make check
make 
# etc.

Flashing

The container has avrdude installed and a default conf file located in /root/.avrduderc. By default, it points to the /dev/ttyUSB0 port.

docker run --rm -it --device /dev/ttyUSB0 -v ${PWD}:/mount rubberduck/avr bash

If you need to use a differenc avrdude conf file, you can mount it in like this.

docker run --rm -it --device /dev/someOtherTty -v ${PWD}:/mount -v someOtherAvrdude.conf:/root/.avrduderc rubberduck/avr bash

Mac/Windows

Accessing the host's USB ports can be difficult on non-Linux operating systems. You need to use a virtual machine to host the docker daemon.

See this blog post for instructions on accessing USB ports inside the container on Mac.

CppUTest and Make

This image includes pkg-config. It can be leveraged in your makefile to locate the CppUTest includes and libs.

CPPFLAGS += $(shell pkg-config --cflags cpputest)
CXXFLAGS += -include CppUTest/MemoryLeakDetectorNewMacros.h
CFLAGS += -include CppUTest/MemoryLeakDetectorMallocMacros.h
LD_LIBRARIES = $(shell pkg-config --libs cpputest)

avr's People

Contributors

rubberduck203 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.