Skip to content

TinyRF85 example does not compile #11

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
themelispan opened this issue Jun 30, 2023 · 3 comments
Open

TinyRF85 example does not compile #11

themelispan opened this issue Jun 30, 2023 · 3 comments

Comments

@themelispan
Copy link

I tried compiling the TinyRF85 Receiver example with board "Digispark (Default - 16.5MHz)" which is my digispark ATtiny85 board. I chaged the line #include <SoftwareSerial.h> to #include <SoftSerial.h> because the compiler thought it should use the ESP8266/ESP32 SoftwareSerial library. Still, I am getting the error 'SoftwareSerial' does not name a type.

C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino:13:1: error: 'SoftwareSerial' does not name a type
SoftwareSerial mySerial(3, 4); //rx, tx
^
C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino: In function 'void setup()':
C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino:31:3: error: 'mySerial' was not declared in this scope
mySerial.begin(115200);
^
C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino: In function 'void loop()':
C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino:54:5: error: 'mySerial' was not declared in this scope
mySerial.println("Buffer too small for received data!");
^
C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino:59:5: error: 'mySerial' was not declared in this scope
mySerial.println("Received corrupted data.");
^
C:\Users\theme_9p6cezr\OneDrive\Arduino\Tiny85_RC_car_receiver\Tiny85_RC_car_receiver.ino:66:5: error: 'mySerial' was not declared in this scope
mySerial.print("Received: ");
^

exit status 1

Compilation error: 'SoftwareSerial' does not name a type

@pouriap
Copy link
Owner

pouriap commented Jul 1, 2023

I haven't used that library but I guess you should change the line

SoftwareSerial mySerial(3,4);  //rx, tx

to

SoftSerial mySerial(3,4);  //rx, tx

@themelispan
Copy link
Author

I tried it, it doesn't work. It will only compile if I comment out all serial-related commands

@pouriap
Copy link
Owner

pouriap commented Jul 5, 2023

Does the library have an example sketch? Does the example sketch compile?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants