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

Missing and repeated data output #1

Open
VoxoTech opened this issue Apr 2, 2023 · 3 comments
Open

Missing and repeated data output #1

VoxoTech opened this issue Apr 2, 2023 · 3 comments

Comments

@VoxoTech
Copy link

VoxoTech commented Apr 2, 2023

Thanks for your work !

I got strange issue regarding output in CSV format :

serial monitor shows duplicated output for ~0° to about 18° with blank lines then repeat those values 2 or 3 times , then jump to about 150-170° and fully works until 359 .

I'm running your code on STM32 board ( UStepper S32 )

see example below :
...
357.25,233,232,11
358.00,232,231,8
358.75,231,230,5
359.50,231,230,2

0.26,231,230,-1
1.05,231,230,-4
1.84,231,230,-7
2.63,223,222,-10
3.42,227,226,-13
4.21,235,234,-17
5.00,241,240,-21
5.79,258,256,-26
6.58,266,264,-30
7.37,270,267,-34
8.16,280,277,-39
8.95,285,281,-44
9.78,287,282,-48
10.57,281,276,-51
11.36,285,279,-56
12.15,295,288,-62
12.94,285,277,-63
13.73,280,272,-66
14.51,277,268,-69
15.30,268,258,-70
16.09,271,260,-75
16.88,265,253,-76
17.67,270,257,-81
18.46,272,258,-86

9.78,287,282,-48
10.57,281,276,-51
11.36,285,279,-56
12.15,295,288,-62
12.94,285,277,-63
13.73,280,272,-66
14.51,277,268,-69
15.30,268,258,-70
16.09,271,260,-75
16.88,265,253,-76
17.67,270,257,-81
18.46,272,258,-86

9.78,287,282,-48
10.57,281,276,-51
11.36,285,279,-56
12.15,295,288,-62
12.94,285,277,-63
13.73,280,272,-66
14.51,277,268,-69
15.30,268,258,-70
16.09,271,260,-75
16.88,265,253,-76
17.67,270,257,-81
18.46,272,258,-86
172.40,790,-783,-104
173.19,774,-768,-91
173.99,774,-769,-81
174.78,774,-770,-70
175.57,774,-771,-59
.... fine up to 359.xx

@Mike118
Copy link
Contributor

Mike118 commented Apr 2, 2023

I think this is due to communication problems with the lidar (corrupted data or something like that...).
I will try to check it and modify the library to better handle these issues.

@VoxoTech
Copy link
Author

I just tested you last update , and still got a similar issue but slightly different , the output is not anymore duplicated , but still got a gap between about 10-18° and 150-170° (see below) .
I'll try to use the second free serial on my board .. never know ..

thus I got a few questions :

  • what kind of board are you using ? ( may be related to my UstepperS32 ? )
  • are you planning to implement LD06 PWM control ?

Screen Shot 2023-04-20 à 13 15 54
next turn :
Screen Shot 2023-04-20 à 13 17 22

@Mike118
Copy link
Contributor

Mike118 commented Apr 20, 2023

Glad to see your feedback.

What board Am I using :
Right now I am using Teensy 4.0 boards. Still, the aim is to make this library compatible with smaller boards and even give some compatibility with Arduino uno boards ( An Arduino uno should be able to check all points and tell if there is an obstacle near ... but it will not be able to store a full scan because it has not enough memory for that ... ) .

Am I planning to implement PWM control :
Yes if I manage to get it working well but this is not a top priority right now since the default 10Hz rotation is quite good and there are others more important stuff to do first. Why do you want this feature? Do you want to run it faster or slower?

About your problem: I posted this message https://www.robot-maker.com/forum/topic/14388-test-ld06-library/ on the robot maker forum to suggest some tests you can perform.

Please have a try and tell me what are your results.

Best regards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants