Skip to content
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

Inconsistent behavior when using SoftwareSerial #13

Open
Tsukinara opened this issue Feb 23, 2018 · 0 comments
Open

Inconsistent behavior when using SoftwareSerial #13

Tsukinara opened this issue Feb 23, 2018 · 0 comments

Comments

@Tsukinara
Copy link

Hello!

I am currently using an Arduino Nano (ATmega328P) to work with the Sweep, which only has a single set of RX and TX pins. Because of this, I am using Arduino's SoftwareSerial library to communicate with the sensor.

I have been using the example MegaSerialPrinter for testing, with the modifications of (1) using a SoftwareSerial stream instead of Serial1, and (2) continuously printing readings instead of collecting full revolutions first. However, although I am able to set the motor settings and get device information without a problem, I am unable to get readings from the sensor, as getReading returns false.

Oddly, this issue occurs intermittently, and the program behaves perfectly as expected roughly 10% of the time. However, upon resetting, all calls to getReading fail, and no data can be read. I have confirmed that the isScanning is true when getReading is called, and that the firmware is up to date. I have attached the code I am using to test, if it is relevant.
scanse_test.zip

Thanks!

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

1 participant