A talk I gave at Hackware v1.9 about my experience in using an Intel Edison in my company's product.
The video of my talk can be found here: https://engineers.sg/v/828
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
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