drive-sdk icon indicating copy to clipboard operation
drive-sdk copied to clipboard

Car Goes Crazy

Open rollinsjw opened this issue 7 years ago • 3 comments

Hello!

I am currently working on a self driving car project with the drive-sdk!

Unfortunately, if the car leaves the track at all, it tends to go crazy (it seems to be searching for the track), would it be possible to change this/would could it be possible to get a hint as to where in the code this would be located?

I appreciate the help!

rollinsjw avatar Oct 11 '17 02:10 rollinsjw

Also, there was a stack overflow (according to valgrind) occurring in vehicle_cmd.c: get_turn_type_by_name so I fixed it locally. Now the turn command no longer crashes the vehicle-tool. Let me know if you would like the fix :)

rollinsjw avatar Oct 11 '17 03:10 rollinsjw

Hello, I get the same trouble, How to solve this problem?

Thank you for the help!

BenDuan avatar Feb 19 '18 08:02 BenDuan

A work around is to note the car's outputs when it is off the track. I am working on this from Python so whenever it cannot detect a track piece, it throws a Key Error in a specific function of mine which checks for position, in which case I tell the car to stop moving as well as printing a message in the console.

albertjc avatar Feb 21 '18 15:02 albertjc