I am working on a project that needs to convert a high input/output voltage into a TTL signal. The box I am working with has a parallel port output that was supposed to send out a TTL signal when a button was pressed. Instead the voltage reads 9V before the button is pressed and 14V when you press the button. The problem is I need the voltage to start at 0V and go up to 5V when the button is pressed. Is there a simple way to do this? Thanks for any help. -M
You have a 5V swing and undefined grounds for isolation or not with unknown source impedances or voltage/current shift.
An Opto isolator may be the ideal choice for isolation and level shifting with pullup R on input and output to determine input and output current limits. THere are thousands to choose from. But you indicated non-inverting logic so choose a non-inverting output or add a logic inverter.
Otherwise, a cheap and dirty method is to use a Common base transistor biased at 12V with a zener and series R to Vb and input 9~14V on Ve and output on Vc with a pullup to 5V goes to 0 to 5V.