32
Introduction to Intel IoT Hardware, Software, Connectivity, and Innovation using Intel Galileo INNOVASEAN Southeast Asia Makerspace Summit 5-7 June 2015 Singapore

Intel galileo

Embed Size (px)

Citation preview

Page 1: Intel galileo

Introduction to Intel IoT

Hardware, Software, Connectivity, and Innovation using Intel Galileo

INNOVASEANSoutheast Asia Makerspace Summit

5-7 June 2015Singapore

Page 2: Intel galileo

Name          :  Sofian  Hadiwijaya  SocMed  :  @sofianhw  Email          :  [email protected]

 Introduction    

Page 3: Intel galileo

 Introduction    ▪ Founder  of  Crazy  Hackerz  ▪ Intel  IoT  Innovator  

▪ Web  developer  ▪ Javascript,  Nodejs,  Python  

▪ The  Winner  of  Blackberry  Jam  Hack  Asia  in  Bangkok  2012

Page 4: Intel galileo

 Introduction    

Page 5: Intel galileo

 Introduction    

Page 6: Intel galileo

 Introduction    

Page 7: Intel galileo

 Intel Galileo Board Overview    

7

Page 8: Intel galileo

 Intel Galileo Board Overview    

8

Page 9: Intel galileo

 Intel Galileo Board Overview    

9

▪ The   Intel®   Galileo   board   is   based   on   the   Intel®   Quark   SoC  X1000,  a  32-­‐  bit  Intel  Pentium®-­‐class  system  on  a  chip  (SoC).  It  is  the  first  board  based  on  Intel®  architecture  designed  to  be   hardware   and   software   pin-­‐   compatible   with   shields  designed  for  the  Arduino  Uno  R3.  

▪ The   Galileo   board   is   also   software-­‐compatible   with   the  Arduino  Software  Development  Environment.  

▪ The   Intel   processor   and   surrounding   native   I/O   capabilities  of  the  SoC  provides  for  a  fully  featured  offering  for  both  the  maker  community  and  students  alike

Page 10: Intel galileo

 Intel Galileo Board Communication

10

▪ 10/100  Mb  Ethernet  RJ45  port  ▪ USB  device  port.  ▪ USB  Host  port.  ▪ Mini  PCI  Express  (mPCIe)

Page 11: Intel galileo

 Internet of Things Overview

11

Page 12: Intel galileo

 Internet of Things Overview

12

Page 13: Intel galileo

 Internet of Things Overview

13

Page 14: Intel galileo

 Internet of Things Overview

14

Page 15: Intel galileo

 Internet of Things Component

15

▪ Things  ▪ Internet    ▪ People  /  Process

Page 16: Intel galileo

 Internet of Things Device

16

▪ Sensors  /  Actuators  ▪ Microcontroller    ▪ Minicomputer

Page 17: Intel galileo

 Internet of Things Connectivity

17

▪ Data  Protocol  ▪ HTTP  ▪ MQTT  ▪ CoAP  

▪ Network  ▪  WiFi  ▪ LAN  ▪ Bluetooth  ▪ BLE  ▪ 6lowpan

Page 18: Intel galileo

 Intel Galileo Board Arduino

18

▪ There  are  two  location  where  you  can  download  the  Arduino  IDE  for  Intel  Galileo:  ▪ The  Arduino  website  http://arduino.cc/en/main/software.  ▪ The   Intel   website   https://downloadcenter.intel.com/

download/24782

Page 19: Intel galileo

 Intel Galileo Board Connecting

19

▪ Always   connect   the  power   supply  before   the  USB   cable  on  client  port,  to  avoid  hardware  damages.  Remember,  the  intel  Galileo  Gen   2   power   supply  must   be   between   7V   and   12V  DC.  You  cannot  use  5V  DC.  

▪ Always   keep   the   power   supply   connected   to   Intel   Galileo  when  transferring  sketches  or  updating  the  firmware  of  your  board.   Developers   are   tempted   to   use   the  USB   Client   Port  because  if  can  boot  the  board  and  run  the  sketches  but  the  5V  power  supply   is  really  recommended  to  keep  connected  in  all  occasions  and  to  avoid  hardware  instability.

Page 20: Intel galileo

 Intel Galileo Board Connecting

20

Page 21: Intel galileo

 Intel Galileo Board Installing Aduino IDE

21

▪ For   the   windows   user,   just   simple   extract   the   file,   and  double  click  Arduino.exe  

▪ And  for  the  MacOs  user,  also  extract  the  file  and  move  it  into  Application  folder.  

▪ For  The  Linux  User:  ▪ Extract  download  file  ▪ some  of  linux  distribution  include  a  package  call  “modem  

manager”   that  can  affect   the  serial  port  communication.  you  should  remove  it.  

▪ after  that  just  run  “./arduino”

Page 22: Intel galileo

 Intel Galileo Board Understanding Arduino IDE

22

Page 23: Intel galileo

 Intel Galileo Board Understanding Arduino IDE

23

1. Area  code  where  you  develop  the  code.  2. Notification   bar   informing   you   if   the   code   was   saved   and  

whether  the  compilation  was  successful.  3. Console   message   with   details   of   compilation,   file   transfer  

messages,  and  error  messages.  4. Informs  the  line  number  of  the  cursor  in  the  editor.  5. Verify  icon:  compile  the  code.  6. Transfer  icon:  compule  the  code  and  transfer  to  Intel  Galileo.  7. Open  a  new  sketch.  8. Open  a  sketch.  9. Save  the  edited  sketch.  10.Open  the  serial  debug  console.

Page 24: Intel galileo

 Intel Galileo Board Understanding Arduino IDE

24

Page 25: Intel galileo

 Intel Galileo Board Understanding Arduino IDE

25

Page 26: Intel galileo

 Intel Galileo Board Understanding Arduino IDE

26

• Note   that   the   port   name   varies   according   to   operational  system  :  • Windows:   the   ports   are   named   with   the   COM   prefix,  followed  an  integer  number,  such  as  COM5.  

• Linux:   the   ports   are   named   with   the   ttyACM   prefix,  followed  by  an  integer  number,  such  as  ttyACM0.  

• MacOs:   the   ports   are   named   with   the   /dev/cu.usbmodem   prefix,   followed   by   a   sequence   of  numbers   and/or   alphabetic   characters,   such   as   /dev/cu.usbmodem0001  or  /dev/cu.usbmodemfd021

Page 27: Intel galileo

 Intel Galileo Board What Is a Sketch?

27

The  sketch  is  composed  by  two  main  function:  setup()  and  loop()  • the  setup()   function   is  executed  one  time,  and  this   function  establishes   the   initial   setup  of   your  hardware,   including   the  pin  directions,  etc.  

• the   loop()   function   is   cyclic,   which   means   it   works   like   an  infinite  loop.  It  is  on  this  function  you  control  your  hardware.

Page 28: Intel galileo

 Intel Galileo Board Arduino Reference

28

• Digital  I/O  • pinMode(int  pin,  int  mode)  • digitalWrite(int  pin,  int  state)  • digitalRead(int  pin)  

• Analog  I/O  • analogRead(int  pin)  • analogWrite(int  pin,  int  value)  

• Time  • delay(int  milliseconds)  

http://arduino.cc/en/Reference/Homepage

Page 29: Intel galileo

 Intel Galileo Board Hello world!!

29

• File  -­‐>  Example  -­‐>  Basic  -­‐>  Blink  • Upload  to  Galileo

Page 30: Intel galileo

 Intel Galileo Board Hello world!!

30

• system("ifconfig   eth0   192.168.2.3   netmask   255.255.255.0  gateway  192.168.2.1");  

• system("telnetd  -­‐l  /bin/sh”);  

• system("ifconfig  eth0  >  /dev/ttyGS0”);  • sleep(10);

Page 31: Intel galileo

 Intel Galileo Board GPIO Ref

31

Page 32: Intel galileo

 Intel Galileo Board Control GPIO Linux

32

• Setting  IO13  as  GPIO  Output  :  $  echo  -­‐n  “out”  >  /sys/class/gpio/gpio39/direction  $  echo  0  >  /sys/class/gpio/gpio39/value  #  LOW  $  echo  1  >  /sys/class/gpio/gpio39/value  #  HIGH