Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"invalid token" errors when using steering with Bluetooth #65

Open
rodja opened this issue Aug 26, 2024 · 6 comments
Open

"invalid token" errors when using steering with Bluetooth #65

rodja opened this issue Aug 26, 2024 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@rodja
Copy link
Member

rodja commented Aug 26, 2024

It seems that zauberzeug/field_friend#147 is caused by some kind of issue in Lizard. When I send steering commands I can see that the App successfully sends a wheels.speed(0.0000,0.0000) command, but the wheels keep on spinning:

Screen.Recording.2024-08-26.at.08.33.59-small.mp4

I noticed that there are numerous error messages invalid token at range 0 1 "w"@74 appearing in the serial log while steering. They do not show if the robot is idle and the app does not send anything.

@rodja rodja added the bug Something isn't working label Aug 26, 2024
@Johannes-Thiel
Copy link
Collaborator

it could be that the robot stops because of this line in the startup of the robot.
when core.last_message_age > 1000 then wheels.speed(0, 0); end
This will stop the robot, if the core does not get a command in 1000 milli seconds.

@JensOgorek
Copy link
Contributor

To me, it looks like the message is not received correctly, instead of "wheels.speed(0.000, 0.000)" it just reads the "w" as a full message.

@rodja
Copy link
Member Author

rodja commented Sep 11, 2024

Yes @JensOgorek. But why? The full text is send via mobile to Bluetooth. Is the error in the lizards bluetooth code? Or in the parsing?

@JensOgorek
Copy link
Contributor

JensOgorek commented Sep 11, 2024

I would say it's most likely with the Bluetooth itself. I will try to check out what exactly is going on with the communication.

Edit: Checked out how this works together with rosys.

@JensOgorek
Copy link
Contributor

Ok, I checked if there was an error within the Bluetooth connection or something, but that is not the issue. It works without any errors in my (limited -> No Can/Odrives here) testing. I also did add an extra output in the Bluetooth module to see if the received messages are broken or something, but this worked flawless.

The error itself will be created with a faulty input to owl_tree_create_from_string so basically inside the owl tree.

@JensOgorek
Copy link
Contributor

We could not reproduce this with ESP32 or a Robot Brain. Maybe @rodja check if you can break it again with idf 5.3.1 update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants