Skip to content
wickerdj edited this page May 10, 2019 · 2 revisions

Welcome

This project is to help me with two learning objectives. The first objective is to learn how to write Go programs that can run on the Raspberry Pi. The second objective is to learn about electronics.


Build Command

For Raspberry Pi A, A+, B, B+, Zero

GOARM=6 GOARCH=arm GOOS=linux go build {filename.go}

For Raspberry Pi 2, 3

GOARM=7 GOARCH=arm GOOS=linux go build {filename.go}

Cross compile with a C library.

CC=arm-linux-gnueabi-gcc CGO_ENABLED=1 GOOS=linux GOARCH=arm GOARM=7 go build {filename.go}