-
I'm trying to run a program on the Move hub to do hub-to-hub communication which is listed in the guide as supported: https://pybricks.com/learn/getting-started/what-do-you-need/#choosing-a-lego-hub But, if I import the class I get an immediate import error. from pybricks.hubs import MoveHub
from pybricks.pupdevices import Motor, ColorDistanceSensor
from pybricks.parameters import Button, Color, Direction, Port, Side, Stop
from pybricks.robotics import DriveBase
from pybricks.tools import wait, StopWatch
print('Start')
hub = MoveHub()
hub.light.on(Color.YELLOW)
wait(3000)
from pybricks.iodevices import LWP3Device
hub.light.on(Color.GREEN)
wait(3000)
print('Done') Outputs:
The program fails at the same spot (stops running after yellow light) if I disconnect it from the computer and run it by pushing the button on the hub. What am I doing wrong? Thanks in advance. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
The The hub to hub communication mentioned in the docs is https://docs.pybricks.com/en/stable/hubs/movehub.html#bluetooth-examples, which is different from |
Beta Was this translation helpful? Give feedback.
The
pybricks.iodevices
is not enabled on the BOOST Move hub due to limited flash memory on that hub.The hub to hub communication mentioned in the docs is https://docs.pybricks.com/en/stable/hubs/movehub.html#bluetooth-examples, which is different from
LWP3Device
.