-1

I'm new to raspberry pi, and I have a raspberry pi 4. I'm trying to read gps data from RX-TX pins, but it prints nothing. I'm using: sudo cat /dev/ttyAMA0 This command should print the data coming from the GPS module, but it prints nothing. I've searched trough all youtube and web for tutorials and solutions but found nothing. Everyone using pi 3.

People are changing the cmdline.txt from original to: dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet splash plymouth.ignore-serial-console I tried both with the original file and with this lines replaced, nothing happened. I have enabled the UART from config. The GPS module is "Ublox Neo 7M" Thanks.

  • 1
    Please show exactly how you have connected all wiring and also format your code properly by selecting it with your mouse and clicking `{}` in the Formatting Toolbar beside **Bold** and *Italic*. Thank you. – Mark Setchell Aug 28 '21 at 08:47
  • Also be aware that you need additional electronics when connecting most GPS receivers to a Raspberry Pi, because the input level is only 3.3V, while a standard RS232 output operates at up to 25V. – PMF Aug 28 '21 at 12:26

1 Answers1

1

I solved this problem via formatting the SD card.

For those who will read this post later: If you have a Raspberry pi 4; DO NOT change the cmdline.txt file, as shown in many tutorials made with Pi 3. It's not necessary. Connect the RX pin on module to TX pin on Pi, and TX to RX. Finally; first check id the data coming to Pi with terminal, not on python code that using serial library.