Questions tagged [wiringpi]

WiringPi is a C language library for accessing GPIO pins.

WiringPi is a C language library for accessing GPIO pins. The homepage for WiringPi can be found at: http://wiringpi.com/

Full documentation and instructions for using the library will be found there.

213 questions
6
votes
2 answers

how to read output of gpio readall

I never used wiringpi library before. I'm trying to understand how to read the output of gpio readall. What are the BCM and wPi columns? What does ALT0 mode mean? I searched online for output explanation but couldn't find anything. I found the…
flashburn
  • 173
  • 1
  • 1
  • 6
5
votes
2 answers

wiringpi is missing from bullseye. how do i install it?

I get the following when trying to install wiring pi on a fresh bullseye image. Anyone have any way to get it installed? $ sudo apt-get install wiringpi Reading package lists... Done Building dependency tree... Done Reading state information...…
user1816847
  • 153
  • 1
  • 1
  • 4
3
votes
2 answers

What is the byte order for the WiringPi 16 bit I2C reads and writes?

The WiringPi library has APIs called wiringPiI2CWriteReg16 and wiringPiI2CReadReg16 for writing and reading 16 bits of data from a given I2C device at a specific register. Since the resulting 16 bit value is made up from the read of two 8 bit…
Kolban
  • 1,784
  • 2
  • 16
  • 28
1
vote
3 answers

wiringPi.h: No such file or directory #include < wiringPi.h>

When I try to compile I get this error: fatal error: wiringPi.h: No such file or directory #include < wiringPi.h> ^ The code is: My includes are: #include < wiringPi.h> #include < stdio.h> #define LEDPIN 0 I have double…
dka13
  • 163
  • 2
  • 4
  • 13
1
vote
1 answer

Parallel/simultaneous read

Is there a way to read more than 1 port pin simultaneously (like a parallel port read) using wiringpi? I can see wiringpi functions to do a single pin read (digitalRead()) - but in my application I need to read 2+ pins at once. I guess I can read…
Steve R
  • 19
  • 4
1
vote
0 answers

Controlling PWM by wiringpi through python programming

Can anyone give me the program for controlling PWM by wiringpi through python programming? I have already searched on the net but could only find program through C programming.
0
votes
1 answer

Reading multiple channels from a pcf8591 ADC

I am writing a little "oscilloscope" program in c++ using /dev/fbx. I am reading in analog values via a pcf8591 connected to the I2C bus. Every thing works well if I only read 1 channel of analog data. But if I add in a 2nd channel the data gets…
0
votes
0 answers

Toggling LEDs on/off using the wiringPi library and threads

I'm following the instructions at http://wiringpi.com/reference/priority-interrupts-and-threads/ using the PI_THREAD and piThreadCreate(myThread) methods and cannot get the LED(s) to blink. Here's the code I'm using: /* * c_pins_01.c * * Toggle…
Farad'n
  • 129
  • 1
  • 11
0
votes
0 answers

wiringPiSetup() hangs system

My Pi user is a member of the group "gpio". I have a C++ programm calling "wiringPiSetup()". Whenever I forget to use sudo, my Pi is not reachable anymore and I have to do a power cycle. I know that I can either use wiringPiSetupSys() or remove my…
Christian
  • 259
  • 3
  • 10
0
votes
1 answer

wiringPiSetup: mmap (PADS) failed: Cannot allocate memory

I've been trying to change the TLC5940NT library for Arduino that can be found here https://sites.google.com/site/artcfox/demystifying-the-tlc5940 so that I can use it on Raspberry Pi, but I keep getting the error wiringPiSetup: mmap (PADS)…
Mika
  • 33
  • 1
  • 5
0
votes
0 answers

gcc and g++ compilers don't find wiringPiSetup() and wiringPiI2CSetup() functions

Update/solution: The sample program(s) Gordon refers to are at github/wiringPi - specifically for me lcd-adafruit.c. On my Rpi, the correct libraries are in /usr/lib and are libwiringPi.so and libwiringPiDev.so. from /home/pi/bin this works: gcc -o…
Joe Wharton
  • 13
  • 1
  • 5
-1
votes
2 answers

Compiling a C program latest version of wiringPi

System: RPi 3 B OS: Ubuntu 16.04 Mate desktop. Uninstalled pre-installed v2.32 wiringPi package. Downloaded latest version from the wiringPi site. Ran build. The build worked; gpio readall command worked. Now trying to compile a…
Farad'n
  • 129
  • 1
  • 11