Getting started with the Intel Edison

With the Sparkfun breakout blocks the Intel Edison becomes a compact, powerful, mechanically robust target board for robotics

Parts list:

Ubilinux has been a popular distribution for the Edison in the past. As of June 2016, Emutex no longer supports Ubilinux on Edison.

Yocto is the distribution that Intel recommends

Installing Yocto:

Plug both cables into the base block

Update the firmware, create a password, and connect to WiFi as described here: https://software.intel.com/en-us/get-started-edison-windows-step2

Connect to the Edison using TeraTerm, putty, or GNU screen

Although branded as a system to compile custom OS images for your target board, Yocto also includes a conventional, apt-like package manager. No repositories are included by default, so you’ll need to add them like so:

echo "src/gz all http://repo.opkg.net/edison/repo/all"           >> /etc/opkg/base-feeds.conf
echo "src/gz edison http://repo.opkg.net/edison/repo/edison"     >> /etc/opkg/base-feeds.conf 
echo "src/gz core2-32 http://repo.opkg.net/edison/repo/core2-32" >> /etc/opkg/base-feeds.conf
opkg update

A full list of packages available through opkg can be found here

Installing Packages - numpy, pyplot, smbus and scipy:

We’ll need the smbus package to communicate with the LSM9DS0. Git and screen will be convenient.

opkg install git screen python-smbus

Scipy can be installed from pip. You’ll see some error messages about not having support for HTTPS, but that’s okay.

pip install --upgrade pip
pip install numpy scipy matplotlib

Plotting Acceleration:

You’ll need to find python drivers for the LSM9DS0. As of October 2016, you can find a driver here.

I’ve uploaded a python script to read and plot data from the IMU at this gist

Git SSH Permissions

Your keys might be generated and shared correctly, but git wants to enforce good security practice by demanding that your private key not be writable by other users on your system.

fkoran@host~/$ git push
...
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@         WARNING: UNPROTECTED PRIVATE KEY FILE!          @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Permissions 0770 for '/home/fkoran/.ssh/id_rsa' are too open.
It is required that your private key files are NOT accessible by others.
This private key will be ignored.
Load key "/home/fkoran/.ssh/id_rsa": bad permissions
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
fkoran@host:~/$ ls -l ~/.ssh/id_rsa
-rwxrwx--- 1 fkoran fkoran 3326 Jan  6  2016 /home/fkoran/.ssh/id_rsa

To fix this, use chmod to remove write permissions for users in the “group” and “other” categories.

fkoran@host:~/$ chmod go-w ~/.ssh/id_rsa
fkoran@host:~/$ ls -l ~/.ssh/id_rsa
-rwxr-x--- 1 fkoran fkoran 3326 Jan  6  2016 /home/fkoran/.ssh/id_rsa

More detailed information can be found here

Ergodox Build

Parts | Case | Assembly | Troubleshooting | 3D Printing

Parts List

I purchased parts on DigiKey per the ergodox.org list, which I’ll reproduce here since that site is currently offline

If I were building this again I would substitute surface mount parts in place of the through hole diodes. They’re easier to solder and trim and will result in a cleaner final product with wider mechanical clearances. Be aware that the mini-USB B connecter often goes out of stock.

I chose to use Gateron Brown switches. They seem widely regarded as a better quality clone of the gold standard Cherry MX brand and have a light, tactile throw without being clicky.

Note that a standard, stereo audio cable isn’t enough to connect the two sides. You need a four conductor TRRS cable (the extra aRRRR is for tip-ring-ring-sleeve) to carry GND, +5, and I²C SDA/SCL.

There are a couple standard keycap profiles. DSA is convenient because keys are interchangable between rows. This was especially desirable because I planned to use the Colemak layout, for which profiled keycaps would be hard to find

Case

I pulled what appear to be Litster’s original .DXF files from bishboria’s github and exported them to SVG using Inkscape.

I had the files laser cut from acrylic at Ponoko. I made a mistake scaling one of the spacer layers in the process of tiling the SVGs onto a single panel, so I had to substitute a set of washers until I was able to print a replacement.

The SVGs are up on my github.

These are the layer thicknesses I used. The Gateron switches fit perfectly with 4.5mm acrylic on layer 3. Be sure if you’re using THT diodes that layer 4 is a bit thicker than 4.5mm.

  • Top - 3mm
  • Spacer - 4.5mm
  • Switch plate - 4.5mm
  • Spacer - 4.5mm
  • Bottom - 3mm

Assembly Instructions

I used the Massdrop assembly instructions as a reference. If this is your first soldering project it’s worth flipping through the Soldering is Easy (8 page pdf)

Tools

For THT diodes

Bend each diode into a U shape and populate the marked spaces below each of the keyswitch sockets

Confirm that each diode is oriented so that the cathode, marked with a black ring, is closer to the square solder pad

Clip the leads with a pair of flush cut trimmers and press the diode bodies flat against the PCB

For SMT diodes

Solder a diode below each of the keyswitch sockets. Confirm that each diode is oriented so that the cathode, marked with a white line, is closer to the square solder pad

https://learn.sparkfun.com/tutorials/polarity/diode-and-led-polarity

Resistors

The resistors are color coded. (relevant xkcd)

TRRS Connector (3.5mm audio jack)

Populate the jumpers as shown. These are needed to reuse the same PCB for left and right hands

IO Expander

Populate the IO expander DIP as shown

Teensy

Cut and strip the spare USB mini-B cable to bridge from the PCB to the Teensy

Plug the 12 pin inline headers into the right hand PCB and stack the Teesny 2.0 on top of them. Tack down two pins on opposing corners to hold the assembly in place before soldering the rest

Keyswitches

Plug the keyswitches into the layer 3 support plate. Place the support plate switch-side down on a table and align the PCB with the switch pins. Solder the switches down while the support plate is sandwiched between the keyswitches and the PCB.

Troubleshooting

The left side of the keyboard worked perfectly on the first try. As soon as I plugged in the right side my laptop started opening the Win+X menu.

I rebuilt the firmware to generate a ‘z’ from what had been the windows key and got a spray of “bzzxcvbzzxcvbzzxcvbzzxcvbzzxcvbzzxcvb”

After a quick visual inspection to verify that the diodes were all oriented correctly, I brought up the board file

When the firmware performs a scan it pulls each column low in turn. While a given column is low it checks each row to see if a closed switch is connecting the two. Komar has a good overview of this on his site. All the affected keys were on the ROW2 net.

Since each row net surfaces only at the IO expander and at the switches of that row, I had only to check for shorts at those points. The culprit was a solder bridge between a switch and an adjacent mounting hole.

3D Printing

I was able to get an extra layer printed in PLA at PSU’s LID Lab. I used Landa’s svg2stl to rasterize and extrude the flat SVG to an STL file. To reduce print time I removed the ceiling and floor, exposing an attractive honeycomb fill pattern.

Inkscape - How to display path direction

By default, Inkscape doesn’t show tick marks to indicate the direction of a path. There’s an option to turn those on.

This is useful when using the node tool to set path direction in preperation to set fill-rule: even-odd or nonzero.

Animated walkthrough to the right, click to enlarge.