2012-03-28 3 views
2

pyusb를 사용하여 nxt py 라이브러리 용 예제 스크립트 중 하나를 실행하려고합니다. 나는 다음과 같은 오류 얻을 예를 실행하려고 할 때마다 :nxt-py 백엔드 오류 없음

USB module unavailable, not searching there 
Bluetooth module unavailable, not searching there 
Traceback (most recent call last): 
File "C:\Documents and Settings\*\Desktop\nxt-python-2.2.1\examples\mary.py", line 
15, in <module> 
b = nxt.locator.find_one_brick() 
File "C:\Python27\lib\site-packages\nxt\locator.py", line 112, in find_one_brick 
for s in find_bricks(host, name, silent, method): 
File "C:\Python27\lib\site-packages\nxt\locator.py", line 80, in find_bricks 
raise NoBackendError("No selected backends are available! Did you install the comm 
modules?") 
NoBackendError: No selected backends are available! Did you install the comm modules? 

을 내가 어떻게이 문제를 해결하는 방법 몰라 그냥 블루투스로 전환 이외의 다른 방법이 있다면 궁금 해서요?

답변

1

USB 및 Bluetooth를 사용할 수 없습니다. 예제를 실행하려면 파이썬 모듈을 설치해야합니다. 설치 안내서는 choose your operating system입니다.

나 (mac os x)는 fantomusb에서만 작동합니다. 또한 나는 벽돌 로케이터에 대한 속성을 정교화하여 찾아 냈다.

b = nxt.locator.find_one_brick(name="NXT", strict=True, method=nxt.locator.Method(bluetooth=False, fantomusb=True, fantombt=False, usb=False))