Home
Here
Contents
1. 15 7 ULTor region AAA e Se eS 16 10 11 12 15 14 15 16 17 vel ACG 4 Ae hoe 3 2 S a a a eh ee eS Sal 16 OPUSC y skua E S oe So 16 Stepper motor construction 17 Stepper motor phase winding configuration 17 Stepper motor phase polarity sequence 18 H bridge construction operation 18 Phase sequencing code 18 HCS12 interrupt vector table am d ses Gok Bo hk K d s 19 ooo s Oh at agag ug ua a ake ow Sew Ae 20 Cantuta aura G oh ee we E BG 21 111 1 Introduction Our project is to build a 3D Scanner that will scan a real world object and create a digital representation This process will use mathematical triangulation calculating intersections between a laser line plane and the camera s rays The math behind it uses primarily linear algebra and geometry techniques such as matrix operations and vector plane calculations 1 In order for these calculations to accurately display a 3D scan we must account for intrinsic parameters and extrinsic parameters of the camera 2 3 The process involves the following 1 Calibrate a webcam to obtain the intrinsic and extrinsic parameters 2 Build the scanning environment and integrate hardware pieces 3 Develop code that will interact with the development board 4 Develop the application for calibration scanning and output 5 C
2. 12 Program control is returned to the original program RTI instruction 8 13 The original program continues execution from where it was interrupted 13 1 In this project this is simply a return to the wait state 3 2 3 Block Diagram A block diagram of the hardware modules associated with driving the stepper motor which is composed of the Dragon12 development board stepper motor power supply and computer running windows can be seen in Figure 16 4 Work Completed This section describes some of the research and tests we have performed 4 1 Red Plot settings In order to obtain the laser line from the image it is necessary to determine the location of the red component in a row of pixels We have tested this out using our laser line in a dark room for a specific row of pixels halfway down the image At first we were using the intensity value from an HSV image Hue Saturation Value of Intensity This produced fair results However using HSV is unnecessary The image is first captured as a BGR Blue Green Red image so we can just get the red component from each pixel instead We did so and plotted the results which can be found below This is not on the highest resolution of the camera Future work will include higher resolution and determining what point to use as the intersection point of the laser and object 4 2 Undistort One of our questions when walking through the math is what the z component for an image co
3. 2 1 3 Solve for using a ray plane intersection Za 2192 Represent the ray through the image point u found above using paramet ric form R Po qo Au Since we are working in the ideal camera system we can assume qo is the origin of the camera system 0 0 0 Any line will intersect a non parallel plane at one point So using the implicit representation of a plane the point of intersection p is where ni p q 0 The point pis in the ray we defined above so the equation becomes n qo Au qp 0 Then solving for n qp qc niu A We let gc a point in the laser plane in this case be the approximate intersection of la and lg found above 2 1 4 Use to obtain the camera coordinate Po of the object laser plane intersec tion using Po Au 2 1 5 Convert Po to either the back plane or ground plane world coordinate system using the respective Py R 1Po RAT R Po RIT equation 2 1 6 Store Py along with the number of the current image in memory 3 Design Methodology This section describes part of the design we will use for implementation 3 1 Software This section describes the software portion of the project Due to page constraints we could not include all of our diagrams including sequence diagrams for calibration and scanning as vvell state diagrams for intrinsic and extrinsic calibration and the interrupt 3 1 1 State Diagram Scanning The state
4. o Any user input will be correctly handled e Miscellaneous Testing o Ensure views and models are getting updated correctly Each of the developers will be responsible for testing and determining if the test results are acceptable Testing frameworks may be used to correctly assess collected data where applicable Once testing has been completed for each segment we will then proceed on with the next phase of development For example we will need to ensure that calibration is working correctly before moving on to the scanning segment of the project 3 2 Hardware This section describes the hardware portion of the project 3 2 1 Description of Functional Modules 1 Power Supply 1 1 The external power supply must be capable of delivering between 18V 20V and around 1A of current This power supply will be used to provide external power for the Stepper Motor via the Terminal Block 4 Vext power connection on the Dragon12 Development Board The Dragon12 5Voutput will likely be used to provide power to the laser line generator 2 Stepper Motor 2 1 The stepper motor being used is an Applied Motion Products HT23 396 motor which is rated at 7 2V and 1A It is a 2 phase hybrid style stepper motor wired in a bipolar series configuration The bipolar nature of the motor means that it requires an H Bridge to allow for the reversal of current through the motor coils The 2 phase construction of the motor also means that 4 Half H B
5. 8 19 Serial Communications Cable Windows Computer Running Scanning Software Dragon12 Plus Rev F 4 coil 2 phase leads Power Supply Applied Motion that can provide Products 1A current H123 396 Stepper Motor Figure 16 The block diagram of the hardware systems associated with the Dragon12 for the purpose of controlling the stepper motor 20 aqqejourij INO JO UOISISA poyepdn UR SI SI 1 910314 uonmglu s ud Puy uo GJON justunzop jeu uo ypy spnop quiod abupy us uu puobAod o1 10 05 ppy pnp 1utod wo ysaw jevobijod puna prop zurod Aejdstp ppmg Y uogeadde jo AqijJpuonsuni buruuess juabuajduur bewi jo uonejnbueij wos syuiod ugo de 194 Ayevorpunj uoqesqyjes qu tu dui E 531481 Buungdes 104 103004 UPIM uonmgziuoisu s 318405 C Jus wuonaus buruuess abejs ping E ujorqyejuasajd ubisap uo yop yuatunoop ubisap uo 410 pp peog pue IOJOLLI ad 03014 mad jo mos 104 Ajsuaju 1358 1014 C 21
6. This is a basic Dell desktop computer This machine has a serial communica tions interface port used to compile the stepper motor control program onto the Dragon12 development board This computer will run the scanning calibration software that sends the interrupt signal via serial connection thus allowing the stepper motor control program to run 3 2 2 Theory of Hardware Operation 2 Phase Bipolar Hybrid Stepper Motor The following information along with more detailed descriptions can be found at the NMB Technology Corporation s Website 6 A stepper motor is a form of DC motor that relies on magnetism to advance a rotor in increments known as steps A hybrid stepper motor has been selected for this project In a hybrid motor the rotor contains an axially magnetized permanent magnet that is encompassed by two rotor cups which have teeth notched around their circumference see Figure 10 The teeth of the two rotor cups are offset to each other by a specified number of degrees that is dependent upon what step resolution the motor has The motor housing i e stator that surrounds the rotor contains two phases each comprised of 4 windings with their own set of teeth for a total of 8 windings between the two phases Each winding creates a magnetic field according to which direction current is passing through the winding For each phase the 4 windings are placed at 90 degree angles to each other The windings that are 180 degrees to eac
7. punoi JEJUIOY suejgugjund P 4380 IO AA equlogpalqo gt 10y9a9 pno quod ET JE1uI0q shoo poa 101 Jagwn yawe Jejuog POOD qUIOgpalqg Jagun pawey Jul pioogPLOM JEJUIOJ 1u10d13 qo Buuys tuBN Idsug I punoja Buuys LLlIEN 1J 0upuno I 3x buLjg LLIEN IdSUE I eg Ka bus awena jo ega Bugs i awenaji jua pOJSIP Bugs ate gas uu JEW JOYDISULI XAYIEq JEW SUE 31SUL1X3323e lt 20 420133A u0 Bauypeq EH U101J10 51p 12H 108315uLxapuno B Yeh SUB 3 sutx3punoiB SjEO 2108 vobagpunojb JEW uyu JSPOWUBIS JEW JOSIP JEN uuqul 3lsuuqul JEW U01110 SIp I JEW ISUJU Jey xugepuogejsue 13064 JEW i qejuoqejogjabt JEW sue1 5 yey 1085 Jey UBIA Jey 1080 35U11X3 Je ayNGUye Jey 10upunoi B JEW SUE PET JEW 1089180 TEE 13 UsISep ssejo MO JO UOLJIOA uoryeiqI 62 SYT VIN LY 14 3D Scan Calibration Intrinsic Vertical Squares Messages Figure 4 Main calibration screen for intrinsic calibration 3D Scan Calibration Extrinsic Horizontal Squares Vertical Squares Load Directory Messages Figure 5 Main calibration screen for extrinsic parameters Take Picture VIDEO FEED HERE Exit Picture 1 of 20 Message Figure 6 This is the screen the user wil use to take a picture of the board lo 3D Scan Region Specification Messages 3D
8. Aejjanojda2e4 mal ANdujueIS BIDA 32014 pioosAjuobagpuast 7 i PIOA gt W IA LU0H ALMA LUOHJASH Buys 109JUN0J0 x8 poA bulijs aweyajyjajanes Buys SUBI punga pea paana QUES buljs jiojsip PIOA UB3S1181S BULIIS 3ISUINul AMAL AINGUIUEIS maigndujuegs majjndujuess iMBJA Bujuueag MBJADUIUUEIS MBIA ABUBAG MBJAAE ano MBA SHS majjnsal 19 0 13U40 U835 QUI qMesp masya y 381204 aun auuopasaypzwxudde 493A ul i ur Jejulog Julod 32334 JOA ysap euoDAjog PIGA Bugs Wopalp Uojaviqpeo Ysapwpeuob jOd plo peas 21 pio bus atuegajjaji anes lt Jul0q133 0 gt 10138A Squlogalqqyab prop i uri WN abew jabewyssaqqd juj i spalqoabetujpjing oog buruueogauogsit oog abetuj aBewaJnpigares lt JE0 4 gt 10 38A 5p100 pa10 5105 prop 3150113 i 1X3punoiB 915411341 JU sung 134980 55920 1d prop Ju tun mo ABEL a ewjyuauodwogpayab hu wunyabew yey abeunjabetujt pisuupa xajsajeuiplooje atuejo WaAUOD MEJA 38A8BEui yequiog ulBiuggi tug3 u0 3as lu pul 4833 JO IaA PWOU JEJUOJ abeysuyquiod jaueyg 38014 Juo pasJayujpuy plo ueogjejst 008 jJauoqueIssi juj spr005paJ0 5 Lun gjab pagu JU 32014 pioosAjuoibaypuas PIOA sp 00311g8AUu03 ug d aug di se ae pon ueDs4 J9poyjuess aun 13141599 es 7 auejg Jasej JE38A JOJPSAJELLIOU ue i
9. Design Document Implement a 3 D Scanner Using Triangulation Grady Barrett BSCS amp BSCE Jeffrey Bishop BSCS Tyler Gunter BSCS Faculty Mentor Dr David Wolff CSCE 499 Fall 2012 Contents List of Figures 11 1 Introduction 1 2 Research Review 1 2 CAMEL oe GO da a a a Q rr W s ira a eh l A ruay ay O S Go ste A Suka ee a SZ SUS ST Sa A 1 3 Design Methodology 4 OO AA A e S e oe a R S a 4 LLE plate Diagram SOS a z ZI g ance Ble ai de Bok Se gu Ache N s 4 DZ Class Des sir u lt 1 X os m bka dos eek apa Ya nas at asa Sow Q dh S Qa Q 4 E GLP Se 4 Sd Pests len ds ra AA G QS S Se S S Q Q 4 Sk eo ia 5 3 2 1 Description of Functional Modules 5 3 2 2 Theory of Hardware Operation 6 las PO sa Q x ia E s Q S a s G oe u d r ee 9 4 Work Completed 9 Ad PIUS e b 2 44 k Sa k acs bates Q S kb bog we h bu sh a 9 dul USE ea wk Suwa e p SI gC te gu SUQ a a YA 9 Jo SNI OR OCO a 6 0 a E E IA 10 5 Future Work 10 6 Updated Timetable 10 Glossary 10 References 11 A Appendix A 12 List of Figures l SEAN AE aa a ee a DD S s a S ha oe 2 as 12 2 Class Digerati Canines cido mod G M Q Ee e A 82 2 13 3 ClasseDiapram OT mg a AS A ua p d ee 14 4 Ul Sketeh Intrinsic CaliDfatIoB s ewe aet anaa e 48 i W we r a 15 Main calibration screen for extrinsic parameters 15 6 Calibration Take Picture screen
10. Scan Scanning Scan Results Results Scan complete Point Cloud Figure 9 Screen showing the resulting point cloud 10 Figure 10 The Construction of a 2 phase Hybrid stepper motor Image taken from NMB Technologies Corporation Website 6 Figure 11 The 8 windings that make up the 2 phases A and B in a 2 phase hybrid stepper motor Image taken from NMB Technologies Corporation Website 6 17 Phase A Phase Phase A Phase A Phase B Phase B Phase E Phase B Phase Phase A Phase Phase A Phase B Phase B PhaseB PhaseB Figure 12 Full step phase winding polarity progression to turn the stepper motor Image taken from Orientalmotor website 10 Figure 13 above A full h bridge circuit where switches S1 54 are generally transistor switches and M is the load below The two valid operating configurations of a full h bridge circuit DORE OxOF PORTBO PORTB3 as output DORP 0x03 PORTPO and PORTP1 as output for 12EN 1 and 34EN 1 PORTE 0b000000003 ff start with all off PTP 0b00000011 Turn on both 12EN and 34EN Enables for 754410 chip for 1 PORTE 0b00000011 Mspelay 50 PORTB 0b00000110 MSDelay 50 PORTB 0b00001100 MsDelay 50 PORTB 0b00001001 MSDelay 50 Figure 14 Phase sequencing code for infinite clock wise rotation The mapping for PORT B to M1 M4 is as follows PORTB 0 b 0 0 0 0 M4 M3 M2 MI where M1 M2 M3 and M4 are 1 when v
11. d in Appendix A at Figure 17 our previous version was quite ambitious While we may not actually get to merging point clouds we have left it in the diagram in case we are able to successfully get that far Glossary extrinsic parameters The translation and rotation vectors relating the stage s world co ordinates to camera coordinates H bridge A circuit that provides functionality to reverse DC current direction through a load using switches intrinsic parameters A model of the camera s geometry and a distortion model of the camera s lens 2 p 371 stage Two perpendicular boards in which the object to be scanned is placed triangulation A mathematical process of determining an intersection point using geometry 10 References El 14 15 16 17 D Lanman and G Taubin Build your own 3d scanner Optical triangulation for beginners http mesh brown edu byo3d index html 2012 G Bradski and A Kaehler Learning OpenCV Sebastopol CA O Reilly Media Inc 2008 J Y Bouget Camera calibration toolbox for matlab http www vision caltech edu bouguetj calib_doc index html 2010 How to use opencv to capture and display images from a camera http opencv willowgarage com wiki CameraCapture 2011 videolnput a free windows video capture library http www muonics net school spring05 videoInput 2009 N T Corporation The permanent magnet in motors c
12. diagram for scanning can be found in Appendix A at Figure 1 3 1 2 Class Design The class diagram showing our object oriented MVC design can be found in Appendix A at Figure 2 and 3 3 1 3 GUI Sketches Updated GUI designs can be found at Figures 4 9 3 1 4 Testing Plan Our project will consist of ongoing testing throughout the projects various phases T his will be to ensure that all data and application behaviors are working properly throughout each phase Because our project is predominantly concerned with the accuracy of data points of a scanned object we will need to ensure that our data precisely represents the object In order to test this we will ensure the following items are tested in their corresponding stages e Calibration Intrinsic and Extrinsic parameters o Accuracy and precision of data o Processing images for calibration works as intended e Scanning Process o Scanning Speed to ensure optimal data is collected o Accuracy of point data collected including time data of each point O Best Fit Line is determined correctly o Correct calculations using our pinhole camera model and related mathematics o Processing points in the final stages o Polygonal Meshing accurately represents object e User Interactions o Correctly produce messages to user ensuring complete understanding of the scan ning process o Making sure the XML files that are loaded contain correct data and that they are stored correctly
13. e is linked with the ISR containing the necessary phase sequencing code to rotate the stepper motor rotor It is also necessary to enable interrupts on the board as a whole Clear Interrupt Mask instruction as well as for the specific interrupt to the used SCI1 When an interrupt event occurs the following takes place 1 The current instruction execution is completed 1 1 In this project the original program is simply a wait state defined by an infinite for loop 2 instruction queue is cleared 3 The return address is calculated 4 Key registers associated with the current program execution most notably the Program Counter are pushed to the stack 5 The interrupt T bit in the Conditional Code Register CCR is set to disable all other interrupts The interrupt vector in this case the vector for SCIL is fetched Control over the program is transferred to the ISR The interrupt source is cleared programmer must do this CO GOO N O The programmer s code in the ISR is executed 9 1 In this project a bit will be sent back to the windows machine when the stepper motor scan routine finishes executing indicating to the scanning application on the windows machine that the stepper motor has finished the hardware side of the scanning process 10 The key register values for the original program are popped off the stack 11 The T bit of the CCR is cleared to re enable all interrupts
14. h other are the same magnetic polarity and the windings that are 90 degrees from each other are opposite magnetic polarities see Figure 11 When energized the windings in a particular phase that are of the same polarity will attract the teeth on one end of the axially magnetized rotor while the other set of windings will attract the teeth on the opposite end of the rotor This in combination with the fact that the two sets of teeth on the rotor are offset from each other causes the rotor to rotate see Figure 12 In this project the stepper motor controller functionality built into the Dragon12 Plus development board is used to control the phase sequencing see Figure 12 Another aspect of the stepper motor that can be controlled is the choice between a bipolar parallel bipolar series or unipolar winding wiring scheme This choice affects the amount of current required to run the stepper motor the type of stepper motor controller and driver required and the torque characteristics of the motor In this case a bipolar parallel configuration was chosen because it requires less current than bipolar series The torque profile of each wiring configuration is not a concern for this project because we are only rotating a very light and small laser line generator H Bridge The bipolar configuration allows the motor to generate current flow in either direction in each winding This means that a driver circuit is needed that can switch the d
15. irection of the current flowing through the windings Driving a 2 phase bipolar stepper motor with 4 pairs of windings where each pair has the same polarity when energized can be achieved using 2 H bridge circuits or in the case of this project 4 half bridge circuits see Figure 13 Each half bridge circuit is composed of half of a full h bridge circuit as the name suggests which means that only two transistor switches on one side of the load are used to reverse the current The quadruple half bridge integrated circuit SN754410 that is integrated into the Dragon12 development board serves the purpose of driving each of the pairs of windings Dragon12 Stepper Motor Phase Sequence Control The half bridges are controlled using the stepper motor controller functionality on the Dragon12 The phase sequencing can then be programmed in C and compiled onto the board An example program for stepper motor control from which the code in Figure 14 was derived can be found on the MicroDigitalEd website 7 This phase sequence is specific to any given stepper motor Example phase sequencing code for the stepper motor used in this project can be seen below in the form of an infinite for loop PORI B in this code is defined to be the M1 M4 voltage output connections on the Dragon12 Interrupts Information in this section as well as more detailed information on interrupts and serial communication can be found in Microcontroller Theory and Applica
16. niu A 1 2 3 Use each A to obtain the associated camera coordinate Po of the back plane using Po Au and store it in memory 1 2 4 After all points have been processed find the best fit line of all Po s and store it in memory This represents the laser line across the back plane in camera coordinates 1 3 Repeat the process for the stored points in the ground plane region 1 4 Perform a least squares approximation of the intersection point between the two lines Store it along vrith the normal vector cross product of the vector compo nents of the 2 lines in memory The approximate intersection will be used as the point on the plane along with the normal vector to the plane for the ray plane intersection in the object region 2 Object Laser Intersection 2 1 For each row of pixels in the object region 2 1 1 Find the image coordinates of the red component where the laser hits the object by obtaining where the red component is near its highest point in the pixel row 2 1 2 Convert the obtained image coordinates which are in a real life 2D image camera coordinate system to the ideal 3D image camera coordinate system via undistortion using the distortion parameters of the camera and the inverse intrinsic matrix K followed by converting to homogeneous coordi nates This will give us an ideal 3D camera coordinate of Po Au where u is the resulting idealized image coordinate and A is some scalar
17. oltage is desired on that output connection and 0 when no voltage is desired Code adapted from example stepper motor control code at MicroDigitalEd website 7 18 ve FARE SF Res HPRIO Value to Elevate Rene Wee SFFFC SFFFD Clock Monitor fail reset Onimplemented instruction rap None None L SERFS SPEFT SW ome None serra seers Ra et o JI AAR i rm RG RGROENJ S Enhanced Capture Timer channel Fr MECO E SFFEC SFFED Enhanced Capture Timer channel ret Tem SEFER SFFEB Enhanced Capture Timer channol2_ ret ME GA SER SEFES SFFES Enhanced Capture Timer channel3_ rt mim SEFES SFFE7 Enhanced Capture Timer channel _ ret meca se SFFES SFFES mecs s Enhanced Capture Timer channel 18H Teten sez ISFFEO SFFET Enhanced Capture Timer channel ven mm 380 SFFOE SFFOF Enhanced Capture Timer overtow ven TSRC2 TOF SDE Pulse accumdatorinputedge a Penny sa gt SADA SA so ran SPORT SPIE SPTIE 08 PTS SCUCR2 ad oi ATDOCTL x So SFFCCSFFCD Reni E PRITEJ C SFFCA SFFCB Modulus Down Counter undertow ret MOCTLMCZ Figure 15 Interrupt Vector Locations for the Dragon12 HCS12 Development Board Table taken from Microcontroller Theory and Applications
18. onstruction and oper ating theory Hybrid motor http www nmbtc com step motors engineering construction and operating theory html M Mazidi Stepper motor control using the h bridge on dragon12 http www microdigitaled com HCS12 Hardware Dragon12 CodeWarrior Stepper_ Motor_Control_H_Bridge_Cprog txt D J Pack and S F Barrett Microcontroller Theory and Applications HC12 amp S12 Upper Saddle River NJ Pearson Education Inc 2008 T Almy Designing with Microcontrollers The 68HCS12 Lulu com 2006 Orientalmotor Basics of motion control http www orientalmotor com technology articles 2phase v bphase html C documentation http www cplusplus com 2012 G Taubin ENGN 2502 3d photography http mesh brown edu 3DP index html 2012 G Taubin 3d photography and image processing http mesh brown edu 3DPGP 2009 index htm1l 2009 T Shifrin and M R Adams Linear Algebra A Geometric Approach New York NY W H Freeman and Co 2 ed 2011 T Tong Medical applications in 3d scanning http blog 3d3solutions com bid 78455 Medical Applications in 3D Scanning 2011 3d digital corp applications Architecture http www 3ddigitalcorp com applications architecture 2012 Dragon12 Plus Trainer For Freescale HCS12 microcontroller family User s Manual for Rev F board Revision 1 06 11 A Appendix A bon jnot for commercial usa Visual PARDO bje
19. oordinates which are in a real life 2D image camera coordinate system to the ideal 3D image camera coordinate system via undistortion using the distortion parameters of the camera and the inverse intrinsic matrix K followed by converting to homogeneous coordi nates This will give us an ideal 3D camera coordinate of Po Au where u is the resulting idealized image coordinate and A is some scalar 1 2 2 Solve for each A using a ray plane intersection 1 221 M2 2 2 L 2 2 5 1 2 2 4 Represent the ray through the image point u found above using paramet ric form R Po qo Au Since we are working in the ideal camera system we can assume qc is the origin of the camera system 0 0 0 Pick a point Pgy on the back plane namely 0 0 0 and convert it to camera coordinates using the equation Po RgPgw Tp where Rpg and Ig are the extrinsic parameter rotation and translation matrices respectively The resulting point will be gp in following steps Assuming the back plane is the xz plane in its coordinate system the normal vector is 0 1 0 Convert this to camera coordinates as well This will be n in the steps below Any line will intersect a non parallel plane at one point So using the implicit representation of a plane the point of intersection p is where ni p q 0 The point pis in the ray we defined above so the equation becomes n qc Au qp 0 Then solving for A n qp qc
20. ordinate obtained from the actual image would be The undistort method from OpenCV handles converting a distorted image coordinate to the ideal image coordinate To determine how the undistort method would look for an obtained image point we tested it out using the calibration code provided by OpenCV VVe calibrated provided chessboard images to obtain the intrinsic and distortion parameters and then picked one image that vvas fairly straight on We found its corners and converted them from the obtained image coordinates to the ideal coordinates and plotted them in a scatter plot as vvell as mapped the points directly on the board The mapped points on the board were undetectable from each other and the scatter plot showed a good correlation between distorted and undistorted as well 4 3 Motor Circuitry VVe have successfully implemented a spinning motor interrupts are in the prototype stage VVe hope to have the interrupts done in January 5 Future Work Plans for our future work include e Determining red intersection point technique Jeff e GUI interaction between C and OpenCV Tyler e Constructing the scanning stage Jeff Tyler Grady Build C program to control motor laser Grady e Develop Basic Scanning Functionality Jeff Tyler Grady Testing major deliverables Calibration Scanning etc Tyler e Final document and presentation Jeff Tyler Grady 6 Updated Timetable We have updated our timetable which can be foun
21. reate a polygonal mesh representation of the object using the point cloud For our project to be considered a success we should be able to produce a point cloud and hopefully a polygonal mesh representation of a real world object Please see our requirements document for more details 2 Research Review This section gives more detail to some of the research we have done related to implementa tion 2 1 Camera Settings OpenCV does not currently appear to support setting a variety of camera settings that vve need automated for our project such as white levels gain control etc In order to achieve this will need to use a C library called videolnput This video library uses Microsoft Windows DirectDraw library also known as VFW or Video For Windows to make it easier to set parameters for the camera This is documented at 4 and can be downloaded at 5 2 2 Math Here is a description of the mathematical procedure to generate the points for the point cloud of an object For each image 1 Determine Laser Planes 1 1 For each row of pixels in the back plane region 1 1 1 Find the image coordinates of the red component where the laser hits the back plane by obtaining where the red component is near its highest point in the pixel row Store it in memory 1 1 2 Repeat for pixel rows in ground plane region 1 2 For the stored points in the back plane region 1 2 1 Convert the obtained image c
22. ri Communi Ed in scene Failure Display Error Userloads directory where calibration files were saved and hits Start Success Camera takes picture of the scene and it is displayed to user with instructions for Region Clicking User rejects regions User clicks four times to define non object regions of back and ground planes User Exits i User accepts i Message displayed to User enters save turn off lights directory and hits e User Exits User turns off lights hits Start Scan Interrupt sent scanning of object All frames analyzed completes Motor returned to original position and put in wait state Images stored to disk o dis Laser plan found Intersection stored in array as workl coordinate Figure 1 This shows the state transitions we will use for the scanning phase 12 USISOp SSeTD MO Jo uoryod SUTUULOS SHI Z GINS PIGA ospiadojs abessajy abessawjabessayymoys plo JU auop ul passadold regssalbolgajepdn pion 4204 ZA Jeoy TA Yeop ZX Jeo TX ACAAQMEIp labessajj abessawjabessapymoys 18 10 UOJuess 3sliaj 0Juogug3s as prop oapip ejdsip maj Arjan BI0A aj osjuoguesg 3S 1 g0 nun yug3c1as MOIA R ISAD Jaa ABUIULIE IS M IABuluue3sS PIDA j pop ug3s Lusjapojyue2Gjast poA ita abessayy ahessatujabessapjmojst joog abeu aew jainjaiganes BI0A ajouogue2 35 18 10qUOJUEISIaS pioa
23. ridges are necessary to drive the motor The 1A current rating as vvell as the 2 phase bipolar nature of this stepper motor allows it to be paired nicely with the Quadruple Half H Bridge driver on the Dragon12 which is also rated at 1A 3 Dragon12 Plus Revision F Development Board 3 1 The Dragon12 is a Freescale HCS12 based development board that provides a host of different microcontroller and other educational functionalities In this particular project the integrated stepper motor controller functionality is being paired with the onboard SN754410 Quadruple Half H Driver and the ability to program interrupts in order to drive and control the stepper motor The ability to connect an external power supply to the Dragon12 is being utilized to overcome the current and voltage limitations of the provided 9V Dragon12 power supply Finally one of the two provided serial communications interfaces on the Dragon12 is being employed to provide communication in the form of interrupt signals be tween the Windows computer running the scanning calibration software and the Dragon12 This communication is necessary for the purposes of implementing interrupt functionality on the Dragon12 This allows the precompiled program on the development board to be in effect started and stopped as desired based on signals sent from the scanning calibration software running on the Windows computer 4 Desktop Computer running Windows Operating System 4 1
24. tions HC12 amp 12 and Designing with Microcontrollers The 68HCS12 8 9 The Dragon12 is simply a dumb processor This means that its default mode of operation is to start running the code that has been compiled onto it as soon as compilation finishes In order to be able to control the Dragon12 s code execution there must be a connection between the PC and the board A serial communications interface on the Dragon12 provides for a serial connection between the PC and the development board This connection provides several asynchronous interrupt events For this project the Receiver Interrupt Enable RIE interrupt will serve as the backbone for controlling the execution of code on the Dragon12 When an interrupt event is triggered on the Dragon12 execution of the current program is halted and a programmer specified interrupt service routine ISR is run In this case the ISR will contain the code to rotate the stepper motor in the manner necessary to scan the object After the ISR is finished the Dragon12 returns to where the original program was halted and continues execution of the original program In order for interrupts to work properly the memory locations for the interrupt vectors must be linked with the address of the ISR that the programmer wishes to be called when that particular interrupt occurs The memory locations of the various available interrupts are defined in Table 15 In this case the SCI1 interrupt sourc
Download Pdf Manuals
Related Search
Here hereditary heretic heredity here movie here comes the sun heretic definition hereditary meaning hereinafter heresy definition here\u0027s johnny hereby here comes the guide hereditary angioedema hereditary hemochromatosis here comes the sun lyrics heretic movie hereditary spherocytosis hereditary hemorrhagic telangiectasia herencia hereditary movie here to slay heredia costa rica heretic game heretic streaming here come the mummies
Related Contents
Rollei Car Kit MIPRO ACT-51 FM3 family inverter reference board User Manual 42LB5820 User Manual ` uni. il Manual de instruções DCR-DVD650/DVD850 Ion pump 第4章 測定機の維持管理 4.1 維持管理の体制 回覧 - 木阪賞文堂 DK Brugerhåndbog DE Benutzerhandbuch EN User Manual ES Copyright © All rights reserved.
Failed to retrieve file