Skip to content
This repository has been archived by the owner on Jun 13, 2019. It is now read-only.

Raspberry Pi 3 #97

Open
micrcx opened this issue Dec 4, 2016 · 11 comments
Open

Raspberry Pi 3 #97

micrcx opened this issue Dec 4, 2016 · 11 comments

Comments

@micrcx
Copy link

micrcx commented Dec 4, 2016

Is it possible to install nodejs iotivity on Raspberry PI 3? What do need to do for this? You can advise something? Maybe there are ready-made solution?

@sanbeam
Copy link

sanbeam commented Dec 5, 2016

I'd imagine it should work out of the box. I havent tried it though.
scons build for resource layer should be invoked with TARGET_ARCH=armv7a maybe.
Other than that the process is straight forward. Assuming Raspbian the following steps should work.

  1. npm install iotivity-node
  2. node node_modules/iotivity-node/js/high-level-server-example.js
  3. node node_modules/iotivity-node/js/high-level-client-example.js

@rzr
Copy link
Contributor

rzr commented Dec 16, 2016

I think it should be possible , later I'll try to cook a Tizen PI3 image if you can test it ?

@rzr
Copy link
Contributor

rzr commented Dec 20, 2016

Those are work in progress, but you rebuild an image with iotivity 1.2.0 and iotivity-node ,
just change MACHINE=raspberrypi3

https://wiki.iotivity.org/automotive#work_in_progress_120

I am building for pi2 at the moment

@mjkoster
Copy link

I am trying to use Ubuntu on Raspberry Pi 3 and getting the -m32 flag set even though verbose output shows that it seems to correctly identifies arm architecture:

Checking for C function strptime()... no
scons: done reading SConscript files.
scons: Building targets ...
Compiling out/linux/x86/release/resource/csdk/logger/src/logger.o
gcc: error: unrecognized command line option '-m32'
scons: *** [out/linux/x86/release/resource/csdk/logger/src/logger.o] Error 1
scons: building terminated because of errors.

I'm installing by using:
npm install iot-rest-api-server
and having it install iotivity-node and build iotivity as dependencies

I'm not sure what to do; it seems like it should "just work"...

@rzr
Copy link
Contributor

rzr commented May 29, 2017

out/linux/x86 is not expected for pi3 it should be out/linux/arm

@gabrielschulhof
Copy link

@mjkoster @micrcx is iotivity-node installation working for you now on Raspberry Pi 3?

@mjkoster
Copy link

It was working in July for the W3C Plugtest, but I haven't tried after the last update to the iotivity 1.3 version. I was just about to test it all again in preparation for more development work, so will get back to you with the results.

@kelsayed
Copy link

kelsayed commented Jul 5, 2018

I am trying to install iotivity-node on RPI-3, got the following error. Any clue:
In file included from ../generated/constants.cc:20:0: /home/pi/iotivity-node/iotivity-node/src/enums.h:26:25: error: could not convert ‘Nan::New(((const char*)("ttl")))’ from ‘Nan::imp::MaybeFactoryBase<v8::String>::return_t {aka v8::MaybeLocal<v8::String>}’ to ‘v8::Local<v8::Value>’ Nan::New((name)), \ ~~~~~~~~^~~~~~~~

And the end of the log:

iotivity.target.mk:126: recipe for target 'Release/obj.target/iotivity/generated/constants.o' failed
make: *** [Release/obj.target/iotivity/generated/constants.o] Error 1
make: Leaving directory '/home/pi/iotivity-node/iotivity-node/build'
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack at emitTwo (events.js:126:13)
gyp ERR! stack at ChildProcess.emit (events.js:214:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Linux 4.14.34-v7+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/pi/iotivity-node/iotivity-node
gyp ERR! node -v v8.11.3
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

@rzr
Copy link
Contributor

rzr commented Jul 5, 2018

@kelsayed , Can you build regular iotivity on it ?

FYI, I was able to build snapshots of master branch for raspbian and can share binaries at:
https://dl.bintray.com/rzr/raspbian-9-armhf/

@kelsayed
Copy link

kelsayed commented Jul 5, 2018

@rzr
Yes, regular iotivity compiles but compiling iotivity from within iotivity-node need to be hacked for some .h files were not visible.

Which of these .deb correspond to iotivity-node binaries?

@rzr
Copy link
Contributor

rzr commented Jul 5, 2018

none this just iotivity, I havent looked at i-node debian packaging to not overlap with NPM one.

If it helps, I remember I was able to build iotivity-node fine on yocto using meta-iot-web it was 1.2 at that time usure about 1.3 or upcoming 1.4

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants