Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Laser diode instead of servo motor #20

Open
panosss opened this issue Jan 25, 2019 · 4 comments
Open

Laser diode instead of servo motor #20

panosss opened this issue Jan 25, 2019 · 4 comments

Comments

@panosss
Copy link

panosss commented Jan 25, 2019

I use the GRBL for unipolar stepper motors GRBL-28byj-48-Servo library, which uses your library (grbl-servo).

I replaced the servo motor with a laser diode, 5mW, this one.
But when the diode lights on (with M03 S255, or any number) it does not come off with M03 S1.
Or M05. It only dims.
With M03 S255 is bright and with M03 S1 it 's a little less bright. (not great difference but noticable)

So I have to modify the code to switch the diode on and off.
How can I do this?
As a switch I use a 2N2222A transistor.

@panosss panosss changed the title Replace servo motor with a laser diode Laser diode instead of servo motor Jan 25, 2019
@robottini
Copy link
Owner

Hi you have to use the vanilla GRBL, not this one. See https://github.com/grbl/grbl

@panosss
Copy link
Author

panosss commented Jan 25, 2019

(thanks for the so quick reply!)
The vanilla GRBL is for bipolar stepper motors. (I have unipolar stepper motors, this is why I use GRBL-28byj-48-Servo)
There must be some way to use your code (modified) with a laser diode.

If I have understood well, the posistion of the servo is set by voltage level on the contol pin of the arduino, right?
So, if I can make it go to 0 Volts, it might work.

@robottini
Copy link
Owner

robottini commented Jan 26, 2019 via email

@panosss
Copy link
Author

panosss commented Jan 29, 2019

I can't use the vanilla version of GRBL because it is for bipolar stepper motors.
I have unipolar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants