Node-red-node-pi-mcp3008 always return 0

#1

Hello there,

I’ve been trying for several hours to figure out why the MCP3008 always read “0” on node-red.

I’ve confirmed with many site and also using the Adafruit Library ( https://learn.adafruit.com/raspberry-pi-analog-to-digital-converters/mcp3008 ) that my connection are okay. I can get/read value with the Adafruit librairy using the simpleexample.py .

I just started fresh, so let me know what I should try or do

I’m using a RPi Zero W

  1. Installer Raspian
  2. raspi-config, enable “SPI” in “Interface Options” and reboot
  3. Using curl command ( https://nodered.org/docs/hardware/raspberrypi ) to install node-red (I tried with and without RPi specific nodes).
  4. Install “node-red-node-pi-mcp3008” using Pallet Manager
  5. Add an inject node (let at timestamp), add the MCP3008 (lets A0 and CE0), add a debug.

I tried on CE1 and all the others Ax ports… always return Zero.

Any idea ?

0 Likes

#2

I feel SO stupid… I plugged the 3.3V and GND at the other end of the breadboard and forgot it was separated on the middle… damn me… sorry !

0 Likes