External drivers

Post any suggestions that you have for new features and enhancements for the Buildbotics Controller here.
Post Reply
retrosmith
Posts: 6
Joined: Wed Feb 13, 2019 1:15 pm

External drivers

Post by retrosmith » Tue Mar 05, 2019 2:23 am

An option for the user to utilize their own drivers would be a huge benefit. I realize it would be a substantial change involving updates to the actual hardware in the controller, but it would allow your customers to use more than the 36 volts that the controller is currently limited to, making the controller much more versatile and usable in more areas.

Honestly, I don't know that there would be a need to disable the onboard drivers. The user could simply set the output to zero in the software. Adding connections for the outbound control signals would likely be all that was needed.

You wouldn't even need to tell the controller to switch between the two would you? Is there any drawback to having the controller feed identical control signals to both outputs at the same time? You'd only use one or the other.

leadgtr7
Posts: 4
Joined: Mon May 13, 2019 9:22 am

Re: External drivers

Post by leadgtr7 » Wed Jan 08, 2020 12:03 pm

In trying to get closed loop stepper motors (aka hybrid servo motors) to work with the buildbotics controllers I have done a fair bit of digging and bothered Doug with quite a few questions (Which he always answers super quick so thanks for the support on that!). I will detail what I have found so far and the challenges that I think will need to be overcome.

• There is a breakout on the control board for step and direction pulses which feed each of the four DRV8711 motor driver chips. The location and ease of access does vary by board but as I have an early version of the control board I have four 4 pin headers for each motor channel
• The signal voltage from bbctrl is 3.3V
• The pulse width of each of the step pulses from the control is 1.9 us (micro seconds)
• The time between direction pulse and step pulses is 200 ns (nano seconds)


Things will need to be changed in order to use external drivers. These statements are made so that a CL57T external motor driver will work (https://www.omc-stepperonline.com/close ... cl57t.html) so you will need to check the spec sheet to make sure the driver you want to use will.

• Some kind of level shifting will need to be done as most of the external drivers I’ve come across require a minimum of 5V. I will be designing a board for level shifting and output using the same style of connector as the existing motor outputs.
• The minimum step pulse width for the driver is 2.5us as well as the minimum direction pulse time is 5 us. This change requires a change to the AVR code.
o I believe that a change in the following line in the config.h code should do the trick for the step pulses.
 #define STEP_PULSE_WIDTH (F_CPU * 0.000002 / 2) // 2uS w/ clk/2
o I believe that a change in the following line in the motor.c code should do the trick for the direction pulses.
 if (m.timer->CCA < m.timer->CNT) m.timer->CNT = m.timer->CCA + 1
• In the final solution I would think these would need to be a variable set in the settings webpage.

I think that should cover it. I will update when as I find out new info and any comments or suggestions would be awesome!

leadgtr7
Posts: 4
Joined: Mon May 13, 2019 9:22 am

Re: External drivers

Post by leadgtr7 » Fri Jun 05, 2020 12:38 pm

So after a long while i have found a solution that works. You will need to make an add on board for this (Here is my github page on it https://github.com/leadgtr7/Buildbotics ... tion_Board).

As of right now i have my 2 y axis gantry motors running closed loop (https://www.omc-stepperonline.com/close ... river.html) and i am still using the internal stepper drivers for the x and z axis at this time.

Hope this helps out and again thanks to Joe and Doug!

Post Reply