Go Down

Topic: another cnc mill questionaire (Read 33205 times) previous topic - next topic

theMPloc

checked all the switches. everything is correct :/

theMPloc

i tried the following: when i disconect all switches from the arduino all axis move how and where they should. i checkt the wiring and everything is fine and i doublechecked the switches which are fine. strange world.

mmcp42

#107
Jan 12, 2011, 02:19 pm Last Edit: Jan 12, 2011, 02:35 pm by mmcp42 Reason: 1
ok
a common problem is noise
the motors make electrical noise (as well as singing to you)
that can make the Arduino think the switch came on

maybe small capacitors (0.1 microFarad) from the arduino microswitch pins to ground may help

they need to be at the arduino end of the wire, not the microswitch end btw
there are only 10 types of people
them that understands binary
and them that doesn't

theMPloc

ok. this meand the capacitors should be where the resistors are now. is this correct?

mmcp42

#109
Jan 12, 2011, 02:35 pm Last Edit: Jan 12, 2011, 02:35 pm by mmcp42 Reason: 1
I hope the resistors are directly connected at the arduino - then yes! :)
there are only 10 types of people
them that understands binary
and them that doesn't

theMPloc

the wire that comes back from a switch is connected to arduino. on this wire there is also the 10k resistor connected which goes to gnd on the arduino.

mmcp42

that's good
add the capacitors there
there are only 10 types of people
them that understands binary
and them that doesn't

theMPloc

good morning. got some 0.1 400V capacitors (getting electronic components in tyrol is like looking for kangaroos in austria). i will try them out. readying some more threads on makecnc.com i found out that noise on limit switches is quite a common problem and it seems that this issue is always solved with 0.1 capacitors. i never found anything about 10k resistors so maybe i don´t need them. we´ll see and i keep you informed!

mmcp42

:)
noise is a common problem, glad to hear the "usual" solution is 0.1 microfarad capacitors (400v is overkill, but does no harm; and probably all you can get anyway!)

you will need the resistors to ensure the inputs aren't floating, so I would use both
there are only 10 types of people
them that understands binary
and them that doesn't

theMPloc

#114
Jan 13, 2011, 11:45 am Last Edit: Jan 13, 2011, 12:07 pm by theMPloc Reason: 1
i am just messing around with the capacitors. classic noob question: do capacitors have a "direction". on one pin of the capacitor it says "hi" at the moment this is where i have the wire coming back from the switch connected. and it does not work.

so my idea is to do the following:

the wire coming back from the switch goes to the according pin on the arduino. then i will add a resistor on the wire that comes back from the switch. then i will add a capacitor there and connect it to the pin which says "hi" the other pin will be connected to gnd on the arduino.

basially thats how i had it already just with a capacitor added in the line. or should i wire the capacitors and the resistors parallel?

how about that?

mmcp42

some capacitors (high value ones) are polarised, so it DOES matter which way round they go
they are usually marked with a + and -
low value (the sort you are using) are generally not, so it doesn't matter which way round you connec them
one end of the capacitor should go to ground, the other should go to the input pin
there are only 10 types of people
them that understands binary
and them that doesn't

theMPloc

tried and failed. machine moved a little. now it says all switches are 1.

mmcp42

well we're definitely poking the right place
very odd

wild guess
instead of connecting one ond of the capacitor to ground, connect it to +5
(think that means it's in parallel with the resistor but that's ok)
there are only 10 types of people
them that understands binary
and them that doesn't

theMPloc

to make sure: that is how i have it now:


mmcp42

Nooooooooooooooooooooooooooo
+5v to switch is good
one side of10k to other side of switch is good
other side of 10k should go to ground
capacitor should be in parallel with resistor

try that!
there are only 10 types of people
them that understands binary
and them that doesn't

Go Up