rirze / mirobot-py

A Python interface library for WLkata's Mirobot
https://rirze.github.io/mirobot-py/
MIT License
24 stars 9 forks source link

Implement Rover Protocol #12

Open rirze opened 4 years ago

rirze commented 4 years ago

image

JorisvanDamTUD commented 4 years ago

I noticed that W0 (Stop) is missing in the library. Perhaps this is due to the assumption that the Rover move commands are 'discrete'; so a 'W8' would spin all wheels forward by some given angle and then stop.

Unfortunately, Wlkata currently implemented Rover move command as latching switches: a W8 makes all wheels to spin forward. And they will just keep spinning forward, forever, unless the W0 command is issued. So in current rover firmware the W0 command is quite vital :))

As a side note: the current speed of the rover after move commands is very high, and I hope that after we get access to the firmware I can change this. Of just change it to a discrete, repeating angular movement, as you have already implemented

rirze commented 4 years ago

So to be clear, move forward, backward and stop are continuous operations right? Not discrete?

Are all the others like this as well?

JorisvanDamTUD commented 4 years ago

Yes, all move command are continous, and stop will always stop all wheels. Sorry. I gives it a rather course way of controlling movement offcourse. The rover hardware itself is capable of better control, it has encoders on the motorwheels

rirze commented 4 years ago

Thanks for clarifying.

This means I have to redo the wrapper around the rover commands to include some kind of time parameter for how long it should run before stopping. Will upload something soon.