francibm97 / UM3750

An arduino library to emulate the UM3750 encoder/decoder and transmit or receive fixed 12 bit codes over the 315/433MHz bandwidth.
MIT License
7 stars 1 forks source link

Can't compile the receive sample code #1

Closed BubbleKID closed 5 years ago

BubbleKID commented 5 years ago

`C:\Users\fqche\Documents\Arduino\sketch_nov06c\sketch_nov06c.ino: In function 'void loop()':

sketch_nov06c:11: error: no matching function for call to 'UM3750::Code::Code()'

 UM3750::Code code;

              ^

C:\Users\fqche\Documents\Arduino\sketch_nov06c\sketch_nov06c.ino:11:18: note: candidates are:

In file included from C:\Users\fqche\Documents\Arduino\sketch_nov06c\sketch_nov06c.ino:1:0:

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:52:3: note: UM3750::Code::Code(int, float)

Code(int value, float symbolDurationTime) {

^

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:52:3: note: candidate expects 2 arguments, 0 provided

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:48:3: note: UM3750::Code::Code(int)

Code(int value) {

^

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:48:3: note: candidate expects 1 argument, 0 provided

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:44:9: note: constexpr UM3750::Code::Code(const UM3750::Code&)

struct Code {

     ^

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:44:9: note: candidate expects 1 argument, 0 provided

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:44:9: note: constexpr UM3750::Code::Code(UM3750::Code&&)

C:\Users\fqche\Documents\Arduino\libraries\UM3750-master\src/UM3750.h:44:9: note: candidate expects 1 argument, 0 provided

sketch_nov06c:24: error: 'um3750' was not declared in this scope

 um3750.resetReceivedCode();

 ^`
BubbleKID commented 5 years ago

Hi francibm97, should I initialize the struct code with some arguments? Is um3750 equals to myUM3750? Cheers

francibm97 commented 5 years ago

Sorry for the late response.

I'm sorry for those mistakes and I thank you for pointing them out, I'm updating the readme with a working example.

Bye