Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Nice Porject but getting errors, starting it #1

Steakschen opened this Issue · 9 comments

4 participants


Here my "startup log"

root@raspberrypi /var/www/raspi-tank # node app.js
info - started

console.log('Listening %d in %s mode', app.address().port, app.settings.env);
TypeError: Cannot read property 'port' of null
at Object. (/var/www/raspi-tank/app.js:41:53)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:901:3

Port is defined like you with 3000, 2 rows before.

How do you control the servos ? with a board oder directly with the gpio?


Have you tried using a different port? Maybe 3000 is already in use.

I built a motor driver using L298N circuit. This is the diagram I used:


Got it working now Thanks :)

But must learn js now, because i will control it over the Raspberry pi servo board and must execute serial commands :-/


Hello Mircea Georgescu,

can i fork your great work to make it work with the Servo-Board from

with some Code changes?
Its my first time i do this, so i will ask you if this is ok.


Sorry for the late response. Of course you can fork it and do whatever you want with it. Open source FTW!


What was the problem with the port? How did you fixed it?



I want to try this project but I do not know which pins to use.

Examples like this;

Port.1 > GPIO port x ?

and can i use toy car engines ?


I think the pins to use are: (pin numbers on the Pi, see )

Pin #11 = Right Motor
Pin #15 = Left Motor
Pin #12+16 = Reverse

If you plug the toy car engines into a motor driver (I use the L298N motor driver because it is really cheap on eBay) then there is no reason why they shouldn't work. Bear in mind what voltage they were originally used at, and keep that the same!

Hope this helps! :)


You can read more about pin configuration here:


thanks for answer but i want to ask...

how can i connect for this schema

Port.1 to GPIO.x like this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.