Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options answers only not deleted user 8697

For questions pertaining to compiling C programs on the Raspberry Pi.

0 votes
Accepted

Serial Input for the Pi

I want the equivalent of fgets(), and was going to write this using serialGetchar but the timeout caused problems, requiring post processing. I realised the required functionality was already in the …
Milliways's user avatar
  • 61.4k
1 vote

How to create an GPIO event loop with C (Or Objective-C)?

You may be interested in the following. http://wiringpi.com/reference/priority-interrupts-and-threads/ I have used int wiringPiISR (int pin, int edgeType, void (*function)(void)) ; in some of my cod …
Milliways's user avatar
  • 61.4k
0 votes

Connecting multiple DHT11 sensors using WiringPi and C

The DHT11/22 family have rather critical timing constraints. While there are many libraries purporting to support these, and it is relatively simple on an Arduino, the nature of the Raspberry Pi Linux …
Milliways's user avatar
  • 61.4k
3 votes

Unable receive character properly in UART

It is much easier to use the wiringSerial module from wiringPi, but if you must do it the hard way tab should be a buffer e.g. char tab[128] not a single char. It looks like you are sending random ju …
Milliways's user avatar
  • 61.4k
0 votes

Serial Communication C/C++

As @joan states wiringpi has a wiringSerial library which includes a number of functions (which are easier than using fcntl). E.g. it provides serialOpen etc. Unfortunately no serialGets although I h …
Milliways's user avatar
  • 61.4k
3 votes

Communication Raspberry Pico and 3B+

It is unrealistic to expect a "tenfold" increase. There are many ways of communicating with the Pico (all the usual suspects in fact). You may be interested in Pico as a computer peripheral.
Milliways's user avatar
  • 61.4k
1 vote

High Impedance (Hi-Z) state for Pico GPIO

AFAIK this is not possible (I am assuming Pico GPIO similar to Pi based on limited experience) as there is no command to Tri-state. What other applications do is put in INPUT mode which is high impeda …
Milliways's user avatar
  • 61.4k
1 vote

Controlling Raspberry Pi GPIO with c and Python

I have since written a new dynamic library in C and a Python overlay pi-gpio & pi_gpio which makes this obsolete. …
Milliways's user avatar
  • 61.4k
2 votes

Controlling Raspberry Pi GPIO with c and Python

The pi-gpio dynamic C library to control GPIO is now at Release 1.4 Includes a socket interface to the pi-gpio dynamic C library to control Raspberry Pi GPIO. … Functionality Supported pi-gpio A dynamic C library to control Raspberry Pi GPIO channels A fast dynamic C library to control Raspberry Pi GPIO channels Supports all production models available in September …
Milliways's user avatar
  • 61.4k
1 vote
Accepted

It is possible to set I2C bus speed programmatically without the bcm2835 library?

I have never used i2c-smbus although I have written code in python and c to use I²C using the kernel driver either directly in c or python smbus library. …
Milliways's user avatar
  • 61.4k
13 votes
Accepted

Controlling Raspberry Pi GPIO with c and Python

The pigpio library is written in C and the pigpio daemon offers a socket and pipe interface to the underlying C library. pigpio is probably the most capable library for the Raspberry Pi and offers a number … The C library is not conventionally accessible. Your C program actually becomes the pigpio daemon when you run it, effectively blocking access to other programs. …
Milliways's user avatar
  • 61.4k
0 votes

C and C++ Library and where is it located actually?

All of the functions are in c, but are usable from c++ because of the included #ifdef __cplusplus extern "C" { #endif There is some software by Gert van Loo (supplied with the gertboard) which enables …
Milliways's user avatar
  • 61.4k
1 vote

Pin GPIO5 set to output by default with constant 2.4V output during and after boot

Your code won't run - you don't even have a main() and never call wiringPiSetup. I can't figure out what your circuit is even trying to achieve. You have to make up your mind whether you are asking …
Milliways's user avatar
  • 61.4k
1 vote

Interfaces besides sysfs for GPIO programing in C

AFAIK WiringPi should be included in latest Raspbian. If you have the gpio utility it is there (as gpio is a WiringPi utility).
Milliways's user avatar
  • 61.4k
1 vote

Size of serial port read size in c

You can certainly read multiple bytes using read. The comments about FIFO are misleading, even though they are important to ensure high speed troughput, are inaccessable. The kernel drivers almost c …
Milliways's user avatar
  • 61.4k

15 30 50 per page