CNC Touch Control App

CNC Touch Control App

Postby Kaldonis » Fri Nov 18, 2011 11:41 am

I'm planning to make an android app that basically gives the user touch control of the CNC (think finger painting in wood). I've only barely started but the general idea is that the app will map screen coordinates to the CNC cut area and moving your finger around on the screen will move the CNC around. On the device it would appear to the user as a simple paint app.

Update: It lives!
- Tic Tac Toe fail: http://www.youtube.com/watch?v=V-9eZLgqRHw
- Tic Tac Toe fail (cont'd): http://www.youtube.com/watch?v=lq2xrWOY0eg
- Smiley face demo: http://www.youtube.com/watch?v=vLpZSTjCVJE

How it works:
Three pieces of software,
- android application translates screen presses into gcode and feeds this data over the network to a...
- java server running on the CNC computer which simply dumps the gcode into a text while which is read by a...
- vbscript executing within mach3 which just keeps reading gcode from a specified file

Current features:
- Supports G00 (fast movement on tap), G01 (slow movement for cuts with long click/drag), G02 for circles
- Bit gets lowered when a "long click" is detected on screen, stays lowered until finger is lifted from screen (in path mode)
- Ability to specify cut depth
- Tool path drawn on screen while cutting (like a paint app)
- Additional cut modes - line, circle, rectangle
- Ability to redefine cut area on the fly

Current challenges:
- occasionally crashes when you get too far ahead of the machine

Future ideas:
- gyro control (kurtis noted this could make some killer art)
- specify feed rate on the fly (as simple as issuing a G94 F<X> command, currently must set this up within mach3)

Code: http://code.google.com/p/touch-cnc/
- this is my first ever android app and I haven't done java in a long time so I know the code isn't perfect
- a few values are still hard coded in (such as my screen size), will change in future revision
User avatar
Kaldonis
 
Posts: 327
Joined: Wed Jan 12, 2011 3:29 pm

Re: CNC Touch Control App

Postby rsilk » Fri Nov 18, 2011 1:08 pm

Picture this: "extreme finger painting" workshop at the space. Goliath positioned where the current CNC bench is, below the window. "Artist" stands on the other side of the window doodling on a tablet, while watching the machine make a mess of the other room. For bonus points, also place the red danger light in the window.
rsilk
 
Posts: 305
Joined: Wed Dec 01, 2010 11:55 am

Re: CNC Touch Control App

Postby Bergo » Sat Nov 19, 2011 12:17 pm

sounds fun!
User avatar
Bergo
 
Posts: 323
Joined: Wed Jan 05, 2011 4:57 pm

Postby Kaldonis » Sun Nov 20, 2011 5:40 pm

It works! Demo'd it today - video will come later. For now:
Attachments
mobileimage.jpg
mobileimage.jpg (200.19 KiB) Viewed 4513 times
User avatar
Kaldonis
 
Posts: 327
Joined: Wed Jan 12, 2011 3:29 pm

Postby Kaldonis » Mon Nov 21, 2011 10:45 am

Two videos on sax's YouTube page: http://www.youtube.com/user/thesaxmachine
User avatar
Kaldonis
 
Posts: 327
Joined: Wed Jan 12, 2011 3:29 pm

Re: CNC Touch Control App

Postby DigitalOSH » Mon Nov 21, 2011 12:25 pm

The touch painting app seems unreal. You should do an instructable and a submission to hackaday, i feel like that's something that could get us a lot of publicity. Maybe get the painter girl next door to use it for a demo?
User avatar
DigitalOSH
 
Posts: 435
Joined: Tue Nov 30, 2010 10:03 pm

Re: CNC Touch Control App

Postby Kaldonis » Mon Nov 21, 2011 12:48 pm

DigitalOSH wrote:The touch painting app seems unreal. You should do an instructable and a submission to hackaday, i feel like that's something that could get us a lot of publicity. Maybe get the painter girl next door to use it for a demo?


Yeah, I think that's the eventual plan... I kind of want to work on a few things first. For sure I want to clean up my code so that it doesn't get mocked by the masses. :P

My next step is going to be to add "shapes"... lines, circles and squares namely. Also want to be able to zoom and pan so you can do more precision cuts in smaller areas.
User avatar
Kaldonis
 
Posts: 327
Joined: Wed Jan 12, 2011 3:29 pm

Re: CNC Touch Control App

Postby Travis7s » Mon Nov 21, 2011 1:56 pm

Cool... I wish there was 2 spindles so you could play Tron!

I think you guys should make a dedicated Techworks Youtube channel...
Travis7s
 
Posts: 52
Joined: Mon Jan 10, 2011 9:45 pm

Re: CNC Touch Control App

Postby Kaldonis » Tue Nov 22, 2011 11:12 am

Alright, so I've added shapes (line/circle/rectangle) to the app and they all seem to be working good (haven't tested on actual CNC but the gcode output appears fine)... improved the on screen drawing now too so it's an actual path being draw instead of a dotted line (figured out how to use drawPath properly).

Rather than adding zoom/pan I'm just going to add the ability to redefine your cutting area on the fly, so you can zero the machine on your piece and then set the cut area to be the dimensions of that piece. This will lessen the likelihood of death.

I'd like to test this all out tonight as well as get a good video demo done (perhaps with two cameras - one on the screen and one on the surface).
User avatar
Kaldonis
 
Posts: 327
Joined: Wed Jan 12, 2011 3:29 pm

Re: CNC Touch Control App

Postby DigitalOSH » Tue Nov 22, 2011 3:21 pm

I'll bring my camera
User avatar
DigitalOSH
 
Posts: 435
Joined: Tue Nov 30, 2010 10:03 pm

Next

Return to Software

Who is online

Users browsing this forum: No registered users and 1 guest