far-galaxy / N4

Светильник многофункциональный Н4
GNU General Public License v3.0
0 stars 0 forks source link

Не собирается... #1

Open Menooooo opened 2 years ago

Menooooo commented 2 years ago

In file included from C:\Users\ASUS\Downloads\N4-master\N4-master\N4 Rev.2\N4.2\N4.2.ino:79:0: D:\Program Files (x86)\Arduino\libraries\FastLED\src/FastLED.h:14:21: note: #pragma message: FastLED version 3.004.000

pragma message "FastLED version 3.004.000"

                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~

N4.2:8:18: error: expected identifier before numeric constant

define FADE_OUT 10 // коэффициент плавности затухания (чем ниже, тем плавнее)

              ^

C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:77:9: note: in expansion of macro 'FADE_OUT' FADE_OUT, ^~~~ N4.2:8:18: error: expected '}' before numeric constant

define FADE_OUT 10 // коэффициент плавности затухания (чем ниже, тем плавнее)

              ^

C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:77:9: note: in expansion of macro 'FADE_OUT' FADE_OUT, ^~~~ N4.2:8:18: error: expected unqualified-id before numeric constant

define FADE_OUT 10 // коэффициент плавности затухания (чем ниже, тем плавнее)

              ^

C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:77:9: note: in expansion of macro 'FADE_OUT' FADE_OUT, ^~~~ In file included from C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/TM1637.h:6:0, from C:\Users\ASUS\Downloads\N4-master\N4-master\N4 Rev.2\N4.2\N4.2.ino:82: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:82:1: error: expected unqualified-id before 'public' public: ^~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:85:5: error: expected unqualified-id before '{' token {} ^ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:87:16: error: variable or field 'blink' declared void void blink(Tasker::duration_type delay) ^~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:87:16: error: 'Tasker' has not been declared C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:102:18: error: variable or field 'fadeOut' declared void void fadeOut(Tasker::duration_type delay) ^~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:102:18: error: 'Tasker' has not been declared C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:117:17: error: variable or field 'fadeIn' declared void void fadeIn(Tasker::duration_type delay) ^~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:117:17: error: 'Tasker' has not been declared C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:134:21: error: variable or field 'scrollLeft' declared void void scrollLeft(Tasker::duration_type delay) ^~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:134:21: error: 'Tasker' has not been declared C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:159:16: error: non-member function 'void off()' cannot have cv-qualifier void off() const ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: In function 'void off()': C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:161:9: error: 'sendToDisplay' was not declared in this scope sendToDisplay<DataCommand_e::FIXED_ADDRESS, AddressCommand_e::C6H>(DisplayControl_e::DISPLAY_OFF); ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:161:23: error: 'DataCommand_e' has not been declared sendToDisplay<DataCommand_e::FIXED_ADDRESS, AddressCommand_e::C6H>(DisplayControl_e::DISPLAY_OFF); ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:161:53: error: 'AddressCommand_e' has not been declared sendToDisplay<DataCommand_e::FIXED_ADDRESS, AddressCommand_e::C6H>(DisplayControl_e::DISPLAY_OFF); ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:161:76: error: 'DisplayControl_e' has not been declared sendToDisplay<DataCommand_e::FIXED_ADDRESS, AddressCommand_e::C6H>(DisplayControl_e::DISPLAY_OFF); ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: At global scope: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:164:13: error: variable or field 'on' declared void void on(DisplayControl_e brightness) const ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:164:13: error: 'DisplayControl_e' was not declared in this scope C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:164:13: note: suggested alternative: 'PixelController' void on(DisplayControl_e brightness) const ^~~~ PixelController C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: In function 'void reset(const String&)': C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:170:9: error: 'buffer' was not declared in this scope buffer_ = ""; ^~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:172:22: error: 'toDisplayDigit' was not declared in this scope auto d = toDisplayDigit(value[counter]); ^~~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:172:22: note: suggested alternative: 'isDigit' auto d = toDisplayDigit(value[counter]); ^~~~~~ isDigit C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:178:9: error: 'resetAnimation' was not declared in this scope resetAnimation(); ^~~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:178:9: note: suggested alternative: 'Animator' resetAnimation(); ^~~~~~ Animator C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: In function 'void clear()': C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:183:9: error: 'buffer' was not declared in this scope buffer_ = ""; ^~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:184:42: error: 'totalDigits' was not declared in this scope for (sizet counter{}; counter < totalDigits; ++counter) ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:186:9: error: 'refresh' was not declared in this scope refresh(); ^~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: In function 'void refresh()': C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:191:9: error: 'sendToDisplay' was not declared in this scope sendToDisplay<DataCommand_e::AUTOMATIC_ADDRESS_ADDING, AddressCommand_e::C0H>( ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:191:23: error: 'DataCommand_e' has not been declared sendToDisplay<DataCommand_e::AUTOMATIC_ADDRESS_ADDING, AddressCommand_e::C0H>( ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:191:64: error: 'AddressCommand_e' has not been declared sendToDisplay<DataCommand_e::AUTOMATIC_ADDRESS_ADDING, AddressCommand_e::C0H>( ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:192:17: error: 'brightness' was not declared in this scope brightness_, ^~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:192:17: note: suggested alternative: 'brighten8lin' brightness, ^~~ brighten8_lin C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:193:50: error: 'buffer' was not declared in this scope reinterpret_cast<const uint8t*>(buffer.c_str()), ^~~ In file included from sketch\N4.2.ino.cpp:1:0: C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:194:55: error: 'totalDigits' was not declared in this scope static_cast(min((unsigned int)totalDigits, buffer.length()))); ^ D:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:92:20: note: in definition of macro 'min'

define min(a,b) ((a)<(b)?(a):(b))

                ^

In file included from C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/TM1637.h:6:0, from C:\Users\ASUS\Downloads\N4-master\N4-master\N4 Rev.2\N4.2\N4.2.ino:82: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: At global scope: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:197:1: error: expected unqualified-id before 'private' private: ^~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:203:39: warning: inline variables are only available with -std=c++1z or -std=gnu++1z static inline uint8_t control2Int(DisplayControl_e e) noexcept ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:203:39: error: 'DisplayControl_e' was not declared in this scope C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:203:39: note: suggested alternative: 'PixelController' static inline uint8_t control2Int(DisplayControl_e e) noexcept ^~~~ PixelController C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: In function 'void resetAnimation()': C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:211:9: error: 'currentAnimation' was not declared in this scope currentAnimation = Animation::NONE; ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:211:9: note: suggested alternative: 'resetAnimation' currentAnimation = Animation::NONE; ^~~~ resetAnimation C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:211:28: error: 'Animation' has not been declared currentAnimation = Animation::NONE; ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h: At global scope: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:214:19: error: 'DisplayControl_e' does not name a type; did you mean 'PixelController'? static inline DisplayControl_e fetchControl(uint8_t value) noexcept ^~~~ PixelController C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:234:15: error: 'DataCommand_e' has not been declared template <DataCommand_e DATA_COMMAND, AddressCommand_e ADDRESS_COMMAND> ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:234:43: error: 'AddressCommand_e' has not been declared template <DataCommand_e DATA_COMMAND, AddressCommand_e ADDRESS_COMMAND> ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:235:24: error: variable or field 'sendToDisplay' declared void void sendToDisplay(DisplayControl_e displayControl) const noexcept ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:235:24: error: 'DisplayControl_e' was not declared in this scope C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:235:24: note: suggested alternative: 'PixelController' void sendToDisplay(DisplayControl_e displayControl) const noexcept ^~~~ PixelController C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:248:15: error: 'DataCommand_e' has not been declared template <DataCommand_e DATA_COMMAND, AddressCommand_e ADDRESS_COMMAND> ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:248:43: error: 'AddressCommand_e' has not been declared template <DataCommand_e DATA_COMMAND, AddressCommand_e ADDRESS_COMMAND> ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:249:24: error: variable or field 'sendToDisplay' declared void void sendToDisplay(DisplayControl_e displayControl, const uint8_t values, size_t size) const noexcept ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:249:24: error: 'DisplayControl_e' was not declared in this scope C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:249:24: note: suggested alternative: 'PixelController' void sendToDisplay(DisplayControl_e displayControl, const uint8_t values, size_t size) const noexcept ^~~~ PixelController C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:249:57: error: expected primary-expression before 'const' void sendToDisplay(DisplayControl_e displayControl, const uint8_t values, size_t size) const noexcept ^~~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:249:87: error: expected primary-expression before 'size' void sendToDisplay(DisplayControl_e displayControl, const uint8_t values, size_t size) const noexcept ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:265:25: error: no matching function for call to 'MI2C::MI2C()' MI2C mi2C; ^~~~~ In file included from C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:6:0, from C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/TM1637.h:6, from C:\Users\ASUS\Downloads\N4-master\N4-master\N4 Rev.2\N4.2\N4.2.ino:82: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/mI2C.h:12:5: note: candidate: MI2C::MI2C(uint8_t, uint8_t) MI2C(uint8_t clkPin, uint8t dataPin) noexcept : clkPin{clkPin}, dataPin_{dataPin} ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/mI2C.h:12:5: note: candidate expects 2 arguments, 0 provided In file included from C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/TM1637.h:6:0, from C:\Users\ASUS\Downloads\N4-master\N4-master\N4 Rev.2\N4.2\N4.2.ino:82: C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:266:5: error: 'DisplayControl_e' does not name a type; did you mean 'PixelController'? DisplayControle brightness = DisplayControl_e::DISPLAY_ON; ^~~~ PixelController C:\Users\ASUS\Documents\Arduino\libraries\TM1637Driver\src/animator.h:269:25: warning: uninitialized const 'totalDigits' [-fpermissive] const uint8t totalDigits; ^~~~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:270:5: error: 'Tasker' does not name a type Tasker tasker; ^~ C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:271:5: error: 'Animation' does not name a type; did you mean 'Animator'? Animation currentAnimation = Animation::NONE; ^~~~~ Animator C:\Users\ASUS\Documents\Arduino\libraries\TM1637_Driver\src/animator.h:288:1: error: expected declaration before '}' token }; ^ exit status 1 expected identifier before numeric constant

far-galaxy commented 2 years ago

Конечно, спустя год отвечать, крайне забавно, но всё же отвечу, что надо использовать библиотеки из папки lib этого репозитория (т.е. перетащить содержимое этой папки в Документы/Arduino/libraries); с другими библиотеками, естественно, это не соберётся. В данном случае, из-за неправильной библиотеки случилось наложение #define, поэтому всё сломалось.

Если вы ещё на связи, то прошу рассказать о ваших успехах в сборке светильника, сейчас активно занимаюсь разработкой новой версии, из-за чего я и заметил этот issue (: