5

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.ac.uk/projects/raspberrypi/tutorials/temperature/) as shown below:

enter image description here

I followed the instructions on the Cambridge link, but to no avail (I used the alternative temperature sensor listed on the website). When I type:

cd /sys/bus/w1/devices/ ls

It does not show a the temperature sensor, but it merely shows:

w1_bus_master1

Gah! The Pi Cobbler I use is for the Model B, not B+, but the first 26 pins are identical so it works (in case that's relevant).

Thanks for trying to help!

EDIT I also tried connecting a 3V LED to the 3V3 pin (and ground) but it didn't light up!

8
  • 1
    Most likely you have the ribbon cable between the Pi expansion header and the cobbler plugged in back to front. NEVER connect power to a LED without a resistor in series, you will burn out the LED.
    – joan
    Jan 18, 2015 at 22:19
  • @joan thanks for the advice. Do you mean the cobbler part is connected where the Pi is supposed to and vice versa, or do you mean one of them is upside down? I'll try both later.
    – Kachamenus
    Jan 18, 2015 at 22:59
  • also, the image is supposed to be postimg.org/image/xu87umb7d
    – Kachamenus
    Jan 18, 2015 at 22:59
  • 1
    The cable looks OK. I can't make out where the non-3V3 end of the resistor is plugged in. It should be connected to the data line in gpio 4 (pin 7).
    – joan
    Jan 18, 2015 at 23:09
  • 1
    I couldn't get mine to work with Raspbian 1.4.0 and a model B+ until I did this: Add the following line to the end of /boot/config.txt : dtoverlay=w1-gpio,gpiopin=4 Mar 5, 2015 at 4:30

1 Answer 1

4

Maybe the cobbler is not connected well, or the sensor is not getting enough power to work (the cable is too long or the power supply you're using is under-powered). Side note: you ALWAYS want to connect a resistor in series with an LED to avoid it getting damaged

(I don't have enough reputation to write a comment on your question)

2
  • Thanks for the answer, I thought about the connection problems with the cobbler as well. I always tried to hold the cobbler down while I'm testing. I'll try with a shorter cable. Also, I didn't have any resistors under 4.7k (or enough under 3k) for the LED. lol.
    – Kachamenus
    Jan 18, 2015 at 22:53
  • 1
    Or try with jumper cables on a breadboard. You're lucky if the LED still works :) Jan 18, 2015 at 23:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.