Monday, October 14, 2013

TSS Tiny Stamp Supercomputer

Tiny Stamp "Supercomputer" TSS
The World's 1st Hand-Held BASIC Stamp "Supercomputer"


by Humanoido

This is the TSS Tiny Stamp Supercomputer that appeared in Robot Magazine.

In the January/Feb. 2011 issue of Robot magazine, page 16 in the LERN section you saw the BASIC Stamp Supercomputer. This is actually the new portable project TSS - Tiny Stamp Supercomputer that uses seven cores and a BELKIN USB HUB. In the same issue of Robot magazine, you can see two more articles about robot humanoids in China.

(demonstration of basic principles to take some characteristics of a supercomputer, in particular the notion of larger multiples of relatively simple processors communicating over a common bus, each doing a portion of a task in parallel)

The BASIC Stamp Clustered Supercomputer series is a number of hobby projects to design BASIC Stamp microcontroller clusters with more power compared to a single Stamp. The name supercomputer is indicative of the increase in power by comparing to a single stamp.

Absolutely the most powerful in terms of the smallest footprint with many tiny Stamp networked processors. It’s a cluster of Stamps in your hand. Has its own book with 30 fun projects. Includes Architecture, Assembly, Programming, Tutorial, Applications, Complete Code. The TSS has multiple computers, LCD monitor, radio transmitter, receiver, speakers, breadboard real estate and a 64K EEPROM memory board, all interfaced to a tiny Hub. The TSS Stamp supercomputer is so small it will fit into a soup bowl or coat pocket. Includes special features such as hardware programming "on the fly."

The Tiny Stamp Supercomputer (TSS) is the first hand-held Basic Stamp Supercomputer. It’s the smallest in the series of Parallax Basic Stamp supercomputer projects by Humanoido. It is also the first USB Stamp supercomputer, made possible by the innovative BS1USB board made by Parallax. This project compliments the Basic Stamp Supercomputer (BSS), the Stamp Baby Supercomputer (SBS/Baby), and the Propeller (MELS) supercomputer.

Price & Disclaimer
This is a pure hobby project for my personal enjoyment and use only, and is not for sale. If the project does not satisfy your requirements, keep in mind that it was not intended to do so. This is not a product, and the descriptions are offered as is, in whatever degree or lack of degree of completeness for your inspiration and ideas. Good luck!

ABOVE: This is a view of the new “hand-held” Tiny USB Stamp Supercomputer TSS during construction. Seven computers, LCD monitor, radio transmitter, receiver and a 64K EEPROM memory board are interfaced to a Belkin USB Hub. The Stamp supercomputer is so small, it will fit into a soup bowl or Parka coat pocket. The yellow wires are for the port-to-port one wire interface. The black wires are adjoining Vss and red wires are Vdd. White represents a serial signal wire. By comparison, the American penny shows the extreme tiny features of the TSS Tiny Stamp Supercomputer! 

Tiny includes an optional serial “green screen” by Parallax, pulling a whopping 20ma, the most power hungry device in this ultra tiny array. This is actually a miniscule power draw. In fact, the supercomputer consumes so little power, it would be a good candidate for solar power. Note the position of two computers located in the front behind the LCD. The remainder computer array is located to the rear of the USB hub.

How to Build Tiny - Building Up the USB Hub First build up the USB Hub by attaching three small solderless breadboards using their self adhesive sticky tape on the back side. Locate the breadboards according to the photo. Each breadboard side has 17 rows of 5 pins for 85 holes to a side, giving a total of 170 holes perboard. This makes a total of 510 wire and component mounting positions with all three breadboards. The hub has eight lights (one red power light and seven green LEDs indicating connected USB devices). The USB Basic Stamps have seven green LED lights indicating power on status. Tiny has a total of fifteen status lights.

Tiny is a powerful array of seven BS1USB computers connected to a Belkin HI-Speed USB 2.0 powered 7-port Hub. The 7-port Belkin Hub’s advantage is its ability to provide considerable power to the USB devices (Stamps) simultaneously, and peripherals, not drawing from the laptop’s limited power source. Each tiny Stamp PCB contains vital components (processor, clock source, memory, power regulator).
Tiny packs a punch in a small package and is loaded with features and peripherals. Let’s take the grand tour!

Affixed to the high speed USB hub are seven Parallax BS1USB computers, seven piezo speakers, a Parallax 433 Mhz radio transmitter, a matching receiver, Parallax serial LCD green screen monitor, eight pushbutton keypad, DS1620 Digital Thermometer, Parallax EEPROM non-volatile memory board, and a Parallax QT113-D Touch Sensor. Tiny can access other Stamp Supercomputers located within a full city block, communicate with a Base Station, and cluster together entire Stamp supercomputers located around the city!

The Tiny Stamp Supercomputer blueprints show schematics for the base unit. This contains seven clusters of BS1USB computers interfaced to a powered USB hub for programming. After all seven computers are programmed, the USB cable from the Hub to the Laptop is removed. The wall power supply to the hub remains on. Compare the new Tiny Stamp Supercomputer blueprints (seven computers) with the networked 3D Stamp Computer (three computers).

Historically, the 3DSC is the forerunner of Tiny, and the first 3DSC Stamp clustered array to incorporate the BS1. The BS1 is filled with advantages, in terms of tiny power consumed, tiny footprint, large number of ports, and large capabilities for more powerful hobby BASIC Stamp clustered machines.

Wiring & Assembly Step by Step
Wiring is accomplished from port to component and component to port using the computer’s on board SIP socket and small gauge wire, plus the three small Parallax solderless breadboards attached to the Belkin Hub housing. This will support numerous additional supercomputer components and sensors.

( ) Plug in seven BS1USB computers to the Belkin 7-port hub
( ) Run a wire from P0 Computer 1 to P0 on Computer 2. Repeat to Computer 7.
( ) Connect all grounds together with jumper wires (Vss)
( ) Connect all +5 volts together (Vdd)
( ) Consult the schematic to wire the peripherals

Tiny Stamp Supercomputer Parts List
Parts for the Main Supercomputer
7 - Parallax BS1USB Board
1 – Belkin Powered High Speed USB 2.0 Hub
3 – Parallax Solderless Breadboards
4 – Rubber Bands
30 – Pin to Pin Jumper Wires
Peripherals Used in this Project, from Parallax
7 – Five Volt Piezo Speakers
1 – Green Screen Serial LCD
1 – 433 Mhz Radio Transmitter
1 – 433 Mhz Radio Receiver
1 – 64K EEPROM Memory Board
Parts for Project Applications
1 – Low Power Parallel LCD
1 – Temperature Chip DS
1 – Capacitor .1uf
1 – Touch Sensor QT113
1 – 470 Ohm Resistor
1 – LED
10 – Toggle Switches
10 – 1K Ohm Resistor
7 – 220 Ohm Resistor

APP 22
CaS Cell
Capacitor .1uf

Wiring “On the Fly”
A unique feature of TSS is that it can be wired and rewired as you are moving from one location to another. It’s a portable wiring feature that enables much more function due to simple access of its circuits.

Test Software for Each Computer
The test program loads into each of the USB stamps. When running the clustered code, after each stamp is programmed, the USB cable can be disconnected and the hub is removed from the laptop. All computers will remain powered on and functional.

' {$STAMP BS1}
' {$PBASIC 1.0}
DEBUG "hello world"

Test Software for the Cluster Interface
Test software for networking the cluster is seen below. This code includes timing routines. Each computer sleeps a designated time period and wakes to perform a task.

Loading in Code to Seven Computers
When loading a program, the menu appears to select any one of the seven Basic Stamps. Simply click on the desired computer, 1 through 7, and the code will load. This process is the most simple of all the Stamp/Propeller supercomputers.

Use this as a wiring guide to each pin. Note the actual configuration for each computer mounted on the USB Hub is inverted from this photo.

Loading code into each computer is a very simple process. Wait for this window to appear and select the stamp to receive the code.

The BS1USB is tiny, measuring only 2.26-inches long, .73-inch wide and .3-inch thick. Right: the back side of each board has a legible pin code printed in white.


  • 7 Computers (BS1USB)
  • Fifty-Six Ports (configurable as inputs or outputs)
  • Each Computer 2.26-inches Length x .73-inch Width x .3-inch Thickness
  • Overall Stock Supercomputer 4 ¾ wide x 4 ¾ deep x 2 ½ height
  • Each I/O pin sources 20ma and sinks 25ma
  • All I/O pins on one computer can source 40ma and sink 50ma
  • Each Computer has an on-board USB interface
  • Two Vss, Two Vdd and eight pin I/O connectors
  • 7-Port Belkin High Speed Powered USB 2.0 Hub
  • Memory: 64K Serial EEPROM Memory Board
  • Two Thousand Four Hundred Bits Per Second Transfer Rate
Single Processor Specifications

  • Microcontroller PIC16C56a
  • Processor Speed: 4 MHz
  • Program Execution Speed: ~2,000 PBASIC instructions/sec.
  • RAM Size: 16 Bytes (2 I/0, 14 Variable)
  • EEPROM (Program) Size: 256 Bytes; ~80 PBASIC instructions
  • Current Draw @ 5 VDC: 1mA Run, 25 μA Sleep
  • Number of I/O Pins: 8
  • Source/Sink Current per I/O: 20 mA / 25 mA
  • Source/Sink Current per unit: 40 mA / 50 mA
  • PBASIC Commands: 32
  • PBASIC Language: v1.0
  • Scratchpad RAM: n/a
  • PC Interface: USB
  • Windows Text Editor Version: Stampw.exe (v2.0 and above)
  • Breadboard Area: 1 3/8 x 2" solderless breadboard or through-hole mounting pads
Seven Processor Specifications

  • Seven Cores
  • Core Speed 28Mhz
  • Program Execution Speed: ~14,000 PBASIC instructions/sec.
  • RAM Size: 112 Bytes (14 I/0, 98 Variable)
  • EEPROM (Program) Size: 1,792 Bytes; ~560 PBASIC instructions
  • Current Draw @ 5 VDC: 7mA Run, 175 μA Sleep
  • Number of I/O Pins: 56
  • Techniques for 448 inputs, or 112 I/Os
  • Source/Sink Current per I/O: 20 mA / 25 mA
  • Source/Sink Current per unit: 40 mA / 50 mA
  • Source/Sink Current per supercomputer I/O: 280 mA / 450 mA
  • Breadboard Area: about 14 by 20”
Comparative Speed to the Cray 1 Supercomputer
Don’t expect too much speed compared to the worlds fastest supercomputers today or even desktop computers! This is a small hobby supercomputer and is super in terms of comparison to one Stamp in the same genre.

If you want to convert the actual speed to OPS, operations per second, a chart will illustrate the example. The SBS runs at about 20,000 IPS (instructions per second). FLOPS is floating point operations per second. Grossly approximating IPS to FLOPS, the SBS is about 20 kiloFLOPs or one fifth of a megaFLOP (MIP). By comparison, the Cray 1 supercomputer was in the MIPs range (millions of instructions per second). So one could roughly say the SBS is only approaching the speed of the Cray supercomputer.

Expansion Peripherals
The Tiny Stamp Supercomputer can be expanded with these low power peripherals:

Expansion Peripherals Computer Ports Used Each Power (ma)

  • Computer 1 N/A 1ma=run, 25ua=sleep
  • Parallax LCD 2x16 1 1 20
  • Memory Board 7 1 10
  • 433 Mhz Radio Transmitter 3,4 1 10
  • 433Mhz Radio Receiver 3,4 1 5.2
  • One Port 8-Pushbutton Keypad 2 1 5.0
  • Touch Sensor 6 1 1.5
  • DS1620 Digital Thermometer 5 3 1.0
  • Piezo Speaker 1-7 1 1.0
7-Port Belkin High Speed Powered USB 2.0 Hub Specs

  • Upstream Ports 1
  • Downstream Ports 7
  • Per-port Voltage DC +5V
  • Per Port Current 500mA (max)
  • Power Mode Self Powered (AC Power Adapter)
  • Operating Temp 5deg ~ 40deg C
  • Storage Temp -20deg ~ 60deg C
  • Enclosure ABS
  • Power Supply Output: DC 5V, 3.8A
  • Plug Size: 3.5mm outer, 1.0mm center
  • Plug Polarity: Center Positive
  • Red Power LED Off Not Operational
  • Power Status LED Green Fully Operational, Off Over-current Condition
Compliant with Universal Serial Bus Specs 2.0, data rate 1.5/12/480 Mbps, backwards compatible with USB spec 1.1 data rate 1.5/12 Mbps, Win 98SE, Me, 2000, XP, supports plug and play, and hot swapping, approved by USB Implementers Forum (USB-IF), over-current detection and protection, individual port status indicator LEDs, five horizontal mounted 480 Mbps downstream ports, two vertically mounted 480 Mbps downstream ports, fully compatible with USB 2.0 and 1.1 devices, compact slim-line design, two hubs may be stacked on top of one another, also Mac enabled – see operating manual for more details.

One Wire Interface The Stamp supports an open baud mode that switches to +5 volts dc only instead of ground. This is the open-source configuration, selected by an argument beginning with ON, such as ON2400. The 1K ohm resistor goes to ground.

Compare the size of these BASIC Stamp Supercomputers with the TSS. From left to right, the BSS Basic Stamp Supercomputer, SEED Supercomputer, and Tiny Stamp Super Supercomputer TSS.

Interesting Comments

USB Computer Ports
You might think it's possible to plug three USB Stamp boards into your computer's USB ports and begin clustered computing. Not possible with most computers. The sum current draw exceeds the amount of deliverable power from the combined USB ports on the PC computer. A powered Hub is needed to remedy this by supplying full power to all USB Stamp boards.

Non-Powered USB Hubs
You might think it's possible to just plug multiple USB Stamp boards into any USB hub and computing is possible. Not possible. A powered hub will be needed. You can try one or two Stamps in a non powered hub, but with 3 or more it is likely to exceed pc power capacity.

Powered USB Hubs
Even with some non-powered USB hubs, there is an incompatibility with some brands. Even a Belkin non-powered hub will not drive three or more Stamps.

Schematic Center

Check out the hi-res version of this rare BS1USB Schematic in the PDF file (download as seen below).

File Type: pdf BS1usb_sch.pdf‎ (112.8 KB, 1219 views) 

A Snoozer Program to put individual cores to sleep for ten seconds, then do a wake-up call based on a pause statement.

' {$STAMP BS1}
' {$PBASIC 1.0}

DEBUG CLS, "Sleep for 10 seconds"
SLEEP 10 ' Sleep for 10 seconds
DEBUG CLS, "awake now!"
PAUSE 1000 ' Awake for a second, or set timing here

GOTO Snoozer

The standard Hello World program is a good first test for each core.

' {$STAMP BS1}
' {$PBASIC 1.0}
DEBUG "hello world"

Determine memory used by a PBASIC Program
Use this code to determine memory consumed by a PBASIC program. On the BASIC Stamp I, enter the following code at the start of your PBASIC1 program:

READ 255,B0
' ****************

Upon running the program, a number will display in the debug window of the editor. Use the following equation to determine how many bytes are used by your PBASIC1 code: 255 - # - 6; where # is the number displayed on the debug window. Note, the “- 6” in the equation results from the fact that the above two lines of code take 6 bytes of program space, thus without those two lines, your program takes 6 fewer bytes of space. 

Cores, Parallelism, Determinism
The little TSS machine has seven cores which is numerically defined by the Belkin HUB. As a purely academic comparison, the TSS can use all seven cores at the same time in parallel, with true determinism. This aspect is similar to a Propeller chip's eight cogs.
In this particular fashion, Propeller cogs can be simulated or emulated on a simple level. The TSS has huge robotics potential for controlling numerous sensors at the same time. Cores can operate servos while the vision center can continue to function, for example. If you have some of these tiny BS1USB boards handy, this is one way to find a good use for all the processors with this simple project.

In the TSS, seven of BS1 USB boards connect to a powereed HUB. Small pin connectors are enough for wiring when combined with several tiny solderless breadboards. Dimensions of this board are: 2.25 x 0.75 x 0.35 in (5.72 x 1.91 x 0.89 cm).
Running Core Software
Serial Communications programs are in the Handbook of BASIC Stamp Supercomputing.

This PBASIC code sets up the Master-Slave concept and establishes Talk/Listen rules for simple communication.

============================================== TinyAI is found in the BASIC Stamp SEED Supercomputer post (runs on ten cores).

PBASIC code utilizes ten cores to set up AI. The same program loads into each core and evolves. Requires ten deterministic pin circuits. The schematic is written in the software comments. In the code, remove three processors to run on the TSS.
TinyAI for the TriCore is found with the BASIC Stamp TriCore Supercomputer post (runs on 3 cores).

This code is written in PBASIC and utilizes three cores to set up AI. The same program loads into each core and evolves. Requires three deterministic pin circuits. The schematic is written in the software comments. In the code, add 4 processors to gain the total of 7, or run as is on the TSS using 3 processors, as a sample program.

This is to announce the hobby TSS Tiny BASIC Stamp Supercomputer and update the family list of BASIC Stamp supercomputing machines.

The TSS is number SEVEN out of seven BASIC Stamp Supercomputers and Stamp Computing Machines.
BASIC Stamp Supercomputers now include the following family. For links, refer to the signature.

BSS - BASIC Stamp Supercomputer SEED - BASIC Stamp SEED Supercomputer TRICORE - Three Cores MINUSCULE - Minimal Two Core Machine TSS - Tiny BASIC Stamp Supercomputer MOM - Master Offloader Machine TWO STAMP BSS (BS2sx + BSpx) AM - The Algorithm Machine

The Grapevine Speculation
Will there be another BSS? Considering that the BSS family and its spinoffs now encompass almost all BASIC Stamp boards and modules, it is possible that the torch may pass on to the Propeller chip. The question is, are there any new Stamp boards or modules that could be utilized in future projects that would show some new features? There is some thought about making a "super stamp" out of a Propeller chip. The Super Stamp would have the extra memory and speed (+cogs) of the prop, yet program in BASIC and have PBASIC functions and a similar module form factor. There is some discussion about using the SPIN Stamp for this purpose. One idea is moving towards more cost effective multiplicities. The propeller chip is about $1 per computer and this remains highly competitive. So what is coming up? You will begin to see some enhancements for modules and chips that can be applied to the BASIC Stamp and the Propeller chip, as well as dedicated supercharged machines.

The education that I get from these supercomputers is the greatest value and it continues. The Basic Stamp Supercomputer is the first in a continuing line of similar projects with additional features and strengths. I consider each project to be a step on a ladder, reaching upwards towards a higher plateau of evolution. With each, there's testing and designing of new circuits and new software, and I do my best to make the details and plans available to everyone to hopefully have as much fun as I have and share in the information.

I began avidly putting multiple Stamps together back around the year 2002, to create a kind of bigger and better brain for humanoid robots. I recall experimenting with two to four connected Stamps to gain added ports and extended software commands and do serial control of servo motors. My overall goal was to create a giant brain that could power humanoid robots. The plan was to use upwards towards hundreds of BASIC Stamp processors!

I am still on the learning path of more powerful super computers, and have another BASIC Stamp version in the works that's very unique and useful. I have also progressed to the Propeller chip with eight cores. You have to blame those guru dudes on the forum for egging me on to start with the prop. They have caused such a propeller passion that consumes all my time! :)

You can read about the Propalot saga in "Propalot Stuff." It describes the continuing evolution of connecting together ten Propeller chips on a breadboard to create a tiny little paralleled cluster. This cluster is evolutionary from my viewpoint - containing 80 computers and 320 controlling ports, running at up to 2,000 MIPS. That's two billion instructions per second in a space the size of your dinner plate. The uses are learning, fun, trying out various designs, experimenting, wiring up hardware, learning SPIN and other languages, programming various effects, etc...

Another surprising benefit of the BSS and SEED supercomputers is that they bring new friends. Nearly every week, someone requests that I run one of the supercomputers through its paces. Of course the talking BSS is very impressive to my Chinese friends, because it's programmed it to speak in Chinese. But I must say, the SEED supercomputer, is loved by everyone. They enjoy watching the life forms evolve and to see their responses on the debug screen (such as getting to know the neighbors, memorizing, reciting, napping, sleeping, working, etc.) Each of the ten processors have a little beeping piezo speaker and we all know they are talking back and forth to each other in some kind of binary code.

One time, the program finished and about 10 minutes later - suddenly- they started beeping to each other. Your guess is as good as mine... I have no idea what they were talking about... (the program had become too big and some parts were overwritten and it took on a mind of its own)