Extra guide stuff

I updated the instructable to reflect the new controller, and also the wiki, though some of that just points at the instructable.  In other news, the new controller has now replaced the old in the trunk of the repository.  New updates will be committed to the trunk rather than polargraph_controller_zoom, so those of you who have checked out of the repo directly, then you can switch to this trunk, or just dump the whole folder and start again from the trunk.

Liberty TSP

I’ve done some TSP stuff, based on the Evil Mad Science TSP guide that was written up for preparing artwork for the eggbot. Don’t be put off, it was easy!

Oh, and for extra credit, I will reveal that this drawing was made with a polargraph running …. standalone!  Exciting isn’t it.  I just turned the computer off and walked away, and the machine just kept on scribbling.  It was a seminal moment.

I exported the queue to a .txt file on a microSD card linked to an arduino mega, and did it that way.  I’ve started a new branch for this in the embedded code repo.

22 thoughts on “Extra guide stuff

  1. It is very inspiring to see the progress in the controller!
    Just published a printable polargraph:
    http://www.thingiverse.com/thing:16692
    I have been looking at the code of the server since I’d like to use the polargrah with pololu divers (a la Kritzler) for higher resolution and the mods seem viable (at least it compiles and uploads – not yet mounted in the wall), the only thing missing is an equivalent to the motor.release function.
    Also, I’d love to test the controller with other apps: is there some reference for the command set?

    • Champion, nice to know you’re following! One of the good things about using the Accelstepper library is that it nicely encapsulates the stepper implementation and it should be pretty straightforward to switch.

      I never really used the .release function anyway. It doesn’t work through the accelstepper, and anyway, releasing is liable to make everything suddenly start putting big lines all over the page just when I’ve finished. I just know it.

      There isn’t a reference as such (you mean the code isn’t self-documenting! how shocking!) but http://www.polargraph.co.uk/forum/?mingleforumaction=viewtopic&t=9 has got a few bits and pieces about it, and these blog posts have sometimes got a bit more info about newer commands. If there’s anything that resists interrogation, just ask.

      Oh and that’s a cool gondola – I have been wondering about printed bearings since I know the steel ones are somewhat overkill. Work great, but do limit the size of the tube and the pen. I want to do some thing with markers and they usually won’t fit.

      • Thank you for the links! I am dreaming of a polargraph to gcode interpreter 😉 actually should be quite straight foward, C01 = G1 , pen up = some M-code etc. Not sure for what, though, giant hatches generated by skeinfoge? ;-))

        My first gondola may only fit smaller stabilo fine point markers. I may go for a more modular one. Also considering integrating the bearings for the additional weight, since the more I think about it, the best it looks to put the mass at that particular point. Will see after the first tests…
        Thank you again!

        • To be honest, it’s probably easier (quicker) to just rewrite the server to read G-code natively. I don’t think there’s an awful lot to it, and I always conceived of the command language to be g-code-ish.

          The extra weight of the bearings are a nice feature, and I think they really do help get sharp corners, but the weight does mean it needs more power than it could otherwise get away with, and there’s a bigger risk of dropping steps because of it. To me, line quality and precision is more important than speed. I usually add another little bag of weights to the gondola if I’m using a very fine pen too, but I need to be careful how fast I move with it on, or it drops steps.

          • So I might have had a good rationale after all to go with NEMA17s (actually reprap motors) in my build 😉 Maybe because I had too many issues with underpowered steppers when building my first eggbot contraption a couple of years ago…

  2. That’s pretty amazing. How many stipples is it in the image? I’m currently using a Mac, so I will try to get Concorde running soon and then I will be able to test some images on my own. Great stuff!!!

  3. Hi Sandy,
    I’m loving all the improvements and the TSP art looks awesome and I hope it try it soon. I have a small issue I wanted to run by you. I am trying to experiment with drawing vector graphics and may have found a glitch. I could just be doing it wrong but for a test I had text (my name) as the image from inkscape. I am using your new trunk files with processing and ran the controller. Upon selecting the .svg file the program freezes and the image never loads. I see that the “DesplayMachine” file is showing an error of “NullPointerException” and is highlighting the line “for(int i = 0; i<pointPaths.length; i++)"
    The black box with red letters says:
    Exception in thread "Animation Thread'
    java.lang.NullPointerException
    at
    PolargraphController$DisplayMachine.draw(PolargraphController.java:2756)
    at
    PolargraphController.drawImagePage(PolaragraphController.java:606)
    at
    PolargraphController.draw(PolargraphController.java:501)
    at processing.core.PApplet.handleDraw(Unknown Source)
    at processing.core.PApplet.run (Unknown Source)
    at java.lang.Thread.run (Thread.java:662)

    I hope that helped and good work on the updated Instructable.
    Matt

    P.S. do you prefer to be contacted on this forum, by email, on instuctables, or carrier pigeon?

    • Don’t mind Matt, whatever you like. If you think it’s something that will be useful to other people, then the forum might be better because it sticks around for longer. On the other hand, these comments are perfect for little issues that would get fixed within a couple of days. There is a proper bug tracking system attached to the google code project too, if you want to be formal.

      Right, there are some issues with loading vectors. I thought there was only the one issue at first, but I think yours is a new one – with the actual exception being thrown. Would you mind emailing me the file so I can have a closer look? Also how did you generate the file? The issue I was having turned out not to be an issue at all – it was just a very big file that took a minute or two to load, and I thought it’d crashed in the meantime.
      sn

  4. Hi Sandy,
    I run your programm perfect.
    but There are several questions
    how to set GRID SIZE smaller as 20? I think the Line spacing is too wide.

    Grain direction can change?
    Such as horizontal or vertical or to the left

    Load Vector can be ok, but wenn I click Draw Vector, the pen wich COMMAND C17
    keep going down no stop.

    is this where the problem then?

    thanks

    • Do you have the latest version? In the controller, if you press “I” then it’ll say at the top what version you have. The latest precompiled binary is 1.0.5 and that has a fix in it for an issue a bit like this.

      I set minimum grid size to 20 because lower than that the program starts slowing down a lot when there’s lots of pixels, and there’s not much you can express in a pixel that’s only 20 steps across.

      However, you can set it manually by editing the value:
      controller.grid.size
      in the polargraph.properties.txt.

      The corner that the drawing starts in can be changed in the most recent code (1.1.0 – currently in the repository but no compiled binary yet). But it always goes in the rows you have already seen.

      Does your drawing all fit on the board? Zoom fully out and make sure there is nothing overlapping the board. Are you remembering that you need to calibrate the machine before drawing?

      sn

  5. Would you be willing to write your own tutorial on drawing TSP art for the Polargraph using Windows 7? I have been working on it for the last few days and am falling short. I seem to be missing a step or something but I can’t get the final image to generate. I did get the vector graphics to draw, pretty awesome!
    Matt

    • Good stuff Matt, glad it you got it working. I’ve added a page to the wiki about TSP at http://code.google.com/p/polargraph/wiki/TspVectorArtOnPolargraph but to be honest, there’s not much more to it than is on Dan Newman’s eggbot pages. The only thing I figured out was that it absolutely _wouldn’t_ work if you ran the python commands from the inkscape folder. At least on windows 7, since windows stops linkern.exe from writing to the program files/ folders. Which is a bit annoying. So what I needed to do was move the three python script files out into a non-program files folder and run the command line from there.

      And don’t forget that in Windows 7 you can open a command prompt in a certain folder from explorer by holding down shift and right-clicking on the folder and you’ll see that there’s an option for “open command window here” on the context-sensitive menu.

      • Good news, Bad news. The issue you had with TSP is the same I had. I just moved the file out of “program files” and ta-da it worked. I set it up in Inkscape and loaded it in the Polargraph Controller. It started drawing and lasted about 3 short lines and seemed to pause. It just stopped and I wasn’t able to get it going again without shutting it down and restarting. But the same issue happed again. Upon reloading the program it would not connect to the arduino until I restarted the computer. Well I was close. Do you have an idea what I did wrong? Thanks
        Matt

        • I just tried some regular pics (non-vector) for it to draw and it too seemed to freeze also upon it starting to draw. So just FYI. I’m not sure if this was resulting from an update, but i’ll try it a few more times. I see you added some extra pix render options. I’m excited to give them a try when it gets going again. Have a good night.
          Matt

        • Scratching head here I’m afraid Matt. There is definitely scope for the firmware to get itself very confused about what it’s doing, with the C17 commands anyway. I’ve just had it spinning away endlessly here, telling me it was heading somewhere, but clearly not actually ever getting there. I have seen this firmware run out of memory before, while it’s going, and that exhibited the same behaviour, so it’s possible that’s the problem. I think it might be time to make a “reduced feature” firmware just for vector drawing.

        • Matt I’ve just updated both sets of code to help with this. I think it has something to do with trying to get a cord to be 0 length, or what happens after that. I have added checks that will stop the machine from trying to draw anything that isn’t actually inside the machine’s space. And on the controller side, I’ve changed the path extraction to discard all vector points that fall outside of the _page_. It makes sense to use the “select area” function to select the lines to draw, but that’s a bit tied up in the bitmap stuff at the moment so I haven’t yet.
          No binaries yet, so please just get the code from the repo, and let me know how you get on!

  6. This is awesome! I was wondering if it would be possible to run this via an SD card. That really opens up this machine to literally be it’s own art piece. If you are having a party at your place, load up a picture into the SD card, and have it draw it out all evening! Brilliant!

    I have already received all my imported items from your side of the pond. The only thing I’m still waiting for is my sprockets and gondola that I am having Ponoko make up. They’ve been working on it for nearly two weeks now. I didn’t realize they took that long

    Anyway, I hooked up everything I have, and loaded your older version of the code and I got the motors running! When I get some more time, I’ll work on getting the newest versions running and start thinking about how I’m going to mount everything to a drawing board.

    Thanks for everything, and thanks for answering all my stupid questions last month. I’m hoping I will be up and running soon! Cheers 🙂

    • Hey Bob, yep this was drawn from an SD card. The new mega code can go into “store mode” where it writes the commands into an SD card instead of acting on them, or you can just put them on a card directly in a txt file and draw from there. Initially, this is only for arduino mega, but I reckon it might squeeze into a simplified version on a regular uno.

  7. Pingback: DrawBot – Onwards and Upwards! | MakerBlock

Leave a Reply