Turn-key PCB assembly services in prototype quantities or low-volume to mid-volume production runs

Half duplex UART from single AVR pin

Smaller microcontrollers like Attiny84 microcontrollers don’t have UART interface and in many cases you may not need it. But if you will want to have an USART option, you will need to user software USART library or write your own routines. You can find many great software USART libraries for that purpose. As a rule you will have to use two pins to establish communication. But if you are tight on I/Os then you can cheat a little and make it work from single pin. Ralph has been experimenting with simple but smart circuit which allows to perform half duplex UART communications with other systems. The whole trick lies in a small schematic made of diode, transistor and resistor. Diode is only for making one way TX signal path from MCU to other device. Resistor is only for limiting base current. All is left a transistor which works as a key. We need to keep in mind, that when serial line is inactive- it stays in high state. So when microcontroller transmits data, TX on the right keeps transistor open.… Continue reading