1. Got a question or need help troubleshooting? Post to the troubleshooting forum or Search the forums!

Mike Kelly's Printer

Discussion in 'Show and Tell' started by Mike Kelly, Jan 27, 2014.

  1. Ziggy

    Ziggy Moderator
    Staff Member

    Joined:
    Feb 20, 2013
    Messages:
    707
    Likes Received:
    530
    Mike

    Servo(s) have 3 leads (Sig, +5v, Gnd) and plug directly into the AUX1 connector on the Ramps

    http://reprap.org/mediawiki/images/c/ca/Arduinomega1-4connectors.png

    Marlin has all the servo control firmware built in, including options to power up/down the servo. Test using gcode M280.

    Important configuration.h data is

    #define NUM_SERVOS 1 // Servo index starts with 0 for M280 command


    #define SERVO_ENDSTOPS {-1, -1, 0} // Servo index for X, Y, Z. Disable with -1
    #define SERVO_ENDSTOP_ANGLES {0,0, 0,0, ??,??} // X,Y,Z Axis Extend and Retract angles

    where ?? is in the range 0-90 degrees
     
  2. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    Ziggy my current configuration I'm using the RRD fan extender on the servo ports. The solenoid switch I'm using is a 5v on/off voltage. I'm hoping to use a pin like D1 to control the solenoid but I'm not sure that's possible?
     
  3. Ziggy

    Ziggy Moderator
    Staff Member

    Joined:
    Feb 20, 2013
    Messages:
    707
    Likes Received:
    530
    Suggest moving the RRD extender so at least one servo set of pins is available out of the 4 sets.

    If you are using a solenoid (not a servo) to extend the Z probe, then another option is the Z probe "sled" idea. ie Use the sled activate/docking output to control the solenoid. But you will need a FET switch to handle the solenoid current and some diode reverse polarity protection when the solenoid is turned off.

    https://github.com/ErikZalm/Marlin/issues/1014

    Of course as an alternative you can always mod the firmware code to switch on/off any free digital output on Ramps AUX 1 or 2 connectors
     
  4. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    Well then I need a way to control my parts fan. It might be possible to solder directly to the pins from the RRD fan extender. I assume they sell pins that are double length for making circuit build sandwiches. The RRD uses D6 and D11 so D4 and D5 should still be available.

    What does the FET switch require? I have a spare STP55NF06L, like what drives the heaters. Do I just mimic their circuit of a 10 ohm resistor between the output and the FET with a 100k resistor to ground for a filter. Then I'm not entirely sure what you mean on the reverse polarity protection. Do I need a diode on the solenoid power line or on the digital pin side?

    I'm gonna look at Thantik's firmware here and see what he did to enable the solenoid.
     
  5. Ziggy

    Ziggy Moderator
    Staff Member

    Joined:
    Feb 20, 2013
    Messages:
    707
    Likes Received:
    530

    Simple FET circuit to control a solenoid is like this

    upload_2014-11-24_9-55-25.png

    The diode (IN4001 or similar type) is there to kill the reverse polarity voltage spike when the solenoid is switched off.
     

    Attached Files:

    2 people like this.
  6. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    Thanks man. I figured out that with M42 command I can toggle a pin. I think I'm going to just tell it to enable the probe that way using a digital pin then not worry about messing with the servo port.
     
  7. Ziggy

    Ziggy Moderator
    Staff Member

    Joined:
    Feb 20, 2013
    Messages:
    707
    Likes Received:
    530
    Actually the 5v supply from the Arduino board will struggle to provide enough power to the solenoid. Would be better to use 12v supply if you can. Just change the VDD value in the diagram above.
     
  8. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    I agree that the arduino can't. Though 12v would provide more strength than I'd like. The 5v from the Ramps triggers it fine though the arduino doesn't. I'm gonna make a mosfet switch to use the ramps power instead of the arduino or I can use a 5v supply
     
  9. Ziggy

    Ziggy Moderator
    Staff Member

    Joined:
    Feb 20, 2013
    Messages:
    707
    Likes Received:
    530
    The ramps 5v comes from the Arduino board 5v regulator. So every milliamp of 5v power puts more strain (and heat load) on that Arduino 5v regulator.

    If you prefer 5v for the solenoid, I suggest you use another 5v regulator (like a LM7805 three terminal regulator) with 12v as the source.

    The LM7805's are really simple to use and very cheap on ebay - see diagram 9 (fixed output regulator) in this spec sheet.

    https://www.fairchildsemi.com/datasheets/LM/LM7805.pdf

    You don't really need the capacitors. Just the regulator is fine for most applications.
     
  10. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    I thought the ramps would down convert 12v to 5v for the arduino? Electronics is my weakest point
     
  11. Ziggy

    Ziggy Moderator
    Staff Member

    Joined:
    Feb 20, 2013
    Messages:
    707
    Likes Received:
    530
    Unfortunately the only 5V regulator is on the Arduino Mega board. When LCD displays etc are added this regulator is really working hard.

    Another option to provide a separate source of 5v (at up to 2 Amps) is to use one of these

    http://www.ebay.com.au/itm/DC-DC-LM...Electrical_Test_Equipment&hash=item5d45619bfb

    There are 100's of these on ebay. They are easy to connect (solder in) and the volts output is adjustable.
     
    #111 Ziggy, Nov 23, 2014
    Last edited by a moderator: Nov 24, 2014
    3 people like this.
  12. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,912
    Likes Received:
    7,338
  13. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    Thanks for the help guys. I'll pick up a few step down converters.

    You should see my printer right now. Getting hard to recognize....
     
  14. Galaxius

    Galaxius Well-Known Member

    Joined:
    Jan 18, 2014
    Messages:
    632
    Likes Received:
    342
    Pics
     
  15. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    Not much to look at right now...

    [​IMG]

    Only 2 original plastic parts remain. Thinking of getting an aluminum build plate and redoing the Z idlers...
     
    2 people like this.
  16. SteveC

    SteveC Well-Known Member

    Joined:
    Jun 12, 2013
    Messages:
    894
    Likes Received:
    316
    Mike, Any idea if the cable guide chain will add much noise? I printed a few of them out and started worrying about the noise.
     
  17. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    @donhuevo would be the better person to ask. I don't tend to hear them running but my 24v power supply has a ridiculously loud fan so that drowns out all noise
     
  18. donhuevo

    donhuevo Active Member

    Joined:
    Mar 29, 2014
    Messages:
    138
    Likes Received:
    100
    At least for my purposes under the bed, the noise isn't an issue at all. Moving the bed by hand with the printer powered down, I hear the motor and not the conduit.
     
    5 people like this.
  19. Mike Kelly

    Mike Kelly Volunteer

    Joined:
    Mar 11, 2013
    Messages:
    6,967
    Likes Received:
    2,276
    The shape of things to come...

    [​IMG]
     
  20. Brandon Quimson

    Brandon Quimson New Member

    Joined:
    Oct 20, 2014
    Messages:
    13
    Likes Received:
    0
    can i use it with my current carriage?
     

Share This Page