View on GitHub

drive-by-compass

This extension can be used with the OrientBit breakout board with blocks or functions for communicating with MPU9250 IMU, TCS34725, moving towards a given direction heading and microbit gpio. This is beta version.

Open this page at https://mintgenie.github.io/drive-by-compass/

image

Here is the OrientBit - used to change the orientation of MicroBit on certain Robots so that the built-in Compass can be used.

Use as Extension

This repository can be added as an extension in MakeCode.

Edit this project Build status badge

To edit this repository in MakeCode.

The Course_correct block is used for driving in the direction of a particular heading angle. This heading angle has to be passed as parameter to “preferred_heading”. The Course_correct block returns an array of speeds for the left motor and right motor. Assign the value of array[0] to left motor and value of array[1] to right motor.

THe available functions are shown below:

image and image

Blocks preview

This image shows the blocks code from the last commit in master. This image may take a few minutes to refresh.

A rendered view of the blocks

Metadata (used for search, rendering)