Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wiring pi is not working #19

Open
pavelsr opened this issue Nov 28, 2017 · 6 comments
Open

wiring pi is not working #19

pavelsr opened this issue Nov 28, 2017 · 6 comments

Comments

@pavelsr
Copy link
Member

pavelsr commented Nov 28, 2017

Unable to determine hardware version. I see: Hardware	: BCM2835
,
 - expecting BCM2708 or BCM2709. Please report this to [email protected]
@pavelsr
Copy link
Member Author

pavelsr commented Nov 28, 2017

Possible solution: use arm32v6/alpine:3.6 in dockerfile

@pavelsr
Copy link
Member Author

pavelsr commented Nov 28, 2017

Steps to reproduce the problem:

docker run pavelsr/fabkey:armhf gpio readall

@pavelsr
Copy link
Member Author

pavelsr commented Nov 28, 2017

Check with raspbian:

arm32v7/debian:stretch
resin/rpi-raspbian

@pavelsr
Copy link
Member Author

pavelsr commented Nov 29, 2017

Dockerfile1:

FROM arm32v7/debian:stretch
RUN apt-get update && \
    apt-get install wiringpi

Dockerfile2

FROM resin/rpi-raspbian
RUN apt-get update && \
    apt-get install wiringpi
docker build -t paveslr/fabkey-strecth -f Dockerfile1 .
docker run -it paveslr/fabkey-strecth gpio readall

@pavelsr
Copy link
Member Author

pavelsr commented Nov 29, 2017

Result:

arm32v7/debian:stretch : E: Unable to locate package wiringpi

resin/rpi-raspbian:
wiringPiSetup: Unable to open /dev/mem or /dev/gpiomem: No such file or directory. Try running with sudo?

Working:

docker run -it --privileged paveslr/fabkey-resin gpio readall

Ok but

E: Unable to locate package perl-dev
E: Unable to locate package openssl-dev

So let's try with following Dockerfile:

libperl-dev
libssl-dev

@pavelsr
Copy link
Member Author

pavelsr commented Nov 29, 2017

Wiring pi (gpio) script without sudo:

#!/bin/bash
PIN=22
gpio export $PIN out
gpio -g write $PIN 1
sleep 3
gpio -g write $PIN 0
printf 1;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant