8000 GitHub - nuttycream/omniscient: Self contained rust web application to 'strictly' observe a Raspberry Pi powered three wheeled omnidirectional bot.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.
/ omniscient Public archive

Self contained rust web application to 'strictly' observe a Raspberry Pi powered three wheeled omnidirectional bot.

Notifications You must be signed in to change notification settings

nuttycream/omniscient

Repository files navigation

omniscient

A pair program for the OmniBot that uses IPC and WebSockets to give us near real-time updates from our bot

preview

what does it do?

the premise of this web app, is to read from shared memory from the bot

flowchart TD
    subgraph omnibot["omnibot (C)"]
        botMain[main.c] --> motors[Motor Control]
        botMain --> sensors[Sensors]
    end
    
    subgraph sharedMem["Shared Memory"]
        shared["Shared Struct
        - version
        - direction
        - motor_power
        - bot_mode
        - obstacle
        - line sensors"]
    end
    
    subgraph omniscient["omniscient (Rust)"]
        webApp[Web Interface]
        webApp --> sound[Sound System]
        webApp --> wsServer[WebSocket Server]
    end
    
    omnibot -->|writes| shared
    omniscient -.->|reads| shared
    wsServer -->|updates| browser((Browser))
    
    classDef cCode fill:#5c8dbc,color:#fff,stroke:#000
    classDef rustCode fill:#dea584,color:#000,stroke:#000
    classDef sharedMemory fill:#f9e79f,color:#000,stroke:#000
    classDef external fill:#f9f9f9,color:#000,stroke:#000
    
    class omnibot cCode
    class omniscient rustCode
    class sharedMem sharedMemory
    class browser external
Loading

shared memory structure

typedef struct {
    // we'll check for version
    // number per update
    // seems jank but the other option
    // is to check for modified 0/1
    // but the rust code needs W perms
    // which i dont want
    int ver;
    int direction;
    int motor_power[3];
    // bot can be either
    // line following: 0
    // obstacle tracking/avoidance: 1
    // man control: 2
    int bot_mode;

    // osbtacle stuff
    int obstacle;

    // line following stuff
    int go_left;
    int go_right;
    int sensor_mode;

    int sensors[4];
} Shared;

attribution

chicken sounds from:
minecraft wiki

docker image inspo:
friday

About

Self contained rust web application to 'strictly' observe a Raspberry Pi powered three wheeled omnidirectional bot.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0