This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

BEAGLEBK: Modifying baud rate and uart receive never receives any bytes

Part Number: BEAGLEBK

Sending a lin break signal is not supported by the hardware for the am335. A workaround to this is to decrease the baud rate by 30% and send a 0x00 byte and restore the original baud rate.

The issue I am having is after this I do a write which is fine and then I perform a read, but this never receives any bytes. I am wondering is the uart in some bad state after shifting the baud rate. Is their some cleanup to be performed. I am using direct register writes for changing the baud rate as the posix interface only allows setting default baud rates.

Here is what I do when I am sending my break signal

// Get access to Divisor Latch registers
// Disable mode select
// Save current baud rate settings
// Change baud rate to custom value (DLH/DLL)
// Disable divisor latch access
// write 0x00
// Get access to Divisor Latch registers
// Disable mode select
// Restore baud rate to original value
// Disable divisor latch
Also I read that when accessing the mdr1 register there is a bug and a dedicated fix which I have implemented (http://www.ti.com/lit/er/sprz444a/sprz444a.pdf)  - i202 MDR1 Access Can Freeze UART Module
Then I perform a write (which looks fine on logic analyser)
Then I perform a read and doesn't receive anything (on logic analyser I can see the data on the line to be read)
  • Hi Noel,

    What OS are you using?

    Regards,
    Melissa
  • I am using QNX. 

  • Hi Noel,

    Sorry for the delay.  Are you still experiencing this issue?

    We don't support QNX, but below are a few generic debug suggestions:

    1.  Transmit 0x55 or 0xAA after each baud rate change and confirm that you’re transmitting the correct baud rate.

    2.  Create a loop back test (i.e. connecting the AM335x TX pin to the AM335x RX pin) and transmit data:

    - Before changing baud rate for line break

    - After changing baud rate for line break   (trying something other than

    - After changing baud rate back to original value

       Does AM335x see the correct RX values after each transmission?

    3.  Double-check that you’re following the sequence described in section 19.4.1.1.3 ("Protocol, Baud Rate, and Interrupt Settings") of the AM335x TRM and the errata steps

    Regards,

    Melissa

  • Hi Noel,

    I haven’t heard back from you and am assuming you were able to resolve your issue. If not, just post a reply below (or create a new thread if the thread has locked due to time-out).

    Thanks,
    Melissa