SlideShare a Scribd company logo
1 of 27
Download to read offline
Get	
  Moving	
  With	
  Core	
  Mo/on!	
  
                           Jonathan	
  Blocksom	
  
                           Tuesday	
  Sept	
  28	
  2010	
  
                           2:00	
  –	
  3:15	
  PM	
  




h1p://www.slideshare.net/jblocksom/core-­‐mo/on-­‐presenta/on	
  
Agenda	
  
•    Intro	
  
•    SDK	
  
•    Experiments	
  
•    Q	
  &	
  A	
  

•  Intro	
  level,	
  but	
  lots	
  of	
  code	
  
About	
  Me	
  
Jonathan	
  Blocksom	
  
blocksom@gollygee.com	
  
augmentedjonathan.tumblr.com	
  
@jblocksom	
  


•  Computer	
  Vision	
  So[ware	
  Engineer,	
  
   SET	
  Corp	
  
•  Computer	
  Graphics	
  background	
  
•  Several	
  years	
  working	
  with	
  Remote	
  
   Sensing	
  
Meet	
  Core	
  Mo/on!	
  
•  Core	
  Mo/on	
  Framework:	
  
   High	
  level	
  interface	
  to	
  the	
  	
  
   orienta/on	
  and	
  movement	
  	
  
   data	
  from	
  the	
  device	
  

•  Based	
  on	
  Accelerometer	
  and	
  Gyroscopes	
  
•  Accelera/on,	
  Gravity,	
  Rota/onal	
  Accelera/on	
  
•  High	
  level	
  filtering	
  
Core	
  Mo/on	
  isn’t…	
  
•  For	
  GPS	
  data	
  
    –  That’s	
  Core	
  Loca/on	
  (Loca/onManager)	
  
•  For	
  Compass	
  data	
  
    –  Also	
  Core	
  Loca/on	
  
•  High	
  Level	
  Mo/on	
  Events	
  
    –  Orienta/on	
  change	
  
    –  Shake	
  events	
  

•  Perfect	
  
Quick	
  Demo	
  
•  CoreMo/onTeapot	
  
   (WWDC	
  2010	
  sample	
  
   code)	
  
Accelerometer	
  
•  Available	
  since	
  iPhone	
  1	
  
•  Consider	
  it	
  a	
  “Gravity	
  Detector”	
  
•  Noisy	
  

•  iPad,	
  iPhone	
  4:	
  
   STMicro	
  STM33DH	
  
   3-­‐axis	
  accelerometer	
  
                                       Photo	
  by	
  David	
  Hodson	
  
                                       h1p://www.ifixit.com/Guide/Image/meta/IP1qEpYFQSSqwSbg	
  
Gyroscopes	
  
•  New	
  in	
  iPhone	
  4,	
  iPod	
  
   Touch	
  4	
  
•  Detects	
  rota/on	
  rate	
  
   along	
  three	
  axis	
  
•  Chip	
  datasheet:	
  
   h1p://www.st.com/stonline/products/literature/ds/
   17116.pdf	
  

•  200/500/2500	
  dps	
  
   (degrees	
  per	
  second)	
  
•  0.03	
  dps	
  error	
  
Gyro	
  Teardown	
  




h1p://www.ifixit.com/Teardown/iPhone-­‐4-­‐Gyroscope-­‐Teardown/3156/1	
  

Andrew	
  Bookholt:	
  
h1p://www.ifixit.com/Guide/Image/meta/UurGsklhtJRW2uuB	
  (le[)	
  
h1p://www.ifixit.com/Guide/Image/meta/MeunHawo54qPRY5S	
  (right	
  1)	
  

Miroslav	
  Djuric	
  
h1p://www.ifixit.com/Guide/Image/meta/RUQLo2PP1oqVtVsD	
  (right	
  2)	
  
Accelerometer,	
  Gyro	
  &	
  Device	
  Mo/on	
  


Accelerometer	
                                        Gyro	
  



                      Device	
  Mo/on	
  

                    Gravity	
  
x,	
  y,	
  z	
                               yaw,	
  pitch,	
  roll	
  
                    User	
  accelera/on	
  
                    Aptude	
  
                    Rota/on	
  Rate	
  
Supported	
  Devices	
  
                     iPhone	
  1	
   iPhone	
     iPhone	
              iPhone	
  4	
   iPod	
          iPod	
               iPad	
  
                                     3G	
         3GS	
                                 Touch	
  	
     Touch	
  4	
  
Accelero             Y	
            Y	
           Y	
                   Y	
               Y	
           Y	
                  Y	
  
meter	
  
Gyros	
                                                                 Y	
  
iOS	
  4	
                          Y	
           Y	
                   Y	
                             Y	
  




          iPhone	
  4	
                             iPhone	
  3GS	
                                     iPhone	
  1	
  
          iPod	
  Touch	
  4	
                      iPod	
  Touch	
                                     iPad	
  iOS	
  3.x	
  
                                                    iPad	
  w/	
  iOS	
  4	
  


               Yay!	
                             If	
  we	
  must…	
                                                No.	
  
Classes	
  
Class	
                   Descrip8on	
  
CMMo/onManager	
          The	
  Gateway	
  
CMAccelerometerData	
     Accelera/on	
  data	
  
                          X,	
  Y,	
  and	
  Z	
  rela/ve	
  to	
  
                          device	
  
                          In	
  G’s	
  
CMAptude	
                Orienta/on	
  
                          Roll,	
  Pitch,	
  Yaw	
  
                          Rota/on	
  Matrix	
  
                          Quaternion	
  
CMDeviceMo/on	
           Roll	
  up	
  of	
  sensors	
  
                          Differen/ates	
  gravity	
  from	
  
                          user	
  accelera/on	
  
CMGyroData	
              Rota/onal	
  Velocity	
  
CMLogItem	
               Timestamped	
                               Parent	
  Class	
  for	
  
                          Measurement	
                               measurements	
  
CMMo/onManager	
  
•  Tells	
  you	
  what’s	
  available	
  
    –  is<Acclerometer|DeviceMo/on|Gyro>Available	
  
•  Sets	
  the	
  update	
  intervals	
  
    –  set<…>UpdateInterval	
  
•  Starts	
  and	
  stops	
  updates	
  
    –  start<…>Updates	
  
    –  start<…>UpdatesToQueue:withHandler:	
  
    –  stop<…>Updates	
  
•  Lets	
  you	
  poll	
  for	
  updates	
  
    –  accelerometerData	
  
    –  gyroData	
  
    –  deviceMo/on	
  
CMMo/onManager	
  
•  CMMo/onManager	
  *mgr	
  =	
  
   [[CMMo/onManager	
  alloc]	
  init];	
  

•  Ini/alizes	
  reference	
  frame	
  at	
  construc/on	
  

•  Only	
  make	
  one	
  of	
  these	
  for	
  your	
  app	
  
Core	
  Mo/on	
  Coordinate	
  System	
  
Quick	
  Reference	
  

            z	
                        yaw	
  




                                                  pitch	
  
                    x	
  

                            roll	
  
    y	
  



 Accelerometer	
                 Gyroscopes	
  
CMAccelerometerData	
  
•  accelera/on	
  
   CMAccelera/on	
  struct:	
  
  typedef struct {
      double x;
      double y;
      double z;
  } CMAcceleration;


•  Measured	
  in	
  G’s
CMGyroData	
  
•  YAGNI	
  

•  Gyro’s	
  have	
  bias;	
  DeviceMo/on	
  fusion	
  
   algorithms	
  remove	
  this	
  

•  Get	
  orienta/on	
  from	
  DeviceMo/on	
  instead	
  
CMDeviceMo/on	
  
•  CMAptude	
  aptude	
  
•  CMRota/onRate	
  rota/onRate	
  

•  CMAccelera/on	
  gravity	
  
•  CMAccelera/on	
  userAccelera/on	
  
DEMO	
  
•  MacCMViewer	
  
•  CMIPViewer	
  




•  Source	
  code	
  available:	
  
  h1p://bitbucket.org/jblocksom/coremo/onviewer	
  
MacCMView:	
  What’s	
  Going	
  On?	
  
•  Mac	
  opens	
  socket;	
  iPhone	
  connects	
  
•  iPhone	
  sends	
  CM	
  updates	
  to	
  Mac	
  
•  Mac	
  uses	
  rota/on	
  matrix	
  for	
  display	
  
                                                            From	
  CMAptude	
  
CMAptude	
  
•  Rota/on	
  as	
  
    –  Yaw,	
  Pitch,	
  Roll	
  
    –  Quaternion	
  
    –  Rota/on	
  Matrix	
  


•  mul/plyByInverseOfAptude:	
  	
  
Why	
  Quaternions?	
  
•    Great	
  technique	
  for	
  represen/ng	
  rota/ons	
  
•    Mu/plying	
  q1	
  and	
  q2	
  is	
  composing	
  rota/ons	
  
•    Can	
  easily	
  pull	
  out	
  axis	
  /	
  angle	
  
•    Avoids	
  “Gimbal	
  Lock”	
  

•  h1p://en.wikipedia.org/wiki/
   Quaternions_and_spa/al_rota/on	
  
   is	
  a	
  pre1y	
  good	
  treatment	
  
•  Graphics	
  Gems	
  textbooks	
  
mul/plyByInverseOfAptude:	
  
•  Teapot	
  Demo	
  revisited	
  
Core	
  Mo/on	
  in	
  Simulator	
  
•  Accelerometer:	
  Not	
  available	
  
•  Gyros:	
  Not	
  available	
  
•  Device	
  Mo/on:	
  Not	
  available	
  

•  Workaround	
  thoughts…	
  
Final	
  Steps:	
  App	
  Requirements	
  
•  Add	
  UIRequiredDeviceCapabili/es	
  for	
  
   	
  accelerometer	
  
   	
  gyro	
  

•  Not	
  needed	
  for	
  orienta/on	
  /	
  shake	
  events	
  

•  See	
  Event	
  Handling	
  Guide,	
  
   “Sepng	
  Required	
  Hardware	
  Capabili/es	
  for	
  
   Accelerometer	
  and	
  Gyroscope	
  Events”	
  
Experiments	
  
•  iPhone	
  3GS	
  vs	
  iPhone	
  4	
  
•  Inter/al	
  Navigator	
  
•  Salad	
  Spinner	
  
Further	
  Reading	
  
•  Event	
  Handling	
  Guide	
  for	
  iPhone	
  OS	
  
    –  Look	
  under	
  “Mo/on	
  Events”	
  
    –  Sec/on	
  /tled	
  “Core	
  Mo/on”	
  
•  Core	
  Mo/on	
  framework	
  reference	
  
•  Sample	
  Code	
  
    –  WWDC	
  ’10:	
  CoreMo/onTeapot	
  


•  iPhone	
  Sensor	
  Group?	
  

More Related Content

What's hot

Motion capture technology
Motion capture technologyMotion capture technology
Motion capture technologyArun MK
 
Motion Capturing Technology
Motion Capturing TechnologyMotion Capturing Technology
Motion Capturing TechnologyMurlidhar Sarda
 
Motion capture technology
Motion capture technologyMotion capture technology
Motion capture technologyAnvesh Ranga
 
Motion Capture Technology
Motion Capture TechnologyMotion Capture Technology
Motion Capture TechnologyGameyan Studio
 
Motion capture technology
Motion capture technologyMotion capture technology
Motion capture technologyharini501
 
rescue robot based on embedded and ROV
rescue robot based on embedded and ROV rescue robot based on embedded and ROV
rescue robot based on embedded and ROV siddharth bhatt
 
Motion Capture Technology
Motion Capture TechnologyMotion Capture Technology
Motion Capture TechnologyAl Asheer
 

What's hot (7)

Motion capture technology
Motion capture technologyMotion capture technology
Motion capture technology
 
Motion Capturing Technology
Motion Capturing TechnologyMotion Capturing Technology
Motion Capturing Technology
 
Motion capture technology
Motion capture technologyMotion capture technology
Motion capture technology
 
Motion Capture Technology
Motion Capture TechnologyMotion Capture Technology
Motion Capture Technology
 
Motion capture technology
Motion capture technologyMotion capture technology
Motion capture technology
 
rescue robot based on embedded and ROV
rescue robot based on embedded and ROV rescue robot based on embedded and ROV
rescue robot based on embedded and ROV
 
Motion Capture Technology
Motion Capture TechnologyMotion Capture Technology
Motion Capture Technology
 

Similar to Get Moving With Core Motion Framework

Phonegap deep-dive
Phonegap deep-divePhonegap deep-dive
Phonegap deep-divealunny
 
台科大機械系 c 程式語言第二次演講
台科大機械系 c 程式語言第二次演講台科大機械系 c 程式語言第二次演講
台科大機械系 c 程式語言第二次演講Peter Chang
 
The Baseband Playground
The Baseband PlaygroundThe Baseband Playground
The Baseband Playgroundslides_luis
 
MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...
MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...
MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...MeasureWorks
 
Smau milano 2012 arena social media emanuele-bolognesi
Smau milano 2012   arena social media emanuele-bolognesiSmau milano 2012   arena social media emanuele-bolognesi
Smau milano 2012 arena social media emanuele-bolognesiSMAU
 
Mobility testing day_2_3_ppt
Mobility testing day_2_3_pptMobility testing day_2_3_ppt
Mobility testing day_2_3_pptsayhi2sudarshan
 
Mobile testing day_2_3_ppt
Mobile testing day_2_3_pptMobile testing day_2_3_ppt
Mobile testing day_2_3_pptsayhi2sudarshan
 
HIT3328 - Chapter01 - Platforms and Devices
HIT3328 - Chapter01 - Platforms and DevicesHIT3328 - Chapter01 - Platforms and Devices
HIT3328 - Chapter01 - Platforms and DevicesYhal Htet Aung
 
趣味に仕事にM5STACK♥.pdf
趣味に仕事にM5STACK♥.pdf趣味に仕事にM5STACK♥.pdf
趣味に仕事にM5STACK♥.pdfairpocketsoundman
 
How Internet of Things Works | IoT Examples | IoT Applications
How Internet of Things Works | IoT Examples | IoT ApplicationsHow Internet of Things Works | IoT Examples | IoT Applications
How Internet of Things Works | IoT Examples | IoT ApplicationsAnand SFJ
 
Experimenting with the OSGi platform in the Aspire RFID middleware
Experimenting with the OSGi platform in the Aspire RFID middlewareExperimenting with the OSGi platform in the Aspire RFID middleware
Experimenting with the OSGi platform in the Aspire RFID middlewareClément Escoffier
 
Creating Asha Games: Game Pausing, Orientation, Sensors and Gestures
Creating Asha Games: Game Pausing, Orientation, Sensors and GesturesCreating Asha Games: Game Pausing, Orientation, Sensors and Gestures
Creating Asha Games: Game Pausing, Orientation, Sensors and GesturesJussi Pohjolainen
 
Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...
Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...
Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...Comit Projects Ltd
 
IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...
IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...
IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...Spark Summit
 
ICEflo Implementation Management Solution V1d1
ICEflo Implementation Management Solution V1d1ICEflo Implementation Management Solution V1d1
ICEflo Implementation Management Solution V1d1Agenor Technology Ltd
 
Developing for Leap Motion
Developing for Leap MotionDeveloping for Leap Motion
Developing for Leap MotionIris Classon
 

Similar to Get Moving With Core Motion Framework (20)

Phonegap deep-dive
Phonegap deep-divePhonegap deep-dive
Phonegap deep-dive
 
Making sense
Making senseMaking sense
Making sense
 
台科大機械系 c 程式語言第二次演講
台科大機械系 c 程式語言第二次演講台科大機械系 c 程式語言第二次演講
台科大機械系 c 程式語言第二次演講
 
The Baseband Playground
The Baseband PlaygroundThe Baseband Playground
The Baseband Playground
 
MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...
MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...
MeasureWorks - Multichannel 2013 - Why your users quit your online (mobile) s...
 
Smau milano 2012 arena social media emanuele-bolognesi
Smau milano 2012   arena social media emanuele-bolognesiSmau milano 2012   arena social media emanuele-bolognesi
Smau milano 2012 arena social media emanuele-bolognesi
 
Adam w. mosher - geo tagging - atlseccon2011
Adam w. mosher - geo tagging - atlseccon2011Adam w. mosher - geo tagging - atlseccon2011
Adam w. mosher - geo tagging - atlseccon2011
 
Mobility testing day_2_3_ppt
Mobility testing day_2_3_pptMobility testing day_2_3_ppt
Mobility testing day_2_3_ppt
 
Mobile testing day_2_3_ppt
Mobile testing day_2_3_pptMobile testing day_2_3_ppt
Mobile testing day_2_3_ppt
 
HIT3328 - Chapter01 - Platforms and Devices
HIT3328 - Chapter01 - Platforms and DevicesHIT3328 - Chapter01 - Platforms and Devices
HIT3328 - Chapter01 - Platforms and Devices
 
趣味に仕事にM5STACK♥.pdf
趣味に仕事にM5STACK♥.pdf趣味に仕事にM5STACK♥.pdf
趣味に仕事にM5STACK♥.pdf
 
How Internet of Things Works | IoT Examples | IoT Applications
How Internet of Things Works | IoT Examples | IoT ApplicationsHow Internet of Things Works | IoT Examples | IoT Applications
How Internet of Things Works | IoT Examples | IoT Applications
 
Tot.st 1
Tot.st 1Tot.st 1
Tot.st 1
 
Experimenting with the OSGi platform in the Aspire RFID middleware
Experimenting with the OSGi platform in the Aspire RFID middlewareExperimenting with the OSGi platform in the Aspire RFID middleware
Experimenting with the OSGi platform in the Aspire RFID middleware
 
Creating Asha Games: Game Pausing, Orientation, Sensors and Gestures
Creating Asha Games: Game Pausing, Orientation, Sensors and GesturesCreating Asha Games: Game Pausing, Orientation, Sensors and Gestures
Creating Asha Games: Game Pausing, Orientation, Sensors and Gestures
 
Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...
Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...
Sensors, threats, responses and challenges - Dr Emil Lupu (Imperial College L...
 
IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...
IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...
IoT and the Autonomous Vehicle in the Clouds: Simultaneous Localization and M...
 
ICEflo Implementation Management Solution V1d1
ICEflo Implementation Management Solution V1d1ICEflo Implementation Management Solution V1d1
ICEflo Implementation Management Solution V1d1
 
Iommu tracing reviewed
Iommu tracing reviewedIommu tracing reviewed
Iommu tracing reviewed
 
Developing for Leap Motion
Developing for Leap MotionDeveloping for Leap Motion
Developing for Leap Motion
 

Recently uploaded

SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 

Recently uploaded (20)

SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 

Get Moving With Core Motion Framework

  • 1. Get  Moving  With  Core  Mo/on!   Jonathan  Blocksom   Tuesday  Sept  28  2010   2:00  –  3:15  PM   h1p://www.slideshare.net/jblocksom/core-­‐mo/on-­‐presenta/on  
  • 2. Agenda   •  Intro   •  SDK   •  Experiments   •  Q  &  A   •  Intro  level,  but  lots  of  code  
  • 3. About  Me   Jonathan  Blocksom   blocksom@gollygee.com   augmentedjonathan.tumblr.com   @jblocksom   •  Computer  Vision  So[ware  Engineer,   SET  Corp   •  Computer  Graphics  background   •  Several  years  working  with  Remote   Sensing  
  • 4. Meet  Core  Mo/on!   •  Core  Mo/on  Framework:   High  level  interface  to  the     orienta/on  and  movement     data  from  the  device   •  Based  on  Accelerometer  and  Gyroscopes   •  Accelera/on,  Gravity,  Rota/onal  Accelera/on   •  High  level  filtering  
  • 5. Core  Mo/on  isn’t…   •  For  GPS  data   –  That’s  Core  Loca/on  (Loca/onManager)   •  For  Compass  data   –  Also  Core  Loca/on   •  High  Level  Mo/on  Events   –  Orienta/on  change   –  Shake  events   •  Perfect  
  • 6. Quick  Demo   •  CoreMo/onTeapot   (WWDC  2010  sample   code)  
  • 7. Accelerometer   •  Available  since  iPhone  1   •  Consider  it  a  “Gravity  Detector”   •  Noisy   •  iPad,  iPhone  4:   STMicro  STM33DH   3-­‐axis  accelerometer   Photo  by  David  Hodson   h1p://www.ifixit.com/Guide/Image/meta/IP1qEpYFQSSqwSbg  
  • 8. Gyroscopes   •  New  in  iPhone  4,  iPod   Touch  4   •  Detects  rota/on  rate   along  three  axis   •  Chip  datasheet:   h1p://www.st.com/stonline/products/literature/ds/ 17116.pdf   •  200/500/2500  dps   (degrees  per  second)   •  0.03  dps  error  
  • 9. Gyro  Teardown   h1p://www.ifixit.com/Teardown/iPhone-­‐4-­‐Gyroscope-­‐Teardown/3156/1   Andrew  Bookholt:   h1p://www.ifixit.com/Guide/Image/meta/UurGsklhtJRW2uuB  (le[)   h1p://www.ifixit.com/Guide/Image/meta/MeunHawo54qPRY5S  (right  1)   Miroslav  Djuric   h1p://www.ifixit.com/Guide/Image/meta/RUQLo2PP1oqVtVsD  (right  2)  
  • 10. Accelerometer,  Gyro  &  Device  Mo/on   Accelerometer   Gyro   Device  Mo/on   Gravity   x,  y,  z   yaw,  pitch,  roll   User  accelera/on   Aptude   Rota/on  Rate  
  • 11. Supported  Devices   iPhone  1   iPhone   iPhone   iPhone  4   iPod   iPod   iPad   3G   3GS   Touch     Touch  4   Accelero Y   Y   Y   Y   Y   Y   Y   meter   Gyros   Y   iOS  4   Y   Y   Y   Y   iPhone  4   iPhone  3GS   iPhone  1   iPod  Touch  4   iPod  Touch   iPad  iOS  3.x   iPad  w/  iOS  4   Yay!   If  we  must…   No.  
  • 12. Classes   Class   Descrip8on   CMMo/onManager   The  Gateway   CMAccelerometerData   Accelera/on  data   X,  Y,  and  Z  rela/ve  to   device   In  G’s   CMAptude   Orienta/on   Roll,  Pitch,  Yaw   Rota/on  Matrix   Quaternion   CMDeviceMo/on   Roll  up  of  sensors   Differen/ates  gravity  from   user  accelera/on   CMGyroData   Rota/onal  Velocity   CMLogItem   Timestamped   Parent  Class  for   Measurement   measurements  
  • 13. CMMo/onManager   •  Tells  you  what’s  available   –  is<Acclerometer|DeviceMo/on|Gyro>Available   •  Sets  the  update  intervals   –  set<…>UpdateInterval   •  Starts  and  stops  updates   –  start<…>Updates   –  start<…>UpdatesToQueue:withHandler:   –  stop<…>Updates   •  Lets  you  poll  for  updates   –  accelerometerData   –  gyroData   –  deviceMo/on  
  • 14. CMMo/onManager   •  CMMo/onManager  *mgr  =   [[CMMo/onManager  alloc]  init];   •  Ini/alizes  reference  frame  at  construc/on   •  Only  make  one  of  these  for  your  app  
  • 15. Core  Mo/on  Coordinate  System   Quick  Reference   z   yaw   pitch   x   roll   y   Accelerometer   Gyroscopes  
  • 16. CMAccelerometerData   •  accelera/on   CMAccelera/on  struct:   typedef struct { double x; double y; double z; } CMAcceleration; •  Measured  in  G’s
  • 17. CMGyroData   •  YAGNI   •  Gyro’s  have  bias;  DeviceMo/on  fusion   algorithms  remove  this   •  Get  orienta/on  from  DeviceMo/on  instead  
  • 18. CMDeviceMo/on   •  CMAptude  aptude   •  CMRota/onRate  rota/onRate   •  CMAccelera/on  gravity   •  CMAccelera/on  userAccelera/on  
  • 19. DEMO   •  MacCMViewer   •  CMIPViewer   •  Source  code  available:   h1p://bitbucket.org/jblocksom/coremo/onviewer  
  • 20. MacCMView:  What’s  Going  On?   •  Mac  opens  socket;  iPhone  connects   •  iPhone  sends  CM  updates  to  Mac   •  Mac  uses  rota/on  matrix  for  display   From  CMAptude  
  • 21. CMAptude   •  Rota/on  as   –  Yaw,  Pitch,  Roll   –  Quaternion   –  Rota/on  Matrix   •  mul/plyByInverseOfAptude:    
  • 22. Why  Quaternions?   •  Great  technique  for  represen/ng  rota/ons   •  Mu/plying  q1  and  q2  is  composing  rota/ons   •  Can  easily  pull  out  axis  /  angle   •  Avoids  “Gimbal  Lock”   •  h1p://en.wikipedia.org/wiki/ Quaternions_and_spa/al_rota/on   is  a  pre1y  good  treatment   •  Graphics  Gems  textbooks  
  • 24. Core  Mo/on  in  Simulator   •  Accelerometer:  Not  available   •  Gyros:  Not  available   •  Device  Mo/on:  Not  available   •  Workaround  thoughts…  
  • 25. Final  Steps:  App  Requirements   •  Add  UIRequiredDeviceCapabili/es  for    accelerometer    gyro   •  Not  needed  for  orienta/on  /  shake  events   •  See  Event  Handling  Guide,   “Sepng  Required  Hardware  Capabili/es  for   Accelerometer  and  Gyroscope  Events”  
  • 26. Experiments   •  iPhone  3GS  vs  iPhone  4   •  Inter/al  Navigator   •  Salad  Spinner  
  • 27. Further  Reading   •  Event  Handling  Guide  for  iPhone  OS   –  Look  under  “Mo/on  Events”   –  Sec/on  /tled  “Core  Mo/on”   •  Core  Mo/on  framework  reference   •  Sample  Code   –  WWDC  ’10:  CoreMo/onTeapot   •  iPhone  Sensor  Group?  

Editor's Notes

  1. Wikipedia rant – great for Epipolar Geometry, terrible for Quaternions