SlideShare a Scribd company logo
Intel Edison: Beyond the breadboard
1
By: Yeo Kheng Meng (yeokm1@gmail.com)Hackware v1.9 (29 June 2016)
Why beyond the breadboard?
2
One of Algoaccess’s hardware product
3
Algo Access’s hardware setup
OD, OS, CYL…
OD, OS, CYL…
Direct or USB-Ethernet adapter
RS232 DB-9 Serial port
Agenda
1. Intel Edison Basics
2. Hardware experience
3. Software experience
4
So what is the Intel Edison?
5
35.5mm x 25 mm x 3.9mm System-on-module (SOM)
• Using Hirose 70-pin DF40 Series Connector (0.4mm pitch)
Raspberry Pi 3 vs Intel Edison specifications
6
Specifications Raspberry Pi 3 Intel Edison
CPU 1.2Ghz quad-core BCM2837
Cortex-A53
ARMv8 (64-bit)
500Mhz dual-core Intel Atom x86 (32-bit)
+
Intel Quark MCU
GPU 400Mhz Videocore IV None
RAM 1GB DDR2 1GB DDR3
Storage External microSD cad 4GB eMMC flash onboard
Networking Single band 802.11n Wifi + Dual-mode BT + LAN Dual-band 802.11n Wifi + Dual-mode BT
I/0 Connectivity 3.3V level level GPIO bank + connectors 1.8V logic level GPIO-bank
Price US$35 US$50++
Power consumption (Idle/Peak) 1W/3.6W 0.1W / 1 W
Dimensions 85 x 56 x 17mm 35.5 x 25 x 3.9mm
2 models of Intel Edison
7
No chip antenna image from:
http://www.nix.ru/autocatalog/thin_clients/208148_2254_draft_large.jpg
From Intel Edison Compute Module Hardware Guide (June 2016) Page 13
http://www.intel.com/content/www/us/en/support/boards-and-kits/000005808.html
Official Intel carrier boards
8
Mini Breakout board
• USB Serial
• USB-OTG
• GPIO pins (1.8V logic level)
• ~US$25
Arduino Breakout board
• Arduino-style pins
• USB-Serial
• USB-OTG
• Micro-SD slot
• DC Jack 7-15V DC
• 3.3V or 5V logic levels depending on J9 position
• Default is 5V
• ~US$60
https://www.arduino.cc/en/ArduinoCertified/IntelEdison
Sparkfun stackable/carrier boards
9
Base Block
64x48 0.66” OLED + buttons “Level-shiftable” GPIO breakout 9-DOF IMU Dual H bridge Battery board
Prototyping: Bare breakout board
10
• Hirose 70-pin DF40 Series Receptacle Connector (0.4mm pitch)
• Tough to solder by hand without magnifying glass/microscope
• Stencil highly recommended to avoid solder bridges
• https://github.com/algoaccess/intel-edison-pin-breakout
Hirose 70-pin DF40 interface
11
Pin Function Description
1, 5, 9, 11, 13,
15
GND Ground
2, 4, 6 VSYS in Power Input (3.3V to 4.5V)
14 DCIN Connect to VSYS if powered from
external power
8, 10, 12 3.3V/1.8V out Reference voltage (100mA)
46, 61, 63, 65 UART1
(with flow
control)
UART with flow control
/dev/ttyMFD1
22, 27 UART2
(no flow control)
Linux debug serial port
/dev/ttyMFD2
3, 16, 18, 20 USB
(USB_VBUS does
not supply
power)
USB interface
41, 43
45, 47
I2C1
I2C6
2x I2C interfaces
Only master supported
51, 53,
55, 57, 59
SPI Master/Slave supported
Chip select: 51, 53
Picture from: https://learn.sparkfun.com/tutorials/general-guide-to-sparkfun-blocks-for-intel-edison
All pins except power and USB operate at 1.8V levels
1.8V logic levels
• All pins except power and USB operate at 1.8V levels
• But most chips are using 3.3/5.0 V
• For eg, MAX3232 RS232-TTL transceiver (3.3V)
• Use a level shifter like TXS0108EPWR
• Reference 1.8V from Module Pin 12
• For LEDs, you can just use a transistor
12
Bug: Using GPIO48 destabilises Wifi
13
http://iotdk.intel.com/docs/master/mraa/edison.html
Arduino Pin 7 can sometimes
negatively impact the WiFi capability,
if using WiFi avoid using this pin
Pin Naming Aliases:
GP48
Compute Module Pin 32
Arduino Pin 7
Avoid GPIO48
14J19, Pin 6
USB On-The-Go
15Adapted from Intel Edison Compute Module Hardware Guide (June 2016) Page 36
http://www.intel.com/content/www/us/en/support/boards-and-kits/000005808.html
• Host mode
• Connect USB peripherals like flash drives
• Client mode
• Loading firmware (DFU mode)
• USB OTG supports both Host and Client
• Can use a Double pole, double throw (DPDT) switches
USB Role USB_ID
(Pin 3)
FAULT
(Pin 19)
USB_VBUS
(Pin 20)
Host GND Floating Floating
Client Floating GND Host 5V
GND
Fault
USB_ID
USB-A Power Line
USB_VBUS
Source 5V
Client
Host
Intel Edison Linux Distributions
1. 1.6 (Default)
• Based on “Poky” Linux distribution
• Compile Poky Linux sources/packages using provided toolchain and recipes
• Limited “opkg” package manager and few default packages
• (eg, no nano, only vi)
• Can add third party “meta-openembedded” recipes during compile time
2.
• Produced by Emutex Labs
• Based on Debian 7 Wheezy (2013)
• More packages compared to Yocto using (apt-get)
• Packages outdated compared to Debian 8 Jessie (2015)
3. Compile your own: Yocto or Debian Jessie
• All use old kernel version 3.10.17 (Oct 2013)
16
Poor default support for USB-Ethernet and USB-Serial adapters
• Only supports adapters based on these chipsets
• Ethernet: ASIX AX88xxx USB 2.0 to Gigabit adapter
• Serial: Prolific PL2303 USB-Serial adapter
• More support requires kernel recompilation 17
Small rootfs partition size
18
• 1.4GB, 541MB available on initial boot, may be too small for some uses
• Modifying rootfs partition size requires recompilation
My compilation script
• Compiles in all available USB-Ethernet/Serial drivers, custom rootfs size
• Downloads sources, modifies compile options then compile
• https://github.com/algoaccess/edison_mod_kernel_image_gen
19
Lengthy compilation time
• 4-6 hours typical
• Use the cloud -> Google Compute Engine or AWS (About half hour on 32 threads)
• export SETUP_ARGS="--parallel_make=32 --bb_number_thread=32"
• IMPORTANT: Remember to SHUT DOWN your instance once finished, if not hefty charges will be incurred!!! 20
File System safety for embedded systems
• Improper shutdown of systems can corrupt file systems
• Cause: System off while data is being written
1. Read-only file system
• No writes to file-system allowed, no chance of system corruption
2. Enable full-journaling
• File-system journals store a list of changes to be made
• Ext4 default is to journal meta-data only, not the data itself
• We should also journal the data for additional protection
21
Read-only file system (preferred)
• ----------------/etc/fstab------------------------
rootfs / auto ro 1 1
/dev/disk/by-partlabel/boot /boot auto ro 1 1
/dev/disk/by-partlabel/home /home auto ro 0 2
tmpfs /var/tmp tmpfs nodev,nosuid 0 0
tmpfs /var/log tmpfs nodev,nosuid 0 0
• ------------------------------------------------------
• tmpfs: RAM drive
• nodev,nosuid: Security precautions for world-writeable file-systems
22https://gist.github.com/yeokm1/00bf00fbcda99cc33c2b
Mount file system to journal everything
• Set journal option to / partition
• tune2fs -o journal_data /dev/mmcblk0p8
• Set journal option to /home partition
• tune2fs -o journal_data /dev/mmcblk0p10
• ----------------/etc/fstab------------------------
• rootfs / ext4 data=journal,sync,noatime 1 1
• /dev/disk/by-partlabel/boot /boot auto ro 1 1
• /dev/disk/by-partlabel/home /home ext4 data=journal,sync,noatime 0 2
• ------------------------------------------------------
• data=journal: Journal everything. Data will be written twice, first in to journal, second into disk
• sync: Commit changes to disk immediately, do not cache. Performance loss
• noatime: Do not store last access time to increase disk performance to avoid updating access time in every sync
23
QnA
24

More Related Content

PPTX
Lab Handson: Power your Creations with Intel Edison!
PDF
IoT Getting Started with Intel® IoT Devkit
PDF
Interacting with Intel Edison
PDF
Rdl esp32 development board trainer kit
PDF
Introduction to ESP32 Programming [Road to RIoT 2017]
PDF
Introduction to RIoT Hardware Kits & ESP32 Programming [Road to RIoT 2017]
PDF
Republic of IoT - Hackathon Hardware Kits Hands-on Labs
ODP
Raspberry Pi introduction
Lab Handson: Power your Creations with Intel Edison!
IoT Getting Started with Intel® IoT Devkit
Interacting with Intel Edison
Rdl esp32 development board trainer kit
Introduction to ESP32 Programming [Road to RIoT 2017]
Introduction to RIoT Hardware Kits & ESP32 Programming [Road to RIoT 2017]
Republic of IoT - Hackathon Hardware Kits Hands-on Labs
Raspberry Pi introduction

What's hot (20)

PDF
Secret of Intel Management Engine by Igor Skochinsky
PPTX
PCB Business Card
PDF
How to Install ESP8266 WiFi Web Server using Arduino IDE
PPTX
[5]投影片 futurewad樹莓派研習會 141218
PDF
Home automation-in-the-cloud-with-the-esp8266-and-adafruit-io
PDF
Tapping into the core
PDF
Iot Bootcamp - abridged - part 1
PPTX
IOT Talking to Webserver - how to
PPTX
A Quick Introduction to Programmable Logic
PPT
Beagle board101 esc-boston-2009b
PPTX
Remote tanklevelmonitor
PDF
Asus Tinker Board
PDF
MOSS 2016, Bucharest, Romania - Designing the IoT Jukebox with Brillo
PDF
lesson2 - Nodemcu course - NodeMCU dev Board
PDF
HITBSecConf 2016-Create Your Own Bad Usb
PPTX
Esp8266 - Intro for dummies
PPT
Introduction to beagle board
PDF
HITBSecConf 2017-Shadow-Box-the Practical and Omnipotent Sandbox
PDF
BlackHat Asia 2017-Myth and Truth about Hypervisor-Based Kernel Protector
PPTX
Nodemcu - introduction
Secret of Intel Management Engine by Igor Skochinsky
PCB Business Card
How to Install ESP8266 WiFi Web Server using Arduino IDE
[5]投影片 futurewad樹莓派研習會 141218
Home automation-in-the-cloud-with-the-esp8266-and-adafruit-io
Tapping into the core
Iot Bootcamp - abridged - part 1
IOT Talking to Webserver - how to
A Quick Introduction to Programmable Logic
Beagle board101 esc-boston-2009b
Remote tanklevelmonitor
Asus Tinker Board
MOSS 2016, Bucharest, Romania - Designing the IoT Jukebox with Brillo
lesson2 - Nodemcu course - NodeMCU dev Board
HITBSecConf 2016-Create Your Own Bad Usb
Esp8266 - Intro for dummies
Introduction to beagle board
HITBSecConf 2017-Shadow-Box-the Practical and Omnipotent Sandbox
BlackHat Asia 2017-Myth and Truth about Hypervisor-Based Kernel Protector
Nodemcu - introduction
Ad

Viewers also liked (6)

PPTX
Getting started with Intel IoT Developer Kit
PDF
Teeth presentation by Nathan Carver
PDF
Intel IoT webinar #1 - Tedison presentation
PDF
Intel Edison a toda potencia.
PDF
IoT Knowledge Forum Slides by Deepak Gupta
PPT
Internet of Things and its applications
Getting started with Intel IoT Developer Kit
Teeth presentation by Nathan Carver
Intel IoT webinar #1 - Tedison presentation
Intel Edison a toda potencia.
IoT Knowledge Forum Slides by Deepak Gupta
Internet of Things and its applications
Ad

Similar to Intel Edison: Beyond the Breadboard (20)

PDF
How to Hack Edison
PPTX
Начало работы с Intel IoT Dev Kit
PDF
DeviceHub - First steps using Intel Edison
PDF
TDC2016SP - Trilha Linux Embarcado
PDF
Android Things in action
PDF
Valerio Di Giampietro - Introduction To IoT Reverse Engineering with an examp...
PDF
LAS16-300: Mini Conference 2 Cortex-M Software - Device Configuration
PDF
Mainline kernel on ARM Tegra20 devices that are left behind on 2.6 kernels
PDF
Android Things Linux Day 2017
PDF
It's Assembler, Jim, but not as we know it: (ab)using binaries from embedded ...
PDF
Linux+sensor+device-tree+shell=IoT !
PDF
The GNU Debugger GDB for the benefit of Embedded Engineering
PDF
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
PPTX
Embedded Systems Overview
PDF
Kernel Recipes 2018 - New GPIO interface for linux user space - Bartosz Golas...
PDF
44CON London 2015 - Jtagsploitation: 5 wires, 5 ways to root
PDF
Embedded Linux Systems Basics
ODP
UWE Linux Boot Camp 2007: Hacking embedded Linux on the cheap
PDF
Develop Your Own Operating Systems using Cheap ARM Boards
PDF
Userspace drivers-2016
How to Hack Edison
Начало работы с Intel IoT Dev Kit
DeviceHub - First steps using Intel Edison
TDC2016SP - Trilha Linux Embarcado
Android Things in action
Valerio Di Giampietro - Introduction To IoT Reverse Engineering with an examp...
LAS16-300: Mini Conference 2 Cortex-M Software - Device Configuration
Mainline kernel on ARM Tegra20 devices that are left behind on 2.6 kernels
Android Things Linux Day 2017
It's Assembler, Jim, but not as we know it: (ab)using binaries from embedded ...
Linux+sensor+device-tree+shell=IoT !
The GNU Debugger GDB for the benefit of Embedded Engineering
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
Embedded Systems Overview
Kernel Recipes 2018 - New GPIO interface for linux user space - Bartosz Golas...
44CON London 2015 - Jtagsploitation: 5 wires, 5 ways to root
Embedded Linux Systems Basics
UWE Linux Boot Camp 2007: Hacking embedded Linux on the cheap
Develop Your Own Operating Systems using Cheap ARM Boards
Userspace drivers-2016

More from yeokm1 (20)

PPTX
I became a Private Pilot and this is my story
PPTX
What's inside a Cessna 172 and flying a light plane
PPTX
Speaking at Tech meetups/conferences for Junior Devs
PPTX
Reflections on Trusting Trust for Go
PPTX
Meltdown and Spectre
PPTX
Gentoo on a 486
PPTX
BLE Localiser (Full) for iOS Dev Scout
PPTX
BLE Localiser for iOS Conf SG 2017
PPTX
Repair Kopitiam Specialty Tools (Part 2): Short Circuit Limiter
PPTX
PCB Business Card (Singapore Power)
PPTX
SP Auto Door Unlocker
PPTX
SP IoT Doorbell
PPTX
Distance Machine Locker
PPTX
A Science Project: Building a sound card based on the Covox Speech Thing
PPTX
A Science Project: Swift Serial Chat
PPTX
The slide rule
PPT
Windows 3.1 (WFW) on vintage and modern hardware
PPTX
Repair Kopitiam Circuit Breaker Training
PPTX
A2: Analog Malicious Hardware
PPTX
Getting Started with Raspberry Pi
I became a Private Pilot and this is my story
What's inside a Cessna 172 and flying a light plane
Speaking at Tech meetups/conferences for Junior Devs
Reflections on Trusting Trust for Go
Meltdown and Spectre
Gentoo on a 486
BLE Localiser (Full) for iOS Dev Scout
BLE Localiser for iOS Conf SG 2017
Repair Kopitiam Specialty Tools (Part 2): Short Circuit Limiter
PCB Business Card (Singapore Power)
SP Auto Door Unlocker
SP IoT Doorbell
Distance Machine Locker
A Science Project: Building a sound card based on the Covox Speech Thing
A Science Project: Swift Serial Chat
The slide rule
Windows 3.1 (WFW) on vintage and modern hardware
Repair Kopitiam Circuit Breaker Training
A2: Analog Malicious Hardware
Getting Started with Raspberry Pi

Recently uploaded (20)

PPTX
Tartificialntelligence_presentation.pptx
PPTX
Chapter 5: Probability Theory and Statistics
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
1. Introduction to Computer Programming.pptx
PDF
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
PPTX
TLE Review Electricity (Electricity).pptx
PDF
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
PDF
A comparative analysis of optical character recognition models for extracting...
PPTX
SOPHOS-XG Firewall Administrator PPT.pptx
PDF
A novel scalable deep ensemble learning framework for big data classification...
PDF
project resource management chapter-09.pdf
PDF
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PPTX
A Presentation on Artificial Intelligence
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Transform Your ITIL® 4 & ITSM Strategy with AI in 2025.pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Getting Started with Data Integration: FME Form 101
Tartificialntelligence_presentation.pptx
Chapter 5: Probability Theory and Statistics
Building Integrated photovoltaic BIPV_UPV.pdf
Digital-Transformation-Roadmap-for-Companies.pptx
1. Introduction to Computer Programming.pptx
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
TLE Review Electricity (Electricity).pptx
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
A comparative analysis of optical character recognition models for extracting...
SOPHOS-XG Firewall Administrator PPT.pptx
A novel scalable deep ensemble learning framework for big data classification...
project resource management chapter-09.pdf
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
Assigned Numbers - 2025 - Bluetooth® Document
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
A Presentation on Artificial Intelligence
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Transform Your ITIL® 4 & ITSM Strategy with AI in 2025.pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Getting Started with Data Integration: FME Form 101

Intel Edison: Beyond the Breadboard

  • 1. Intel Edison: Beyond the breadboard 1 By: Yeo Kheng Meng (yeokm1@gmail.com)Hackware v1.9 (29 June 2016)
  • 2. Why beyond the breadboard? 2 One of Algoaccess’s hardware product
  • 3. 3 Algo Access’s hardware setup OD, OS, CYL… OD, OS, CYL… Direct or USB-Ethernet adapter RS232 DB-9 Serial port
  • 4. Agenda 1. Intel Edison Basics 2. Hardware experience 3. Software experience 4
  • 5. So what is the Intel Edison? 5 35.5mm x 25 mm x 3.9mm System-on-module (SOM) • Using Hirose 70-pin DF40 Series Connector (0.4mm pitch)
  • 6. Raspberry Pi 3 vs Intel Edison specifications 6 Specifications Raspberry Pi 3 Intel Edison CPU 1.2Ghz quad-core BCM2837 Cortex-A53 ARMv8 (64-bit) 500Mhz dual-core Intel Atom x86 (32-bit) + Intel Quark MCU GPU 400Mhz Videocore IV None RAM 1GB DDR2 1GB DDR3 Storage External microSD cad 4GB eMMC flash onboard Networking Single band 802.11n Wifi + Dual-mode BT + LAN Dual-band 802.11n Wifi + Dual-mode BT I/0 Connectivity 3.3V level level GPIO bank + connectors 1.8V logic level GPIO-bank Price US$35 US$50++ Power consumption (Idle/Peak) 1W/3.6W 0.1W / 1 W Dimensions 85 x 56 x 17mm 35.5 x 25 x 3.9mm
  • 7. 2 models of Intel Edison 7 No chip antenna image from: http://www.nix.ru/autocatalog/thin_clients/208148_2254_draft_large.jpg From Intel Edison Compute Module Hardware Guide (June 2016) Page 13 http://www.intel.com/content/www/us/en/support/boards-and-kits/000005808.html
  • 8. Official Intel carrier boards 8 Mini Breakout board • USB Serial • USB-OTG • GPIO pins (1.8V logic level) • ~US$25 Arduino Breakout board • Arduino-style pins • USB-Serial • USB-OTG • Micro-SD slot • DC Jack 7-15V DC • 3.3V or 5V logic levels depending on J9 position • Default is 5V • ~US$60 https://www.arduino.cc/en/ArduinoCertified/IntelEdison
  • 9. Sparkfun stackable/carrier boards 9 Base Block 64x48 0.66” OLED + buttons “Level-shiftable” GPIO breakout 9-DOF IMU Dual H bridge Battery board
  • 10. Prototyping: Bare breakout board 10 • Hirose 70-pin DF40 Series Receptacle Connector (0.4mm pitch) • Tough to solder by hand without magnifying glass/microscope • Stencil highly recommended to avoid solder bridges • https://github.com/algoaccess/intel-edison-pin-breakout
  • 11. Hirose 70-pin DF40 interface 11 Pin Function Description 1, 5, 9, 11, 13, 15 GND Ground 2, 4, 6 VSYS in Power Input (3.3V to 4.5V) 14 DCIN Connect to VSYS if powered from external power 8, 10, 12 3.3V/1.8V out Reference voltage (100mA) 46, 61, 63, 65 UART1 (with flow control) UART with flow control /dev/ttyMFD1 22, 27 UART2 (no flow control) Linux debug serial port /dev/ttyMFD2 3, 16, 18, 20 USB (USB_VBUS does not supply power) USB interface 41, 43 45, 47 I2C1 I2C6 2x I2C interfaces Only master supported 51, 53, 55, 57, 59 SPI Master/Slave supported Chip select: 51, 53 Picture from: https://learn.sparkfun.com/tutorials/general-guide-to-sparkfun-blocks-for-intel-edison All pins except power and USB operate at 1.8V levels
  • 12. 1.8V logic levels • All pins except power and USB operate at 1.8V levels • But most chips are using 3.3/5.0 V • For eg, MAX3232 RS232-TTL transceiver (3.3V) • Use a level shifter like TXS0108EPWR • Reference 1.8V from Module Pin 12 • For LEDs, you can just use a transistor 12
  • 13. Bug: Using GPIO48 destabilises Wifi 13 http://iotdk.intel.com/docs/master/mraa/edison.html Arduino Pin 7 can sometimes negatively impact the WiFi capability, if using WiFi avoid using this pin Pin Naming Aliases: GP48 Compute Module Pin 32 Arduino Pin 7
  • 15. USB On-The-Go 15Adapted from Intel Edison Compute Module Hardware Guide (June 2016) Page 36 http://www.intel.com/content/www/us/en/support/boards-and-kits/000005808.html • Host mode • Connect USB peripherals like flash drives • Client mode • Loading firmware (DFU mode) • USB OTG supports both Host and Client • Can use a Double pole, double throw (DPDT) switches USB Role USB_ID (Pin 3) FAULT (Pin 19) USB_VBUS (Pin 20) Host GND Floating Floating Client Floating GND Host 5V GND Fault USB_ID USB-A Power Line USB_VBUS Source 5V Client Host
  • 16. Intel Edison Linux Distributions 1. 1.6 (Default) • Based on “Poky” Linux distribution • Compile Poky Linux sources/packages using provided toolchain and recipes • Limited “opkg” package manager and few default packages • (eg, no nano, only vi) • Can add third party “meta-openembedded” recipes during compile time 2. • Produced by Emutex Labs • Based on Debian 7 Wheezy (2013) • More packages compared to Yocto using (apt-get) • Packages outdated compared to Debian 8 Jessie (2015) 3. Compile your own: Yocto or Debian Jessie • All use old kernel version 3.10.17 (Oct 2013) 16
  • 17. Poor default support for USB-Ethernet and USB-Serial adapters • Only supports adapters based on these chipsets • Ethernet: ASIX AX88xxx USB 2.0 to Gigabit adapter • Serial: Prolific PL2303 USB-Serial adapter • More support requires kernel recompilation 17
  • 18. Small rootfs partition size 18 • 1.4GB, 541MB available on initial boot, may be too small for some uses • Modifying rootfs partition size requires recompilation
  • 19. My compilation script • Compiles in all available USB-Ethernet/Serial drivers, custom rootfs size • Downloads sources, modifies compile options then compile • https://github.com/algoaccess/edison_mod_kernel_image_gen 19
  • 20. Lengthy compilation time • 4-6 hours typical • Use the cloud -> Google Compute Engine or AWS (About half hour on 32 threads) • export SETUP_ARGS="--parallel_make=32 --bb_number_thread=32" • IMPORTANT: Remember to SHUT DOWN your instance once finished, if not hefty charges will be incurred!!! 20
  • 21. File System safety for embedded systems • Improper shutdown of systems can corrupt file systems • Cause: System off while data is being written 1. Read-only file system • No writes to file-system allowed, no chance of system corruption 2. Enable full-journaling • File-system journals store a list of changes to be made • Ext4 default is to journal meta-data only, not the data itself • We should also journal the data for additional protection 21
  • 22. Read-only file system (preferred) • ----------------/etc/fstab------------------------ rootfs / auto ro 1 1 /dev/disk/by-partlabel/boot /boot auto ro 1 1 /dev/disk/by-partlabel/home /home auto ro 0 2 tmpfs /var/tmp tmpfs nodev,nosuid 0 0 tmpfs /var/log tmpfs nodev,nosuid 0 0 • ------------------------------------------------------ • tmpfs: RAM drive • nodev,nosuid: Security precautions for world-writeable file-systems 22https://gist.github.com/yeokm1/00bf00fbcda99cc33c2b
  • 23. Mount file system to journal everything • Set journal option to / partition • tune2fs -o journal_data /dev/mmcblk0p8 • Set journal option to /home partition • tune2fs -o journal_data /dev/mmcblk0p10 • ----------------/etc/fstab------------------------ • rootfs / ext4 data=journal,sync,noatime 1 1 • /dev/disk/by-partlabel/boot /boot auto ro 1 1 • /dev/disk/by-partlabel/home /home ext4 data=journal,sync,noatime 0 2 • ------------------------------------------------------ • data=journal: Journal everything. Data will be written twice, first in to journal, second into disk • sync: Commit changes to disk immediately, do not cache. Performance loss • noatime: Do not store last access time to increase disk performance to avoid updating access time in every sync 23