I've used Asterisk and Sangoma Net Border Express as a T1 to SIP gateway. All had their pluses and minuses.

The most bang for the buck for me was using Asterisk. I could fit 8 T1's into a single 1U machine.