Comments (10)
I'm sorry for the delay. You've probably figured it out by this time.
But will you please send me all your code so I can duplicate your problem?
Thanks,
Bud
from tfmini-plus.
from tfmini-plus.
There was no attachment with your last message.
Please send me your entire sketch ("all your code") so that I can duplicate your problem.
You may send the archive to my email [email protected]
Please include images of your setup and cabling, if you think that will be helpful.
Thanks,
Bud
from tfmini-plus.
-
You listed only two lines of output:
SET_Mode: Status: SERIAL
00 00 00 00 00 00 00 00
Is that it? Only two lines? No "Hello"?
Something like:
TFMPlus Library Example - 18JUN2020
-
Your Software Serial assignment of Pins 0 & 1
SoftwareSerial mySerial( 0, 1);
appears to use the same pins as the hardware serial port.
Are you sure about those pin assignments?
Which Arduino board (and revision) are you using? -
Is the Arduino working? Is the sensor working?
Is the Arduino working okay with the sensor in Serial mode?
We'll fix this.
Bud
from tfmini-plus.
from tfmini-plus.
-
I apologize for any confusion. Your [images] are not showing up here. Please save your output into a text file and attach or send me the file.
-
The D0 & D1 pins on the Nano V3.0 Module ATmega328P 5V 16MHz CH340G are the hardware serial lines that you use to program and communicate with the Nano from your IDE (running on your PC). The Nano has an onboard USB to TTL converter (CH340G) that requires the use of these pins. You cannot use these same pins to communicate with your TFMini-Plus. That's why we use the Software Serial library - because the ATmega328P does not have a second hardware serial port. I believe that pins 9 & 10 will work for that purpose (11 & 12 are for the SPI interface) ; but please check the Software Serial documentation for your particular board.
You say that your Nano and your TFMini-Plus are working together just fine in Serial Mode. I don't see how that is possible, so I must really be misunderstanding something. Again, please send me a text file of your output from running the example sketch in the Serial Mode. Pictures of your wiring would be helpful, too.
-
You are correct that the I2C Mode is the way to go. It will allow you to use more than one TFMini-Plus on the same bus.
Bud Ryerson
San Francisco
from tfmini-plus.
from tfmini-plus.
Your images are still not showing.
You wrote that, "the sensor is working and giving me the correct distance with serial." So I asked to see the output from TFMP_example.ino
, the Serial Mode example sketch, running correctly. I don't see that. In the output you show above, every command has failed.
You wrote, "I do have to unplug the tx/rx wires to flash but then I plug back in and hit the rest button and monitor the output."
Why are you plugging and unplugging wires? Which "tx/rx wires" are you talking about? How do you "monitor the the output?"
I get the uneasy feeling that you are still confusing hardware and software serial ports. The hardware serial port is for programming and monitoring ONLY. The Software Serial port is for communicating with the Lidar. Am I wrong?
Please let me know.
Bud
from tfmini-plus.
from tfmini-plus.
Please understand that the Lidar device communicates with the Arduino - and the Arduino then turns around and communicates with the user (you). This requires two independent data channels. The USB cable connects the Arduino with your computer. It uses the D0 & D1 (TX/RX) pins. You cannot EVER use those to connect to the Lidar. You must use the Software Serial pins. BUT As soon as you send a SET_I2C_MODE
command to the Lidar, that device can no longer communicate in serial mode. So DO NOT send any commands to change the communication mode until after we've got everything working in serial mode. Okay?
I am still not getting your files or images. Please contact me further by email at:
bud-at-budryerson-dot-com
from tfmini-plus.
Related Issues (20)
- 'fdevopen' was not declared in this scope HOT 2
- TFmini plus timeout? HOT 7
- How to change 100Hz measurement frame rate to 1000HZ? HOT 1
- printf.h: No such file or directory HOT 3
- How to use TFmini plus distance reading as a threshold? HOT 2
- Failure rate HOT 5
- "Status: Checksum" Galore HOT 4
- Wrong constant in TFMPlus.h HOT 2
- sendCommand() not working with Arduino MKR GSM 1400 HOT 5
- Signal saturation Data - Error HOT 5
- Setting precision to mm HOT 2
- TFMini-Plus Neuf HOT 5
- What is this library called in the Arduino examples HOT 7
- 2x (or more) devices on one board? HOT 19
- Any working code in arduino uno? HOT 1
- How to use multiple TFMini Plus and TF02 Pro sensors on AT Mega 2560? HOT 5
- got message - Status: HEADER Data: 20 09 68 FF 20 09 68 FF 20 HOT 1
- Need some help with TF-Luna and Seeeduino XIAO HOT 3
- PIN_WIRE_SDA' was not declared in this scope
- RPi Pico CRC check error (memcpy)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tfmini-plus.