wyc / nxt-python

Automatically exported from code.google.com/p/nxt-python
GNU General Public License v3.0
0 stars 0 forks source link

[Feature Request] HiTechnic motors? #40

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
My robotics group has been using RobotC for a long time, so we got HiTechnic 
motors to make our robot faster. However, I want to use python but can not find 
a way, in nxt-python to use our HiTechnic motors. I found nxt.sensors.hitechnic 
but it isn't a sensor?

If there is a way to get HiTechnic motors to work, can I see an example? Our 
motors are attached to PORT_1 (and only that, that's why I don't get to use it 
from the examples haha)

Original issue reported on code.google.com by CodyDos...@gmail.com on 22 Mar 2012 at 6:28

GoogleCodeExporter commented 9 years ago
https://code.google.com/p/nxt-python/source/browse/trunk/nxt/sensor/hitechnic.py
#519

Something like:

import nxt.sensor.hitechnic
htmot = nxt.sensor.hitechnic.MotorCon(b, nxt.PORT_1)
print dir(htmot)

Should do the trick. The last line will print a list of methods which are 
supported (see also help('nxt.sensor.hitechnic.MotorCon') and the source). Note 
that this class has not been extensively tested and I'm looking for reports 
(good and bad) on how it works. Thanks!

Original comment by marcus@wanners.net on 22 Mar 2012 at 11:40