Elektroda.com
Elektroda.com
X

Search our partners

Find the latest content on electronic components. Datasheets.com
Elektroda.com

DIY CNC milling machine, another raspberry ..

rafikAVR 12336 13
This content has been translated » The original version can be found here
  • DIY CNC milling machine, another raspberry ..

    Hello
    I present my next CNC milling machine which I have not finished long ago.

    The purpose is mainly: milling, engraving, cutting in materials such as:
    - wood
    - mdf
    - plexiglass

    The main assumptions are: a large working field combined with the stiffness of the structure and good material processing parameters.
    and it happened, the working field is:

    X = 1000mm
    Y = 1500mm
    Z = 190mm

    External dimensions
    width 1400mm
    length 1850mm
    620mm height

    Work on the project began in August 2018, construction and storage of elements in the area beginning of October 2018

    So

    The structure is made of aluminum profiles 60x60x30 (L-shaped), additionally vertical profiles 60x30.
    In addition, I used reinforcements at right angles made of 10mm aluminum, which facilitated the assembly of the whole,
    in the back part I just bothered an extra strengthening broom.
    In the front I gave up what did not affect the stiffness of the structure, thanks to which it is easier to transport the material to the worktop.

    The worktop is a 22mm chipboard from the bottom, additionally stiffened and bolted to the 60x30 profiles, preventing the tabletop from bending.
    The material is fixed to the top by means of handles and M8 screws to 176 muffs in pre-drilled holes in the worktop and additionally glued.

    From the inside, the 5mm plexiglass is mounted as a dust-proof cover.
    On the right side of the machine, I mounted the electronics using 4mm aluminum sheet + rubber shock absorbers for screws for aluminum profiles.

    The frame is also based on aluminum profiles and sides of 20mm aluminum
    X-axis
    rollers supported over the entire length of 20mm + linear bearings
    drive: ball screw 2010 + 20mm supported spindles + linear bearings: 4Nm motor
    Y axis
    drive: 2x ball screw 2010 + 2x stepper motor 4Nm
    Z axis
    Roller supported 16mm ball screw 1605 and aluminum sheet 15mm, motor 3Nm
    On the bottom profile I installed 15 LEDs for lighting.

    Electronics:
    Control via raspberrypi directly without GPIO, all axes have TB6600 (original) drivers set to split 1/8
    power supply: 800VA 30V AC transformer (DC ~ 42V)
    Drivers for TB6600 engines
    1.5kW air-cooled spindle, + Sanyu inverter with which the control via RS485 with raspberrypi is carried out with the modbus protocol
    Thanks to this, I have a preview of parameters such as:

    DC bus voltage
    Output voltage
    Output current with an accuracy of 0.1A
    Frequency
    Temperature of the inverter
    and full configuration of the inverter parameters from the software level I wrote on raspberrypi to control the whole

    I wrote a service program in delphi 7 and communication with rPi is done using TCPIP
    DIY CNC milling machine, another raspberry ..
    The driver PCB includes:
    16 opto-isolated inputs
    16 OC OC outputs
    1 relay
    2 x Mosfet with PWM, 1 channel for TB6600,2 controllers for the spindle where I disassemble the upper part for a long time by installing a fan + temperature sensor for the spindle itself

    The machine achieves travels of about 6m / min which is fully enough for me
    Below the photos (sorry that the part is hardly visible, I worked mainly at nights and the camera hardly caught it)


    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..

    Cool! Ranking DIY
    Can you write similar article? Send message to me and you will get SD card 64GB.
    About Author
    rafikAVR
    Level 16  
    Offline 
    rafikAVR wrote 342 posts with rating 71, helped 9 times. Been with us since 2013 year.
  • #2
    Janusz_kk
    Level 31  
    You did not write anything about the costs, pictures in a better light would be useful too ;-)
  • #3
    Slawek K.
    Level 34  
    Respect for an independent soft cnc control. And what's sitting in raspberry?
  • #4
    locos1
    Level 12  
    Complicate with greater accelerations of engines because they are terribly silting.
  • #5
    hawryszka
    Level 11  
    This video where the machine makes holes. Optimization of the code and it could go much faster - acceleration and speed of passage.
    Test yourself with the linuxcnc configuration there you can play with the ramps from speed, acceleration and braking you will find the required optimum.
  • #6
    pitsa
    Level 11  
    Everything is self-contained. Great applause. :-)
    Describe how the preparation of the project looks like, from the drawing to loading it into your program and sending it to the machine.
  • #7
    szczepan999
    Level 11  
    You wrote that "Control using raspberrypi without directly using GPIO".
    My question - how soft sits in this Raspberry that you are sure that stepper motors will not lose their steps?
    If some realtime linux - is so sure that you can use it to control time-critical things such as impulses controlling stepper motors? Or maybe something else?
  • #8
    rafikAVR
    Level 16  
    Janusz_kk wrote:
    You did not write anything about the costs, pictures in a better light would be useful too ;-)


    the costs are already a secret, let the 2 half know nothing :D I will put better photos on the days after moving the machine to the target place

    rs6000 wrote:
    Respect for an independent soft cnc control. And what's sitting in raspberry?


    raspbian with RT kernel

    locos1 wrote:
    Complicate with greater accelerations of engines because they are terribly silting.

    I have already done this, I badly generated Ściesze narzędzi w aspire: /

    hawryszka wrote:
    This video where the machine makes holes. Optimization of the code and it could go much faster - acceleration and speed of passage.
    Test yourself with the linuxcnc configuration there you can play with the ramps from speed, acceleration and braking you will find the required optimum.

    jw

    pitsa wrote:
    Everything is self-contained. Great applause. :-)
    Describe how the preparation of the project looks like, from the drawing to loading it into your program and sending it to the machine.


    at the beginning I operate in verctric aspire => generating gcod and then uploading to rpi on SD
    szczepan999 wrote:
    You wrote that "Control using raspberrypi without directly using GPIO".
    My question - how soft sits in this Raspberry that you are sure that stepper motors will not lose their steps?
    If some realtime linux - is so sure that you can use it to control time-critical things such as impulses controlling stepper motors? Or maybe something else?


    raspbian + kernel RT
    pulses are generated by the timer with an accuracy of 1ns (but after lower 250ns it is worse with its accuracy)
    The program works on threads of each of SCHED_FIFO, except that the one from the motor control has the highest prio, the TCP server has the lowest and gives advice to poll it every 10mS for data further data from the planner fly into the thread control of the stepper motors using GPIO + DMA.

    The fact that they do not lose I'm 100% sure, I set the axes in position 0 (working, not machine) I set the dial gauge to the spindle sleeve by resetting it, I started the program to move around the table in random positions at the end of the return to 0.0.0.

    Deviation about 0.018mm (clearance of screw nuts)

    next weekend the machine changes its working place from the attic where it stands now and I finished soft for her, to the garage.

    The whole document here with newer photos :)
  • #10
    ExtreMme
    Level 9  
    I would recommend teens 4.1 with ide for arduino. The same is programmed, but we have a 600Mhz clock that executes 2 commands during one cycle. I will add that it can be turned up to 1Ghz :) the cost is PLN 150.
    I am currently writing my own cnc controller to handle gcode.
    It's nice, because the complicated calculations that the machine has to calculate with the s-curve speed profile are made within 7us, where system interpolation, which is responsible, among others, for reading from the serial port or motor control, is performed in a 10us loop.
    So you can get really fast axis movements with 1/16 pulses setting.
  • #11
    rafikAVR
    Level 16  
    Currently working on a driver project for STM32F407, more info will appear here:

    https://github.com/rafik84/xcore407i-CNC

    STM32F4 overclocked to 240MHz works stably, after that I have computing power in it up to this ;)

    So that there was no lazy: another 2 CNC machines
    larger working area 800mm x 1250mm x 240mm (X, Y, Z)

    smaller 600 x 900mm x 280mm (X, Y, Z)

    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
    DIY CNC milling machine, another raspberry ..
  • #12
    ExtreMme
    Level 9  
    In my case, 240Mhz is not enough.
    Below is a photo of my project that I have completed.
    Unfortunately, I do not share the software that I have on github :)

    DIY CNC milling machine, another raspberry ..
  • #13
    rafikAVR
    Level 16  
    cool as an engraving, because you will probably not be able to use it for milling (what do I see the rollers unsupported there, 8 -10 mm?, the gate pulled back too far on the brackets), 240Mhz for the s-curve? not enough ??

    xmega 32Mhz in tiny2 https://github.com/synthetos/TinyG embraces the 7-step S-curve without any problems with the periphery
  • #14
    ExtreMme
    Level 9  
    And did you look at the code, what does the s curve profile look like on what you write? This is not the correct way to implement a trajectory, it is just a simple trapezoidal calculation and several functions inserted in the appropriate places that imitate the trajectories at times t1 t3 t5 and t7. On my 800 MHZ month, it takes 6us to calculate the entire trajectory. So such a TinyG would probably be several dozen ms. which would prevent smooth transitions of subsequent movements. As for my project, the axis is on linear guides supported by 20x10 profiles and on fi20 fights and sma20guuL bearings. The x-axis is on the fights without support, but also on a linear guide, and is supported on the rear wall with a wheel on a bearing. Maybe a simple solution, but effective because the x and z axis are stiff.
    The z axis has 4 bearings, which you won't see in the picture, and it's also very stiff. I can easily cut aluminum with an accuracy of 0.00350 mm. You could sit on your back without you bending it :) because additionally I have added cast iron angles that connect the y-axis side walls with the bottom plate.

    At the beginning, without corrections, the x and y axes were not so stiff.