Arduino 7 segment 4 digit library SevSeg

When I try the following code out, the display shows four "8." instead of "12.54". Why?

#include "SevSeg.h"
SevSeg sevseg;

//D1 = pin 2 ... D4 = pin 5
//a = pin 6
//b = pin 7 etc...
//dp = pin 13

void setup() {
  const int numDigits = 4;
  byte digitPins[] = {2, 3, 4, 5};
   byte segmentPins[] = {6, 7, 8, 9, 10, 11, 12, 13};
  sevseg.begin(COMMON_ANODE, numDigits, digitPins, segmentPins);
}

void loop() {
  sevseg.setNumber(1254,2);
  sevseg.refreshDisplay();
}

You've probably done something wrong.
Like, not posting a schematic, or not posting enough details.

Hi,

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

What are the 7seg displays you are using?
What model Arduino are you coding?

Thanks.. Tom... :slight_smile: