So I tried to connect the ls20031 GPS with PWM pin 0 and 1 to rx and tx on MEGA 2560. tried tinyGPS code as provided on the internet. but it doesnt work. May I get some help from u guys who have work with it before. Appreciate it!
The Arduino Mega operates at 5V, but that GPS runs on 3.3V. So, if you are not already, you should use a voltage divider or level shifter on the TX pin of the Arduino to drop the voltage down to 3.3V. You should also make sure there is a common ground connection between the GPS and the Arduino, and check that your baud rate is set to 57600bps.
If you are still having trouble connecting after checking those things, can you tell me more about your setup? Can you post a picture that shows all of your connections and the sketch you are using? How are you powering the GPS?
By the way, if you have a USB-to-serial converter, you could verify that the GPS is working by connecting it to your computer via the converter and running the MiniGPS application, which you can find under the Resources tab of that GPS’s product page.
@JoabChua, in some cases, a 3.3V level is recognized by certain ICs but mostly they recognize a voltage level over 3.6V or 4.3V sometimes. If you search on the internet you’ll find a lot of buffer ICs that can act as a buffer as well as a level shifter. It is important for you to check if the level convertor that you’ll be using is unidirectional or bi-directional based on the application that you need it for. It is also important to check the propagation delay of these ICs since you intend on using it for very fast switching signals.