The most common way to write a TSP is to take the source code for an existing TSP and use it as a template for writing a new one. Microsoft has made the source code for a simple TAPI 1.x modem TSP (ATSP) and a simple TAPI 2.x modem TSP (ATSP32). The source code for these TSP's can be found on the Microsoft Developer Network (MSDN) CD library.
JulMar Entertainment Technology has developed a TSP c++ class library using the Microsoft Foundation Classes (MFC) that serves as a template for rapid TSP development. The complete source code of this class library is provided. See the JulMar web site for more details and pricing information.
2. How do I make my voice modem work with Unimodem/V?
Many modem vendors already support Unimodem/V with most of their voice modems. The first thing you should do is contact your modem manufacturer and ask them if they support Unimodem/V. if they do support Unimodem/V then they will need to provide you with an information file (*.inf) that contains the information that tells Unimodem/V how to interact with the modem. Follow the vendors instructions to install the *.inf file and configure the modem properly.
If you are looking for information on how to write the *.inf files needed to configure Unimodem/V then you should visit the Modem Developers Kit Page on the Microsoft Web Site. These pages contain a great deal of information about the architecture of Unimodem/V, how it interacts with wave drivers in order to play and record audio files, how to write the *.inf files needed to configure modems, and much more.
Microsoft has a special TSP called the "Repeater TSP" that traps and displays all data sent to and from a TSP you want to debug. This Repeater TSP is available in the MSDN library on the Platform SDK.
When you write a TSP it is strongly suggested that you incorporate some sort of tracing mechanism that can be turned on and off as necessary. Not only will this be an extremely useful tool when debugging your TSP, but it can also prove invaluable when others are using your TSP and trying to get it to work with other TAPI applications.