In some situations, you might find that bitlbee closes the connection on you. The server channel will show something like Ping Timeout: 490 seconds.
If you think that it might work if only you could increase the timeout, here's how. First, you need to find the bitlbee config file. It's probably a file called bitlbee.conf in your config directory. The config directory is usually /var/lib/bitlbee/ but you can change it using the -d option.
The file might not exist, or it might be empty. Here's how to change the pingtimeout option:
The default is 300 seconds (five minutes).