Conversation
|
|
||
| def send(sock): | ||
| global last_gps, last_angle | ||
| sock.send("{} {} {} {} {} {}\n".format(last_gps[0], last_gps[1], last_gps[2], last_angle, -1, -1).encode("utf-8")) |
There was a problem hiding this comment.
I think you missed the accuracy.
see https://github.com/penguinmenac3/robotics-introduction/blob/master/robots/alice.py
if tags[0] == "gps":
# lat, lon, alt, angle_to_north, ?, accuracy, ?
self._update_global_position(float(tags[1]), float(tags[2]), float(tags[4]), float(tags[6]))If the app does not support accuracy, fake it. ;)
Also did you test it with the robotics-introduction implementation?
There was a problem hiding this comment.
I put in -1 to indicate that accuracy is not known. I think that's better than putting in some arbitrary value.
I tested it with robotics-introduction, the values are being received.
There was a problem hiding this comment.
So no accuracy support by that app? :(
There was a problem hiding this comment.
No, I don't think so, every sensor has three values, and for GPS that is lat, lon and alt. But I guess for the introduction it's ok, it gets interesting for SLAM but for that we will have to use the big robot anyway.
No description provided.