Welcome to Our Community

Some features disabled for guests. Register Today.

limit switches can't be inverted

Discussion in 'OpenBuilds Forum Help' started by heldenfrosch, Apr 16, 2023.

  1. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hi!
    I use NPN NO proximity switches with my new Blackbox. I flashed new firmware.
    They are wired correctly, the LEDs work.
    ? shows Pn: PXYZ when limit pins are not inverted. After inverting it shows PYZ. Homing then works for X, but of course not for Y and Z.
    Any ideas why X obviously can be inverted but Y and Z not?

    Thanks in advance

    Matthias
     
  2. David the swarfer

    David the swarfer OpenBuilds Team
    Staff Member Moderator Builder Resident Builder

    Joined:
    Aug 6, 2013
    Messages:
    3,489
    Likes Received:
    1,925
    in CONTROL use the troubleshooting page to check that the switches correctly trigger AND trigger the correct axis.
    upload_2023-4-16_18-12-52.png

    ignore my probe input, the external optocoupler inverts it and that is not currently connected.
     
  3. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hi!
    Thanks for the quick reply. I did this already, the right axis get triggered when tested manually before inverting. By default all switches are triggered.
    When I change $5 from 0 to 1:
    upload_2023-4-16_18-34-25.png
    Y and Z can still be untriggered manually.

    Cheers
     
  4. Peter Van Der Walt

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

    Joined:
    Mar 1, 2017
    Messages:
    15,190
    Likes Received:
    4,346
    X32: $5=0 or $5=7 if you want it to act on all.
    Its a bitmask. X=1, y=2, z=4. XYZ =1+2+4=7
     
  5. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hey Peter!

    I didn't know that. Great, that did the job!
    The next problem is, that the laser won't fire on full power. M3S100 leads to ca. 350mV PWM. Here are my settings. Any idea?
    Thanks in advance!

    Matthias

    $$

    $0=8.0

    $1=25

    $2=1

    $3=0

    $4=0

    $5=7

    $6=0

    $7=0

    $8=0

    $10=509

    $11=0.010

    $12=0.002

    $13=0

    $14=0

    $15=0

    $16=0

    $17=0

    $18=0

    $19=0

    $20=0

    $21=1

    $22=1

    $23=3

    $24=50.0

    $25=500.0

    $26=250

    $27=10.000

    $28=0.100

    $29=0.0

    $30=1000.000

    $31=0.000

    $32=1

    $33=5000.0

    $34=0.0

    $35=0.0

    $36=100.0

    $37=0

    $39=1

    $40=0

    $43=1

    $44=4

    $45=3

    $46=0

    $62=0

    $63=3

    $64=0

    $65=0

    $70=7

    $73=1

    $74=

    $75=

    $100=320.000

    $101=160.000

    $102=320.000

    $110=500.000

    $111=500.000

    $112=500.000

    $120=10.000

    $121=10.000

    $122=10.000

    $130=200.000

    $131=200.000

    $132=200.000

    $300=Grbl

    $302=192.168.5.1

    $303=192.168.5.1

    $304=255.255.255.0

    $305=23

    $306=80

    $307=81

    $341=0

    $342=30.0

    $343=25.0

    $344=200.0

    $345=100.0

    $370=0

    $384=0
     
  6. Peter Van Der Walt

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

    Joined:
    Mar 1, 2017
    Messages:
    15,190
    Likes Received:
    4,346
    S100= 100/1000 = 10% of 3.3v = 330mv so spot on yes

    You want S1000

    Use the provided Tool On menu in CONTROL it does that kind of math for you, and you can learn from the commands it sends :)
     
    David the swarfer likes this.
  7. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hi! Thanks! This test with the tool button showed that I can get the 100% or 3.3V.

    The problem is, that no matter what job I start the laser won't go above 20% or so. GCode says M4
    S1000F24000
    I spent so much time trying everything I could without any change.
    Thanks for your help!
     
  8. Peter Van Der Walt

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

    Joined:
    Mar 1, 2017
    Messages:
    15,190
    Likes Received:
    4,346
    That is correct (if $30 is still set to 1000, just make sure it did not change)

    M4 is Dynamic Power - so have read through Grbl v1.1 Laser Mode
    If your acceleration is set too low it won't ramp up to full power sometimes

    Post a full Grbl Settings backup for review
     
  9. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hey Peter!

    Great! The acceleration was the problem. Now everything works fine!

    Thank you so much! It's been a struggle for several months with 2 broken XPros.

    Cheers!

    Matthias
     
    Peter Van Der Walt likes this.
  10. Peter Van Der Walt

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

    Joined:
    Mar 1, 2017
    Messages:
    15,190
    Likes Received:
    4,346
    Sorry to hear that - did you find root cause?
    Just raising potential issue - if it was something like using a 3rd party PSU (not ours) and not replacing it, or a short in the wiring never found - we don't want you having any more struggle later on with a broken BlackBox :)
     
  11. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hi!
    I added a diode laser to my diy mill (CS MIO). Therefore I made an entirely separate controller-setup.

    The first XPro broke due to a shortage, maybe caused by wrong wiring of proximity switches. The reason for several trials was, that Spark Concepts didn't say anywhere and not in support communication that PNP won't work. Openbuilds is very clear in this.

    The second one had obviously a hardware failure. First everything worked well. Now it permanently sends PWM of 1.3V, even when nothing is plugged in. No chance to fix this, also not with resistor. Wiring the laser via relay was suggested by Spark Concepts, but this left the laser still firing permanently on high power.

    I like the Blackbox.

    Can I use the door port also like an end stop/emergency button?
    Cheers and thanks again!
    Matthias
     
  12. Peter Van Der Walt

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

    Joined:
    Mar 1, 2017
    Messages:
    15,190
    Likes Received:
    4,346
    If that damage was caused by the Laser module itself, BB could be at risk too.

    It's not advisable...

    Creates a possibly false sense of safety!

    We don't recommend a software based Emergency stop / button connected to a controller thats dependent on controller/firmware/computer etc.

    The software has an Abort (click button or ESC key on keyboard) for less-real emergencies, but a proper E-Stop should ALWAYS cut ALL power to the machine.

    We recommend Wall Socket > https://www.rockler.com/safety-power-tool-switch > Power Strip> Everything else (Machine, Spindle, Dust extractor etc). In a real emergency you want to cut power to EVERYTHING at once. What if the dust extractor caught fire. Or the PSU is on fire. Or someone's hand is stuck under the router. That's why we advise against a software/controller based solution. When life, limb or property is at risk, cutting power is the safer option
     
    David the swarfer likes this.
  13. heldenfrosch

    Builder

    Joined:
    Apr 16, 2023
    Messages:
    7
    Likes Received:
    1
    Hi!
    How can we know if this was caused by the laser module?
    You aee right, I will install a switch that powers of the main wire...
    Thanks
    Matthias
     
  14. Peter Van Der Walt

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

    Joined:
    Mar 1, 2017
    Messages:
    15,190
    Likes Received:
    4,346
    Best I can offer there is "go with your gut"
    If you are not 100% sure it could have been a mistake, a loose wire straggler outside a terminal, or some other explainable short/fault/accident - one would always wonder what really happened.
    Is the module from a reputable source (JTech or Optlaser). If not, do you, ultimately, trust them.

    Best case, it can damage a single output pin - with some effort you can remap pins in firmware (swop enable and PWM for example). But depending on what it did it may fry more
     

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