luni64 / TeensyStep4

MIT License
17 stars 15 forks source link

Acceleration issue #8

Open vp8181 opened 1 year ago

vp8181 commented 1 year ago

Hello sir @luni64 I wanted to achieve constant speed for my 6 axis robotic arm. For constant speed I set the acceleration at 999999. But that high value is causing some issue. I don't get the speed appropriately. It's like there is a fixed speed for value untill 1414 and the speed after that will be same for any value. If i set speed at 600 or 1413 it will be same. And if i set 2500 or 10000 it will be same , no difference. But when I reduced the acceleration to around 100k . It was working well. So I guess there is some kind of calculation issue. Please look into it sir. Also can we edit this Library for any other controller. And if yes than in what part of code do i need to specifically make changes. And i am not very good at coding , but I do things by learning. Thanks in advance.

vp8181 commented 1 year ago

Sir @luni64 any updates on the issue above or any other way to get constant speed?

vp8181 commented 1 year ago

Hello sir @luni64 Sorry to bother you again and again. But this is such an amazing and powerful library i can't resist myself from using it. Sir is it possible to collab in any way on projects? Teensy 4x supply is uncertain just as 3x , i cannot risk the projects i am working on. Can you help me in any way possible so i just dont have any problem with using and customizing this library for any other board.... I appreciate your work sir. Thankyou sir for all your help

luni64 commented 1 year ago

Sorry, I currently have absolutely no time left for support. I'll continue working on this library as soon as possible

luni64 commented 1 year ago

Can you test if v0.0.2 fixes your issue?

vp8181 commented 1 year ago

Sure sir , I will update you once i will try it, and this may take some time as i dont have the hardware setup right now with me. And what part do i need to specifically look into? The 999999 should not give me be issue any more for constant speed as i had mentioned? Once Again Thanks for your support.

cbradburne commented 1 year ago

@vp8181 Similarly with this issue, this branch LINK should fix the incorrect speeds at high acceleration. If you're able to test it and let me know if it's successful, that would be great.

vp8181 commented 1 year ago

Sure sir, I will try to update you both ASAP.

vp8181 commented 1 year ago

Hello Sir @luni64 , @cbradburne I will be able to test the results in this week so please can anyone let me know which one do I need to try . This main branch by @luni64 or the one shared by @cbradburne in the above link(2 commits ahead of main branch). Should i expect 1] The 999999 acceleration issue solved 2] The stop( ) function working using external ISR emergency button? Its should stop the stepper motor and move back to void loop instead of freezing the teensy4.1 Do i need to check for anything else?

Thankyou for both of your Support .

vp8181 commented 1 year ago

Big thanks to @luni64 and @cbradburne for helping with the acceleration issue. The latest code fixed it.

In the future, if I need more project help or want to collaborate, can I reach out to you two? Any way possible to share email id ...etc.

Thanks again!

vp8181 commented 1 year ago

Hey @luni64 @cbradburne I have tested for interrupt based stop . In earlier version the controller was getting unstable and there were issues but now the motors stops at interrupt and prints stops for 1 single motor at a time and continues after release of button. And there is no command for group Stop so that gave me error .