Here's a brain teaser for you:

I have the following 3 digit 7 segment display that has only 6 wires

Experimentally I found out how it works, even though I don't understand it, but anyways every segment is lit by a combination of HIGH and LOW of certain two pins, the combinations are below:

So I tried to make it work, but encountered the following problem (as you can see in the first picture): if, for example, I want to activate the segment that requires pin 5 high and pin 6 low, it also activates the other segments that require 5 to high, because apparently if a digital output is not high, it's automatically pulled to ground, and that's a problem. I tried by setting the other pins I don't use in a segment to high, but then the segments that require 6 low are being activated, so that didn't work.

Other option I have would be transistors or a tri-state buffer, but for that I need all 12 digital inputs of arduino for the two states of each pin of the display.

Hope you understand what my problem is and maybe you have some advice on how to solve it.

Thanks in advance!

Edit: I managed to drive every segment individually using a small delay, and it works if the sketch has only the code for the display, but as soon as I add more code (for the temperature sensor I want to use) it starts to malfunction. You can find the code below.

LE: I managed to make it work by leaving only the display function in the loop and calling every 5 seconds the function for the temperature sensor. It still refreshes the display when it is called, but that doesn't bother me.

Here's the code: http://www.mediafire.com/file/2bs5r8u5rkzpu8g/6w_3D_7S_display.rar

  • 2
    You can emulate tri-state by setting a pin to INPUT. That gives you your three states that you need: OUTPUT & HIGH, OUTPUT & LOW, and INPUT. – Majenko Mar 23 '18 at 21:28
  • Sometimes the simplest solution is the best solution, thanks Majenko! – sundaysfantasy Mar 23 '18 at 21:41
  • The link to your code is not working. – VE7JRO Mar 25 '18 at 14:34
  • I changed the upload site, try now. – sundaysfantasy Mar 25 '18 at 17:00
  • 1
    It’s a hassle because I split the code into tabs and would mean to upload everything individually. Anyways, I solved the issue. – sundaysfantasy Mar 26 '18 at 15:13

What you have is a Charlie-Plexed display like the one in the picture below. You need one more wire than this example because your display also includes the decimal point. If you go through the electrical paths where for each pair one line is driven high, the other is driven low and all other lines are set to input, only one LED at a time will be forward biased.

enter image description here

| improve this answer | |
  • Yes, that’s exactly how i did it, glad to find out how it works, thanks ! – sundaysfantasy Mar 28 '18 at 4:40

Before I can answer your question, I need you to answer a few questions first.

  1. I've circled 2 things on your image of the display connected to the Arduino. Are they wires from the 7 segment display module that have been bent out of the way so they don't connect with the positive supply rail of the solder-less breadboard?

  2. Isn't there a row of 5 or 6 pins at the top of the 7 segment display module that are plugged into the positive supply rail of the solder-less breadboard?

  3. Is the positive supply rail of the solder-less breadboard connected to any power supply or to the 5V output of the Arduino?

enter image description here

Normally, these 7 segment displays are classified as common anode or common cathode displays. If your display actually has 11 or 12 connections on the back of it, then you may want to start looking for a diagram like this one to better understand the internal connections of the display.

enter image description here

EDIT: Here are 2 more images that may help to explain whats going on inside the display module.

enter image description here enter image description here

There are many libraries for Arduino that simplify driving these 7 segment displays.

| improve this answer | |
  • The 2 wires were bent in order to fit the display on the other holes. I tested them and nothing happened, also from the circuit I got the display those two weren’t connected. It has another six wires and depending how I apply voltage segments are lit. I still don’t know how it works because every one of those six can work with either 5V or GND. – sundaysfantasy Mar 24 '18 at 14:13
  • Please update your question with the sketch you are using to drive the display. – VE7JRO Mar 24 '18 at 19:11
  • I added the code and a brief explanation of the new problem – sundaysfantasy Mar 25 '18 at 8:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.