Programmaticly "shorting" a 5V input to ground

Current only flows when there is a voltage difference.
With 5volt on one device and 5volt on another device there is no voltage difference...
Leo..

Update- I was wrong. There are some SMD LEDs with a forward current of 2mA.

That 2mA or 20mA is the absolute max current for a specified lifetime.
It doesn't mean you must drive them with that current.
The LEDs on an Uno/Mega have a 1k CL resistor (3mA through a 20mA LED), which is is sometimes too bright to look into.
Leo..

And what if there are flunctuations in the voltage? When I tested with the multimeter intially, I could see the 5.0V slightly varying... though this could also be my hands affecting the movement of the wires. Is 5.0V on one device and 4.8V on the other going to cause issues?

It does appear that the circuit I'm using is working consistently only using the LED In connection to the Uno (as an OUTPUT). The Logic Ground wire does not seem to make a difference.... and thus may not be necessary. I suspect it was included in the device to be used for making a remote physical switch, just connected between these two wires to turn the LED on and off. With the Arduino it doesn't seem to be necessary instead using it's own ground to short the Logic In wire.

What are people's thoughts with regard to my not using the Logic Ground at all for this. Meaning one less wire to prep/connect. The wires in this device are ultra slim... like hair. So one less thing to go wrong in connections to the mic.

Only you can tell. The mic LED must have some hysteresis, so some difference could be ok.

I would add that ground, for safety. Don't rely on a ground path you don't know.
Leo..

So, I just did some testing with headphones - with the gain set to full (+10db). And there's perhaps something to this.

With only the device's LED In connected to an arduino digital pin (output), the sound in the headphones is the same while I toggle the output to high/low to trigger the LED off/on on the device.

But, if I also connect the device's Logic Ground to the arduino GND pin, which has no affect on the functioning of the arduino and mic's LED control software (it keeps working regardless)... a hum/buzz (and a sort of morse code) can be heard in the headphones.

So it seems that connecting the ground has a bad effect with regards to the audio from the mic. Notably, with the mic level set to 0 db, the added noise isn't really noticable. Still, multiplying this by many more mics could be.

What is the practical layout. Are all of these mics connected to a single mixing desk.
Does the LED control wire travel through a snake to the desk.
If so, then the opto couplers can/should be mounted inside or near the desk.
Leo..

All the mics come with attached 10' XLR cables which will run under the interlocking desks the mics are on. A few of those will have mics extensions to get them ~40' from further away in the room - they will run across the floor under cable protectors. The mic cables will all arrive at an audio mixer under the centermost desk area.

The pigtails (2 or 3 wires if I use ground connection) that'll connect to logic wires inside the XLR will start from inside the XLR connector and go out thru strain relief. Those will start at the end of the 10' cable that come attached to the mics. For the mics without extensions, the pigtail will be maybe 2-3 feet long from the XLR connector plugged into the audio mixer to the arduino box somewhere near the audio mixer. For the mics that need extensions, the pigtails will run the ~30' length of the extension back to the arduino.

The arduino side of the pigtails will terminate with dupont connectors, or I'm considering getting a screw terminal breakout board for arduino mega, if I can find one that can work somehow with an ethernet shield on it too. Still researching this.

For the pigtails I need a small enough gauge cable to squeeze in thru the XLR strain relief which is fairly tight, and also thru the plastic end piece that sits at the cable end of XLR connectors. I initially tried to use 4 wire telephone cable (I think maybe 24 AWG stranded), inside the standard telephone pvc sheath, but I couuldn't get it to go past the plastic end piece. So, for my prototype I stripped off the pvc sheath and just pushed in 3 wires adding some shrink tubing along the wire outside to keep the 3 wires together mostly.

Now that the prototype is working, I'm hunting online for 2 or 3 (if ground not needed) wire cable with pvc sheath that will fit inside the XLR strain relief. I'm thinking possibly 1.27mm 24 AWG wire solid (not stranded) with a tight pvc sheath... if I can get that working with 2.55 dupont connectors I already have. The solid wire gives a good stiffness to the cable making it easier to slide into the strain relief. I'm gonna have to order several in hopes of one being small enough... hard to tell from looking at pictures of wire and sheath how big they really are in reality.

The logic wires inside the XLR are like 28 or 32 AWG or smaller... I had to strip ends with wire cutters cuz so small.

While reading this I think the choice of opto couplers becomes more important.
That won't create multiple ground loops, which can bite you with this multi-mic setup.

You can buy "Arduino Mega proto shields" that plug on top of the Mega.
Leo..

I'm picking up what you're puttin down as they'd say in the ummm 60/70s?

I'm new to optocouplers... but I understand what they do after some research. I see some seemingly overly complex designs searching "arduino octocopuler".

Do I just need to place an octocoupler at the end of each wire coming from the mic logic circuit, then connect the other end into the digital i/o pin? Can I leave the mic's logic ground out then still? I could avoid dupont connectors altogether, if I had an octocoupler with screw terminals (one of those came up when I googled) for in and out. Or maybe there's such a thing as an octocoupler I can just plug into the i/o pin. For this first iteration I've got about 20 mics to do, but after its done, I'll need to replicate this a bunch of times. So, looking for quick ways to put this together, without too much soldering. At an absolute minimum I likely have to solder the logic wires inside the XLR cable as they're so tiny probabyl no other way to join to the. Stripping them sucks too.

These low voltage wire connectors are pretty cool, albeit costly on Amazon, but they don't support the extra small wire inside the XLR.

This article is interesting and on the right track I think. I see there are 8 input modules too at least. I wonder if there is simiar with enough optocouplers for a mega i/o. Also, I think what would be simplest is if there was something that only required one 5V and Ground connection for the whole optocoupler collection.

I was considering something like this (hopefully cheaper)...

or this...

But I was planning to also use an ethernet shield, but I'd have to switch to using an ethernet module instead.

And with the optocoupler consideration below, I may get the screw terminals with the optocouplers, so this kind of thing might not be needed then.

This isn't all going to fit into the case I got though...

I would say most of the frequent posters here have reached the retirement age, including me,
and we have a shipload of combined experience.
(component-level consumer electronics tech here, with experience in studio/PA setups)

Myself, I would not go for a turn-key solution,
because I can build something like this myself for a fraction of the price.

That PC817 board would do the job, but you certainly don't need that ground link jumper.
That defeats the use of an opto coupler.

I would gain some experience with that PC817 board, before going the next step.
Leo..

I believe way back there this is what Wawa was getting at.

Your goal is just to remotely turn the LED on your device On/Off correct? When touching your LED wire to the Logic Ground the LED turns on. R1 is selected based on your choice of opto-coupler. The drawing is just generic.

Ron

Thanks Ron.
Yep, that's all you need.
R can be 1k.
Logic GND is of course mic ground (ground of the mic/LED you're switching).
Leo..

:slight_smile: Just completed 73 trips around the sun. Come May 1st been 10 years since my last trip out the plant gate. :slight_smile: I found this forum and like it here. Rumor control claims if I don't continue to exercise my brain it will turn to oatmeal. :slight_smile: Guess I was a little late with the basic drawing.

Ron

@Wawa

The safe way to do this is with an opto coupler.
That will also eliminate the possibility of introducing noise in the audio.

Since this application involved grounding a lead to turn on a low power Ied, I wonder if using an i2c port expander PCF8574/5 might provide the isolation similar to the optos but come in a 16 or 8 input chip on a module for easy integration.

I would be wary of letting a digital chip near a mic signal.
Leo..

Given that I'm gonna need like 40 optocouplers... That's 10 x PC817.