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.

TM4C1294NCPDT: Hardware Circuit LED Design for RxD and TxD

Part Number: TM4C1294NCPDT
Other Parts Discussed in Thread: MAX3221

Hello. I am using TM4C1294NCPDT uC and need help in knowing whether what I have designed is correct.

In the RxD and TxD pin of uC, I am using LED (for indication of data transmitting and receiving) along with pull up resistor and another resistor for ground.The current taken by uC pin is around 4 mA. Is it fine if I use this or do I need to use Transistor in LED indication circuit ? 

  • Rakshita Dhar said:
    ...current taken by uC pin is around 4 mA. Is it fine if I use this or do I need to use Transistor in LED indication circuit ? 

    That's a bit much - the MCU is generally NOT to be "stressed" - far better for you to drive a small FET for such "indication purposes."       I suggest a "Logic Level N FET" - which drives the Led's cathode to ground - when your MCU pin is active (high) - driving the FET's gate.      (Led anodes tie to 3V3)      Drawing 4mA from an MCU pin should NOT prove damaging - yet is outside, "best practice" - especially so when alternate methods are available...

    Note that if the UART is operated at "high enough" data speeds - Led turn on / off - may be "too brief" to be viewed comfortably.     (as a guide to assist your, "Baud Rate Selection" - @ 9600 bps - each serial bit has a duration of 104µS.    Depending upon the Leds employed (even their color) so brief a pulse may / may not be easily recognized.)

    There are other methods which better solve your desire to, "observe signal activity upon key MCU pins."     These would, "Await the arrival of a signal pulse - and then generate an "adjustable width" output pulse - which "insures" the Led will be "well noted."     And - w/use of the earlier suggested FETs - this may be done substantially w/in the MCU - employing the MCU's Timer to output a programmed pulse width - which is fed to the Led Driving FET. 

    There is yet (another) method of "Signal Monitoring" - which saves you the: time, effort, cost of that "to be added" Led circuitry.      You can route both UART_RX & UART_TX to (separate) free MCU Timer input pins - and set those Timers to a (very) high count.     In this manner - your review of each Timer's Count Register (and discovery of count change) - "proves that UART activity" has occurred.

    If you "must" use the Leds - upon reaching a, "minimum number of counts" the resulting interrupt - (w/in its ISR) may trigger a GPIO Output (into a FET) which lights your Led...

  • cb1_mobile said:
    There are other methods which better solve your desire to, "observe signal activity upon key MCU pins."     These would, "Await the arrival of a signal pulse - and then generate an "adjustable width" output pulse - which "insures" the Led will be "well noted."     And - w/use of the earlier suggested FETs - this may be done substantially w/in the MCU - employing the MCU's Timer to output a programmed pulse width - which is fed to the Led Driving FET. 

    Alternatively something simple in H/W like an R/C followed by a comparator.

    Some transceivers have similar functionality. The MAX3221 has a pin that indicates if the receive line is connected.

    Robert

    Apparently log ins are working again.

  • Just to make sure here, are you talking about UART or ETHERNET? Or maybe some other comm peripheral?

    If it is UART, do as cb1 says: do NOT use leds on the Tx/Rx lines, but rather assign a separate GPIO and create some "smart" led blinking software based. The idle UART signal is HIGH, anyway, and your led will be ON almost permanently, and you won't be able to see it turning off for such brief bit times.

    If it is ethernet, then the pins are already exclusive for leds, and every example and implementation I've seen drive those tiny leds directly from the MCU.

    Bruno

  • Friend Bruno - greetings - while some here (i.e. Robert, Charles) struggle w/"log in" - those of us equipped w/"Secret Decoder Ring" gain immediate (tout de suite) acces - mais non?    (even Vendor's Charles seemed surprised - that "ring" is (far back) in vendor's catalog!")

    As your work day has expired (like that ever happens for we in SMALL Tech Biz) might you - for "extra credit" - inform our poster of the noted relationship between "LED Color" and the "Led's recognizable Output vs. Pulse ON time?"       (suspect some - (maybe many) here are disbelievers - yet cb1 has won "many a (fine) well drink"  -  when "money rides upon such outcome..."