Here is a sample hybrid system set-up for asterisk. This was done for another group but I figured I would share it here incase anyone wanted to look at some examples of how asterisk is configured.
Asterisk: Sample Hybrid Setup Download, Install, and play with the above files at your own risk. If this causes loss of computer, loss of life, or your wife gets pregnant, etc, it's not my problem.
That being said, I have tried to put comments through the files to explain what the different lines do. This is not the only approach to "skinning this cat" but simply one method that I could think of in about 30-minutes. The sample file are currently set-up to take TDM/POTS in and use SIP as the extensions. This can be changed/swapped around at will. Sip.conf and zapata.conf will allow you to configure your SIP and TDM devices for use in asterisk.
The included readme.txt file will explain how to load these examples into asterisk. You will need to have a basic understanding of Linux and how to compile source code to test this. Even if you just browse the files, you can understand how asterisk is set-up and runs. Might give you some ideas of using it in your own way.
zapata.conf and zaptel.conf will need to be customized for your particular system. Zaptel.conf is not included in the archive as it is unique to each system. Search
https://www.voip-info.org for examples of setting the zaptel.conf file.
If you have any questions on them, feel free to ask. I can either point you in the right direction to understand the answer or explain it to you. Enjoy.