As it was designed to be an embedded system, there was never need to run it as non-root. Just run it as root.perfo wrote:Now when I run it :-Fair enough it can't see the various I2C board as I haven't got any connected....Code: Select all
root@ROV:~/Moki-ROV# node server.js PCA9685 Not found, disabled! MPU9150 Not found, disabled! MS5803 Not found, disabled! MCP3424 Not found, disabled! ROV Server up and running. Go to http://192.168.2.13:3000
It runs for about 10 seconds then
Do I have to run this as ROOT ie sudo su - or should it run from a normal user ? Not a problem as long as I know...Code: Select all
connected /root/Moki-ROV/server.js:412 imuserver.on('listening', function () { ^ TypeError: Cannot call method 'on' of undefined at Namespace.<anonymous> (/root/Moki-ROV/server.js:412:11) at Namespace.EventEmitter.emit (events.js:95:17) at Namespace.emit (/root/Moki-ROV/node_modules/socket.io/lib/namespace.js:205:10) at /root/Moki-ROV/node_modules/socket.io/lib/namespace.js:172:14 at process._tickCallback (node.js:415:13)
Sorry for so many questions. It does look good even though its only for 10 seconds
Thanks
Ofcourse, if you wish to run it as non-root. You have to change a few things.. ill just add that to the wishlist.
As you don't have a MPU-9150, the software doesn't init the MPU-9150 routine... which breaks the code later on in the program. Ill see if i can add another if-then construct to fix this.