There have been a few threads lately asking for help when optos have been changed and there seemed to be no improvement in the fault condition. In some cases the answer was the replacement opto part was installed in the incorrect sense (the leads swapped around).
We have found recently in the Homepin factory several batches of LEDs both IR and conventional types that have been manufactured "differently" to the normally accepted way resulting in the two leads being swapped. These parts have worked perfectly (when connected electrically the right way around) but it is VERY easy to install them the wrong way in the PCB because of the, let's call them, 'errors' in manufacture.
The example I will use in this thread is the brand that we use almost exclusively in the factory, Everlight, a Taiwanese brand (although they are made in China in the Everlight factory).
I will add that we have NEVER had this issue with Everlight parts but we certainly have had with other brands.
Let's start by using the correct terminology. RX stands for receiver and TX for transmitter. We are not too concerned with the TX parts here because they are almost always clear or at least transparent and you can easily determine by looking inside the part which lead is which. The shorter lead, connected to the "anvil" inside the LED is the cathode and should connect in the direction of ground. The short lead will also usually (but not always) correspond to the 'flat' on the rim of the plastic body.
The main thing is that the 'anvil' part is the cathode REGARDLESS of the lead lengths, flat on the body or any other markings.
The first picture below shows a standard, clear 5mm Everlight IR TX LED - you can clearly see the 'anvil' inside and the short lead and flat spot on the body of the part.
The short lead (anvil side) is the CATHODE of this LED, often marked on PCB's as "C" or sometimes "K".
On to the RX device now. They are actually NOT LED's but are in fact 'photo sensitive transistors' and that's why the leads are marked as "C" for collector and "E" for emitter. These devices don't have an externally accessible base lead. Most are encased in a black plastic like the second picture below. It appears impossible to see inside to look for the anvil but in fact if you shine a bright LED from behind you can make out the 'innards' quite easily.
The anvil in the case of the RX is actually the collector, "C" and most pinball boards are marked with a "C" & "E" denoting this. Have a look at part of the data sheet for the Everlight part that shows the short lead and flat on the body as the collector.
Connecting this RX (black) device with its leads swapped around will greatly reduce the efficiency of the device BUT in many cases it will still work to a degree and this can become very confusing.
When we get a new batch of any devices like this now we carefully check to make sure that we will be able to install them the correct way to avoid messy re-working of the brand new boards.
While on the subject check out the excerpt from a Sharp Optoelectronics datasheet that mentions life expectancy of these IR devices (the Sharp parts have a very similar specification to the Everlight ones we use).
It talks about a working life of only five years before the device degrades by 50% - amazing. The ones in our pinball machines are 20 years plus and climbing so we can expect more issues with optos in the future I suspect.