Raspberry PI 3 with a hdt11 sensor and blynk

Hi All,

I recently bought my first Raspberry PI 3 and would now like to send temperature and humidity data to Blynk. I’ve been able to hook it up and send data to ‘thingspeak’.

It looks like node js installed ok, though I’m not sure in what directory I should in still it, if I install in in root I get permissions issues so should I install it in my project specific directory.

currentl I’m atempting to install node js but get this…
pi@raspberrypi:/ $ node-gyp configure

gyp info it worked if it ends with ok
gyp info using node-gyp@3.4.0
gyp info using node@0.12.6 | linux | arm
gyp ERR! configure error
gyp ERR! stack Error: EACCES, mkdir ‘/build’
gyp ERR! stack at Error (native)
gyp ERR! System Linux 4.4.26-v7+
gyp ERR! command “node” “/usr/local/bin/node-gyp” “configure”
gyp ERR! cwd /
gyp ERR! node -v v0.12.6
gyp ERR! node-gyp -v

any ideas out there?

It looks like you’re working in the root directory “/”.
This may be very dangerous, you can kill your OS installation.

Go to tour home directory instead:

cd ~

Thanks mate,

I’ll give that a go tomorrow!

Hi, I still get the error even if I’m in the home directory…

pi@raspberrypi:/home $ node-gyp configure
gyp info it worked if it ends with ok
gyp info using node-gyp@3.4.0
gyp info using node@0.12.6 | linux | arm
gyp ERR! configure error
gyp ERR! stack Error: EACCES, mkdir ‘/home/build’
gyp ERR! stack at Error (native)
gyp ERR! System Linux 4.4.26-v7+
gyp ERR! command “node” “/usr/local/bin/node-gyp” “configure”
gyp ERR! cwd /home
gyp ERR! node -v v0.12.6
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

what am I doing wrong…

Try this: https://www.hackster.io/vshymanskyy/blynk-javascript-in-20-minutes-3ee903

I was able to build and install everything, now I’m getting this.

pi@raspberrypi:~ $ sudo NODE_PATH=/home/pi/build/node-dht-sensor node ./blynk-sensor-test.js
module.js:339
throw err;
^

Error: Cannot find module ‘/home/pi/build/node-dht-sensor’
at Function.Module._resolveFilename (module.js:337:15)
at Function.Module._load (module.js:287:25)
at Module.require (module.js:366:17)
at require (module.js:385:17)
at Object. (/home/pi/blynk-sensor-test.js:2:17)
at Module._compile (module.js:435:26)
at Object.Module._extensions…js (module.js:442:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:311:12)
at Function.Module.runMain (module.js:467:10)

but the node-dht-sensor.cpp is in that folder… so why the error