Real Time Computer Vision Development for a 2-DOF Gimbal Application Sakari Kettunen Center for Self-Organizing and In
9Controlling Gimbal The third part of the project was to integrate image acquisition system and gimbal controlling system in to one computer. Until n
10 Figure 3 'Homef.mdl' - Home point search Simulink model ‘Homef.mdl’ [2] was used to find the home position of Gimbal. That is, the zero
11 ‘Point.mdl’[2] can be used for finding the starting point of the curve. Both axes will move straight to the desired angle (x_deg, y_deg). Simulati
12Kuva 1 Subsystem 'selected input signal' from 'Model.mdl' Math-file ‘ILCprocess.m’ To test and demonstrate the working of the s
13F:/Sakari/gimbal_interface/ Folder ‘Gimbal’ includes only the necessary files for the project; the other folder is a working folder with extra fil
14Conclusions The reason why I run out of time with this project, and was not able to implement the ILC process can be blamed on two reasons: first,
15Bibliography [1] The MathWorks - Support - MEX-files Guide http://www.mathworks.com/support/tech-notes/1600/1605.html [2] Mohua Ghosh, Master’s T
16Appendix I ‘FrameCapt.h’ /* This program is based on a sample program called "acq2host.c"/"acq2host.h" produced by Data
17/* by the current device */ typedef struct tagDEVCAPS { BOOL DoesInputFilter
18 OLT_LNG_RANGE TopRange; OLT_LNG_RANGE WidthRange; OLT_LNG_RANGE HeightRange; OLT_LNG_RANGE HorizontalIncRange;
1 Table of Contents Introduction...
19 DT3157_SYNC_CTL_HPULSE_WIDTH = 0x0003, DT3157_SYNC_CTL_VPULSE_WIDTH = 0x0004, DT3157_SYNC_CTL_PHASE = 0x0005 } DT3157_SYNC_CON
20BOOL PRIVATE InitInstance(HINSTANCE, int); LPARAM CALLBACK __export MainWndProc(HWND, UINT, WPARAM, LPARAM); BOOL CALLBACK __export About(HWND, UIN
21BOOL CALLBACK __export VideoAreaProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); void PRIVATE InitVideoAreaDlg(HWND hDlg, LPVIDEOAREAIN
22Appendix II ‘FrameCapt.c’ /* This program is based on a sample program called "acq2host.c"/"acq2host.h" produced by Dat
23 char *array; /* The gateway routine */ void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[]) { const i
24 if(!memcpy(start_of_pr, hpAcquireBuf, bytes_to_copy)) { GlobalUnlock(hpAcquireBuf); GlobalFree(hAcquireBuf); OlFgDestroyFrame( Cu
25 /* Allocate space for info */ hDevInfoList = GlobalAlloc(GHND, iCount * sizeof(OLT_IMGDEVINFO)); if ( !hDevInfoList ) { FI
26 /* Try to open the device */ Status = OlImgOpenDevice(lpcszAlias, &DevId); if ( ! OlImgIsOkay( Status ) ) { mexPrintf("
27 /* Function: AcquireToHost */ BOOL AcquireToHost() { OLT_APISTATUS Status = 0L; ULNG ulPixelDepth = 0L; ULNG ulMinBufSize = 0L
28 FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, NULL, dw, MAKELANGID(LANG_NE
2Introduction This document is about the project that I made for the Center of Self Organizing and Intelligent Systems (CSOIS), Utah State University
29Appendix III ‘ILCprocess.m’ clear; k = 0; while(k < 3) %starting point search model name: mn = 'point'; FrameCapt; %I
30 %%%%%%%%%%%%%%%%%%%%%%% % The actual curve: % --------------------------------------- %%%%%%%%%%%%%%%%%%%%%%% pause(2);
31 wc_stop('homef'); %pause(1); k = k + 1; end FrameCapt(1); %Close camera
3The goal of the project The Gimbal is a 2 DOF rotating robot. It consists of a vertically rotating shaft extending into a fork and another shaft pla
4Because of the limited time I had in use and the troubles I had with the system during the project I was not able to implement Iterative Learning Co
5Image acquisition program The first part of the project was to create a program, which grabs a frame from digital camera (Pulnix TMC-7DSP connected
6NOTE! You have to wait a while (>0.5 seconds) after the camera initialization before you acquire the image. Otherwise the picture will contain er
7Saving the path The second part of the project was to create a program (MatLab m-file) which saves the curve that the laser pointer draws in the pap
8from the file ‘ILCprocess.m’. Sorry about that! Those lines are remains of earlier versions of the function. Read more about the file ‘ILCprocess.m’
Comments to this Manuals