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

Random motor stall in (0.4.6 <= version <= v0.4.7-rc10) #215

Closed
RJSavell opened this issue Apr 24, 2019 · 12 comments
Closed

Random motor stall in (0.4.6 <= version <= v0.4.7-rc10) #215

RJSavell opened this issue Apr 24, 2019 · 12 comments
Labels

Comments

@RJSavell
Copy link

This issue seems this started with 0.4.6 or 0.4.7 but it may have been there all along. This is the 3rd time the Buildbotics controller suddenly and apparently for no reason changed the tool path to a new position and ruined my work piece. The first 2 times I thought it was maybe something I was doing but this time I am sure it was not. Where this happens is not consistent, each time it has happened it seems to just change direction and continue in a different direction, in this case it went from cutting a circle to the start of a figure eight and then continued with the circle but in the wrong place. It then stays aligned with the new position continuing to ruin the work piece.

Hopefully you can find and correct this quickly as I am not able to use the controller with this bug

Buildbotics bug.zip
20190424_140707
Annotation 2019-04-24 142413

!

I have attached the debug files, a picture of what happened and a screen shot showing the path viewer still thinking it is in the correct position.

Please let me know there is any more information you need from me.

Thanks,

Randy

@jcoffland
Copy link
Member

Thanks for the report I'll look into it. I'm sorry your workpiece was ruined but please be aware that there is some risk involved in choosing to use a beta firmware.

@RJSavell
Copy link
Author

Good point about being beta, should I go back to 4.6?

@jcoffland
Copy link
Member

jcoffland commented Apr 26, 2019

I went through the log file and it did contain one weird thing related to reporting modbus communication warnings but I don't think this would have caused the problem above. I extracted the position data from the log file and plotted it. The controller reported the correct positions in the log file. The Buildbotics controller keeps track of how many pulses it sends to the motor drivers so unless the motors slip, it's internal position should correspond. It seems impossible for it to have driven the motors so far off without this being visible in the log file.

This leads me to conclude that the most likely explanation is that there was either an electrical or mechanical failure that caused the motors to stall and lose position. It's odd that both X and Y lost position. However, if the tool head stalled as it was trying to come back around the circle for about 1/4 of the circle in just the right spot it would lead to exactly the failure depicted above.

I'm not saying this absolutely was not the Buildbotics controller's fault but I suggest you also look carefully into other possibilities such as loose wiring, things that could physically block the movement of the tool head or mechanical problems. I'll also keep looking for a better explanation.

Here's the plot I got:
path
Note that the log file only contains periodic position updates, thus the jagged lines, but it does follow the correct path without drifting out of position.

@RJSavell
Copy link
Author

RJSavell commented Apr 27, 2019 via email

@RJSavell
Copy link
Author

RJSavell commented Apr 27, 2019 via email

@jcoffland
Copy link
Member

Thank you for the detailed analysis. That is really helpful. There were some changes to arc handling between version 0.4.5 and 0.4.6 so you're probably on to something here.

This is a bit of a stab in the dark but can you tell me if 0.4.7-rc9 works any better?

@jcoffland jcoffland added the bug label Apr 30, 2019
@jcoffland jcoffland changed the title CRITICAL path error CRITICAL path error in v0.4.6 & v0.4.7 Apr 30, 2019
@jcoffland
Copy link
Member

I'm having trouble reproducing this. Could you provide your simplified oval path that exhibits this problem? Note, I didn't get the debug attachment you mentioned in your last message.

@RJSavell
Copy link
Author

I will give it a try with RC9 and let you know but it may be a couple of days before I can test with it.

Here is the file for the oval (it is actually for making a planter :-)
Planter.txt

Thanks!

Randy

@jcoffland
Copy link
Member

Ok, I was able to reproduce this bug but only a couple of times and I'm still unsure what is causing it. It would be good to narrow it down further. Since you are able to easily reproduce the bug a can you try it with your spindle disabled and/or camera unplugged? These may or may not affect it.

@jcoffland
Copy link
Member

I think I've fixed this. Please try 0.4.7-rc10.

The problem was caused by the planner queue bottoming out. I'm not quite sure what was causing it but after reducing the internal communication traffic I can no longer reproduce the problem.

Most likely the RPi was either not sending data fast enough or not reading the responses from the AVR (step generating processor) fast enough. When the queue runs dry the AVR enters the READY state because it has no more commands. This causes the ETA, Remaining and Progress fields on the Web interface to clear. When it switches from RUNNING to READY and back to RUNNING quickly, those fields flash and the motors stall.

@jcoffland jcoffland changed the title CRITICAL path error in v0.4.6 & v0.4.7 Random motor stall in (0.4.6 <= version <= v0.4.7-rc10) May 6, 2019
@jcoffland jcoffland reopened this May 6, 2019
@RJSavell
Copy link
Author

RJSavell commented May 6, 2019

Joe,

I saw there was a rc11 so I loaded that instead of rc10. I ran it several times and preformed perfectly - Thank you!!!!

Randy

@jcoffland
Copy link
Member

Gald to hear it.

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

No branches or pull requests

2 participants