Welcome to Our Community

Some features disabled for guests. Register Today.

Smoothieboard with DQ542MA

Discussion in 'Controller Boards' started by yarnairb, Mar 4, 2017.

  1. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    Hi Everyone,
    I'm a newbie who just ordered a bunch of parts to get my feet wet and gain some experience with the build-your-own world. I got the smoothie board and a couple of the linear motion kits to play around with. I got the smoothie with the onboard driver to work with my NEMA 17 but I'm having issues with the external driver and the NEMA 23. I soldered on the pin header and wired everything for the common anode, open-drain configuration with the 5v coming off of one of the limit switch pins. I have metered everything for continuity and voltage but get an alarm LED on the driver as soon as I power everything up. I also set the config file to the open-drain mode with appended 'o'. When I power up just the 24v and leave smoothie off I get a green light on the driver and the stepper locks up tight. So far so good. But once I power up smoothie I lose the green light and the alarm comes on. I've reviewed this a dozen times and lost a bunch of hair so would really appreciate if anyone has any tips or clues. Thanks!
     
  2. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    BTW I should add that I set grbl mode so I could use bCNC and I'm running the cnc firmware.
     
  3. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Builder Resident Builder

    Joined:
    Mar 1, 2017
    Messages:
    14,837
    Likes Received:
    4,275
    Hi @yarnairb

    1) In open collector mode, you also need to invert the pin by adding "!"
    2) As a quick test, the DQ542MA does work OK with 3.3v signals (ie not open collector mode) if the wiring is nice and short. (I wouldnt recommend it as the final installation, but this would afford you an opportunity to test your setup it a little better, without the complication of open collector. Can always go there later - lets just get it working first)
    3) The alarm coming on as soon as you apply power, to me, usually indicates a wiring issue.
    3.1 Using (2) above, wire GND (from Smoothieboard) to DIR- and PUL- on the driver
    3.2 Wire P2.0 (STP1) to PUL+ on the driver
    3.3 Wire P0.5 (DIR1) to DIR+ on the driver
    3.4 Leave Enable floating. On the DQ542MA Enable is inverted (ie 0v = enabled, 5v = disabled) - skip the EN wiring for now as a first test as with nothing connected, the motor should be enabled
    3.5 Check your Smoothieware config to make sure P2.0 and P0.5 is alpha_step_pin, and alpha_dir_pin respectively
    3.6 Test again and post here how it went


    It would be helpful if you post pictures of your wiring for me to check, as well as a dump of your smoothie config file :) - makes troubleshooting just a little easier than working in the dark




     
    yarnairb, Paul Stoller and Mark Carew like this.
  4. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    Peter,
    Thanks for the help! I wired it up as you described (I hope) and changed my settings to the following:
    I have the alpha channel configured for the NEMA17 which is currently disconnected.

    beta_step_pin 2.1 # Pin for beta stepper step signal
    beta_dir_pin 0.11 # Pin for beta stepper direction
    beta_en_pin 0.10! # Pin for beta enable
    beta_current 1.5 # Y stepper motor current
    beta_max_rate 3000.0 # mm/min
    beta_steps_per_mm 800
    grbl_mode true

    I was able to get the board to power up without a fault on the driver but got no motion. I then connected enable from the board to ENB - and can now get slight movements of the axis. For example G91G0Y1 moves the stepper slightly. But if I try a larger move like G91G0Y10 I get another slight move but nothing close to 10 times the first one. It also makes a different high pitched sound. I'm sure I probably jumped the gun and did something wrong with my ENB wiring but here are the pics. The white wire in the block is the jumper from DIR - to PUL -

    I also posted the DIP switch settings which according to the guide printed on the driver are set to 2.37A and 800 on the pulse/rev. I'm suspicious of that 800 value though. Please excuse my crazy colored wiring. I used what I had.

    20170306_112519.jpg 20170306_112535.jpg 20170306_112552.jpg
     
  5. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Builder Resident Builder

    Joined:
    Mar 1, 2017
    Messages:
    14,837
    Likes Received:
    4,275
    Dip Switch: Half Current

    SW4 is still in the off position. in that position it is "half current" - that switch provides you with a little more fine control (for example, if you need 1.5A, there is no preset directly. But you can set it to 3A, + half current = 1.5A )
    So in your example, you are now set to 2.37A / 2 = 1.185A. Which may not be enough for a big nema23

    The step DIP switches can be confusing, I agree. Remember that they ASSUME 200steps/rotation steppers (but you do get different steppers. OpenBuilds stock are all 200 though so if you bought from OpenBuilds you can safely work off the table printed on the driver)

    1/4 microstep mean 4 pulses per step * 200 steps = 800 steps to make one rotation

    Default smoothie configs are for 1/16th drivers, so maybe easier to bring that closer in line. Set SW5=ON, SW6=ON, SW7=OFF, SW8=ON (3200 steps per rotation - aka 1/16th microstepping). In 1/4 your acceleration may be too high (4x too high?) and thus not get the motor spinning. Telltake sign is a high pitched noise from the motor

    On your current wiring, the ENBL+ isnt hooked up to anything. Those drivers have optocouplers, and none of the terminals are shared. So you have to make sure that you hook up + and - signal on both (take your gnd jumper over to ENBL-, move the red wire to ENBL+, and remove the invert "1" from the enable pin in the smoothie config.

    Holding thumbs, I think we are getting close :)
     
    #5 Peter Van Der Walt, Mar 6, 2017
    Last edited: Mar 6, 2017
    yarnairb likes this.
  6. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Builder Resident Builder

    Joined:
    Mar 1, 2017
    Messages:
    14,837
    Likes Received:
    4,275
    As a sidenote: Awesome pictures! Makes checking out what it could be a pleasure! Thanks!
     
  7. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    Glad you like the pics ;^)

    OK I flipped the switches, rewired and changed the config per your note. Now I'm back to getting an alarm when I power up the smoothie....argggh.

    beta_step_pin 2.1 # Pin for beta stepper step signal
    beta_dir_pin 0.11 # Pin for beta stepper direction
    beta_en_pin 0.10 # Pin for beta enable
    beta_current 1.5 # Y stepper motor current
    beta_max_rate 3000.0 # mm/min

    BTW on this page cnc-mill-guide [Smoothieware]
    It says "Smoothieboard V1.1 always divides steps into 32 microsteps. (16 for older smoothieboards)."
    Mine is a 1.1 so does that mean I should set the driver to pulse/rev 6400?
    Also, is the beta_current in the config used since I'm connecting an external driver? I just left that at the default but I did set it to 1.68 for my NEMA 17. Which by the way worked perfectly.

    Thanks!

    20170306_112519.jpg 20170306_140148.jpg
     
  8. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    One more thing. I measured the voltage across the +- pins on the driver while idle (and with the driver powered off) and got around 2.8v on the ENBL pins and zero for the other two.
     
  9. openhardwarecoza

    openhardwarecoza Journeyman
    Staff Member Builder

    Joined:
    Aug 9, 2014
    Messages:
    134
    Likes Received:
    138
    IWe'll we'd have to fix the alarm condition first... But yeah, if its needs to be 1/32 then it would help (at least with default configs it just rules out one variable)

    The current setting in smoothie config is not applied when using external drivers (external driver has dip switches. Onboard drivers can have their VREF set from the onboard softpots)

    The DQ542MA manual says Alarm is only dealing with input power. Measure voltage in, and maybe post pics of the power setup?

    Motor is from where? OpenBuilds?
     
  10. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    Peter,

    First, your patience and helpfulness is making my day.

    I decided to be brave, trust the docs at smoothieware.org and set the driver to pulse/rev 6400. Since it was faulting with ENB - connected I removed the jumper, crossed my fingers (and held my thumbs ;^) then powered up. Woo hoo! I got nice clean travel with long moves of 500mm and no odd noises.
    I'm assuming that while this works with my short cable I will still want to get the 5v open-drain stuff to work so any other advice you have to offer would be VERY much appreciated.

    Thanks
     
  11. openhardwarecoza

    openhardwarecoza Journeyman
    Staff Member Builder

    Joined:
    Aug 9, 2014
    Messages:
    134
    Likes Received:
    138
    Testing with my DQ542 here on the bench, I can reliably trigger Alarm LED by powering it from 12-16v. As soon as I adjust my PSU to 18v before powering on, no alarm. You mention 24v in your first post, but are you sure its a 24v PSU? Sufficient current?
     
  12. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    @openhardwarecoza

    Thanks for chiming in! Everything is from OpenBuilds. I got myself a sampler to familiarize myself with the offering and get my feet wet with the DIY CNC scene.
     
  13. openhardwarecoza

    openhardwarecoza Journeyman
    Staff Member Builder

    Joined:
    Aug 9, 2014
    Messages:
    134
    Likes Received:
    138
  14. openhardwarecoza

    openhardwarecoza Journeyman
    Staff Member Builder

    Joined:
    Aug 9, 2014
    Messages:
    134
    Likes Received:
    138
    Glad you are running. Now you can test the open collector later again. For initial test, unplug enable.
     
  15. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    24v on the money at the driver. Could the alarm be for the fact that we're trying to troubleshoot with the 3.3v from the smoothieboard which is actually only 2.88v measured at the driver?

    So just to double check.
    No wires on enable
    beta_step_pin 2.1o # Pin for beta stepper step signal
    beta_dir_pin 0.11o # Pin for beta stepper direction
    beta_en_pin 0.10o # Pin for beta enable
    beta_current 1.5 # Y stepper motor current
    beta_max_rate 3000.0 # mm/min

    Do I also need to invert them? And back to the reversed wiring described here general-appendixes [Smoothieware]

    Please forgive my ignorance and my hesitation. I don't want to burn anything up ;^)
     
  16. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    Progress is being made. I ran the 5v from the end stop pin to PUL+ then jumped that to DIR+. Smoothieboard STP and DIR go to the PUL- & DIR- respectively. Nothing wired to ENBL.
    beta_step_pin 2.1o # Pin for beta stepper step signal
    beta_dir_pin 0.11o # Pin for beta stepper direction
    beta_en_pin 0.10o # Pin for beta enable
    beta_current 1.5 # Y stepper motor current
    beta_max_rate 3000.0 # mm/min

    No alarms and good movement as before. At idle get ~4v across PUL and .25v across DIR. During a move I get ~4v across DIR and ~3.65 across PUL.

    Now here's my ignorant newbie question: What does ENB do since this all seems to work without it?

    The light green wire coming from the 5v pin is the same wire on PUL+ in these pictures even though it looks different 20170306_140148.jpg 20170306_154512.jpg
     
  17. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Builder Resident Builder

    Joined:
    Mar 1, 2017
    Messages:
    14,837
    Likes Received:
    4,275
    Think of ENBL as a "disable" - when you apply 5v between the two pins, it "disables" the driver.

    It defaults to enabled to allow for easier wiring. But its nice to go into CNCweb and hit the 'motors off button' when you need to move a carriage out of the way by hand like when you are loading material. Therefore, worth wiring up. Sending M84 / clicking Motors off in hosts that support it, will definately help
     
  18. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    So I jump my +5v to the ENBL + and EN2 on the smoothie to ENB- ? Is this then the pin that I invert as well?

    beta_en_pin 0.10o! # Pin for beta enable
     
  19. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    I tried what I described with the ! and it alarms as soon as I power up smoothie. I took it out and it comes up green but as soon as I issue a move it alarms again. When I send an M18 (motorsOff) the alarm clears but I still can't make any moves without alarming again. Also, the motor is still engaged and I can't freehand the stepper.
     
  20. yarnairb

    yarnairb New
    Builder

    Joined:
    Feb 14, 2017
    Messages:
    13
    Likes Received:
    0
    I hope I'm not just rambling, but wanted to share what I'm finding out. This was pure SWAGing on my part but what I did was connect GND to ENB- and and EN2 to ENB+ with no modifiers in the config i.e no 5v just the 3.3v from smoothie.

    beta_en_pin 0.10

    Now what happens is my moves work just fine with no alarms. When I issue an M18 the motor stops, turns freely by hand and the alarm light comes on. When I issue another move the alarm goes off, the green light comes back on and the axis moves as expected.

    So the question is: do I need to worry about the alarm light being on? Is there something bad going on despite things seemingly working as expected?
     
  21. Peter Van Der Walt

    Peter Van Der Walt OpenBuilds Team
    Staff Member Moderator Builder Resident Builder

    Joined:
    Mar 1, 2017
    Messages:
    14,837
    Likes Received:
    4,275
    If I read correctly, "alarm" comes on when you have the driver disabled in other words? In that case it is correct, a disabled driver is an "alarm" condition, as it wont move if disabled. Which is fine, as when you issue a move, Smoothie will enable the driver, and away you go
     
    yarnairb likes this.
  22. magpern

    magpern New
    Builder

    Joined:
    Oct 14, 2017
    Messages:
    11
    Likes Received:
    0
    Hi yarnairb,
    I am trying to accomplish the same thing as you, and I seem to have the exact same problem as you. Did your problem just resolve itself somehow? Can you share your smoothieboard config?

    I have the DQ542MA and Nema23 motors. The DQ52MA dipswitches are set to 3amps, switch4 is ON, and stepping 6400
    I have wired the them for open drain like the smoothieboard manual suggests, with +5V from endstops to all + terminals on DQ542MA and the step/dir/enable from the board to the - terminals on the driver.

    In the config I have set all pins to open drain and the enable pin to open drain and inverted.

    I have the 57BYGH627 nema23 motors and 36V powersupply to the drivers, smootieboard (or MKS SBASE as it is) runs on 12V.

    When I power up the board, I get all red leds on the drivers. If I try and make the motors move (through bCNC) the leds turn green and a motors to a jerking noice, without moving. Then there is just a hizzing sound from the motors.
    They don't move. If I issue a M18, the motors are released and leds go back to red. Smoothie is configured to run bCNC as noted in the smoothie documentation.

    I have tried to disconnect the enable pins on the drivers, get the same thing, except that leds are green all the time and motors make hizzing sound all the time.

    I have no idea what to do? Any suggestions?
    /Magnus
     
  23. magpern

    magpern New
    Builder

    Joined:
    Oct 14, 2017
    Messages:
    11
    Likes Received:
    0
    Never mind... found the problem... I had the STEP and DIR pin mixed up. After switch I got nice movement
     
  24. Lasersc

    Lasersc New
    Builder

    Joined:
    Feb 2, 2018
    Messages:
    28
    Likes Received:
    23
    I know this post is way late, but I am headed down the same path with the same equipment. Could I impose on you to send me or post up a picture of your final wiring at the driver and if at all possible at the Smoothieboard. I have read so many post and to be honest with my lack of knowledge I have become confused as to what works and what doesn't. Thank you for any help you can give.
     
    magpern likes this.
  25. magpern

    magpern New
    Builder

    Joined:
    Oct 14, 2017
    Messages:
    11
    Likes Received:
    0
    Sure I can. I think I have everything set up, but I use bCNC and can just not figure out how to set every thing up. Movement is correct, but it homes to an other corner then the one bCNC think is the corner... SInce my machine has not cut anything yet, I cannot say every wiring is correct. But I just made a post in facebook group "DIY CNC machines" for some help. Join me there and I can share more pictures, if that is what you need? Magnus is my name and last name starts with a P.. you'll find me
     
  26. Lasersc

    Lasersc New
    Builder

    Joined:
    Feb 2, 2018
    Messages:
    28
    Likes Received:
    23
    Ok I am not a avid Facebook user, but I did go to the DIY CNC machines page but couldn’t find you there. I am desperately searching for someone going down the same road I am headed. Here is my drawer that I am putting together to house my electronics and a picture of my build thus far.
     

    Attached Files:

  27. magpern

    magpern New
    Builder

    Joined:
    Oct 14, 2017
    Messages:
    11
    Likes Received:
    0
    Oh, I'm there (Log into Facebook | Facebook) anyway.
    Here are a few pictures of my ratsnest. I'm not sure how it would help. But maybe a start.
    I wired the DQ542 according to one of the pictures (one.png), but I also wired the ENABLE to ENL on smoothieboard. In smoothie settings the pins are open-drain (an o at the end of the pin number).
     

    Attached Files:

  28. Lasersc

    Lasersc New
    Builder

    Joined:
    Feb 2, 2018
    Messages:
    28
    Likes Received:
    23
    Wonderful pictures! Thank you so much. I do have a question or two. I noticed in the drawn wiring there is not a wire in enbl- but looks like a green wire is there in actual wiring. Is that a ground board. Also I see you have 2 steppers on Y axis (as I do as well) are the drives to those steppers slaved together and ran off a single connector from the smoothieboard. Thank you again.
     
  29. magpern

    magpern New
    Builder

    Joined:
    Oct 14, 2017
    Messages:
    11
    Likes Received:
    0
    Yes, I have connected the enable-pin to the the connector on the smoothieboard, and inverted it in the settings file (I can upload it later, I'm at work now). I feed the drivers with +5V from one of the limit switch connectors (picture 2018-04-24 07.57.39.jpg), so all connections get active when smoothie-pins get low. (It is a little LED inside the drivers that turn on when plus and minus connect).

    I have two drivers for Y, correct, they get the same signal from the smoothieboard (picture
    2018-04-24 07.57.26.jpg), but I have just swapped the cables to the steppers. An advanced way is to have a signal inverter on the DIR pin on one of them, but I did not have those and switchinig the cables on the stepper worked just fine.

    Glad I can help... "The blind leading the blind"
     
  30. Ernst-Jan Lusink

    Builder

    Joined:
    Oct 10, 2018
    Messages:
    2
    Likes Received:
    1
    Sharing, this is what right now works for me:
    smoothie-DQ542MA.jpg

    Thx previous posts for helping me sort it.

    Now working on the rest of my config for suitable speeds. NEMA 23 57BYGH627 on a workbee like.
     
    Renaud Bourassa likes this.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice