Deformable mirror is a popular device in adaptive optics. The characterization of this deformable mirror becomes important in a closed loop system. A shack Hartmann based wavefront sensor using a proper combination of lenslet array and a CCD camera has been used for this purpose. The typical process sequence includes, acquisition of reference and distorted image, calculation of centroide for both images, calculation of shift along X and Y axis, calculation of slope data. Finally reconstruction of the wavefront to calculate phase is performed. Integrated software based on Windows 9X platform has been developed for all above steps. This paper describes a novel technique used in this software. A multithreaded approach is used to perform above steps in parallel. Threads are introduced to acquire image from CCD camera, to calculate slope and phase data for each captured image and to display real time graphs viz. Slope matrix, 3D-phase matrix. Phase matrix has been calculated based on standard least square iterative method.