INSTINCTUS Teensy 4.1 COGITATOR Jetson Orin Nano EXPLORATOR Electron/Vue.js (MacOS) serial websocket

Software Architecture Map

Instinctus — Teensy 4.1

Instinctus is the C++ code that runs on a Teensy 4.1 microcontroller. The idea is for Instinctus to maintain control over a deterministic, high-speed low-level loop that handles balancing, low-level locomotion (that is, interfacing with the ODrive S1 controllers), and passing telemetry up the chain to Cogitator. Instinctus only talks to Cogitator. Nothing else has direct access.

Instinctus runs Arduino-style C++ code, which I’ve developed using the grot and servitor tools (convenience wrappers around existing Arduino tools).

Cogitator — Jetson Orin Nano

If Instinctus is Calvin’s spinal cord, Cogitator is his brain. While Instinctus churns through its loop keeping everything upright and controlled, Cogitator handles the bigger picture. That includes things like computer vision, path planning, SLAM, and anything else I can think of. The philosophy here is that Cogitator should be able to crash while Calvin continues balancing with Instinctus. Cogitator runs on a Jetson Orin Nano Super, so it has a fair amount of headroom for experimentation.

Cogitator is also the bridge between Instinctus and Explorator. Telemetry flows out of Instinctus, and commands flow in. Those commands may be generated internally by Cogitator, or they may be passed in from Explorator.

The code is written in Python. A group of services is coordinated through a ZeroMQ bus and broker. Services can be turned on and off independently, and they should be able to crash independently without affecting each other or Instinctus.

Explorator — Electron / Vue.js (macOS)

Explorator is optional. It’s an Electron app written in Vue.js and targeted at macOS (because that’s what I use). It serves as a teleoperation center and data visualization system. The user should be able to “drive” Calvin, monitor his status, and tweak his inner workings while sitting behind a monitor with a view into his world. Commands and telemetry are passed to and from Cogitator. Explorator never talks directly to Instinctus.

That said, Calvin doesn’t require a user. He should eventually be capable of at least some level of autonomy.