You are not logged in.

#1 2018-05-12 19:17:43

pixel
Member
Registered: 2018-02-01
Posts: 7

photo interrupter limit endswitch GPIO PIN VALUE issue.

Hi guys. I having to use a photo interrupter limit endswitch on my raspberry PI 3B

It doing opposite work with Z-axis stepper motor. It should be interrupted to working the motor. If it non interrupt then stop working. all doing odd. And If I replace it to mechanical endswitch then working fine.

It caused NPN and PNP type. And I tried to change the GPIO value of endswitch of raspberry PI. but there is no way to do on the NanoDLP. Also I can't modify my photo interrupter working on when it interrupted. It was on when it non interrupted.

Is here anyone who use the photo limit endswitch on the NanoDLP? 

I'm using one this switch

https://www.aliexpress.com/item/5pcs-3D … 0.0.Gk2xXw



and mechanical switch one is this link.
https://www.aliexpress.com/item/Endstop … autifyAB=0

Mechanical switch working fine and correct. but photo interrupter doing opposite....

Offline

#2 2018-05-13 02:56:57

Shahin
Administrator
Registered: 2016-02-17
Posts: 3,541

Re: photo interrupter limit endswitch GPIO PIN VALUE issue.

You need to reverse logic to use photo interrupters. Also consider photo interrupters sensitivity usually lower than mechanical one. So it is better to use mechanical one as endswitch.

Offline

#3 2018-05-13 05:48:49

pixel
Member
Registered: 2018-02-01
Posts: 7

Re: photo interrupter limit endswitch GPIO PIN VALUE issue.

Yes I tried to reverse logic for my photo interrupters before. But I'm newbie for electronic circuit things. So my photo interrupters using 2TY Transistor. It is PNP type. It seems to be use for turn on the LED when the photo interrupter has interrupted.

Actually just only one photo interrupter sensor doing turn on the LED when it non interrupted. and I think the manufacture which made this Photo Interrupter has change that logic to turn on the LED when it interrupted.

And I think it can be use to signal of endswitch. 

I hope to found a more simply way to reverse logic.

This is circuit for my photo interrupter.
20180512_162422.jpg

Offline

#4 2018-05-13 11:22:08

pixel
Member
Registered: 2018-02-01
Posts: 7

Re: photo interrupter limit endswitch GPIO PIN VALUE issue.

Is there anybody who know how to change GPIO state value for the Limit endswitch both top and bottom ? If I can change that value then No need to touch my circuit of switch. Please.... answer me.

Offline

#5 2018-05-14 09:36:39

exilaus
Member
Registered: 2018-05-14
Posts: 5

Re: photo interrupter limit endswitch GPIO PIN VALUE issue.

pixel can use a simple transistor for invert signal   see   

https://oscarliang.com/sbus-smartport-telemetry-naze32/     "sbus invert" that alway other scope but used for invert digital signal  as a NOT GATE.

anyway ....surely response of admin not great because that are manageable via software and OPTIC ENDSTOP have better repeatability of economic meccanical switch for that in any z i see from formlabs to anycubic photon and  my little sparkmaker use optic endstop.

Offline

#6 2018-05-17 17:30:09

pixel
Member
Registered: 2018-02-01
Posts: 7

Re: photo interrupter limit endswitch GPIO PIN VALUE issue.

exilaus wrote:

pixel can use a simple transistor for invert signal   see   

https://oscarliang.com/sbus-smartport-telemetry-naze32/     "sbus invert" that alway other scope but used for invert digital signal  as a NOT GATE.

anyway ....surely response of admin not great because that are manageable via software and OPTIC ENDSTOP have better repeatability of economic meccanical switch for that in any z i see from formlabs to anycubic photon and  my little sparkmaker use optic endstop.

Thanks for your advise. I fixed this issue. I just connect the Emitter to GPIO and resistor->GND.

Offline

Board footer

Powered by FluxBB