How to make a fingerprint scanner (UART, Serial) for a headphone jack on Android?
It sounds like your question is, how do you go from a UART device to something that can be plugged into a microphone jack.

What protocol does a headphone jack use? should help you understand what is being done on the existing device that you are talking about.

There is still a link missing for you though, that is the ability of turning UART into the audio itself. The easiest way to do this is to buy a microcontroller that you will place between the UART device and the Android device. All the microcontroller will do is read in any UART data and then convert it to what ever form you want the headphone jack to receive. You may also need to implement some handshaking between the microcontroller and the phone in order to know that the device you think is plugged in.

There is also the issue of getting power to the device. A headphone jack is in no way designed to be used as a power source. The easiest method would be to just slap a battery on the device. If you wanted to, you could potentially do some clever tricks with playing audio at full volume for some period of time and have your device charge up a capacitor. You could then run your device off of the power stored in the capacitor. This sounds rather tricky to me though and would personally just go with a battery.