Maybe you can multiplex GPIO.1 and GPIO.2 for the speaker.
I explain myself, from the info provided the speaker is meant for reception (i.e. RX). You can drive the speaker from the GPIO.2 (TX.data) 'anded' with the GPIO.1 (with the proper polarities of course). Thus, when the transmitter is off the speaker is on (enabled). Any data on the TX line (GPIO.2) will not be transmitted (since the TX is off) but will be available for the speaker. When the TX is on the speaker is off (disabled), and any data on the TX line is transmitted but does not get to the speaker.
Something like that. Hope it helps anyway.
languer.
Bookmarks