All Projects → EFeru → hoverboard-sideboard-hack-GD

EFeru / hoverboard-sideboard-hack-GD

Licence: GPL-3.0 license
Hoverboard sideboard hack for GD32 boards

Programming Languages

c
50402 projects - #5 most used programming language
assembly
5116 projects
Makefile
30231 projects

Projects that are alternatives of or similar to hoverboard-sideboard-hack-GD

COVID-away
Repo of paper title 'Avoid touching your face: A hand-to-face 3d motion dataset (covid-away) and trained models for smartwatches'
Stars: ✭ 18 (-73.53%)
Mutual labels:  gyroscope, accelerometer, sensor-fusion
imusensor
Python library for communication between raspberry pi and MPU9250 imu
Stars: ✭ 47 (-30.88%)
Mutual labels:  gyroscope, accelerometer, imu
Balance-Bot
A two-wheel self-balancing robot based on the ATmega2560 micro-controller.
Stars: ✭ 33 (-51.47%)
Mutual labels:  gyroscope, accelerometer, imu
CodeDroneDIY
The most simple, but working, quadricopter flight controller from scratch, using Arduino Uno/Nano.
Stars: ✭ 68 (+0%)
Mutual labels:  gyroscope, accelerometer, imu
pymetawear
Community developed SDK around the Python bindings for the C++ SDK
Stars: ✭ 42 (-38.24%)
Mutual labels:  gyroscope, accelerometer, imu
ios logger
Application for camera and sensor data logging (iOS)
Stars: ✭ 60 (-11.76%)
Mutual labels:  gyroscope, accelerometer, imu
Libopencm3
Open source ARM Cortex-M microcontroller library
Stars: ✭ 2,240 (+3194.12%)
Mutual labels:  stm32, gd32
Smartimu
Inertial Sensor Development Kit,STM32F411C、NRF52810、MPU9250、LPS22HB
Stars: ✭ 231 (+239.71%)
Mutual labels:  stm32, imu
MPU-9250-Sensors-Data-Collect
MPU9250 (MPU6500 + AK8963) I2C Driver in Python for Raspbery PI
Stars: ✭ 51 (-25%)
Mutual labels:  gyroscope, accelerometer
GY-85
Arduino implementation for GY-85 (ADXL345 accelerometer, ITG3200 gyroscope and HMC5883L magnetometer)
Stars: ✭ 63 (-7.35%)
Mutual labels:  gyroscope, accelerometer
Avem
🚁 轻量级无人机飞控-[Drone]-[STM32]-[PID]-[BLDC]
Stars: ✭ 465 (+583.82%)
Mutual labels:  stm32, imu
X360Advance
External Arduino gyroscope & pedals for any Xbox compatible gamepads / Внешний Arduino гироскоп и педали для Xbox совместимых геймпадов
Stars: ✭ 35 (-48.53%)
Mutual labels:  gyroscope, mpu-6050
BetterJoyForDolphin
Allows the Nintendo Switch Pro Controller and Joycons to be used with the Dolphin Emulator
Stars: ✭ 44 (-35.29%)
Mutual labels:  gyroscope, accelerometer
Qcopterflightcontrol
飛控板 FlightController,使用 STM32F405RG / STM32F411CE
Stars: ✭ 143 (+110.29%)
Mutual labels:  stm32, imu
Uwb Node
Local Positioning System Development Kit, use STM32F411C + MPU9250 + LPS22HB + DWM1000
Stars: ✭ 99 (+45.59%)
Mutual labels:  stm32, imu
Qcopterremotecontrol
遙控板 RemoteControl,使用 STM32F407VG / STM32F411CE
Stars: ✭ 40 (-41.18%)
Mutual labels:  stm32, imu
LaunchPadFlightController
TM4C123G based Flight Controller
Stars: ✭ 62 (-8.82%)
Mutual labels:  accelerometer, imu
MPU60X0
Fast, Lightweight STM32 I2C HAL Driver for the MPU6000/MPU6050 IMU
Stars: ✭ 15 (-77.94%)
Mutual labels:  stm32, imu
CtrlUI
CtrlUI (Controller User Interface) is a Windows application, game and emulator launcher for your game controller, DirectXInput converts your game controller to a Xbox (XInput) controller, Fps Overlayer is a tool that shows the frames per second and the cpu, gpu and memory information.
Stars: ✭ 39 (-42.65%)
Mutual labels:  gyroscope, accelerometer
dana
DANA: Dimension-Adaptive Neural Architecture (UbiComp'21)( ACM IMWUT)
Stars: ✭ 28 (-58.82%)
Mutual labels:  gyroscope, accelerometer

hoverboard-sideboard-hack-GD

Build status License: GPL v3 paypal

This repository implements the firmware for the hoveboard sideboards. The hoveboard comes with two identical sideboards that can be flashed with this firmware.

► If you have an STM32 sideboard check-out the repo hoverboard-sideboard-hack-STM


Table of Contents


Hardware

The original sideboard hardware supports one 4-pin cable that originally was connected to the hoveboard mainboard. It breaks out GND, 12/15V and USART. Additionally, two ports are used to connect to the LED boards. On the back of the board, two Photo Interrupter Optical Switches can be found, originally used to detect if a human is standing on the hoverboard. sideboard

The LED boards consist of colored LEDs (blue, red, green, orange) used for design and to inform the user about the current hoverboard state. Below the pinout of the LED boards is shown. ledboard

The sideboard brain is a GD32F130C6T6 with the pinout shown in the follwing figure: MCU_pinout

A very important component of the sideboard is the IMU MPU-6050 from Invensense. The MPU-6050 determines the board orientation by combining a 3-axis gyroscope and a 3-axis accelerometer on the same silicon die, together with an onboard Digital Motion Processor™ (DMP™), which processes complex 6-axis MotionFusion algorithms. The DMP™ offers many features, such as:

  • Accelerometer and Gyroscope raw data output
  • Quaternion output
  • Temperature output
  • Pedometer
  • Interrupts on gesture events such as Tap on all axes or Orientation change
  • Low-power modes
  • Self-test and calibration

The MPU-6050 pinout and orientation of axes is shown in the follwing figure: MPU6050_pinout

For more details see the MPU-6050 datasheet and MPU-6050 registers.


Example Variants

This firmware offers currently these variants (selectable in platformio.ini or config.h):

  • VARIANT_DEBUG: In this variant the user can interact with sideboard by sending commands via a Serial Monitor to observe and check the capabilities of the sideboard
  • VARIANT_HOVERCAR: This variant can be used for Hovercar build. An RC receiver with iBUS protocol can be connected to the AUX serial Rx pin (see schematic)
  • VARIANT_HOVERBOARD: In this variant the sideboard is communicating with the mainboard of a hoverboard using the FOC firmware repository

Of course the firmware can be further customized for other needs or projects.


Flashing

On the sideboard, there is a debugging header with GND, 3V3, SWDIO and SWCLK. Connect GND, SWDIO and SWCLK to your ST-Link V2 programmer. The 3V3 can be either obtained by connecting the pin to the ST-Link programmer or powering the sideboard with 12/15V.

If you have never flashed your sideboard before, the MCU is probably locked. To unlock the flash, check-out the wiki page How to Unlock MCU flash.

To build and flash choose one of the following methods:

Method 0: Using GitHub Fork

  • Fork the project
  • Modify desired source files and commit
  • Go to Actions (in the repo top menu)
  • Click on latest build
  • Download the build zip file from the Artifacts section
  • Upload desired firmware.bin file using ST-Link Utility

Method 1: Using Platformio IDE (recommended)

  • open the project folder in the IDE of choice (vscode or Atom)
  • press the 'PlatformIO:Build' or the 'PlatformIO:Upload' button (bottom left in vscode).

Note the GD32F130C6T6 is now supported by PlatformIO, see https://github.com/CommunityGD32Cores/platform-gd32, alongside other GD32 chips.

Method 2: Using Keil uVision

  • in Keil uVision, open the sideboard-hack.uvproj
  • if you are asked to install missing packages, click Yes
  • click Build Target (or press F7) to build the firmware
  • click Load Code (or press F8) to flash the firmware.

Method 3: Using Linux CLI

  • prerequisites: install ST-Flash utility.
  • open a terminal in the repo check-out folder and if you have definded the variant in config.h type:
make

or you can set the variant like this

make -e VARIANT=VARIANT_####
  • flash the firmware by typing:
make flash

Wiring iBUS Receiver

An RC transmitter (Flysky FS-i6S or FS-i6X) can be connected to the sideboard using an FS-iA6B receiver as shown in the following schematic:

wiring_iBUS_pic


3D Visualization Demo

By converting Quaternions to Euler angles, we can make a 3D visualization example in Processing as shown below. For this Demo VARIANT_DEBUG was used.

sketch_pic


Contributions

Every contribution to this repository is highly appreciated! Feel free to create pull requests to improve this firmware as ultimately you are going to help everyone.

If you want to donate to keep this firmware updated, please use the link below:

paypal


Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].