0

I am trying to interface Tiva C (TM4C123GH6PM) with FTDI connected to PC using UART. I am able to transmit data from Tiva C, but unable to receive data from PC through FTDI.

I tried loopback with the same Tiva C UART peripheral and it worked. I also tried interfacing ESP32 and FTDI using UART and it worked, so I know my FTDI works fine.

zx485
  • 28,498
  • 28
  • 50
  • 59
  • 1
    what speeds are you running and how accurate is the divisor in the mcu? (how accurate is the system clock)(look at the tx transmission on a scope). – old_timer Jul 31 '23 at 17:42
  • Baud rate I'm using is 115200 bps – Dyutimoy Biswas Aug 01 '23 at 02:20
  • what is your accuracy though? have you tried 9600? – old_timer Aug 01 '23 at 06:21
  • are you using a crystal/oscillator or are you using the internal clock source? – old_timer Aug 01 '23 at 06:31
  • I'm using 16 MHz main oscillator at 115200 bps. I am unable to understand why I'm able to transmit but not receive; if my parameters were incorrect surely it wouldn't have allowed me to transmit as well? – Dyutimoy Biswas Aug 01 '23 at 06:48
  • Should I post my code? – Dyutimoy Biswas Aug 01 '23 at 06:49
  • 1
    Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Aug 01 '23 at 07:27
  • I want to be able to receive data from FTDI (https://ftdichip.com/products/ft232rl/) through UART, to my Tiva C board. When I type data in my PC connected to FTDI, my Tiva C should read it as it is connected to FTDI. – Dyutimoy Biswas Aug 01 '23 at 07:53
  • reasons why it may not work include...the ftdi is not sending anything out, which in theory was debugged using a loopback between the tx and rx on the ftdi as well as using it with another mcu. So remaining issues, assuming no simple mistakes like wiring or blowing up I/O pads or something, can be that the ftdi's uart oversampling is better than your tiva c uart oversampling such that the actual frequency you are sending (cant be exactly 115200, not possible unless you have an odd valued crystal driving the chip) not uncommon to have it work only one way based on clocks alone. – old_timer Aug 01 '23 at 15:23
  • what have you done to insure it is not a clock issue (accuracy of the reference clock, and then accuracy of the divisor of that clock as well as how much oversampling)? The math should have been done when choosing the baud rate and divisors, if not already done for you in the datasheet/reference manual (some vendors do the table with accuracy, some dont, dont remember what ti does). – old_timer Aug 01 '23 at 15:24
  • we are still waiting for information to help with this issue. What did the scope show of the tx from the mcu and the tx from the ftdi? are you using the right voltage levels? 1.8 into 3.3 for example? – old_timer Aug 01 '23 at 18:24
  • this is a hardware debug not software debug at this point we do not have the hardware so you have to do the debug. if it becomes a software debug then we can help. – old_timer Aug 01 '23 at 18:25

0 Answers0