Skip to content
This repository has been archived by the owner on Jun 27, 2019. It is now read-only.

Samples:Calamari Lure

Bruno Dilly edited this page Jun 16, 2016 · 10 revisions

Calamari Lure samples

Soletta™ Framework supports fine Minnowboard Max and its Calamari Lure, providing node types that make their usage really straight-forward.

On this page there are a few samples with description and diagrams, but a complete list may be found in Soletta framework's code repository.

Each sample title is a link for the FBP code.

This sample uses the Calamari's lever to change the intensity of the light of LED1 and LED2. Their light intensity should change from 0 to maximum.

Diagram:

calamari-led.svg

Upon the sample execution, the seven segments display must start to display hexadecimal numbers, from 0 to F, one per second.

There are two different ways to control 7-segment displays. Turning each segment on or off using a byte, or sending a value (and the node handles what segments should be on to represent it).

This example shows how to use values. Below there is another example for segments manipulation.

Uses a timer to loop an accumulator from 0 to 15 and display using MinnowBoard's Calamari Lure 7-segment display. It is an example of:

  • wallclock/second node type (emits a package per second)
  • accumulator node type
  • calamari/7seg (controls the Calamari Luire 7-segment display)
  • Using an alias (SevenSegments) for a node type configured in the .conf file

Diagram:

calamari-7seg-value.svg

In this sample, the 7 segments display shows a number (in hexadecimal) from 0 to 15, depending on the position of the lever. So, moving the lever should change the value displayed by the 7seg display.

Diagram:

calamari-lever.svg

Upon the sample execution, the seven segments display will show the letters of the word 'PLAY'.

Diagram:

calamari-7seg-segments.svg

The Calamari lure has a RGB led, identified as LED3 on the board. Running this sample should make this LED blink, changing colors.

Diagram:

calamari-rgb-led.svg

This sample assigns each one of the buttons (S1, S2 and S3) to a color of the RGB led. Pressing S1 should make the LED red, S2 green and S3 blue. An output is generated in the console, identifying which button was pressed.

Diagram:

calamari-buttons-rgb-led.svg

Clone this wiki locally