Hi.
Are you using the bare ATtiny85 microprocessor chip or the Digispark board?
I wanted to do something similar (feed GPS output to the Digispark board and extract the speed). But I couldn't work out how to make the serial connection.
What you want to do ought to be possible as long as the code fits into 6k.