PortA.4 is an open drain port. You must use a pullup resistor in order to drive your transistor.

Cheers

Al.