DIY Inexpensive Bed Leveling Sensor (Part 1)

Sdílet
Vložit
  • čas přidán 15. 04. 2019
  • 🛒⚙️ You can get the items you need here: kit.co/a_make_designs/ender-3
    If you want to test your electronics skills with an inexpensive DIY bed leveling sensor, you have come to the right place!
    The second part of the video with the explanation on how to prepare Marlin Firmware, set the slicer and configure the printer is here: • Ender 3: DIY inexpensi...
    The boooooring explanation:
    The core of the system is an optocoupler that is a diode coupled with a light activated transistor.
    When the diode is powered up, it will in turn open the transistor gate that will act as a switch.
    The diode of the optocoupler has a minimum activation current of 5mA, 20mA is common. The power transmitted depends on the current through the diode, but the absorption from the digital input of the board is so small that any current should do the trick.
    I decided to use a little less current to stay on the safe side since I don’t know the previous history of my opto that could be already worn out.
    Since the 24V comes from the power supply of the printer, any resistance up to 4.8kOhm should work. I got 12mA from the 2k I’m using.
    Please note that during the first few millimeters of print the sensor will still be on so there will be current dissipated through the resistor.
    NOTE before starting: this modification requires fidgeting with the electronics of the control board. You can fry it, trust me, I did. It also requires opening the connection box of the power supply where deadly voltage is present. DISCONNECT your mains plug from the printer before starting.
    If you are not comfortable, do your research, post a comment before working with this mod.
    DO THIS AT YOUR OWN RISK I’m not going to accept any responsibility if you do something wrong and you damage your printer or hurt yourself.
    BARE MINIMUM TOOLS AND MATERIALS:
    - basic soldering skills, a soldering iron
    - a bootloader-enabled printer. We need to make firmware changes to activate the bed leveling
    - Arduino IDE software and a Marlin branch of the firmware
    - any resistor between 1k and 4k Ohm
    - one optocoupler (also known as photocoupler or optoisolator)
    - one NPN normally open sensor
    If you want to support my work with a small donation you can do it through PayPal here:
    🍩 paypal.me/amakedesigns
    🔗 LINKS:
    🛒 My recommended items: kit.co/a_make_designs
    💾 Thingiverse: www.thingiverse.com/A-make-de...
    🐦Twitter: / a_makedesigns
    The bracket on Thingiverse: www.thingiverse.com/thing:336...
    The Breadboard I used: hobbyking.com/en_us/diy-pcb-b...
    I used a 4 pin optocoupler FL817. There are plenty of sources. Mine was salvaged from a scrap board I had lying around.
  • Věda a technologie

Komentáře • 53

  • @ThermaLTake94
    @ThermaLTake94 Před 4 lety +2

    You killed it man,awesome idea and implementation.The only problem I faced was the inverted X direction that was mentioned in a previous comment and the most significant for anyone that tries it is the direction of the dupont Z connector is not the same to plug it just like that cause of the transistor of the optocoupler,it didn't work the first thousand times tried to home the Z axis and I slapped the nozzle to the bed many times before o figure it out that it was the position of the dupont connector was wrong,I flipped it and it was correct. I wonder why you bridged the dupont connectors on the board,anyway that's so little in front of the solution you have to us to add this perfect feature to our printers.Well done greetings from Greece

  • @MichelBricole
    @MichelBricole Před 5 lety +1

    I just discovered your channel, keep doing your videos !
    You are awesome, thanks ;)

  • @JasonViloria
    @JasonViloria Před 3 lety +2

    How is this circtuit working? The cathode of the optocoupler diode is connected to the vcc? Shouldn't it be the other way around?

  • @janzugic6798
    @janzugic6798 Před 3 lety +1

    best video about diy proximity auto bed leveling!

    • @AMakeDesigns
      @AMakeDesigns  Před 3 lety +1

      Thanks mate!

    • @janzugic6798
      @janzugic6798 Před 3 lety

      @@AMakeDesigns im having trouble setting it up as im not as experienced as you.
      if i replace the 24v with 12v, would this work? i use a LJ18A3-8-Z/BX sensor imgur.com/a/9r9zSU9

  • @grafzahl7878
    @grafzahl7878 Před 5 lety +1

    Great video, thanks a lot and please go on like this! Just a few questions: The wiring is not entirely clear to me. According to your schematics the output from the FL817C is connected to four different pins. Port S and Port G likely refer to the z-min pins (signal and ground) on the MKS GEN L. This makes sense to me, however, what is meant with "Board Z-Stop" back/front pin???
    The 1k - 2k resistor is to limit the current through the diode I guess? Assuming we're on 24 volts and the current should be 20mA a 1.2k resistor would be the correct value, right?
    Another question: You used a NO sensor and adapted the firmware accordingly. Woudn't it make more sense to go with a NC version to prevent a the head crashing into the bed in case of sensor failure? Last question: What do you recommend for positioning the sensor? Somewhere else I read something like 1 mm above the nozzle which seems a rather tight to me.

    • @AMakeDesigns
      @AMakeDesigns  Před 5 lety +1

      Welcome!
      The wiring refers to the original board, front and back because they are the correct one in that case. I do not remember which is high and which is low, but I'm sure you are expert enough to find out with a voltmeter. The other two pins are the connectors of the small board of the Z-stop switch for the NO contacts to wire the mechanical switch in parallel to the sensor for extra safety.
      You are right for the resistor. I opted for 2k because I don't know the "wear" state of the scavenged diode and I thought limiting the current more would have been safer (not sure if it's a right assumption, I'm an electronics DIYer). The limit for activation should be 5mA so more than enough nd you do not need to transfer power to the board.
      If you use a NC it will stay ON for most of the print. My first sensor broke and it happened to be failsafe due to the way the internal electronics are designed I suppose. The LED was still triggering, but the output was always on. I still have to "dissect" it to understand what went wrong :-)
      Last question: the answer is in the part 2 of the video! :-) czcams.com/video/l3O9CPr_U-E/video.html

  • @torqu3d451
    @torqu3d451 Před 4 lety +5

    Hey mate! I was doing almost the same project to my ender. So I use your schematics and compare it to mine. I found that to my knowledge, you put the 1 and 2 numbers the incorrect way. I think 1 is top left, 2 bottom left, 3 right bottom and 4 at the top.
    Anyways, this was super helpful. I followed your videos and I made my own little pcb on a diy cnc and everything worked like a charm. I could send you some pictures if you want.
    Thanks and I'll stay around. Cheers from Argentina!

    • @deepa12345611
      @deepa12345611 Před 4 lety +2

      You are right. In the diagram, the opto LEDs are reverse biased. Also the NPN transistor out of the opto is reverse connected too..@A-Make Designs : Wonderful explanation brother.. I was looking forward to upgrade my ender 3 to add ABL with a cost effective solution and your video explains exactly what I wanted to do. Thanks a lot!

    • @Abha-com
      @Abha-com Před 3 lety +2

      @@deepa12345611 Hi, are you able to make this. Is it working for ur ender 3. I also have one and having so much bed levelling issues

    • @deepa12345611
      @deepa12345611 Před 3 lety

      @@Abha-com To be frank, I actually had set up an auto bed leveling feature on my Ender3. But there was inevitable adhesion and warping issues, even with PETG printing. Here is what I did. I carefully measured the warping on my heated bed. Tried to bend it back by applying some pressure after removing it from the printer. The remaining warpage was compensated for by adding aluminium tapes. After that, I got rid of the ABL and modified the Marlin back to disable ABL and to use the stock Z limit switch. Now I don't face any bad bed leveling issues anymore.

    • @Abha-com
      @Abha-com Před 3 lety

      @@deepa12345611i am using a glass bed and whenever i remove prints, the bed levelling is messed up. So for every print i have to bed level manually. I dont know what to do. Auto Bed levelling is expensive. Shud i go for bed levelling solution or change the bed springs & tighten them or remove glass bed while removing prints and put it back?

    • @deepa12345611
      @deepa12345611 Před 3 lety +1

      @@Abha-com you can use G29 Gcode after G28 at the starting Gcode settings of your slicer software. This will cause ABL before every print. However, I am a bit against the concept of ABL as while it compensates for the warpage in bed, it is actually causing layers to be non planar. This can cause warping of bigger prints. The ideal way is to make your bed as planar as possible and using regular printing without ABL. I don't use ABL anymore. I compensated the warpage in bed using aluminium sticker and used the regular bed that came with the ender 3. Prints are now good. (I use only PETG as ABS is too prone to warping and PLA is too weak for my purpose)

  • @rajangohil832
    @rajangohil832 Před 4 lety +1

    Nice tutorial bro . The perfect one.
    I implemented whole.
    But need one modification, if i want to connect the mechanical switch and inductive sensor both to the same port. I tried connecting parallel to the opto coupler out. But no success .. do you have any solution?

    • @AMakeDesigns
      @AMakeDesigns  Před 4 lety

      You have to parallel the branch after the opto to short the two board pins for the Z endstop. Should work like that

  • @meltonpieman959
    @meltonpieman959 Před 4 lety +1

    Congratulations on a great pair of videos. I have a BLTouch 3.0 and it is already erratic on my Ender 3 Pro. I have ordered an SVR mini 3e 32 bit board and I see that the BLtouch is almost unusable with that. Therefore, I thought about the EZABL - but with taxes it starts to get expensive in the UK. So I thought I might try to build one myself and then I found your videos ..... great a guide to the way forward. Would it be possible to publish a still picture of you built circuit board (top and bottom surfaces) - trying to extract a still from the video is hard to get it right.
    Regards David

    • @AMakeDesigns
      @AMakeDesigns  Před 4 lety

      I will do my best to do it when I can!

    • @meltonpieman959
      @meltonpieman959 Před 4 lety

      Great, I know that doing that will take some time - so thanks when you can.

    • @AMakeDesigns
      @AMakeDesigns  Před 4 lety

      Hey mate! I posted the pictures on Twitter. Apparently can't post them here on CZcams. I hope it works for you!
      twitter.com/a_makedesigns/status/1174760863947001856?s=21

  • @mehmetcanuzulmez7418
    @mehmetcanuzulmez7418 Před rokem

    Can EL817 be used insted of FL817?

  • @xxiinsanexx
    @xxiinsanexx Před 4 lety

    what type of components should i use if i want to use a higher frequency ? like a 600hz sensor?

  • @sinkysg
    @sinkysg Před 3 lety

    Do you think a AQY272 would work for this function?

    • @AMakeDesigns
      @AMakeDesigns  Před 3 lety +1

      It might work, just make sure the voltage will not leak in the board. I'm an electronics amateur, make sure you don't fry the board!

  • @plazmax
    @plazmax Před 5 lety +1

    Gj i think, u ll try 100hz 18mm Capacitive Sensor and add circuit reverse voltage protrction ill do forcu when have time and send u ll mail, love ur works thank you

  • @zigajamnik
    @zigajamnik Před 4 lety

    Hi, os this method the same if I use capactive sensor?

    • @AMakeDesigns
      @AMakeDesigns  Před 4 lety

      I think it should work the same way as long as the wiring spec is the same

  • @franzhelge7417
    @franzhelge7417 Před 4 lety +3

    2:30 Great Video, can you please send me a link to download the Firmware for Creality Ender. I appreciate that

    • @AMakeDesigns
      @AMakeDesigns  Před 4 lety +1

      Look in the video description. There is a link to a video explaining where to find it and how to flash it.

  • @Felipe-is3xi
    @Felipe-is3xi Před 4 lety

    I cant find the fl817c chip but i find the pc817c Is it the same?

  • @janzugic6798
    @janzugic6798 Před 3 lety

    can you link the mount file please

    • @AMakeDesigns
      @AMakeDesigns  Před 3 lety

      it's in the video description. You find it here www.thingiverse.com/thing:3367587

  • @potatoboi4872
    @potatoboi4872 Před 3 lety

    Ngl I learned the difference between inductive and capacitive probe the hard way

  • @alex-w8p2e
    @alex-w8p2e Před 5 lety +2

    DYI??

  • @marlonglodo1930
    @marlonglodo1930 Před 5 lety

    hi sir you used 2 pieces 1k resistor?

    • @AMakeDesigns
      @AMakeDesigns  Před 5 lety

      Yes. 1k is probably enough, but I had them lying around and I thought to reduce the voltage a bit more since the opto I used is scavenged and I have no idea of its previous usage and specs

    • @marlonglodo1930
      @marlonglodo1930 Před 5 lety +1

      @@AMakeDesigns i have the same opto came from defective desktop psu and have lying around LJ 12a3-4-Z/BX

    • @marlonglodo1930
      @marlonglodo1930 Před 5 lety +1

      Thank sir for replying.. happý printing

    • @AMakeDesigns
      @AMakeDesigns  Před 5 lety

      You are very welcome mate! The voltage to activate the photodiode usually is above 5mA and 20mA is often used.
      Take care!

  • @Seyfert200
    @Seyfert200 Před 2 lety +2

    First: Why did you use an opto-coupler? Conversion level? It is not necessary: the output (black wire) of inductive sensor is open-collector, so you can power on the sensor with 12~ 36 V and put a resistor (pull-up = 1K f.ex.) from the black wire to the 5 V and connect the black wire direct on the input pin of your controller board.
    (BTW: the inductive probe works from 6 to 36 V. AND it works fine at 5 V as well, but you didn't test it BEFORE to do the "job", right?)
    Second: Why did you use opto-coupler with reverse polarized led? It doesn't work at all.
    Third: Your circuit, besides being wrong, doesn't make any sense.

  • @cosmefulanito5933
    @cosmefulanito5933 Před rokem

    No DIY Sensor.
    Clickbait = Instant thumb down.

  • @armmargret1970
    @armmargret1970 Před 2 lety +1

    Disappointing - This is not DIY you use an off the shelf sensor ...