Javid Butler wrote:
> A microcontroller will definitely give you better response (EMC is to slow 
> to really scan the laser-machine tools are moving about an order of 
> magnitude slower than a laser scan), but you would have to code the graphics 
> or find a way to convert them. Easy enough for simple graphics like a 
> square, but harder for something complex.
> 
> What you could do is use EMC to preprocess the image, drawing in 2D. Then 
> capture the bitstream from the parport into the microcontroller. Each output 
> bitstream would be a single frame, so animations will be a lot of work. On 
> the other hand, if you are getting that involved you really should be 
> looking at Pangolin or something like it.
> 
> All you would have to do in the microcontroller then is convert the X and Y 
> step and direction into galvo control signals.

You don't actually have to mess with step and direction.  EMC's main 
motion controller generates position commands as floating point numbers. 
  Those numbers go to HAL step generator to make make steps.  If your 
drives don't use step and direction, you ignore that part and capture 
the numbers directly.

A existing HAL component called "sampler" would let you capture the 
positions from a single run of a g-code program into a file.  Then that 
file could become the input to your microcontroller.  Another HAL 
component called "streamer" can "play back" the file captured by sampler 
(and would let you play it back at a different speed than you captured it).

The files used by sampler and streamer are simple text, and can be read 
or generated by other programs as well.

> Each time you loop through 
> the sequence it will draw the image, so it's just a matter of how fast and 
> now frequently you run through the loop.

Right now streamer plays the file once and stops, but it can be wrapped 
in a shell script loop so it streams the same file (or a sequence of 
files) over and over again.

> You will probably have to run 
> through the loop at least 20 times per second to get a flicker free image, 
> so work backwards from there to determine how fast the processor needs to 
> be. If the image has 10 points in it you need to be able to update 200 
> points per second, 100 points needs 2000 points per second. A curve needs a 
> lot of points to look smooth. Think about how many step and direction 
> commands EMC generates to cut a circle.

Yep, it really comes down to a matter of speed.  HAL PID loops and such 
can run at a few tens of kiloHertz, which might be enough for simple 
displays.  But I bet the professional laser displays use either 
dedicated processors or analog circuits for their fastest loops, and are 
an order or magnitude faster.

Regards,

John Kasunich




-------------------------------------------------------------------------
SF.Net email is sponsored by: The Future of Linux Business White Paper
from Novell.  From the desktop to the data center, Linux is going
mainstream.  Let it simplify your IT future.
http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to