/var/www/restricted/ssh/stm32/www/stm32circle/ STM CircleOS forum / Project for CNC control

Username:     
Password:     
             

Forum

# 1   2009-06-24 17:29:19 Project for CNC control

Kram
Member
Registered: 2008-01-22
Posts: 24

Project for CNC control

Hello,

I am starting a new project with the goal of making a working computer numerical control device with the STM32 as the controller.

I intend to use H-bridges and stepper motors for testing. The finnished hardware will be using a DVD burner that I have modified to burn high quality PCB's (better than printer methods I hope).



So far I have almost finnished the code for controlling the stepper motors.
Next I need to work out communication with PC -  I think I2C/SMBus will be easyest? but requires me to hack my ram to expose the smbus port :O

USB would be nice but it might make the project a lot more compicated :O

I will post the stepper code as a project in a couple of days :)

Last edited by Kram (2009-06-24 17:30:18)

Offline

 

# 2   2009-06-24 17:36:26 Project for CNC control

repzak
Member
Registered: 2008-03-05
Posts: 170

Re: Project for CNC control

Hello,

I have also been looking into this, and i think the easiest way is to for the old Parrallel port, even if there is a need to a card into the computer, there is severeal routing programs already there is using this, it gives out a pulse for each step and a pin for direction...

http://ohmark.co.nz/download/3step/hard … 20full.pdf

Kasper

Offline

 

# 3   2009-06-24 17:37:26 Project for CNC control

repzak
Member
Registered: 2008-03-05
Posts: 170

Re: Project for CNC control

Btw..

Did you succed to get away the copper with the DVD burner laser? i think there is to litle power?

Kasper

Offline

 

# 4   2009-06-24 23:33:10 Project for CNC control

Kram
Member
Registered: 2008-01-22
Posts: 24

Re: Project for CNC control

The pic example is nice, but I see some problems with it.

I would like to use some simple serial comms to pc, and also to be compatable with existing software.

then some intergrated dual/quad H-bridge chip to make the pcb simple. (my motors are bipolar, but i think thats best too).

This way I am using 4 I/O lines for each stepper


The laser is quite small and wont cut copper, but it should be very capable to burn photoresist down to 0.05-0.1mm traces or so..
http://www.youtube.com/results?search_t … +&aq=f

But, this is not good place to discuss the dvd hacking, since I do not know much yet, but I can think of some very cool stuff to do with a cnc controler big_smile

Offline

 

# 5   2009-06-30 19:30:12 Project for CNC control

Kram
Member
Registered: 2008-01-22
Posts: 24

Re: Project for CNC control

Small update :)

I realised cnc control would not be best for this project because it is mostly 2d and there is no contact with the part, instead I'm going to control it like a printer.

So instead, the computer sends 64 bytes over usb at a time (max for comport example) each byte tells it how far to step, then the laser gets turned on for a fixed time.

It sends back status and asks for next buffer.


So I will also need to write a windows program to send the data - primer1 does not have any storage? or I could use the command line "copy" to send a file. I think I will use a two colour bitmap to save the image, that should be easy from most pcb software.

I havent worked on the hardware yet, other than the stepper circuit.


I worked out how to do the stepper control using a loop and switch statement, so Im hoping the program will be fully working tomorrow!

It is almost compiling with one error so far!! trying to copy an array into one same type and size without loops/indexing :(
Anyone know how?

Last edited by Kram (2009-07-01 12:22:08)

Offline

 

# 6   2009-07-01 12:21:30 Project for CNC control

Kram
Member
Registered: 2008-01-22
Posts: 24

Re: Project for CNC control

I finnished the code today. It compiles with no errors :D
I havent tested it yet, but I will upload it soon.

Im going to add some code so it shows the printing on the screen. since the screen is small it will show only the first 128x128 pixels.

Last edited by Kram (2009-07-01 12:30:45)

Offline

 

Board footer