Build Your Own Hacklebox

IMG_0911In the last two years I supported something like 50-60 hackathons and developer workshops. Many of these were hardware focused.

It became abundantly clear that students can’t do much with just a device – they need soldering irons, pin wire, breadboards, tape, scissors and all manner of other supplies in order to actually build something. These items are not always present at many events.

Thus the idea of a rolling hacklebox was born.

IMG_0888

We (Intel Mashery DEVO, at the time) gathered some feedback, observed the common types of projects that get built and distilled it into this Google spreadsheet. Feel free to use this to build your own rolling hackathon solution for hardware events.

I broke out all the costs, suggested counts of devices and embedded order links from Amazon to make it easy to stock up. The Keter Master Pro (pictured) happens to be quite nice as a rolling chest for these events. It doesn’t survive airplanes very well.

I tried to pick supplies that are on the cheap side.

IMG_0909

Sensors and Sensor Kits

A good approach is to pick a sensor format such as Seeed Studio Grove (a simple format for pluggable sensors) and lend people Grove shields. You can then provide a wide library of sensors for checkout during the event if people want them. These sensors are generally too expensive to give away, so I suggest appointing a sensor librarian to track and recover everything.

Sensors tend to be useful between hackathons, other components like pin wire and LEDs are going to get chewed up and you aren’t going to want them back. Some venues will complain about smoke from soldering and not allow it.

Hardware Platforms

This is too broad a topic to cover in great detail, there are new boards coming out daily.

The Arduino 101 ($30) is pretty sweet, not just saying the because I work on it at Intel MIG. I like that it has BLE and Gyro / Accelerometer by default. This particular combination of basic functionality combined with Arduino Uno compatibility will be compelling for many students.

Anything that requires WiFi is going to have problems at most public events. There are often barriers to overcome (navigating HTML redirects, authentication, isolation mode etc).

Raspberry Pi and other HDMI-capable devices – People are going to want keyboards, mice, monitors – that is hard to support at an event with many people unless you just run in headless mode.

The LightBlue Bean+ is likely a great platform for hackathons and workshops. Most devices from Particle.io should be pretty good. RedBearLab and mBientLab have devices which are promising as well.

The more common requests (with some examples) from students:

  • Flex sensors  (1) (2) -> Good for building glove projects, darn expensive to give to people
  • Light sensors  (1) (2) -> Can be used as a primitive motion sensor also
  • Proximity sensors (1) -> Detect presence of objects
  • PIR / Motion Sensors (1) -> Lots of requests for these to use in home security projects
  • Potentiometers (i.e. knobs) (1) -> General control of some analog actuator
  • Buttons  (1) (2) -> A must, lots and lots of uses
  • Lots of LEDs, multi-color as well as single color (1)
  • Battery power packs, LiPos, 9v batteries (or USB battery sticks) -> A must for wearables, USB battery sticks are wonderful for hackathons
  • 9v Barrel Jack Connectors for 9v batteries (1)
  • Alcohol sensors (1) -> College students go nuts with these things with projects
  • Accelerometer / gyros (1) -> Endless requests for these, very popular
  • Hall sensors (magnetic) (1) -> Detect a gate opening and closing, or maybe if a key or object is picked up
  • Crash Sensor (1) -> Car or skateboard, snowboard crashes, good for wearables
  • LED strips are very popular, especially the NeoPixel
  • There are other fun sensors out there such as UV,  moisture / humidity, flame, dust, gravity and gas
  • Servo motors (1) -> People build really simple things like a box that opens and closes to hide a key to prevent a drunk driver kind of thing
  • Brushless DC motors aka stepper motors (1) -> Robots, things which require stopping the motor at a specific angle
  • Motor driver shields (1) -> Rovers and other similar robots, need wheels though

Where to get kits

Here is the spreadsheet with all the buy links and costs: Check out the open source hacklebox manifest.

Thanks to Martin Kronberg, Steven Xing, Wai Lun Poon, Cheston Contaoi, Dan Holmlund, Monica Houston for providing feedback and suggestions to this list.

Use WinSCP to copy files to Intel Edison

sessionscp

Being able to use the IDE of your choice to develop for Intel Edison is very freeing. I wanted to share a Windows pro-tip about how to use a simple drag and drop action over the local network to deploy code to your Intel Edison using the SCP protocol.

Setup:

  • In WinSCP click the “New Site” icon on the upper left
  • Select “SCP” using the File protocol drop down
  • Enter in your Intel Edison’s IP address into the Host name area
  • Leave Port as 22
  • Enter in your username and password you set for your Edison (user may be root)
  • Click “Save.” There is an option to save your password you can select if you like.
  • Click “Login”

From now on, you can drag files to your Edison (they will appear in the /home/root directory which is where your PuTTy sessions will take you by default). You can double click on files to edit them directly on the device using your editor of choice!

scpexp

Fixing “Does not appear to be a valid volume name for its file system”

If you are trying to use the terminal in OS X to reformat a volume and you are getting “error: does not appear to be a valid volume name for its file system” – You need to capitalize the name of every letter in the name you are trying to specify like this:

diskutil partitionDisk /dev/disk2 1 MBRFormat "MS-DOS FAT32" EDISON 805.30M

Introducing Bloop: CLI commands for working with Intel Edison

Having helped hundreds of people learn to use Intel Edison, I wanted to use my learning to help make everyone’s life easier . I also wanted to streamline the build / deploy process as well as the process of locating Edison on the local network (via Bonjour) or connecting to Edison via Micro-USB serial terminal.

So I created Bloop.

Here are the features and benefits to you, an Edison developer (using a Mac only, at this time):

  • bloop c: Never have to type in “screen /dev/cu.usbserial-XXXXX 115200 -L” ever again, simply type “bloop c” to do this automatically.
  • bloop list: Print out all Edison devices attached via USB Serial / Micro-USB
    • ex: /dev/cu.usbserial-XXXXX
  • bloop scan: Never have to use Bonjour Browser to detect Edison on the local network, simply type “bloop scan.” Add -r to show the raw output of the scan (otherwise, bloop scan simply returns the name of the first Edison it locates on the network).
  • bloop ssh: Instantly initiate an ssh attempt with an Edison on your local network. Add -e to select a specific Edison by name (useful with many Edisons on the local network) or -u to specify a user other than “root.”
  • bloop push: Instantly generate a command to copy your working directory to Edison’s /node_app_slot/ folder via scp. Like ssh, you can add -e or -u.
  • bloop clean: There is a problem with “Screen” which frequently results in detached screen processes resulting in confusing “Could not find a PTY” errors and “Resource busy.” Bloop clean instantly purges all those sessions and allows developers to connect again via bloop c. If you run “bloop c -f” these sessions will be purged automatically before attempting to initiate a new session.

I am very excited about bloop because I feel it will significantly ease the process for new developers (and all developers) to use Intel Edison. The ‘bloop push’ command, especially, allows you to use Sublime Text or your Node development environment of choice. Enjoy and file any bugs you find. Would like to create an equivalent Windows library at some point.

Install it globally by executing:

$ sudo npm install -g bloop

Let’s Call REST APIs with AlamoFire, iOS 8 and Swift

Screen Shot 2014-10-26 at 2.22.38 PM

About Rex St John

I am a mobile software engineer and technical evangelist working for Intel’s Mashery subsidiary. Aside from attending dozens of hackathons, workshops and technical events, it is my job to help developers learn about and engage with REST APIs.

iOS 8 Networking With AlamoFire and Swift

In this article, we will be exploring the basics of REST APIs, learning how to create our first iOS 8 networking application using the AlamoFire library (and using the Swift programming language with Xcode 6). I have written this article to help beginners learn how to interact with REST APIs and learn the basics of iOS 8 development. The GitHub repo for this article is freely available by clicking here.

What are we building?

We are going to be building a basic app to make REST API calls to the JamBase API and display the results in a UISplitViewController. This particular chapter will be primarily concerned with building a very basic networking layer using AlamoFire.
[Read more…]

Setting up Intel Edison (with Intel XDK)

inteliot

Intel Edison is a tiny computer for building compelling #inteliot hardware hacks. This is a quick intro on how to pair Edison with Intel XDK over a local network.

Getting Started Tips:

  • You will need Intel Edison + some kind of mounting board which allows you to SSH into the device / serial into the device to configure Wi-Fi capability
  • This will not work on many public networks (where Wi-Fi “Isolation Mode” is enabled). If isolation mode is turned on, you will not be able to use Bonjour Browser to detect the Edison once it is on the local network and you will not be able to pair it with XDK or SSH into it!
  • Download the Bonjour Browser, a utility for detecting Edison on the local network
  • Download and install Bloop, a tool I have written to automate many common command-line tasks with Edison

Setting Up XDK

Download Intel XDK IoT Edition. Once you install, register for an account and sign into XDK, you should see the following option available under the “New Projects” templates. Click the template to get started with a new Intel XDK project for IoT applications with Intel Edison.

Unknown

Getting Edison on Wi-Fi

The instructions for getting Intel Edison on Wi-Fi are here. If you are on OSX, skip to these directions.

Pairing XDK with Edison

Assuming you have gotten Edison online we can now proceed to deploy code to XDK.

If you haven’t done so already, download the Bojour Browser, a utility for detecting other devices on your local network.

In your XDK project,  click the drop down and see if there is an “Edison” option listed. If not, open the Bojour Browser and find the IP address and port of your Edison. Then select input “Add Manual Connection” and input the Edison IP Address and Port information from the  Bonjour Browser (see below)

IOT Template

Dealing with Intel XDK Whitelist Warning

new

If you are getting the “Authorization Required(401)” warning from Intel XDK, you will need to perform the following steps:

  • Click the blue underlined text in the below dialog to reveal your current IP address (as below)
  • Open Terminal and type in “screen /dev/cu.usbserial” (Tab) to complete then add “115200 -L”
  • Once you have logged into your Edion via the Terminal, run the command:
    • xdi-whitelist –add 192.168.1.3” (that is two “-” symbols in front of “add”, not one)  (replace the IP address with the one you get from the below dialog)
    • Once you submit, you should get a message “192.168.1.3 added to whitelist!”
  • You should now be able to run Node.js via Intel XDK IoT Edition by clicking the “Hammer” icon

Troubleshooting: If you are getting errors, check this guide.

#inteliot #makesoftware

Intel Galileo Gen 2 Mashery + Twilio Samples

Provided you have followed the instructions here to set up your Gen 2 Galileo with Node.js and XDK…

Download and unzip the following samples into a directory and, under the “Develop” tab, select “Open An Intel XDK Project” and import the below directory.

Screen Shot 2014-09-05 at 4.17.17 PM

Download Samples: Mashery Galileo XDK Samples

Next, assuming you have connected an Intel Galileo Gen 2 board and paired it with your XDK instance, you should be able to deploy the code to the board and then run it.

Each sample can be run by navigating to the directory containing your Node.js projects and going “node sampleXXX.js”

Quit Your Programming Job Using AirPair In 3 Easy Steps

Shawshank

Unless you are among the lucky few who work for progressive companies like WordPress, you may have a programming job which requires you to be in your office 5 days a week and sit in hours of traffic both ways.

This guide will show you how to earn industry standard contracting rates  working remote from anywhere using AirPair.

The perks are numerous:

  • Get paid to help cool people work on interesting problems
  • Work from anywhere, even France
  • Get paid competitive industry contracting rates
  • Never worry about finding clients

[Read more…]