...complete newbie to MyRobotLab...

I have the Adafruit16CServoDriver working, now I am looking to try getting Tracking working with Adafruit16CServoDriver but am not getting anywhere.  I have tried everything I can think of, but can't get anything to work.  Is the PCA9685 PWM controller a lost cause for InMoov?

I was hoping for a simpler/cheaper alternative to using the NervoBoard and consuming all the pins on the Arduino...

Mats

7 years 3 months ago

Hi bcarroll

That is the exact reason that I spent time on the Adafruit16CServoDriver. So we have the same goal.

Could you please upload the script that you are testing with and if it doesn't work, please send a no-worky. The goal is that the Adafruit16CServoDriver should work to replace the Arduino in most cases. I use it in my inMoov build. But I write my own scripts to use it. So many of the InMoov services remain to be tested and examples updated with how to use it. 

/Mats

I tried running your Tracking script (only changed the serial port for the arduino).

[python.interpreter.3] [ERROR] python error PyException - null Traceback (most recent call last):

  File "", line 15, in 
AttributeError: 'org.myrobotlab.service.Adafruit16CServoDriver' object has no attribute 'attach'

	at org.python.core.Py.AttributeError(Py.java:205)
	at org.python.core.PyObject.noAttributeError(PyObject.java:1013)
	at org.python.core.PyObject.object___getattribute__(PyObject.java:3816)
	at org.python.core.PyObject$object___getattribute___exposer.__call__(Unknown Source)
	at org.python.core.Deriveds.__findattr_ex__(Deriveds.java:59)
	at org.python.core.PyObjectDerived.__findattr_ex__(PyObjectDerived.java:1036)
	at org.python.core.PyObject.__getattr__(PyObject.java:1006)
	at org.python.pycode._pyx3.f$0(:31)
	at org.python.pycode._pyx3.call_function()
	at org.python.core.PyTableCode.call(PyTableCode.java:167)
	at org.python.core.PyCode.call(PyCode.java:18)
	at org.python.core.Py.runCode(Py.java:1386)
	at org.python.core.Py.exec(Py.java:1430)
	at org.python.util.PythonInterpreter.exec(PythonInterpreter.java:267)
	at org.myrobotlab.service.Python$PIThread.run(Python.java:161)
[python.interpreter.3] [ERROR] ------
Traceback (most recent call last):
  File "", line 15, in 
AttributeError: 'org.myrobotlab.service.Adafruit16CServoDriver' object has no attribute 'attach'

	at org.python.core.Py.AttributeError(Py.java:205)
	at org.python.core.PyObject.noAttributeError(PyObject.java:1013)
	at org.python.core.PyObject.object___getattribute__(PyObject.java:3816)
	at org.python.core.PyObject$object___getattribute___exposer.__call__(Unknown Source)
	at org.python.core.Deriveds.__findattr_ex__(Deriveds.java:59)
	at org.python.core.PyObjectDerived.__findattr_ex__(PyObjectDerived.java:1036)
	at org.python.core.PyObject.__getattr__(PyObject.java:1006)
	at org.python.pycode._pyx3.f$0(:31)
	at org.python.pycode._pyx3.call_function()
	at org.python.core.PyTableCode.call(PyTableCode.java:167)
	at org.python.core.PyCode.call(PyCode.java:18)
	at org.python.core.Py.runCode(Py.java:1386)
	at org.python.core.Py.exec(Py.java:1430)
	at org.python.util.PythonInterpreter.exec(PythonInterpreter.java:267)
	at org.myrobotlab.service.Python$PIThread.run(Python.java:161)

calamity

7 years 3 months ago

In reply to by bcarroll

instead of servodriver.attach() you should use

servodriver.setController(controllerName, i2cBus, I2cAddress) 

for arduino i2cBus is always 1