Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Swift on Raspberry Pi でI2Cデバイスを使う

Yusuke Ito
December 19, 2016

Swift on Raspberry Pi でI2Cデバイスを使う

Yusuke Ito

December 19, 2016
Tweet

More Decks by Yusuke Ito

Other Decks in Programming

Transcript

  1. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE 4XJGUPO3BTQCFSSZ1J Ͱ*$σόΠεΛ࢖͏ ϦʔυΞʔΩςΫτ
 ҏ౻༞ี :VTVLF*UP [email protected] നϠΪίʔϙϨʔγϣϯ 5PLZP4FSWFS4JEF4XJGU.FFUVQ
 

  2. ೥݄೔ʙ೔

  3. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE 

  4. ΄͔े਺ࣾ ΧϝϦΦͷΞϧΰϦζϜΛαʔϏεͱͯ͠"1*ఏڙ

  5. None
  6. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE *$όε w *$·ͨ͸*$·ͨ͸**$ w QJO 4$- 4%" 7$$ 7౳

    ʹϓϧΞοϓ w ಉ͡όεʹ࠷େσόΠε w ඪ४͸LCQT w 1$ ૊ࠐܥϘʔυ ϫϯνοϓͷϚΠίϯ "SEVJOPʹඪ ४౥ࡌ
 1$͸಺෦Ͱ࢖ΘΕ͍ͯΔͨΊ୺ࢠ͸ແ͠ 
  7. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE ༻్ w ηϯα w σΟεϓϨΠ w λονύωϧ w &&130.

    w ௿଎ͳ%" "%ίϯόʔλʔ 
  8. .$$*$#VT5FDIOJDBM0WFSWJFX
 IUUQXXXNDDVTDPN*$#VT5FDIOJDBM0WFSWJFXQEG Ϛελʔ௨৴Λ։࢝͢Δଆ1$ ϚΠίϯ εϨʔϒ௨৴Λड͚ΔଆηϯαʔσΟεϓϨΠ ΞυϨε ෺ཧ഑ઢ όε

  9. ϓϥοτ
 ϑΥʔϜ Πϯλʔ
 ϑΣʔε υϥΠόʔ ΞϓϦέʔ
 γϣϯଆ"1* .BD NBD04 64#*$ม׵

    *0,JU MJCVTC*0,JU 1$ -JOVY 64#*$ม׵ Χʔωϧ EFW JD PQFO JPDUM 3BTQCFSSZ1J
 -JOVY (1*0 ୺ࢠ Χʔωϧ EFW JD PQFO JPDUM 64#*$ม׵ Χʔωϧ EFW JD PQFO JPDUM
  10. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE ઀ଓͱୟ͖ํ w .BD 8JOEPXT1$ ͸64#*$ม׵ΞμϓλΛ࢖͏ w 3BTQCFSSZ1J͸*$ͷ୺ࢠ (1*0಺ ·ͨ͸64#*$ม

    ׵ΞμϓλΛ࢖͏ w .BDMJCVTC౳Λ࢖ͬͯୟ͘ w -JOVYΧʔωϧυϥΠόʔ EFWJD ͕͋ΔͷͰPQFO  JPDUMΛ࢖͏ SFBE XSJUFͰ΋͍͍ 
  11. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE ςετ༻ͷϘʔυ w 64#*$ม׵ JDUJOZVTC Λ࡞੒ w *$όεʹϞδϡʔϧΛ࣮૷ w 

     ηάϝϯτ-&%Ϟδϡʔϧ ;54&(#""  w ໌Δ͞ηϯαʔ #)  w ؾѹηϯαʔ #.1  w "JUFOEP FCBZͰങ͑·͢ w ిݯిѹ͸7 
  12. 64#*$ ม׵ -&% ؾѹ ηϯαʔ ໌Δ͞ ηϯαʔ

  13. $PQZSJHIU4IJSPZBHJ$PSQPSBUJPO"MMSJHIUTSFTFSWFE ϥΠϒϥϦͷ࡞੒ w ϓϥοτϑΥʔϜʹΑͬͯɺୟ͖ํɾ"1*͕ҧ͏
 NBD04ʹ͸EFWJD ͕ແ͍ͳͲ w σόοά͸.BD 9DPEF Ͱߦ͍͍ͨ

    w ͢΂ͯͷϓϥοτϑΥʔϜͰ࣮ߦՄೳʹ͍ͨ͠ 4XJ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