Updated 8/10/2015.
LittleBits makes snap together modules. The modules use a simple 3 wire interface with magnetic snaps. The magnets are arranged so that an input and an output can be snapped together. The three wires are the two power supply wires, 0 volts (GND) and +5 volts (VCC). The third middle wire is the signal wire. Because of the magnets, if you try to connect two outputs together they push away from each other. Softbits Live provides a WEB INTERFACE that presents a drag and drop interface where you can snap together Softbits. Some of the softbits work in the web page and some control softbits in the Softbits Live sketch running on an Arduino. This screen capture shows Arduino and Web page components exchanging data. Inspired by Scratch for Arduino, an HTML5 Canvas object is used to display simple representations of SoftBits. The web page currently uses AJAX to communicate to a backend PHP script. The PHP script makes tcp connections to the SoftBitsLive proxy which over a serial link ( usually a USB one) sends Midi data to the Arduino. When I have more time, it may be possible to emulate the LittleBits KORG Synth kit using something like WebModular (HTML5+Javascript Modular Synthesizer). The web page displays the SoftBits and allows you to connect them together. Some SoftBits only run in the web page and some can only run on the Arduino. So with only the web page you can build circuits. As you make chains of SoftBits, the script keeps track of which of the domains the SoftBits are running in. So if you try to snap together an Arduino domain bit to a web domain chain it will be pushed away... Writing complex programs on any platform can be daunting. Since LittleBits are targeted at kids and beginners, the programming bar for the Arduino is quite high. Simple programs that do basic input and output are easy to implement but tasks that Softbits have been developed for are things such as software envelope generators and Midi data processing to control kits such as the "LittleBits KORG Synth Kit". SoftBitsLive is a front-end to SoftBits. SoftBits was inspired by the LittleBits snap together hardware modules that make building circuits easy. When in college in the70's I thought that we would not need programmers buy now! SoftBits uses a simple programming model. It is just a simple list of function calls that mostly take no arguments and return no values. Most inter function call information passing is done with a single value stored in an array of "Chain" data. Simple lists of function calls were used in languages such as Forth. Forth uses a simple virtual machine model where the Forth interpreter simply executes lists of functions. In Forth the information passed between functions is stored in a stack. Some versions of Forth assign a byte code to each function. Languages such as SmallTalk and Java compile to a bytecode virtual machine where a byte represents an action in their respective interpreters. Some bits have two inputs. The second input will specify another chain to get the value from. Using a bit that has two inputs such as the arith_plus bit. power_on(1); input_a0(); power_off();power_on(2); input_a1(); arith_plus(1); output_a5(); power_off(); A full Softbits sketch looks like // A simple Softbits Demo #include "softbits.h" void setup() { use_d5(); use_d9(); soft_setup(); } void loop() { power_on(1); input_a0(); output_a5(); power_off(); } There are currently four main pieces to SoftBitsLive. (Jan 6, 15) working on Ethernet shield support as seen in the youtube video above. Will update the sketch source soon.
|
|