Talk:Charlieplexing

Active discussions
WikiProject Computing (Rated Start-class)
This article is within the scope of WikiProject Computing, a collaborative effort to improve the coverage of computers, computing, and information technology on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
Start-Class article Start  This article has been rated as Start-Class on the project's quality scale.
 ???  This article has not yet received a rating on the project's importance scale.

KeepEdit

Keep this page, please. The multiplexed display was fundamental to the development of (inter alia) the pocket calculator, and deserves a better technical writeup on Wikipedia. Charlieplexing is an interesting footnote, and should be included for completeness.

IanHarvey (talk) 21:49, 11 February 2008 (UTC)

I would like to comment that this is actually a very important technique for driving a display with a smaller number of i/o pins than traditional multiplexing. It is actually more important now than ever before with the increased integration of embeded computers in appliances and other devices. This technique allows smaller processor chips with fewer i/o pins to do more work, and for commercial products will tend to drive the cost down by preventing an engineer from having to choose a larger chip to support a project. This is critical where the product is a disposable device such as a single use camera, or a device with limited space such as a watch or a battery with a built-in meter. This also reduces the consumption of resources such as copper, so it can be considered an earth friendly technology, making it more than a footnote.
Georgedotcom (talk) 00:17, 10 March 2008 (UTC)
I found about this topic while watching a clip on youtube, but I have to say that the way it's explained here is very confusing. I'm going to try and understand it better and fix this article so it's a little clearer.
--79.36.181.209 (talk) 09:00, 25 May 2008 (UTC)
Can anyone put a circuit diagram of it on here?
Pi.1415926535 (talk) 18:17, 13 June 2008 (UTC)
Seems to me that the linked Microchip article "Complementary LED Drive" serves the requirement of a published third-party article. BrianWilloughby (talk) 07:12, 1 July 2008 (UTC)
I have removed the notability template, I think it's good now. Thanks for adding references.
Gigs (talk) 05:28, 30 October 2008 (UTC)
Are comments in this section necessarily read for consideration after the notability template is removed? I ask since there are no comments here after the notability removal in 2008 Regardless, if anyone does read this and has an understanding: How about adding an example to the "Bigger and Brighter" matrix with 6 LEDs, 3 pins and supposed control to illuminate multiple LEDs on the same rows simultaneously? I have not made sense of the circuit diagram and have not found other examples or explanations of the concept.
--Davidd334 (talk) 16:04, 24 August 2014 (UTC)

Duty Cycle -> Refresh RateEdit

I changed the name of the "Duty Cycle" section to "Refresh Rate" but I'm still not happy with that term as used in that section. To me, the refresh rate is how often the whole display gets activated once (alway 50 Hz, in the section), but what the section is saying (the number of times a LED has to be addressed for possible activation) might be called the "LED write rate" or "LED Activation Rate." Perhaps scan rate from CRT raster technology, but that seems to imply a horizontal line acrosss a display. Maybe pixel rate?

Benbradley (talk) 21:52, 4 November 2008 (UTC)

Also, I wonder if it actually true that you always only can activate one LED. Consider a set of three IOs with 6 LEDs. Then imagine setting IO A to logic low. You then can set both other IOs to either logic H or Z, thereby activating two LEDs at the same time. Do his round robin style.
In the example with three IOs this means every LED is on for 1/3rd of the time, not 1/6th. Correct?
TomFTom Frey (talk) 10:21, 12 November 2008 (UTC)
The Duty cycle is just 1/N, where N is the number of drive lines. For example, if you have 9 IO or driver lines, then at any given time 1 line will be performing the same function as the digit driver in a normal multiplexed display and the other 8 will be the same as segment lines in a normal muliplexed display. So with 9 lines you can drive 9 digits of 8 segments. A normal multiplexed LED display would use 9 digit lines and 8 segment lines and also have the same 1/9th duty cycle, but using a total of 17 IO lines rather than the 9 lines of the Charlieplexing method. The number of segments you can drive with "N" lines using Charlieplexing is N x N-1. With normal multiplexing, for N lines the maximum number of segements you can drive is for a square matrix of equal number digits and segments. So N/2 * N/2 = N^2 / 4. The duty cycle issue is what sets the practical limit on the number of segments driven. 16 lines would drive 16*2=15 = 240 segments, but with a duty cycle of 1/16. Normal multiplexing to drive 240 segments would take 15+16 = 31 pins and would have a slightly better duty cycle of 1/15.
—Preceding unsigned comment added by 71.116.113.160 (talk) 16:06, 29 November 2008 (UTC)

Errors in ArticleEdit

The section on current is almost entirely wrong.

"Due to the decreased duty cycle, the current requirement of a charlieplexed display increases much faster than it would with a traditionally multiplexed display. As the display gets larger, the average current flowing through the LED must be constant in order for it to maintain constant brightness, thus requiring the peak current to increase proportionally. This puts a limit to the size of the display, as when the peak current flowing through the LED’s when they’re turned on exceeds the LED’s ratings, charlieplexing is not a possibility."

The decreased duty cycle is balanced by the fact that only one LED is lit at once. 10 LEDs all at 10mA constantly consumes 100mA. 10 LEDs all at 100mA with a 10% duty cycle and no two LEDs on at the same time also consumes 100mA. So current requirements should stay constant for a given number of lights each emitting a given amount of light.

In fact, the light output increases faster than the current, so putting 100mA/10% duty through an LED will give you more light output than 10mA/100% duty. So current requirements actually *decrease*.

This is a simple energy equation. Charlieplexed displays are in no way inefficient and this paragraph suggests that they are.

Finally, an LED's current limitation is in fact a power dissipation limitation. You can supply a 30mA LED with 300mA for 10% of the time and it should not overheat. However, you may need to increase the switching frequency in this case. The current limit is not a limit on *peak* current, but a limit on *power* which is a function of *average* current. Limits on peak currents are not quoted for LEDs.

—Preceding unsigned comment added by 91.84.151.241 (talk) 17:55, 20 January 2009 (UTC)

The first LED I took a look at the datasheet for ( http://www.rapidonline.com/netalogue/specs/55-1790e.pdf ) clearly had both a DC forward current and a pulse forward current specified. While for the LED junction itself power is roughly proportional to the peak current other parts (such as bondwires to the package) will likely have a resistive characteristic and hence a power disipation proportional to the RMS current.
While you may be able to run some 30ma LEDs at 300ma 10% of the time I doubt they would survive very long at 3A 1% of the time.
There is also the issue that charlieplexing is largely pointless if you cant use the microcontrollers built in tristates (since controlling a tristate generally requires two lines). Most microcontrollers only have about 20ma or so drive on thier IO lines.
In summary charlieplexing is a neat hack for running a small (say 20) group of LEDs that don't have to be particularlly bright off a microcontroller while saving on IO and not using any external active components but for a larger grid you are going to run into issues and will do better using conventional multiplexing (and if you are short of IO putting a 1-of-n decoder on one side of the matrix).
Plugwash (talk) 00:53, 22 January 2009 (UTC)
But in the light of the section above (Duty Cycle-> Refresh Rate), which makes clear that the duty cycle using charlieplexing is only slightly less than that for traditional multiplexing, is there really a substantial disadvantage? Quote: "16 lines would drive 16*2=15 = 240 segments, but with a duty cycle of 1/16. Normal multiplexing to drive 240 segments would take 15+16 = 31 pins and would have a slightly better duty cycle of 1/15." There certainly is a peak current limit for LEDs, but this problem is exactly the same as for a traditionally multiplexed LED array. So this is not a specific problem to charlieplexing. The sentence

Due to the decreased duty cycle, the current requirement of a charlieplexed display increases much faster than it would with a traditionally multiplexed display

from the article is therefore wrong
--Tom Frey (talk) 02:32, 27 March 2009 (UTC)
Perhaps a better way to phrase the problem is that brightness drops faster with increasing Charlieplexed matrix sizes compared to other techniques. Since brightness is very important to some applications, and since increased current is required to maintain brightness, I think that's whence the original current comment stems. However, the real limiting factor is that Charlieplexing puts a circuit up against the maximum current limitations of an LED far quicker than other matrix configurations. Thus the repeated axiom that Charlieplexing is best for small numbers of LEDs and pins. You certainly don't want to try Charlieplexing 200 LEDs if you want them to be bright and have multiple LEDs appear to be lit simultaneously.
BrianWilloughby (talk) 17:31, 6 January 2011 (UTC)
What I think the problem is is a disagreement over what Charlielplexing is:
to some it is driving only one LED at a time, to others several LEDs can be driven at once and it's still Charlieplexing , some would call that Chipiplexing.
So yes if driving a single LED at a time the LED will see a much higher peak current for the same apparent brightness than if ordinary multiplexing was used. Jasen betts
(talk) 22:56, 28 December 2015 (UTC)

I think there's an error in the number of LEDs stated for the clock shown in the article picture. The article says 90, but looking at the photo there seems to be 89 (60 seconds, 12 minutes, 1 AM/PM, 7 days, 8 instructions and 1 for the alarm). 103.49.127.17 (talk) 21:40, 11 December 2016 (UTC)

Requirement for tristateEdit

"...if external tristates must be used then each tristate will require two output lines to control eliminating most of the advantage of a charlieplexed display."

Is this actually correct? Most external tristate drivers do require 2 lines to drive them, but it must be possible to make an external tristate driver that works with only one input line. For example, if the microcontroller has outputs that are either +5V, 0V, or floating, what about a weak pull-to-centre resistor network (say 100k from the pin to each rail), so that the float is biased at 2.5V, and then drive 2 symmetric transistor/diode networks: the lower half would be 4 diodes in series with the (NPN) base-emitter junction (thereby turning on only when the voltage exceeds 3.1V, and the upper (PNP) half only turns on when the voltage is below 1.9V.

—Preceding unsigned comment added by 87.194.171.29 (talk) 02:53, 24 January 2009 (UTC)

Certainly possible in theory but i'm not convinced it's particuarlly practical compared to other options like decoder chips.
Plugwash (talk) 13:05, 21 February 2009 (UTC)
I am with plugwash on this one. Gugaplexing (see e.g. http://blog.makezine.com/archive/2008/06/charlieplexing_times_two.html) uses discrete transistors to do something similar - even giving you the possibility to control twice as many LEDs. But to be honest, this means a lot of effort and as plugwash states, it is probably more space / effort / cost effective to use external logic like shift registers or decoders. But perhaps I can make suggestion. It isn't really necessary to drive the LEDs symmetrically. I don't know if it is frowned upon, but here is a link where I describe this compromise in detail:
http://tomscircuits.blogspot.com/
Tom Frey (talk) 07:46, 21 April 2009 (UTC)

Charlieplexing is based on an idea from the 1970sEdit

Christopher Malinowski's German patent in 1979 (on which U.S. patent 4,319,227 is based) describes how to drive e.g. 12 LEDs on 4 wires, etc. Is there anything new in Charlieplexing other than doing exactly the same thing but with a microcontroller?

—Preceding unsigned comment added by 72.196.244.178 (talk) 02:00, 9 December 2009 (UTC)

For easier reference, here's a link to the "THREE STATE SIGNALING SYSTEM" patent (US4319227A, US 06/085335, CA1175526A1, DE2922595A1, DE2922595C2, priority 1979-06-02, filed 1979-10-16, issued 1982-03-09) by Christopher W. Malinowski, Heinz Rinderle, and Martin Siegle, all associated with Department of Research and Development, AEG-Telefunken, Heilbronn, Germany (although the patent doesn't appear to be assigned to AEG):
Regarding your question, I don't think, Charlieplexing is adding anything new, it is just a catchy new name for something much older. I have seen this trick being utilized in keyboard designs of the late 1980s, and - unaware of the prior art - intuitively used ad-hoc variants of what turns out to be following the same underlying idea in some design optimizations myself, therefore, I assume, others have done so as well...
However, the 1979 patent is already generic enough to apply to all kinds of parallel digital tri-state transmission paths to transfer data or addresses between information entities, and the method can be used to either reduce the number of necessary lines, or to increase the amount of information transferred. It includes applications such as keyboards, displays, memories, en- and decoders, active and passive transmitters and receivers, and does not even stop at electrical circuits. The "theory" of operation is described as well. Quite interesting, the text defines terms like combits, comwords, advantage ratio, etc.
--Matthiaspaul (talk) 21:52, 31 March 2015 (UTC)
Multiplexing led's this way has been around since the invention of the led. It is an easy discovery: who hasn't put in a led the wrong way? Charlieplexing is a specific multiplexing technique for driving 7-segment led displays as per Maxim application note. For some reason ( it sounds nice .. ) it has become a generic name, but strictly speaking this article does not address Charlieplexing but multiplexing in general.
94.214.169.209 (talk) —Preceding undated comment added 12:21, 6 December 2015 (UTC)

The clock in the pictureEdit

is backwards!

—Preceding unsigned comment added by Fastfourier (talkcontribs) 15:18, 11 October 2010 (UTC)

Alternate pathsEdit

 
3 pin, 6 LED scheme

Consider the 6 LED scheme, where we have pin 1 high and pin 2 grounded. The most direct path goes through LED1, directly between the two pins. However, current could also flow through LED6 to pin 3, then through LED4 to pin 2. In larger charlieplexed arrays, there would also be 3-LED paths, 4-LED paths, etc. between any two pins.

Why is this path not utilized? Does charlieplexing require that the voltage drop across the LEDs be more than half of the total voltage, such that there is insufficient voltage for two LEDs in series? Or is there really some current though this path, just not enough to trigger light emission. Would this leakage lead to higher current use than more traditional (and higher pin) multiplexing?

Any addition to the article clarifying these points would be appreciated. Perhaps another subsection of 'Problems'?

--Quantum7 06:06, 25 March 2012 (UTC)

The fact that the article skips this is a strange oversight, as it's the entire point of what makes charlieplexing work. Yes, you're on precisely the right track, due to how LEDs illuminate. The voltage drop across LED1 is nominal (eg if high is 5v, then it's 5v across led6) whereas the voltage drop across LED6 is half that (2.5 in my example) as is the drop across LED4. As you point out, there's a 2-LED path alongside every 1-LED path in the 3-pin array. However, LEDs illumination vs voltage is a curve, not linear (the exact shape varies, of course, but this property is true enough to exploit) such that an LED illuminated at half its proper voltage will usually be so dim as to be effectively off. (And when that's not true, it's effectively always possible to just deliberately reduce the voltage such that even in the 'on' state they're slightly undervolted but bright and in the 'half-volt' state they're unlit).
source: http://www.instructables.com/id/Charlieplexing-LEDs--The-theory/step4/Finallya-Charlieplex-matrix/ (and earlier pages) is decent but not particularly suitable for a citation.
98.212.197.213 (talk) 05:50, 12 April 2013 (UTC)
the "not linear" claim is untrue: led illumination is linear with current and with a series resistor current is linear with voltage (but not zero intersecting)
Jasen betts (talk) 23:03, 28 December 2015 (UTC)
Actually, LEDs should not emit any light when the applied voltage is below the band gap energy.
Mikhail Ryazanov (talk) 05:30, 23 November 2014 (UTC)
Actually it has been discovered that they do emit a little light at slightly below bandgap due to thermal noise pushing electrons over the edge, but that is unlikely to be significant here
Jasen betts (talk) 22:24, 28 December 2015 (UTC)
By the way, the circuit with individual resistors is worse in this respect, since voltages on all LEDs might be large enough (if pin voltages exceed 2 band gap energies, f.e. 5 V with red LEDs), whereas in the case of a common resistor the "active" LED limits the voltage applied to the "alternative" chain.
Mikhail Ryazanov (talk) 07:26, 25 November 2014 (UTC)
yes, that is a bad circuit
Jasen betts (talk) 22:24, 28 December 2015 (UTC)

External links modifiedEdit

Hello fellow Wikipedians,

I have just modified one external link on Charlieplexing. Please take a moment to review my edit. If you have any questions, or need the bot to ignore the links, or the page altogether, please visit this simple FaQ for additional information. I made the following changes:

When you have finished reviewing my changes, please set the checked parameter below to true or failed to let others know (documentation at {{Sourcecheck}}).

As of February 2018, "External links modified" talk page sections are no longer generated or monitored by InternetArchiveBot. No special action is required regarding these talk page notices, other than regular verification using the archive tool instructions below. Editors have permission to delete these "External links modified" talk page sections if they want to de-clutter talk pages, but see the RfC before doing mass systematic removals. This message is updated dynamically through the template {{sourcecheck}} (last update: 15 July 2018).

  • If you have discovered URLs which were erroneously considered dead by the bot, you can report them with this tool.
  • If you found an error with any archives or the URLs themselves, you can fix them with this tool.

Cheers.—InternetArchiveBot (Report bug) 14:49, 20 November 2016 (UTC)

Reverse voltageEdit

LEDs are not capable to resist a high Reverse Vorlage. I think it Works but is Out of specific range. — Preceding unsigned comment added by 2A01:598:9180:C013:C138:5C39:30DE:C3AC (talk) 20:15, 2 December 2016 (UTC)

Diodes are produced so that the reverse voltage is higher than the forward voltage and voltage on any diode in charlieplexed circuits will never be higher than forward voltage. Therefore it is impossible to exceed capabilities of a diode. -- wikimpan (Talk) 02:44, 7 June 2017 (UTC)

Multiple serious issuesEdit

I believe that the article has multiple grave issues. The article should be cleaned up, but since I am unsure what the authors of the previous edits actually meant, I am also not very willing to do that without first getting the following questions solved.

  • The Maxim’s article and the patents describe something different than what the article describes. All of them contain descriptions that incorporate, as a part of the solution, circuits that reduce pin count that resemble the article’s subject, but neither of them clearly describes exactly this approach. Do we have any good sources that clearly describe this particular thing? Because right now it seems like the article is based primarily on someone’s own research on the topic.
  • The structure is somewhat odd. The ideas on which charlieplexing is based are described in a paragraph entitled “Traditional multiplexing”.
  • The order of sections is strange too: first there are conclusions on how charlieplexing pin count, then there is a description of the ideas that form the base for charlieplexing, the overviews itself is mixed up with them. Shouldn’t it be different?
  • The reason charlieplexing works is that the conducting diode will keep voltage on any other branch not higher than its forward voltage. This guarantees that voltage on any other diode will never exceed either its forward or reverse voltage. However the circuit presented in “3-pin configuration for different LEDs” has no such guarantee, because — due to resistors — all the branches receive full voltage from the microcontroller and more than one branch may be in conducting mode. There are very specific scenarios with specific output voltages, resistance values and matched LEDs in which this may work, but it is not a typical case — and the article doesn’t even discuss the thing.
  • The requirement described in the previous point is not clearly highlighted in the article.
  • The article misses a description of Y-s from the two bottom images (1, 2). It is also not clear how these circuits should work.
  • The whole article sounds like a tutorial on how to build a charlieplexed circuit, not an encyclopedic description.
  • The section on refresh rate seems to describe a problem with a particular implementation from the Maxim’s article: not of the general approach.
  • LEDs often have a maximum peak current rating as well as an average current rating.: certainly, but how does this relate to the section?
  • In the diagram above it can be seen that if LED 6 has a 4 V forward voltage: which diagram — there are four of them.

-- wikimpan (Talk) 03:11, 7 June 2017 (UTC)

The whole article sounds like a tutorial on how to build a charlieplexed circuit, not an encyclopedic description.

My sentiments, exactly. The article should begin with the specific operating characteristics of common LEDs that permit this exploit in the first place. Instead we have an enormous tutorial that's treading 75% of the time on OR, as well. The most important trivial example is a parallel circuit, one with a single diode, the other with two diodes in series. Then you have two choice in how to insert the resistor: one resistor in series with both, or two resistors, each on separate branches. Then you have to comment on choosing the resistor based on operating duty cycle to obtain enough intermittent brightness, and the peak/average current ratings for the diodes also needs to be mentioned there, as well as drive current available per pin on a common MCU. This material is not the weeds for the bottom of the page, it's the essential material to make this circuit viable in the first place, and needs to be covered promptly before all this quasi-tutorial OR. — MaxEnt 17:11, 25 August 2020 (UTC)

FlickeringEdit

"Indeed, flicker cannot usually be seen when its frequency is greater than the so-called critical flicker fusion frequency (CFF), which is usually between ~60 and 90 Hz, although the frequency varies with the characteristics of the light and the observer." ... "during a saccade, the flicker could be seen as a trail of lights even when the frequency of the flicker was as high as 2 kHz."

I've tested my own eyes and they match this, perceiving 80 Hz flickering straight-on, and 1 kHz during saccades. — Omegatron (talk) 23:58, 24 July 2018 (UTC)

code exampleEdit

While the code example might be useful as reference for novice hobby-developers, its too long, bloats out the article, and adds little of informative value. I think removing it will improve on the consistency and readability of the article.

Return to "Charlieplexing" page.