I'm hoping to interface a small arduino with some existing low voltage control circuitry on a CNC Lathe.
There are a bunch of requirements, but i'm only going to describe the initial basic case. Hopefully you can help me along in the right direction with this.
When an LED flashes on the lathe Control Panel, two buttons on the control panel need to be pressed by the machine operator: RAPID and then FEED. Each held down for a second with a one second gap between.
So i need some circuitry that detects when an LED is "signaled" then "presses" the buttons. Pretty straightforward.
This is going to be done electronically. By this i mean i will break into the control panel circuitry and solder onto the control PCB. ie I'm NOT using an LDR to detect the LED and using servos to mechanically press buttons.
My question is this: How would I detect that the LED is flashing in a current/voltage signal sense? Is there some way i can detect a voltage across the LED when it is turned on? How do i interface this to the arduino input pin in terms of electronic components (resistors/transistors/amp etc)? Do I need to bother about connection ground pins to various places (I'd like to keep the original control circuitry and my new circuitry seperate)?
I've heard of something called opto isolators or maybe shunt resistors but am out of my depth. I'm a computer programmer whose done a wee bit of googling, not an electrician or electronic hobbyist with lots of experience, so this is still a bit beyond me.
Obviously I really dont want to damage the existing lathe control panel.
Hopefully that all makes sense and gives you plenty of background. Any more questions, fire away.
You simply connect the LED to the analogue input pins and read the voltage.
However you need to make sure that the circuit you are connecting to does not give voltages greater than 5v. Otherwise you need an opto isolator. These are simply an LED and transistor. Look it up on Wikipedia
Since you're probably working with "low" voltages the 15k resistor in the circuit can be lowered to 220 ohms or so, and you can probably eliminate diode D1 as long as you promise not to hook things up backwards.
You would connect the inputs across the LED terminals. This will probably dim the LED, however.
--
The Ruggeduino: compatible with Arduino UNO, 24V operation, all I/O's fused and protected
I should probably go the opto route for safety and just sleeping better at night.
When you say "connect the inputs across the LED terminals" has my attached diagram captured the essence of what you are saying. The boxes on the left with X in them are just unknown 'stuff'.
Note that the dimming you mention doesn't matter as i can drive an LED on the output side of the arduino to mirror the signalling of the LED.
Yes, you have the idea. Just to make sure, it truly is an LED, right? Not a "lamp"? I ask because I'm assuming ~2V across the LED. If the reality is much higher (12V, 24V, etc.) then a higher-value resistor would be appropriate (e.g., 1k).
On the Arduino side don't forget to enable the pullup resistor for the digital pin you will be monitoring.
--
The Rugged Motor Driver: two H-bridges, more power than an L298, fully protected
In hindsight, you're going to want to divert most of the current into the optoisolator, so an even lower value resistor than the one I suggested would be appropriate (maybe even as low as 10 ohms). In the worst case (LED forward voltage lower than optoisolator forward voltage) you can keep the 220 ohm resistor and just cut one of the LED leads to take it out of the picture altogether. Then for sure all of the current will be going into the optoisolator.
--
The Aussie Shield: breakout all 28 pins to quick-connect terminals
I've got hold of a schematic of the existing circuitry I'd like to tap into. The resistors were 5600 Ohms (1% tol) I think.
Anyone have any idea about what's going on in the red box I've highlighted in the attachment?
Specifically:
What are those two transistor like components?
Why are they configured like that?
What's the purpose of the diodes?
Can anyone tell if that's definitely a 24V DC source (it says +24C strangely)?
I'm sure I can just proceed as I was going to.
I'm only asking mainly out of curiosity to get some depth or pointers about what that particular configuration of boxed components achieves.
Okay thanks that could be it, i've had a look online elsewhere and seen many different symbols with/without diodes & solid/dashed gates so you are probably right. The diagram is over 15 years old so cad packages back then maybe compromised on looks.
I've decided to just have a box that intercepts the cables from the lathe distribution panel to the lathe front panel. I'll have some switches on the box that either pass the signals through as normal or divert them to my opto/arduino logic in a separate (second) box. This way, when i'm switched on to intercept the signals, the FET will drive my opto isolator (not the LED) and i'll drive the LED on the front panel from the arduino as part of the output logic. Seems safer all round.
I drew a diagram for this one circuit which needs 3 cables, so it looks like I'll end up having about 8 cables when I've done this first phase.
Does anyone know a good place to buy
The stuff you need to make up 15 and 25 pin D type connector cables?
Enclosures and boxes for electronics?
"technobotsonline" seemed okay but I wondered what the guys in the know here use.