boylesg:
You need to include the FastLED header file in the .cpp file of your library.
You have probably included the FastLED header file in your .ino file, but that is no help to your library source files.
Hiho,
thanks for the reply.
I have the Lib included in the header of the class of my library, as I declare the CRGB array there.
Then the header is included in the cpp file.
I have also tried to also include the FastLED.h within the cpp file, sadly it did not solve the problem. Also only declaring within within cpp and adding FastLED only there - same problem.
HereĀ“s more of the error list, maybe someone sees the problem:
LEDSystem.cpp: 15:56: error: no matching function for call to 'CFastLED::addLeds(CRGB*&, int)
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)
LEDSystem.h:5: In file included from
LEDSystem.cpp:1: from
FastLED.h:223: note candidate template<ESPIChipsets CHIPSET, unsigned char DATA_PIN, unsigned char CLOCK_PIN, EOrder RGB_ORDER, unsigned char SPI_DATA_RATE> CLEDController& CFastLED addLeds(CRGB*, int, int)
template<ESPIChipsets CHIPSET, uint8_t DATA_PIN, uint8_t CLOCK_PIN, EOrder RGB_ORDER, uint8_t SPI_DATA_RATE > CLEDController &addLeds(struct CRGB *data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:223: note template argument deduction\substitution failed
LEDSystem.cpp: 15:56: error: could not convert template argument 'WS2812B' to 'ESPIChipsets
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)
LEDSystem.h:5: In file included from
LEDSystem.cpp:1: from
FastLED.h:237: note candidate template<ESPIChipsets CHIPSET, unsigned char DATA_PIN, unsigned char CLOCK_PIN> static CLEDController& CFastLED addLeds(CRGB*, int, int)
template<ESPIChipsets CHIPSET, uint8_t DATA_PIN, uint8_t CLOCK_PIN > static CLEDController &addLeds(struct CRGB *data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:237: note template argument deduction\substitution failed
LEDSystem.cpp: 15:56: error: could not convert template argument 'WS2812B' to 'ESPIChipsets
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)
LEDSystem.h:5: In file included from
LEDSystem.cpp:1: from
FastLED.h:251: note candidate template<ESPIChipsets CHIPSET, unsigned char DATA_PIN, unsigned char CLOCK_PIN, EOrder RGB_ORDER> static CLEDController& CFastLED addLeds(CRGB*, int, int)
template<ESPIChipsets CHIPSET, uint8_t DATA_PIN, uint8_t CLOCK_PIN, EOrder RGB_ORDER > static CLEDController &addLeds(struct CRGB *data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:251: note template argument deduction\substitution failed
LEDSystem.cpp: 15:56: error: could not convert template argument 'WS2812B' to 'ESPIChipsets
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)
LEDSystem.h:5: In file included from
LEDSystem.cpp:1: from
FastLED.h:301: note candidate template<template<unsigned char DATA_PIN, EOrder RGB_ORDER> class CHIPSET, unsigned char DATA_PIN, EOrder RGB_ORDER> static CLEDController& CFastLED addLeds(CRGB*, int, int)
static CLEDController &addLeds(struct CRGB data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:301: note template argument deduction\substitution failed
FastLED.h:307: note candidate template<template<unsigned char DATA_PIN, EOrder RGB_ORDER> class CHIPSET, unsigned char DATA_PIN> static CLEDController& CFastLED addLeds(CRGB, int, int)
static CLEDController &addLeds(struct CRGB *data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:307: note template argument deduction\substitution failed
LEDSystem.cpp: 15:56: error: wrong number of template arguments (3, should be 2)
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)
LEDSystem.h:5: In file included from
LEDSystem.cpp:1: from
FastLED.h:313: note candidate template<template class CHIPSET, unsigned char DATA_PIN> static CLEDController& CFastLED addLeds(CRGB*, int, int)
static CLEDController &addLeds(struct CRGB *data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:313: note template argument deduction\substitution failed
LEDSystem.cpp: 15:56: error: wrong number of template arguments (3, should be 2)
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)
LEDSystem.h:5: In file included from
LEDSystem.cpp:1: from
FastLED.h:349: note candidate template<template class CHIPSET, EOrder RGB_ORDER> static CLEDController& CFastLED addLeds(CRGB*, int, int)
static CLEDController &addLeds(struct CRGB *data, int nLedsOrOffset, int nLedsIfOffset = 0) {
FastLED.h:349: note template argument deduction\substitution failed
LEDSystem.cpp: 15:56: error: wrong number of template arguments (3, should be 2)
FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS)