Git Product home page Git Product logo

self-balancing-cube's Introduction

Self-Balancing-Cube

UPDATE (2024-07-14)

New code is in esp32_cube_enc folder. I changed sensor orientation. So, if you make my cube before, to use this code, you need to reprint one part.

Or you can print redesigned cube https://www.thingiverse.com/thing:6695891

Cubli

The red connections you see in the schematic must be connected!

If something doesn't work, try the motors test sketch. It tests all motors, rotation directions and encoders.

Folow this video https://youtu.be/ZU0oTBRDgOE


ESP32, MPU6050, Nidec 24H brushless motors, 500 mAh LiPo battery.

Balancing controllers can be tuned remotely over bluetooth.

Example:

Send p+ (or p+p+p+p+p+p+p+) for increase K1.

Send p- (or p-p-p-p-p-p-p-) for decrease K1.

The same for K2, K3. Send "i", "s".

Self-Balancing-Cube

Self-Balancing-Cube-Schematic

About schematic:

Battery: 3S1P LiPo (11.1V). Buzzer: any 5V active buzzer. Voltage regulator: any 5V regulator (7805). All red connections not nescesary for this project! But if you are designing a PCB I recommend making these connections. Maybe I use encoders in the future, you will be able to use the new firmware without any changes.

How to build:

https://youtu.be/AJQZFHJzwt4

If something doesn't work, try the motors test sketch. It tests all motors, rotation directions and speeds. This helps you understand the problem is in software or in hardware.

You can also make this balancing cube with Arduino nano controller. All other parts remain the same.

Self-Balancing-Cube-Schematic

In this version I make offsets setting procedure more simple. First connect to controller over bluetooth. You will see a message that you need to calibrate the balancing points. Send c+ from serial monitor. This activate calibrating procedure. Set the cube to one of balancing points (edge or vertex). Hold still when the cube does not fall to either side. Send c- from serial monitor. This will write the offsets to the EEPROM. Repeat this procedure four times (3 edges and vertex). After calibrating all offsets, the cube will begin to balance.

ESP32 version also has an updated balancing point setting procedure. Important! In this video you can learn how to set the balancing points:

https://youtu.be/Nkm9PoihZOI

self-balancing-cube's People

Contributors

remrc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

self-balancing-cube's Issues

Schematic Feature Request

Hi - Would it be possible for a little schematic of your PCB? Thanks so much for sharing this project <3

Print Settings

Any recommendations for printing the stls?

Infill/Perims/etc? Or it doesn't really matter.

esp32 q1 transistor code

Can you elaborate on the q1 transistor 'p' type for the esp32 schematic? what is its code and what type of transistor is it?

schematic missing information

The schematic shows use of a transistor for the buzzer but there is no transistor number mentioned on the schematic. Can you suggest the transistor number/model used and the pin connections. I am just a hobbyist and do not have knowledge enough to know by myself, what kind of transistor I should utilize here.

Thanks-

Missing license

Hi, this project seems to be missing a license in github but it has one on thingiverse (CC BY). Is it the same for this repo?

Not able to balance on all sides

Hey, I just wanted to ask if a heavier battery might be causing the balancing problems. On one site it works fine, on another it tries but seems to slow to react.

My build differs in that I am using a bigger battery maybe 2 to 3 times heavier and also a bit larger so the center of mass is higher up and also have not achieved the 70g per reaction wheel.

It worked fine on the one side but maybe it's not enough.

If you have time it would be great if you would help.
Otherwise I'll figure it out eventually and try increasing the weight first.

The motor is not moving

I have connected the circuit board, and the gyroscope test is normal, there is a detection sound when starting, but the motor does not move, the replacement motor failure is still the same, what is the reason?
cube.ino
pinMode(DIR1, OUTPUT);
ledcSetup(PWM1_CH, BASE_FREQ, TIMER_BIT);
ledcAttachPin(PWM1, PWM1_CH);
Motor1_control(0);

Motor1_control(0);???

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.