Recent Changes - Search:
ECG Home






Fall 2017

Older Courses

Spring 2017

Fall 2016

Spring 2016

Fall 2015

Spring 2015

Fall 2014

Spring 2014

Fall 2013

Spring 2013

Fall 2012

Spring 2012

Fall 2011

Spring 2011

Fall 2010

Spring 2010

Fall 2009

Spring 2009

Fall 2008

Spring 2008

Fall 2007


edit SideBar


Pictures are coming! Please stand by.

The IchiBoard.

Driver Download

MacOS X, Windows Vista, Windows 7, and most linux distributions come with the driver already loaded. If your system does not have the driver, download the file appropriate for your system from the FTDI VCP driver page.

If you are having driver trouble in Windows, try using the FTClean utility to clean out the drivers.

Launch Sequence (How to Start up Scratch Using the IchiBoard)

Please follow these steps every time you start Scratch with the IchiBoard.

  1. Plug in the IchiBoard
  2. Start Scratch
  3. Don't unplug the IchiBoard while Scratch is running. It won't be able to see the board again unless you restart from Step 1!
  4. If something's weird, try the Debugging Instructions


Scratch has 8 channels of information it reads from the IchiBoard. They are the button, slider, microphone, light sensor, and plug-in channels A, B, C, and D. The first four of these are built onto the board and never change. The four plug-in channels allow a variety of different sensors to be attached, extending the capabilities of the board. On the IchiBoard, the four plug-in ports are also used for the built-in accelerometer and digital inputs. Scratch can only look at one sensor at a time on any channel, so the an accelerometer axis or digital input cannot be used at the same time as a plug-in sensor that uses the same channel. This multiplexing allows the IchiBoard to be used without any modification or addition to the Scratch software.

The IchiBoard is a close cousin to the PicoBoard, the original sensor interface for Scratch. The IchiBoard includes all of the features of the PicoBoard, plus a whole lot more.

This page focuses on what you can do with the advanced features of the IchiBoard. For an introduction to the standard features, read through Getting Started With PicoBoards

Changing Channels

All of the plug-in ports (A, B, C, D) have three different modes, and can only be in one of these modes at a time. The modes for each port can be selected independently. The three modes are Passive, Powered, and Special. Regardless of mode, the data being read by a channel will be visible in Scratch as resistance-A, resistance-B, resistance-C, or resistance-D. Only one mode, and therefore only one data source, can be selected at a time.

Passive Mode

The passive plugs are the connectors at the very bottom of the IchiBoard. They use mini jack plugs, also known as mono mini headphone plugs. These ports can read any passive resistive sensor; meaning anything does does not require power and changes resistance. Common sensors are potentiometers (knobs and sliders) and buttons.

To activate passive mode for a particular channel, set that channel's DIP switch to off/down and plug a jack into the corresponding passive port.

Powered Mode

The powered plugs use 3-pin Hirose DF3 connectors, the same that are used on the HandyBoard Cricket and related devices. These plugs are located just above the passive ports. The powered ports can support advanced sensors that require power, as well as any sensors that can be used on the passive ports. The most common powered sensors are distance sensors, which require power to emit and measure an infrared pulse.

To activate powered mode for a particular channel, set that channel's DIP switch to off/down and ensure there is nothing plugged into the corresponding passive port.

Special Mode

Each of the four ports (A, B, C, D) have a different special mode. Channels A, B, and C are all connected to the on-board accelerometer chip to sense motion. Channel D is an extra set of digital inputs, which can only be used with on/off switches.

Accel XAccel YAccel ZDigital Inputs

To activate special mode for a particular channel, set that channel's DIP switch to on/up.

Digital Inputs

Scratch must be set to Raw Data Mode to use this feature.

The digital inputs are the special mode of Channel D. When active, the IchiBoard will encode the 4 digital states into an integer using base-2. This integer is reported as Channel D in Scratch. Once in Scratch, we need to decode it back to individual binary values.

Setting up the physical buttons

To be detected, the button must connect an input pin to the ground pin. All buttons can share the same ground connection. When the button is pressed, ground should be shorted to the input pin, and the IchiBoard will detect that. You can use one, two, three, or four switches. Here's a diagram of how to hook them up.

Hooking up switches to D

Using Scratch to Decode the signal

Here is what you need to do, in plain text notation. rD is the Resistance-D value. We use the "mod" operator and an "if/else" control structure. When a switch is "true" it means that a ground connection is detected on that pin.

  • if rD % 2 = 1 then D1 is true
  • if rD % 4 > 1 then D2 is true
  • if rD % 8 > 3 then D2 is true
  • if rD > 7 then D4 is true

In scratch, the code can look something like this:

Using Raw Data Mode

Scratch normally formats all the sensor data it receives to the range of 0-100. This range is actually not the full resolution of the sensors. The raw data is of the range 0-1023. Unless you tell it not to, Scratch will transform the data to the smaller range, sacrificing resolution.

Sometimes you want all that extra resolution. To change to Raw Mode, follow these steps:

  • Ctrl-click (or right-click) on a sensor in the panel, and select show ScratchBoard watcher
  • Shift-click on the ScratchBoard watcher and select report raw data
  • Your entire project will now use 0-1023 as the analog data range.

This will cause scaling calculations to break. Any operations that depend on the old range will have to be adjusted to work with the new range. Every time you start scratch you have to repeat this process.

Tools & Demo Software

Graphical Readout Tool

This Scratch program provides a real-time graphical display of all the input board channels. This is useful for exploring the board's capabilities as well as debugging.

Graphical Readout Tool

Test Procedure Video

This video shows how to test the Ichi Board using the above program. It's also available as a H.264 MOV download (80 MB).

Test Procedure Video

Analog Channel Averager Sprite

This is not an entire Scratch program, but a single sprite you can import into Scratch. Create a new sprite by clicking the "Choose new sprite from file" button, and select this file.

This sprite provides a tool for smoothing out the data of an analog channel. Many analog sensors (like the accelerometer) are prone to giving data that is shaky. Smoothing is used to make the data nicer for certain applications. This sprite uses a floating average to perform smoothing. You can adjust how much data it uses for the average, allowing you to control how much smoothing is applied.

When this sprite is imported into Scratch it appears as a small grey triangle. You can change the appearance however you please as it has no bearing on the operation of the sprite. The sprite's script reads from an analog sensor port, does the averaging, and stores the result in a public variable that can be used by any other sprite. This variable always has the current floating average of the analog port. When the sprite is imported, the variable "average" will automatically be created. If more than one copy of this sprite is used, you will need to create additional output variables for the additional copies to use. There are comments in the sprite to help you do this.

The Analog Visualizer below uses this sprite.

Averager Sprite

Analog Visualizer with Smoothing

This Scratch program plots one analog channel over time, and is great for learning about how a certain sensor works. This program also uses the Averager sprite to plot the floating average of the analog channel.

Analog Visualizer

IchiBoard designed and supported by Mark Sherman at the UMass Lowell Engaging Computing Lab, part of the Computer Science Department.

Edit - History - Print - Recent Changes - Search
Page last modified on July 04, 2012, at 03:03 PM