Calibrating V2

Shop Forum Makelangelo Polargraph Art Robot Calibrating V2

  • This topic is empty.
Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #5908
    Anonymous
    Inactive

    Greeetings:
    So I got my V2 assembled and basically functioning. I mounted everything to a piece of plywood taped to an easel for now.
    But my question is how best to calibrate to get smooth clean drawings. There are a couple of specific questions:

    1. When I connect to the board the servo looks like it moves to a default position. Looking at the code there are constants for both the up and down position. I used the Z-axis calibration in the GUI to get good values for those and put those into
    the code. Then my pen would not move at all. Any thoughts on what is happening there.

    2. Second issue is that it looks like the pen holder drags and so even simple straight lines are not straight. Any ideas or suggestions on how to better find the Center of Gravity and balance the pen holder? What is the ideal setup (more weight to the pen, more to the legs, even)? Since my board in on an easel and is not vertical is that making the difference? I figure I can try each of the different thread holes on the holder and see which works best but that is a lot of time so I thought I would
    ask first.

    Finally, the sharpie is a fairly blunt drawing tool. Has anyone had any successes with a different type of pen? How about with a pencil or charcoal?

    I think I will try and write a script to generate some calibration patterns to help this process.

    #6326
    Anonymous
    Inactive

    The gcode should be left with constants. In the DrawbotGUI software you can configure the pen up/down.
    It will replace the “Z90” and “Z0” in the gcode with your numbers. I’ve also put in a “test” button so that you can check your new configuration works.

    How far over is your easel tilted? I have my board leaning against a wall, typically a 10 degree angle. My strings go through the third set of holes and I sometimes add a counterweight to the front by attaching a 9v battery with a zip tie.

    A great trick to make changing the strings easier: make a permanent loop in the end of the string. Get a little piece of cardboard. feed the loop through the hole on the pen holder, put the cardboard through the loop, and pull the string back through the hole until the cardboard blocks it at the hole entrance. I’d say my pieces are 5mm * 20mm. You can cut it from the lip on the box and it won’t show when it’s closed. If you have trouble getting the string through the hole, bend a piece of wire to make a hook and fish it through.

    #6327
    Anonymous
    Inactive

    Dan:
    Thanks. I think I chased down my pen up/down issue at least part of it. The reason I wanted to change the constants in the firmware was that on power-on the servo was rotating and forcing its way out of the area in the pen holder.

    In the firmware (downloaded from GITHUB) in setPenAngle there is code that reads:
    if(posz<PEN_DOWN_ANGLE) posz=PEN_DOWN_ANGLE;
    if(posz>PEN_UP_ANGLE ) posz=PEN_UP_ANGLE;

    The current constants are:
    #define PEN_UP_ANGLE (170)
    #define PEN_DOWN_ANGLE (10)

    However when I did the Z-axis calibration with the gui my working values are about 180% out so my PEN_UP_ANGLE is like 40 and my PEN_DOWN_ANGLE is 110.

    When I commented out those two lines of code things now work with manual controls.

    However, when I convert a drawing and say to execute it still uses Z0 for down and Z90 for up.

    I will use the trick on the strings. My other thought was to get some fishing line swivels like (http://www.amazon.com/20PCS-Grey-Fishing-Connector-Swivels/dp/B005HU5OIG) and use those.

    I will have to measure my current angle. I would say it is probably off vertical by 15 degrees.

    What I notice when I hand code the g-code for a square I get a sort of parallelogram. It is like one motor
    is moving differently than the other.

    #6328
    Anonymous
    Inactive

    Ah, now I understand a little better. You shouldn’t have to edit the firmware at all. The first time you turn on the servo it will act dumb until you configure it in the Settings > Adjust Z menu.

    #6329
    Anonymous
    Inactive

    Should the Z-axis values be written to EEPROM?
    When I look at the Firmware code there is nothing to read them back out of the EEPROM.
    I am also thinking I have a disconnect between the GUI and the firmware.
    When I look at the firmware there is code to set the bobbin size in the EEPROM.
    However I can’t find anyplace in the Java code where that set command is issued.
    Am I missing something or just out of date somehow?

    #6330
    Anonymous
    Inactive

    Settings > Configure Bobbins adjusts the bobbin size.

    It’s possible that as things have evolved a disconnect has crept in.

    There is no EEPROM storage for the z values. I change it in the GUI. Until now nobody’s noticed how inconsistent I’ve been. 🙂

    #6331
    Anonymous
    Inactive

    Dan:
    Thanks. I actually did get something that looked somewhat like my picture last night. I think I am losing small motions and I do think I need to tweak the bobbin size through the firmware.

    For some reason the code in the GUI which is supposed to change Z0 and Z90 to Z, Z is not working. I ended up
    editing the g-code file generated from a picture to change the values to get stuff to work.

    With your permission I would like to contribute to both baselines and work on some of these things.
    I am off to the FIRST Robotics World Championships this week but should have some time to work on stuff.

    #6332
    Anonymous
    Inactive

    Are you sure you have the latest from github? I patched the z thing recently.

    I’d love to have someone help out on the project. You can fork it, change it, and make a pull request to let me know when you’re ready to have your code put back into the system.

    Thanks and good luck at FIRST!

    #6333
    Anonymous
    Inactive

    Dan:
    I did finally get something that looks reasonable. Some kapton tape on the feet of the pen holder helped with
    the resolution. However, my drawing is squished at the top (see http://imgur.com/9sJLEfH)

    Not sure what is causing this. Any thought would be helpful.

    I did verify I have the most recent from GIGHUB.
    The java code to change the pen up/down looks like it should work to change the Z values.

    I have forked the Repo and started some tweaks.
    Specifically:
    – Have java code send D command to save bobbins.
    – Modify code to store pen up/down angles in EEPROM
    – Have java code send a new D05 command to save those
    – modify the pen up/down code on the arduino to account for them being backwards (up less than down).

    Hope to have stuff tested this week.

    #6334
    Anonymous
    Inactive

    Sounds neat! I look forward to it.

    #6335
    Anonymous
    Inactive

    Did a pull request last night. I also tested Cottem’s fixes for the occassional hangs. No
    problems since.

    My next item will be callibration steps. I am going to generate some geometric patterns and
    then develop some steps to calibrate from there.

    Part of my issue right now is I went to a thicker braided fishing line (the thread was just too
    fine for me to deal with) and I have significantly more on one bobbin than the other.
    I plant to write some code that will allow you to wind an exact amount of enough string
    onto each bobbin as part of the process.

Viewing 11 posts - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.