I want to revive long gone control for DC motors. I think DCServo by misan is a good way to controll my DC motors. It take out all the logic of encoders and H bridges from main GRBL driver.
I think there is unique possibility to preprare system with know how hard he got to move.
My code is not prepared properly becouse I’m not familiar with GRBL programming. I’m sharing with You my 2 days of work. There will be more.
If some1 got any polishing suggestions please leave some enchantments.
My CNC description:
2 motors + 2 encoders on X axis
2 motors + 1 encoder on Y axis
1 motor + 1 encoder on Z axis
1 motor + 1 encoder on A –> R’otating axis for cuting pipes with plasma.
Every axis got 2 limit switches.
I like to talk by facebok so if You want to talk just call me on https://www.facebook.com/marcin.przyborowski.10/
评论 (13)
#2 – MarcinanProfesjonalista 于 2020-08-17
Opticaly isolated ESP32 shield + DC servo shield.
https://easyeda.com/polaski/esp32-cnc-shield_copy
https://easyeda.com/polaski/arduino-dcservo-emulator
Two parts.
Rig will use 4 arduino and 1 esp32.
#3 – bdring 于 2020-08-17
Where is the DC servo hardware? Power FETs etc.
#4 – MarcinanProfesjonalista 于 2020-08-17
I’m connecting external H bridges for dc motors. H bridge is connected to DCServo Arduino and motors are connected directly to H-Bridge.
I’m using chineasium 1x L298n and 3x modBTS7960 43A bridges. They can be swapped at any time if damaged. Price on alibaba is good enough. Any random Hbridge will fit. Even DIY mosfet versions.
I can mount brushed motors 250W so they draw 20A each. H bridges are commanded from Arduinos.
So I want to connect motors directly to H bridges.
I didn’t finish my code yet becouse I don’t understand kinematics of GRBL. –> Will it react to alarm signal from normal stepper motor driver? How to slow down movement execution if Alarm occurs?
Did You get the point of emulating stepper motor that way? That DCServo module is just emulator.
#5 – bdring 于 2020-08-17
I think this PR will ultimately be closed. We can leave it open for a while for reference, but it needs to target devt and I think it it should have been done as a motor class.
#6 – atlaste 于 2020-08-18
Motor drivers typically just implement the Motor class. However, I looked at the code and tried to understand what’s going on, but it seems to me all that is required is a simple ‘step’ and ‘direction’, which seems to act exactly the same as a default stepper. Seems the Arduino’s act as drivers. That basically means any default stepper configuration will do, such as 3axis_xyx.h . The rest is default grbl configuration.
In other words, I think this works out of the box.
#7 – MarcinanProfesjonalista 于 2020-08-18
Dir, STEP, Alarm pins from arduino to ESP ![]()
#8 – MarcinanProfesjonalista 于 2020-08-18
Alarm of “I can’t keep up”. I want to let ESP know when it need to slow down witch execution. It will tell if motor is blocked due collision or heavy load. It may help in calculation of max feedrate
But i think if som1 don’t care about collisions, alarm pin can be skipped
Yea. It may work out from start.
What about limit switches?
#9 – MarcinanProfesjonalista 于 2020-08-18
Ok. My esp32 shield cant work w/o key to run that much optocoupler
#10 – MarcinanProfesjonalista 于 2020-08-18
Sooooo. Im going to look on tindie for yo 4 axis esp shield
#11 – MarcinanProfesjonalista 于 2020-08-19
https://easyeda.com/polaski/stepper-emulator Then i will try to adapt this module
So there are only DIR and STEP pins used. I will tinker with size of this.
#12 – MarcinanProfesjonalista 于 2020-08-19
Ok. I made some tweaks to my shield. Now it communicating with comptrollers by transistor array. TBD62003APG may fit here
#13 – MarcinanProfesjonalista 于 2020-08-19
So tell me. May it work? I just remaped ESPduino pin list to fit my adaptation.
#1 – bdring 于 2020-08-17
We have some pull request guidelines.
We don’t accept PR’s into master.
We would also like to have a lot of discussion between the devs on this first.
Is there hardware associated with this? Schematic, BOM?