Skip to content

Core system

A. Malthe Henriksen edited this page May 9, 2024 · 4 revisions

Stores in svelte are essential for interactive pages and no less in ML-Machine.

Stores

At the core of ML-Machine is the Stores object. Located in Stores.ts the object provide all of the essential system objects that runs the ML-Machine website.

const classifier = stores.getClassifier();
const gestures = stores.getGestures();
const engine = stores.getEngine();
$: liveData = $stores.liveData;

The Stores object act as a bridge between the microbit, and the interface. These components are tightly coupled, in the sense that changes applied to the live data object, causes the classifier to classify gestures, thus updating the gestures object.

Clone this wiki locally