X-Y mirror controller

XCore Project reviews, ideas, videos and proposals.
User avatar
infiniteimprobability
XCore Legend
Posts: 1124
Joined: Thu May 27, 2010 10:08 am

X-Y mirror controller

Post by infiniteimprobability »

Version: 0.1
Status: Alpha
License: BSD
Download: /files/project_builds/xy_archive.zip

This is a project that has been floating around in my head for a while.

The goal is to control a pair of steppers from a vector source to steer a laser onto a target. The idea is to write things or project shapes etc.
The main part is the stepper control. I used an 8b port to produce 8x PWM signals. It's efficient thread and port-wise but you get jitter if there are multiple PWM duties that are close together - it's a single thread doing a wide port with timer events. It probably doesn't matter in this case as steppers start to run out of resolution below 1/64 steps unless you start doing some interesting stuff with current recirculation and decay in the power stage which I'm not - simple open collector ULN 2003A drive with freewheeling diode. 1b ports for each output would be better as you can get simultaneous transitions!
The code is a bit of a mess in places, but it works! A bit of fun really and hardly stresses half of a core on the G4 used (XC-1). No plans to spend any more time on it unless there is interest.
Developed in eclipse so beware there are a few source files not used yet/included in the build (star.c, and you should choose either vector.xc, scope.xc or bouncingball.xc to provide the vectors)
Enjoy
Video:

Images:


User avatar
jonathan
Respected Member
Posts: 377
Joined: Thu Dec 10, 2009 6:07 pm

Post by jonathan »

Very nice. Would love to see what happens if you can split the beam but retain tight synchronization on the stepper motors - could it improve refresh rates and therefore image/writing quality? I like this.
Image
User avatar
infiniteimprobability
XCore Legend
Posts: 1124
Joined: Thu May 27, 2010 10:08 am

Post by infiniteimprobability »

Steppers just run out of oomph above a couple of hundred Hz. Too much rotational inertia I'm afraid so clever scheems might eek out another octave or so but you're fighting physics.

Galvonometers are what the professional guys use - for the same reason the HDDs went from steppers to voice coils..

That gets you to Khz and better. Enough for a giant game of vectrex on the wall perhaps
User avatar
shawn
XCore Addict
Posts: 238
Joined: Thu Dec 17, 2009 5:15 am

Post by shawn »

Regardless the x&y mechanisms, how fast can the XCore switch the laser? 10mhz
100mhz? It's a silly question perhaps. In regards to the x&y controller project, I am
impressed with the JIT visualization and explanation, also Jason's, idea of splitting
the beam. It makes me think? so if I cross any clues or idea's I'll pass them along.
User avatar
jonathan
Respected Member
Posts: 377
Joined: Thu Dec 10, 2009 6:07 pm

Post by jonathan »

Lol it was my idea, not Jason's! :-) Thing is, I have no idea what I'm talking about/how easy it is/whether it makes any difference. So if it's a stupid idea, Jason can have it... ;-)
Image
User avatar
jason
XCore Expert
Posts: 577
Joined: Tue Sep 08, 2009 5:15 pm

Post by jason »

Indeed I do not believe I have ever advised you about splitting laser beams!
User avatar
shawn
XCore Addict
Posts: 238
Joined: Thu Dec 17, 2009 5:15 am

Post by shawn »

Sorry Jason, I try not to give you everones credit?
Sorry Jonathan, I hope you got a laugh. 0oo.
User avatar
johanar
Active Member
Posts: 60
Joined: Tue Feb 16, 2010 8:21 am
Location: Sweden

Post by johanar »

These voice coils you mention, maybe you could rip a pair out of some old HDs and try? Looks pretty cool either way! :)
User avatar
shobley
Junior Member
Posts: 5
Joined: Thu Feb 17, 2011 11:32 pm

Post by shobley »

I have quite a lot of experience in "controlled laser placement" - galvo's are a doddle to control and much more precise than steppers.

All you need is a good ladder DAC, and some op-amps for basic ILDA control.

Steve
williamson66
Junior Member
Posts: 5
Joined: Tue Jan 15, 2013 6:44 am

Post by williamson66 »

I would like to construct a digital crossover for use with my occasional loudspeaker construction hip hop leather jackets projects.
Basically stereo in and stereo Sam Flynn jacket out in 3 frequency bands each. Input I would like from an audio line, SPDIF or even USB from the PC. Output to three audio lines per channel on their way to the power amp stages.