Questions tagged [sensor]

For questions dealing with devices that measure the physical world around us and translate it into signals for the Raspberry Pi.

Filter by
Sorted by
Tagged with
45
votes
6answers
23k views

How to measure temperature?

What can I connect to the RPi to measure temperature? I think devices connected to the I²C or SPI would make most sense. Here is a question about DHT-22 and other 1-wire devices. But at this stage it ...
25
votes
5answers
8k views

Is soil moisture sensor corrosion normal?

I have a Raspberry Pi project that has three soil moisture sensors. I take a moisture sample every minute. After about a month I started to get bad readings. On further inspection I noticed that my ...
22
votes
4answers
18k views

How can I control Lego motors?

I'd like to find a way to make my Raspberry Pi control some Lego motors, and as a bonus I'd like to make use of one or more optical sensors. Normally, Lego robotics make use of the Mindstorms "brick" ...
20
votes
3answers
28k views

Do I have to connect a resistor to my DHT22 humidity sensor?

I've just bought a DHT22 sensor to connect to my RPi but most tutorials mention there should be a resistor connected between the sensor and the GPIO pin. Is this necessary? Will it work without or ...
19
votes
7answers
50k views

Multiple temperature sensors with a Raspberry Pi

I have seen plenty of examples for using one temperature sensor with the Raspberry Pi, however, how can I multiplex 5-6 temperature sensors to a Raspberry Pi? I want to read the temperature from ...
16
votes
6answers
41k views

DS18b20 temperature sensor not listed

I would really appreciate some advice on this. Being a TOTAL noob I have closely followed a guide on the internet explaining how to use a DS18b20 sensor with my Raspberry Pi. The guide is http://www....
15
votes
2answers
7k views

Can I use a One Wire File System through the GPIO?

I have installed owfs (under debian) just to realise the initial setup (1wire) works only through the USB port. owfs is short for One Wire File System. It's a standard for low end sensors, but I'm ...
14
votes
5answers
15k views

Can I use a DHT22 as a temperature sensor for my Pi?

Is it possible to use a cheap temperature sensor such as the DHT-22 with the Raspberry Pi? I have found Arduino drivers for this and many similar things, and would be comfortable porting the code to ...
12
votes
2answers
17k views

How to use a DS18B20 temperature sensor in my Pi?

I have a few DS18B20 temperature sensors. These are normally used in Arduino projects, but I don't see why not to use them with a Pi. There is a software called DigiTemp that seems to drive the device ...
11
votes
3answers
9k views

Can I use the 3.3v pin instead of the 5v pin?

I am using a HC-SR04 ultrasonic sensors, and I don't have enough 5V pins on a Raspberry Pi, and I don't want to buy an expander. So is it possible to use the 3.3V pins on some of the sensors? What ...
8
votes
1answer
16k views

How to use the water flow sensor with raspberry?

I'm trying to use this water flow sensor with raspberry: https://www.adafruit.com/products/828 I'm using this python code to read the pulses: #!/usr/bin/env python import RPi.GPIO as GPIO import ...
8
votes
2answers
19k views

i2cdetect doesn't catch ANY address. How can I tell if I2C working correctly?

I'm having difficulties interfacing the Raspberry Pi to basically any I2C sensor. I've gone through a lot of tutorials on how to get the I2C driver to work and my connections are correct. Still, ...
8
votes
2answers
5k views

Why does the Sense Hat / Astro Pi show the wrong temperature and humidity?

I recently bought the sense-hat, previously called astro-pi. Unfortunately the temperature shows 28 to 31 degrees Celsius from both temperature sensors on the board. They often show around 30 degrees ...
7
votes
3answers
13k views

How to read Analog 5V sensor ouput with Digital 3.3V GPIO?

I bought the "Sunfounder Sensor Kit" for Raspberry Pi 2, but the whole content is made for Arduino (5V). I have bought ADC, Level Shifters but I am stuck because I think I certainly miss a simple ...
7
votes
1answer
2k views

How does RPi “know” when it hasn't got enough power

When running X and when it's not content that it can draw enough power from the adapter, my RPi displays an RGB colour square on the screen. (At least, I THINK that's what the RGB colour square ...
6
votes
4answers
29k views

Sensor to detect water/liquid level

I have a swamp cooler that does not turn off automatically when the water level evaporates below the safe level, and if I fail to turn it off even once I could damage it. The sensor simply needs to ...
6
votes
1answer
790 views

Looking for a starter kit for my 10 year old

My daughter would like to get involved with computers. I have heard that a Raspberry Pi is a good place to start. Her mother and I think that she would like to create a motion sensor camera so she ...
6
votes
4answers
5k views

Looking for a pi-compatible thermometer for brewing

I would like to use my Raspberry Pi to monitor my fermentation temperature. I would like a thermometer I can attach to the side of the carboy and wire up to the Raspberry from a few feet away. For ...
6
votes
1answer
10k views

Is there a way to attach multiple serial port devices to a single raspberry pi?

I have three separate devices that all need access to a data serial port on the pi. My devices are an accelerometer, a GPS unit, and a GMS cell service chip. I've found tutorials on how to attach ...
6
votes
4answers
11k views

munin-node plugins : VCHI initialization failed

I'm creating a munin plugin to fetch temp values from my Pi's. When running the script, as root, everything is fine: pi /etc/munin/plugins # ./temp temp.value 47.1 But when running it directly ...
5
votes
2answers
9k views

How to Connect 6 ultrasonic sensors to a raspberry pi?

I need to connect 6 ultrasonic sensors to one raspberry pi and all six sensors should take the distance measurement same time. I have written the code and made the thread also but only two sensors ...
5
votes
5answers
1k views

Sensor Bus for USB

I want to build a plug & play greenhouse system similar to http://www.raspiviv.com/ I thought of a bus system, but I have no experiences with bus systems currently. I stumbled so far over the I2C ...
5
votes
2answers
1k views

ESP 8266 and Raspberry Pi communication without an Internet connection

I am currently working on a project which uses an ESP8266, accelerometer sensor and Raspberry Pi 4. The ESP module has to send the accelerometer data to the Raspberry Pi and the data has to be stored ...
5
votes
2answers
1k views

How to approximate room temperature in a better way

I've just bought an Enviro pHAT. The temperature sensor on my pHAT reads around 31 degrees Celsius for my room This sensor is close to the Pi, so it also gets a heatwave from the CPU Is there a ...
5
votes
2answers
176 views

Sensor Question

I am following this tutorial: http://www.cl.cam.ac.uk/projects/raspberrypi/tutorials/temperature/. The problem is I don't have that specific temperature sensor on me. Since I don't have that specific ...
5
votes
4answers
10k views

How to use JSN-SR04T on a Raspberry Pi?

I want to try out JSN-SR04T, which is an ultrasonic distance measuring module, that is also supposedly water proof. The main reason that i want to try this module over the HC-SR04, is because the JSN-...
5
votes
2answers
8k views

Using 5 volts on an mcp3008

I have a couple different types of hall effect sensors I would like to test out using an MCP3008 ADC to interface with my Pi. The sensors run on 4.5 V minimum. Before I configure the ADC for 5 volts I ...
5
votes
4answers
5k views

Read data from Si7021 via I2C

I have an Si7012 temperature / humidity sensor attached to the i2c pins on my Raspberry Pi. Specifically, I have the Adafruit "break-out" with this sensor attached https://www.adafruit.com/product/...
5
votes
1answer
4k views

Do I need a current limiting resistor in series with a magnetic door sensor?

I'm building an alarm system and I'm using a magnetic door sensor, conected to ground and a pin of the gpio set up with an internal pull-up resistor. As far as I know, this means that the pin will be ...
5
votes
1answer
6k views

nutrient sensors for hydrophonics with raspberry

I am the happy owner of a mancave and I've decided to invest in raspberries, sensors and some small hydroponics vaxer from ikea. I've gotten a camera and some temperature sensors which can log ...
5
votes
1answer
612 views

GPIO Temperature Sensor not Recognized

I recently tried to connect a temperature sensor (http://www.adafruit.com/product/381) to my RasPi via the GPIO, with a 4.7k (2Watt) resistor connecting the power and data (Source: http://www.cl.cam....
5
votes
1answer
7k views

How to Decode TPMS Sensor data through RPi3 Bluetooth

I'm working with a Bluetooth TPMS Sensor (TP630). Here I have some important information about the sensor: Description: ➤ Bluetooth Transmit Power: 0dbm MAX ➤ Processor: 8-bit MCU / S08 core, ARM ...
5
votes
5answers
15k views

How to hook up an AM2302 temperature & humidity sensor several feet away from the Raspberry pi?

I have a raspberry pi running pipgio and am using the provided code under the python section to get the temperature and humidity reading from the AM2302 (http://www.adafruit.com/products/393). If I ...
5
votes
4answers
3k views

HC-SR04 randomly stops taking readings

I have implemented 3 HC-SR04 ultrasonic-distance sensors into my hobby-project, and they are working randomly, meaning they sometimes give me anywhere between 1-12 readings from the sensors and then ...
5
votes
2answers
1k views

A good sensor for a Bed Occupied detector?

I'm trying to build a presence sensor for my bed, to help trigger assorted home automation functions. My first thought was to use a FSR and place it between the frame and boxsprings. I know how to ...
5
votes
1answer
1k views

How can I use the RPi GPIO to make a headphone sensing audio jack?

I am working on a project that involves a raspberry pi acting as an internet radio client which the public can access by plugging their own headphones into a 3.5mm (1/8”) jack. They will have access ...
4
votes
3answers
1k views

Powering a sensor using an external power supply board

In my Raspberry Pi project, I need to measure a distance. To do that, I have an ultrasound sensor called "AJ-SR04M" (it is basically a waterproof HC-SR04 I believe). Characteristics of the AJ-SR04M: ...
4
votes
3answers
942 views

I want to use a common power supply to pi and sensors BME280 and BMA180 (sensor modules). Is it possible?

How can I accommodate between the difference in voltage and current levels with a single power source?
4
votes
2answers
720 views

Building a Raspberry Pi network monitor. My code is not working

Long story short. I moved, put my home server is a closet and started worrying about temp and humidity, saw a guide online to make a network temperature and humidity monitor from a Raspberry Pi and an ...
4
votes
6answers
3k views

Connecting multiple ds18b20 digital temperature sensors to different GPIO ports

There are loads of examples of using the ds18b20 temp probe, or even multiples all to GPIO pin 4, and then running: modprobe w1-gpio modprobe w1-therm cat /sys/bus/w1/devices/28-*/w1_slave The ...
4
votes
2answers
16k views

How to trigger GPIO event using an active infrared sensor

Trying to get an active infrared sensor to trigger an event on a GPIO pin. I'm using python and the RPi.GPIO library on an RPi model B. Some background info, not sure how relevant it is, but I'm a ...
4
votes
2answers
3k views

How to connect a 12V fan sensor wire to the Pi

I have a 3-wire 12v DC fan (Sanyo Denki 9S1212M4011). It's actually getting 15V because my "12V" wall wart isn't accurate. When the fan is not running my multimeter tells me there is 14V on the ...
4
votes
4answers
7k views

Speed detector for amateur sports such as athletics or tennis

I'd like to build a speed detector that can measure speed of a running athlete, or the speed of serve in tennis or any other similar amateur sport. Devices like these are used during Olympics, ...
4
votes
1answer
765 views

Windows IoT on Raspberry Pi: how to eliminate huge variations in reading pins values? (C#)

I have been porting the library for HX711 (Weighting sensor module amplifier) for Arduino to C# for Raspberry Pi Windows 10 Core. Source here on GitHub Arduino library It does work, I am even using ...
4
votes
2answers
231 views

Raspberry Pi sensor error with high CPU

I have a passive infrared sensor attached to a Raspberry Pi. Namely this model which has digital output in addition to the analog one so it can be attached directly to Raspberry Pi. The data pin is ...
4
votes
1answer
10k views

DS18B20 not detected by Raspberry Pi

I'm trying to have a DS18B20 working with my Raspberry Pi Model B Revision 1.0, and it doesn't work. No matter what I try I still see nothing in /sys/bus/w1/devices/ besides: pi@raspberrypi ~ $ ls /...
4
votes
2answers
787 views

433 Mhz transmitter on RPI always sending 00000000

I've bought a Realtek RTL2832 DBV for my RPI to read 433 mhz data and a transmitter HM-T433. I can successfully receive messages from two 433mhz remotes with the rtl_433 utility, but when I try to ...
4
votes
2answers
696 views

Occasionally get “Register read error: 0xee06” when script is run with Adafruit BNO055

I'm running scripts on a Raspberry Pi 3 hooked up to an Adafruit BNO055 sensor, and occasionally when I run the test script I get this error: Traceback (most recent call last): File "...
4
votes
2answers
295 views

Finding /dev Mount Point for Sensor

I am trying to connect to an Airmar 200WX and not having much luck finding the /dev mount point of the sensor. I have the sensor plugged in on boot and dmesg displays the following: [ 1.150836] ...
4
votes
1answer
794 views

Vibration sensor / accelorometer capable of measuring vibrations caused by trains passing by

We live pretty close to the rail tracks, and for a long time I wanted to create a system that is capable of measuring the vibrations of the trains passing by. I tried to do it using the Sudden Motion ...

1
2 3 4 5
11