Welcome! Log In Create A New Profile

Advanced

Auto Bed Leveling Problem

Posted by sarf2k4 
Auto Bed Leveling Problem
September 24, 2015 11:39AM
Hi, I did post this kind of problem before in prusa i3 section but that was long ago and after that I decided to go probeless. Only recently I used the servo based auto bed leveling, I still having the same problem I had on the other post

Currently, the probe offset were set properly on the config.h and here is my probe section settings and my servo sections. My only problem was, marlin seems to register that the nozzle has the same height as the probe does where the z axis at 0, would have my nozzle hanging in the air, I don't know how do I do this to make the nozzle really go nearer to the bed to print

// @section bedlevel

#define AUTO_BED_LEVELING_FEATURE // Delete the comment to enable (remove // at the start of the line)
//#define DEBUG_LEVELING_FEATURE
#define Z_MIN_PROBE_REPEATABILITY_TEST  // If not commented out, Z-Probe Repeatability test will be included if Auto Bed Leveling is Enabled.

#if ENABLED(AUTO_BED_LEVELING_FEATURE)

  // There are 2 different ways to specify probing locations:
  //
  // - "grid" mode
  //   Probe several points in a rectangular grid.
  //   You specify the rectangle and the density of sample points.
  //   This mode is preferred because there are more measurements.
  //
  // - "3-point" mode
  //   Probe 3 arbitrary points on the bed (that aren't colinear)
  //   You specify the XY coordinates of all 3 points.

  // Enable this to sample the bed in a grid (least squares solution).
  // Note: this feature generates 10KB extra code size.
  #define AUTO_BED_LEVELING_GRID

  #if ENABLED(AUTO_BED_LEVELING_GRID)

    #define LEFT_PROBE_BED_POSITION 15
    #define RIGHT_PROBE_BED_POSITION 145
    #define FRONT_PROBE_BED_POSITION 20
    #define BACK_PROBE_BED_POSITION 145

    #define MIN_PROBE_EDGE 10 // The Z probe minimum square sides can be no smaller than this.

    // Set the number of grid points per dimension.
    // You probably don't need more than 3 (squared=9).
    #define AUTO_BED_LEVELING_GRID_POINTS 2

  #else  // !AUTO_BED_LEVELING_GRID

      // Arbitrary points to probe.
      // A simple cross-product is used to estimate the plane of the bed.
      #define ABL_PROBE_PT_1_X 15
      #define ABL_PROBE_PT_1_Y 180
      #define ABL_PROBE_PT_2_X 15
      #define ABL_PROBE_PT_2_Y 20
      #define ABL_PROBE_PT_3_X 170
      #define ABL_PROBE_PT_3_Y 20

  #endif // AUTO_BED_LEVELING_GRID

  // Offsets to the Z probe relative to the nozzle tip.
  // X and Y offsets must be integers.
  #define X_PROBE_OFFSET_FROM_EXTRUDER -46     // Z probe to nozzle X offset: -left  +right
  #define Y_PROBE_OFFSET_FROM_EXTRUDER -14     // Z probe to nozzle Y offset: -front +behind
  #define Z_PROBE_OFFSET_FROM_EXTRUDER -17  // Z probe to nozzle Z offset: -below (always!)

  #define Z_RAISE_BEFORE_HOMING 23       // (in mm) Raise Z axis before homing (G28) for Z probe clearance.
                                        // Be sure you have this distance over your Z_MAX_POS in case.

  #define XY_TRAVEL_SPEED 8000         // X and Y axis travel speed between probes, in mm/min.

  #define Z_RAISE_BEFORE_PROBING 23   // How much the Z axis will be raised before traveling to the first probing point.
  #define Z_RAISE_BETWEEN_PROBINGS 5  // How much the Z axis will be raised when traveling from between next probing points.
  #define Z_RAISE_AFTER_PROBING 15    // How much the Z axis will be raised after the last probing point.

//   #define Z_PROBE_END_SCRIPT "G1 Z10 F12000\nG1 X15 Y330\nG1 Z0.5\nG1 Z10" // These commands will be executed in the end of G29 routine.
                                                                            // Useful to retract a deployable Z probe.

  //#define Z_PROBE_SLED // Turn on if you have a Z probe mounted on a sled like those designed by Charles Bell.
  //#define SLED_DOCKING_OFFSET 5 // The extra distance the X axis must travel to pickup the sled. 0 should be fine but you can push it further if you'd like.


  //If you have enabled the Bed Auto Leveling and are using the same Z Probe for Z Homing,
  //it is highly recommended you let this Z_SAFE_HOMING enabled!!!

  #define Z_SAFE_HOMING   // This feature is meant to avoid Z homing with Z probe outside the bed area.
                          // When defined, it will:
                          // - Allow Z homing only after X and Y homing AND stepper drivers still enabled.
                          // - If stepper drivers timeout, it will need X and Y homing again before Z homing.
                          // - Position the Z probe in a defined XY point before Z Homing when homing all axis (G28).
                          // - Block Z homing only when the Z probe is outside bed area.

  #if ENABLED(Z_SAFE_HOMING)

    #define Z_SAFE_HOMING_X_POINT ((X_MIN_POS + X_MAX_POS) / 2)    // X point for Z homing when homing all axis (G28).
    #define Z_SAFE_HOMING_Y_POINT ((Y_MIN_POS + Y_MAX_POS) / 2)    // Y point for Z homing when homing all axis (G28).

  #endif

  // Support for a dedicated Z probe endstop separate from the Z min endstop.
  // If you would like to use both a Z probe and a Z min endstop together,
  // uncomment #define Z_MIN_PROBE_ENDSTOP and read the instructions below.
  // If you still want to use the Z min endstop for homing, disable Z_SAFE_HOMING above.
  // Example: To park the head outside the bed area when homing with G28.
  //
  // WARNING:
  // The Z min endstop will need to set properly as it would without a Z probe
  // to prevent head crashes and premature stopping during a print.
  //
  // To use a separate Z probe endstop, you must have a Z_MIN_PROBE_PIN
  // defined in the pins_XXXXX.h file for your control board.
  // If you are using a servo based Z probe, you will need to enable NUM_SERVOS,
  // Z_ENDSTOP_SERVO_NR and SERVO_ENDSTOP_ANGLES in the R/C SERVO support below.
  // RAMPS 1.3/1.4 boards may be able to use the 5V, Ground and the D32 pin
  // in the Aux 4 section of the RAMPS board. Use 5V for powered sensors,
  // otherwise connect to ground and D32 for normally closed configuration
  // and 5V and D32 for normally open configurations.
  // Normally closed configuration is advised and assumed.
  // The D32 pin in Aux 4 on RAMPS maps to the Arduino D32 pin.
  // Z_MIN_PROBE_PIN is setting the pin to use on the Arduino.
  // Since the D32 pin on the RAMPS maps to D32 on Arduino, this works.
  // D32 is currently selected in the RAMPS 1.3/1.4 pin file.
  // All other boards will need changes to the respective pins_XXXXX.h file./*********************************************************************\
* R/C SERVO support
* Sponsored by TrinityLabs, Reworked by codexmas
**********************************************************************/

// Number of servos
//
// If you select a configuration below, this will receive a default value and does not need to be set manually
// set it manually if you have more servos than extruders and wish to manually control some
// leaving it undefined or defining as 0 will disable the servo subsystem
// If unsure, leave commented / disabled
//
#define NUM_SERVOS 1 // Servo index starts with 0 for M280 command

// Servo Endstops
//
// This allows for servo actuated endstops, primary usage is for the Z Axis to eliminate calibration or bed height changes.
// Use M851 to set the Z probe vertical offset from the nozzle. Store that setting with M500.
//
// #define X_ENDSTOP_SERVO_NR 1
// #define Y_ENDSTOP_SERVO_NR 2
#define Z_ENDSTOP_SERVO_NR 0
#define SERVO_ENDSTOP_ANGLES {{0,0}, {0,0}, {13,90}} // X,Y,Z Axis Extend and Retract angles

// Servo deactivation
//
// With this option servos are powered only during movement, then turned off to prevent jitter.
 #define DEACTIVATE_SERVOS_AFTER_MOVE

#if ENABLED(DEACTIVATE_SERVOS_AFTER_MOVE)
  // Delay (in microseconds) before turning the servo off. This depends on the servo speed.
  // 300ms is a good value but you can try less delay.
  // If the servo can't reach the requested position, increase it.
  #define SERVO_DEACTIVATION_DELAY 1000
#endif
  //
  // WARNING:
  // Setting the wrong pin may have unexpected and potentially disastrous outcomes.
  // Use with caution and do your homework.
  //
  //#define Z_MIN_PROBE_ENDSTOP

#endif // AUTO_BED_LEVELING_FEATURE


In addition, I tried adding G92 z17 right after the G29 on one of the 20mm cube test for this by editing the gcode using notepad++, the printer doesn't seem to move anymore unless I cut the power. What's more, sometimes the printer suddenly resets/reboots itself after doing the initial homing using the servo, before g29 procedure

Anyone able to explain to me these 2 problems; z axis uses the probe position as its 0 instead of physically 17mm above the bed, printer stucks when I added g92 z17 on gcode and lastly the printer rebooted itself after g28 before g29.

Any help would be greatly appreciated but the most important would be the bed leveling problem on z axis, thank you in advance

Forgot to mention, I am using ramps 1.4, arduino mega 2560, 2004a lcd panel, tower pro sg9 series servo 9g type, rest are geeetech prusa i3b hardware
Re: Auto Bed Leveling Problem
September 25, 2015 04:25PM
have you try adding gcode g1 z.1 after g29?

that brings nozzle to 0.1mm where the measured is, may not look right but it is actually correct when it prints, you might have to try a few times to get the distance bang on when it actually prints, on my setup for some funny reason, it looks to be 1mm off the bed while waiting for hotend to heat up but once it starts to print, its perfect
Re: Auto Bed Leveling Problem
September 25, 2015 04:27PM
another note, add the gcode in your slicer before you sllice it, then you dont have to edit them
Re: Auto Bed Leveling Problem
September 26, 2015 05:35AM
How is this set?
#define min_software_endstops true // If true, axis won't move to coordinates less than HOME_POS.

Home pos would be the z height when the z probe was triggered. If you try to move it below it with this enabled either nothing happens or some kind of safety feature locks up the printer. Try setting this to false.

If you've got eeprom set to true, I can highly recommend using the lcd control motion menu to set the z offset. The higher the offset the closer it will be to the bed. It's much easier to set it here than in firmware or gcode. It will work the same no matter what host you use or what slicer.
Re: Auto Bed Leveling Problem
September 26, 2015 07:44AM
I got the probe z offset problem solved by the way, but my current issues is that I need to supply my chinese arduino (ch340 ftdi) with usb power to start print. Whenever the printer finished probing g29, it moves to the center of the bed, it just stuck there and doing nothing where it supposed to go to z 0.00 to lay down the plastic. In overall, I need the chinese arduino powered through usb for it to continue print after g29 else it will stuck doing nothing. But after it started laying down the plastic, I can just disconnect the usb. I only tried connecting it to the laptop.

It seems like the arduino didn't have much power or something, Can anyone tell me what might be the problem?

My only solution is to add another wire from ramps input using a voltage divider plugged directly to the arduino black input there, trimming it down to 5v. I'm not sure if it's okay to supply another 12v to arduino though
Re: Auto Bed Leveling Problem
September 26, 2015 08:09AM
Would mind sharing the solution for reference for others with the same problem? Thanks!

As for the needing to connect to usb before printing can start, I haven't seen that one before. I assume you're printing from sd? Does the control on the display still respond to input?
Re: Auto Bed Leveling Problem
September 26, 2015 08:19AM
I will make a video on the solution to this, hopefully by this week

I am using from sd card, although after g29 are done, the head hovers on top of the bed by about 20mm, and supposed to go down to z at 0mm after going to the middle of the bed, but without connecting the usb, it just sits there. There is some response when controlling the knob, but somewhat slower response. I tried waiting for about 10-15 seconds but the printer stays like that. I suspect lack of current or something
Re: Auto Bed Leveling Problem
September 26, 2015 10:46AM
After g29 my head goes to center and stays there until the bed heat is right and extruder temp is right. I get the message bed is heating then heating for the extruder. It then begins to print after it meets the firmware settings. This is controlled in firmware. Sometimes I get a M105. Press the button and it starts printing. This is probally due to stopping the print and then continue.
Re: Auto Bed Leveling Problem
September 26, 2015 10:50AM
I didn't see any problem why supplying power through usb would make the printer doing its job right away rather than not. When not connected after it has stopped there, I tried navigating but the response somewhat laggy

I think I didn't provide marlin info, I use marlin dev 1.1.0, downloaded right around a month ago

Edited 1 time(s). Last edit at 09/26/2015 10:51AM by sarf2k4.
Re: Auto Bed Leveling Problem
September 27, 2015 08:12PM
Here is the video [youtu.be], I also made changes to the list of gcodes in reprap wiki adding that missing command
Re: Auto Bed Leveling Problem
October 28, 2015 11:05AM
Hi, my name is travis,

I had that same issue when activating a servo on by 3d printher. I solved it by supplying the positive and negative connection to the servo with it's own power supply. Servos use quite a bit of power i used a 6v 3a power supply and connected straight to servo with signal wire connected to pin 11 of my ramps 1.4 and I have not had any problems.
Re: Auto Bed Leveling Problem
November 02, 2015 09:42PM
Quote
tjmorrow
Hi, my name is travis,

I had that same issue when activating a servo on by 3d printher. I solved it by supplying the positive and negative connection to the servo with it's own power supply. Servos use quite a bit of power i used a 6v 3a power supply and connected straight to servo with signal wire connected to pin 11 of my ramps 1.4 and I have not had any problems.

Currently I have nozzle fan pinout soldered and connected to my e3d v6 hotend fan so it will be on constantly, the servo connected to the servo respective pins, now that you're saying you used another psu, I might just draw current from the power input terminal of ramps 1.4 and make a voltage divider this way, thank you for the idea.

Also, did your printer need another extra power like using usb as external power input or something in order for it to start print?
Re: Auto Bed Leveling Problem
November 02, 2015 10:38PM
These days,I had been working on auto bed leveling.And I found that the height between the nozzle and the bed always change when it printing the first layer.Is it the problem of the trembling servo when bed leveling?Anyone got answer?
Re: Auto Bed Leveling Problem
November 04, 2015 10:57PM
Quote
GeorgeFu
These days,I had been working on auto bed leveling.And I found that the height between the nozzle and the bed always change when it printing the first layer.Is it the problem of the trembling servo when bed leveling?Anyone got answer?

Is your servo jerking/trembling when it goes into position? If it does, you should use the servo power down feature. As for me, it will be slow by adding delay of around 750-1000ms on each servo movement. I also got a feeling that the bed elevation randomized on each prints
Sorry, only registered users may post in this forum.

Click here to login