NEED OF HELP!!!! CAN I USE MY 5VOLT CNC OUTPUT AS SENSOR!

Hi,

I'm newbie about electronic and i don't know if i can used my cnc out that gives 5volts as sensor?
Here is what would like to make.

i have a cnc oxygen fuel machine that have a solenoid valve that hook up in cnc out. when my cnc machine trigger to open the solenoid valve the output give 5 volts to open that valve.

my question is can i use this 5volt as sensor to arduino uno.

Thanks

If it's a signal that switches between (near) 0V and (near) 5V you can read it with a digitalRead(). Make sure that the signal ground is connected to the Arduino ground.

johnwasser:
If it's a signal that switches between (near) 0V and (near) 5V you can read it with a digitalRead(). Make sure that the signal ground is connected to the Arduino ground.

Sorry but i don't get it. please give more details because i don't know where to put the positive 5volts.

Thanks

johnwasser:
If it's a signal that switches between (near) 0V and (near) 5V you can read it with a digitalRead(). Make sure that the signal ground is connected to the Arduino ground.

johnwasser thanks i finally get it and try and its working the only problem now is the code, i think there is something wrong about my code.
if there is somebody out there that can help me...

thanks

rexcobey1:

johnwasser:
If it's a signal that switches between (near) 0V and (near) 5V you can read it with a digitalRead(). Make sure that the signal ground is connected to the Arduino ground.

johnwasser thanks i finally get it and try and its working the only problem now is the code, i think there is something wrong about my code.
if there is somebody out there that can help me...

It will be hard to help unless you show your code.

consider not using all caps, mby.

if there is somebody out there that can help me...

Two knocks for yes and one knock for no.
It looks like the spirit world is your only hope if you don't post your code because only they will be able to see it and see your error.

rexcobey1:
i have a cnc oxygen fuel machine that have a solenoid valve that hook up in cnc out. when my cnc machine trigger to open the solenoid valve the output give 5 volts to open that valve.

my question is can i use this 5volt as sensor to arduino uno.

Thanks

I wonder where the freewheel diode is for that solenoid valve? It may be that somewhat more than 5V is appearing on that output as a result. I'd suggest taking the precaution of connecting the solenoid valve output to the Arduino pin via a 10k resistor - it will then be safe against moderate over-voltage pulses.