lemaker / wiringbp Goto Github PK
View Code? Open in Web Editor NEWThis is a GPIO access library for Banana Pro/Pi. It is based on the original WiringPi for Raspberry Pi.
License: GNU Lesser General Public License v3.0
This is a GPIO access library for Banana Pro/Pi. It is based on the original WiringPi for Raspberry Pi.
License: GNU Lesser General Public License v3.0
Hello,
i try to compile the source wiringpi for banana pi branch in github, the result was incorect status for pull up/down control. Next trial using the banana pro branch in banana pi board, The pull up/down issue has gone, but the pin definition become un sorted as the boad definition di docs.
im just confused when i do gpio readall then there are 2 pins dupliated listed with 2 different gpio and wiringpi numbers
im talking about this lines:
| 8 | 2 | 3 | SDA | IN | High |
| 9 | 3 | 5 | SCL | IN | High |
| 17 | 28 | 3 | GPIO 8 | IN | Low |
| 19 | 30 | 5 | GPIO10 | IN | Low |
how is it possible to have 2 times the same physical pin with different modes?
edit: im using an banana pi
I have an issue with the gpio utility. Everything works fine except the command to enable the pull-down resistor for a pin. If I execute the following command:
gpio mode 7 down
nothing happens, an the pin is still floating. (The pull-up command works fine, btw.)
If I take a look in the correspondig pin-file, after executing the set pull-down command, under
/sys/class/gpio/gpio4/pull
it says "unkown", if I set it manually to "down" everything is working as it should, so I guess there is an issue in the WiringBP lib or is it just me?
This code is riddled with incorrect indentation, along with mixed spaces and tabs. What is WRONG with you??
It's bad enough that the code doesn't work, and that I have to fork it and FIX the damn thing - without having to correct the indentation of EVERY SINGLE DAMN LINE OF CODE.
You suck.
I installed wiringBP but how can I use it in python? (using bananian)
root@bananapipro / # python
Python 2.7.3 (default, Mar 14 2014, 17:55:54)
[GCC 4.6.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import wiringBP
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named wiringBP
>>> import wiringPi
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named wiringPi
>>> import wiringbp2
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named wiringbp2
>>> import wiringpi2
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named wiringpi2
>>>
There is no sudo in bananian:
root@bananapipro ~/tmp/WiringBP (git)-[bananapro] # ./build
wiringPi Build script
=====================
WiringPi Library
./build: 53: ./build: sudo: not found
./build: 59: ./build: make: not found
Make Failed...
Please check the messages and fix any problems. If you're still stuck,
then please email all the output and as many details as you can to
[email protected]
Steps to reproduce:
Initial discussion: http://forum.lemaker.org/forum.php?mod=redirect&goto=findpost&ptid=353&pid=40497&fromuid=17962
To workaround you can take the library from working image - Raspbian 3.1. Compile against that library - and sensor will work:
# gcc -o dht11 mydht11.c -L/home/bananapi -lwiringPi
# LD_PRELOAD=/home/bananapi/libwiringPi.so ./dht11
So Raspbian 3.1 delivers working binary, while library built from sources does not work
At the end of the build there is a "Note" that states to use some sort of option for V2 will be required. I can only assume the first build I did will only support 26 GPIO pins rather than the 40 pins on the GPIO header? I have successfully tested with the current build but only with in the 26 pins.
So is there something that needs to be done differently for V2?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.