-1

I was following this tutorial, and everything is wired correctly as far as I can tell, but my 7seg display is only showing 8888. I tried uploading the code to the controller but I get back "no matching function for call to 'SevSeg::SevSeg()'" I'm not sure what I'm doing wrong. Any help would be greatly appreciated. Thank you!

full error message:


DaysCounterTest:4:8: error: no matching function for call to 'SevSeg::SevSeg()'

 SevSeg sevseg; //Instantiate a seven segment controller object

        ^~~~~~

In file included from C:\Users\Cel\Documents\Arduino\DaysCounterTest\DaysCounterTest.ino:2:0:

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:49:3: note: candidate: SevSeg::SevSeg(byte*, byte*, byte, byte, bool, bool, bool)

   SevSeg( byte segmentPinsIn[], byte digitPinsIn[], byte numDigitsIn = 4, byte hardwareConfig = COMMON_ANODE,

   ^~~~~~

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:49:3: note:   candidate expects 7 arguments, 0 provided

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:46:7: note: candidate: constexpr SevSeg::SevSeg(const SevSeg&)

 class SevSeg

       ^~~~~~

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:46:7: note:   candidate expects 1 argument, 0 provided

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:46:7: note: candidate: constexpr SevSeg::SevSeg(SevSeg&&)

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:46:7: note:   candidate expects 1 argument, 0 provided

C:\Users\Cel\Documents\Arduino\DaysCounterTest\DaysCounterTest.ino: In function 'void setup()':

DaysCounterTest:87:50: error: no matching function for call to 'SevSeg::begin(byte&, byte&, byte [4], byte [8], bool&, bool&, bool&, bool&)'

   updateWithDelays, leadingZeros, disableDecPoint);

                                                  ^

In file included from C:\Users\Cel\Documents\Arduino\DaysCounterTest\DaysCounterTest.ino:2:0:

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:53:8: note: candidate: void SevSeg::begin(byte*, byte*, byte, byte, bool, bool, bool)

   void begin( byte segmentPinsIn[], byte digitPinsIn[], byte numDigitsIn = 4, byte hardwareConfig = COMMON_ANODE,

        ^~~~~

C:\Users\Cel\Documents\Arduino\libraries\Firmware/SevSeg.h:53:8: note:   candidate expects 7 arguments, 8 provided

exit status 1

no matching function for call to 'SevSeg::SevSeg()'



This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Cel F
  • 1
  • Please post the code you uploaded and provide a link to the tutorial you mentioned. – Nino Jul 09 '21 at 06:51
  • The problem arises long before uploading, when compiling your tutorial code. So it's not a wiring question (yet). If that does not help yet: Restart the tutorial from scratch and follow instructions precisely. – datafiddler Jul 09 '21 at 12:35

1 Answers1

0

I noticed my links were not posted in my original post. I found that the libraries I needed were not importing correctly, more specifically the sevseg one. I needed to import another one with it. Now the 7 seg display is showing up correctly

Cel F
  • 1
  • This answer does nothing but report your project status. It doesn't belong here, as it doesn't show what you did wrong and how you fixed it. – TomServo Jul 12 '21 at 01:05