0

My code looks quite similar to this:

board.on('ready', () => {
   const motor = new five.Motor('GPIO17');
   motor.start(255);
}

The problem is that when I run the code, its gets error: Unknown pin "undefined". When I hook my motor up to GPIO18 it works fine but I doesn't want to let GPIO 17 work. I am aware of the different GPIO numbering such was Physical and wiringPi and BCM however any numbering of GPIO 17 gets this error. Help please

3
  • So for WiringPi GPIO numbering pin 1 works fine but when I use 0 i get error unknown in undefined
    – sirshakir
    Nov 26, 2018 at 22:53
  • Ive been testing out all the pins. It appears to be just Wiring Pi pin 0 that is getting the error. Wiring Pi pins: 1,23,24,25 and other pins work. Pin 2 says does not support mode pwm...ok makes since but whats wrong with pin 0?
    – sirshakir
    Nov 26, 2018 at 23:05
  • Im guessing its a JohnnyFive error. I installed onoff npm package and GPIO 17 works just fine
    – sirshakir
    Nov 27, 2018 at 16:10

1 Answer 1

0

Johnny Five does not support use of GPIO17 for motor usage.

1
  • Please accept your own answer with a click on the tick on its left side. Only this will finish the question and it will not pop up again year for year.
    – Ingo
    Jan 24, 2020 at 19:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.