It is recommended that you use the project file TECH.MDP for building the driver.

If you are familiar with the project development environment provided by Microsoft Visual C++, it's very easy to re-build the driver after you add any device-dependent code into the Tech Pack. When you have any problems regarding language itself, please refer to Microsoft Visual C++ on-line or printed manuals for help.

The following lists several basic steps that you may take to build an ONSPEC I/O driver with Tech Pack, and some hints that may be helpful for your work.

The I/O Template collects real-time data from and sends real-time data to the field instruments such as DCS, PLC, Controllers, Data Acquisition Equipment, I/O Cards/Boards. The data communication is usually accomplished through serial ports, network or direct memory access (DMA).

Step 1.

Start Microsoft Developer Studio from Microsoft Visual C++ program group.

Step 2.

Click File | Open Workspace... to load Tech Pack project file.

Step 3.

If you want to add extra modules to the project, click Insert | Files into Project....

Step 4.

Open DEVICE.C and USERCONV.C files, add all the device-dependent code into them.

Step 5.

Click Build | Build tech.exe to re-build the driver.

Step 6.

If the compiler or linker reports any error, check your code and fix it.

Step 7.

If no more error is reported, you will end up with an executable file TECH.EXE. The most important task remaining is to test your driver very carefully. You have to ensure that every function and feature works properly before you release it. In most cases you need to use the DEBUG tool embedded in the Microsoft Visual C++ language to debug the driver. Also Steps 5, 6 and 7 may need to be repeated many times.

Step 8.

Before leaving Microsoft Visual C++, don't forget to save all the changes you made to the disk.

Step 9.

To change the name of the driver, just rename TECH.EXE to whatever name you wish.

Contact us

Feel free to contact us!

Give us a call or drop us an email to schedule a visit!