Skip to content

The Rovercode service for GiggleBot, written directly on the Lancaster C/C++ mBed micro:bit runtime.

License

Notifications You must be signed in to change notification settings

rovercode/rovercode-gigglebot-mbed

Repository files navigation

Rovercode GiggleBot mBed

The Rovercode service for GiggleBot, written directly on the Lancaster C/C++ mBed micro:bit runtime. Based off the Lancaster examples.

Setup

Alternative Docker image
sudo docker build . -t yt

Build

yt clean
yt build
Alternative Docker container
sudo docker run --rm -v ${PWD}:/app yt clean
sudo docker run --rm -v ${PWD}:/app yt build

Lint

Defaults to LLVM style.

clang-format --dry-run --verbose source/*.cpp source/drivers/*.cpp

And to auto-fix errors:

clang-format -i --verbose source/*.cpp source/drivers/*.cpp

Alternative Docker container

sudo docker build -f lint.Dockerfile . -t clang-format
sudo docker run --rm -v ${PWD}:/app clang-format --dry-run --verbose source/*.cpp source/drivers/*.cpp
sudo docker run --rm -v ${PWD}:/app clang-format -i --verbose source/*.cpp source/drivers/*.cpp

Copy hex to the micro:bit

Example command on Ubuntu.

cp ./build/bbc-microbit-classic-gcc/source/rovercode-gigglebot-mbed-combined.hex /media/$USER/MICROBIT

Links

microbit-dal configuration

The DAL also contains a number of compile time options can be modified. A full list and explanation can be found in our documentation.

Alternately, yotta can be used to configure the dal regardless of module/folder structure, through providing a config.json in this directory.

Here is an example of config.json with all available options configured:

{
    "microbit-dal":{
        "bluetooth":{
            "enabled": 1,
            "pairing_mode": 1,
            "private_addressing": 0,
            "open": 0,
            "whitelist": 1,
            "advertising_timeout": 0,
            "tx_power": 0,
            "dfu_service": 1,
            "event_service": 1,
            "device_info_service": 1
        },
        "reuse_sd": 1,
        "default_pullmode":"PullDown",
        "gatt_table_size": "0x300",
        "heap_allocator": 1,
        "nested_heap_proportion": 0.75,
        "system_tick_period": 6,
        "system_components": 10,
        "idle_components": 6,
        "use_accel_lsb": 0,
        "min_display_brightness": 1,
        "max_display_brightness": 255,
        "display_scroll_speed": 120,
        "display_scroll_stride": -1,
        "display_print_speed": 400,
        "panic_on_heap_full": 1,
        "debug": 0,
        "heap_debug": 0,
        "stack_size":2048,
        "sram_base":"0x20000008",
        "sram_end":"0x20004000",
        "sd_limit":"0x20002000",
        "gatt_table_start":"0x20001900"
    }
}

About

The Rovercode service for GiggleBot, written directly on the Lancaster C/C++ mBed micro:bit runtime.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published