Skip to content

Yuri-Lima/CodeDomino_NewFirmwares

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Decabot New Version from Firmware

For you knowledge, this project is a remix from the original project. I had just built a new firmware and included some hardware to cooperate with it.

Basic Notice

  • Walk / 0 -> Stopped function, 1 -> forward, -1 -> back

    • This function controls all the execution of steps, in any direction, even curves.
  • As the basic guidelines are no longer a mystery.

    • I will try to explain a little about how I tried to solve the curve problem, as follows:
      • I noticed that one of the wheels needs to take fewer steps than the other, of course according to the direction, so I found a reason given by the parameter _freqRot, he is responsible, for inhibiting certain steps with a ratio between the steps to walk and the rest comparable to 1, in this rhythm, when varying this division, we can get drives that vary from 1 step each 2, such as 1 step every 5 and so on, so, the larger _freqRot, the longer the activation time for 1 step and the circumference / curve radius decreases, that is, it is inversely proportional.
      • All calculations for making circular movements, that is, curves, must be used as a variable parameter, e_360, because it is there that we have the steps, taking into account the axis of the car and all to follow in a straight line, either backwards or forwards, has as parameter / variable r_360.
      • Other calculations are just simple rules 3. In the function Shapes case 4, Sine and Tagente were used, because to perform it is necessary to create a Rectangle Triangle just specifying the type of the notable triangle and the opposite side measurement, to obtain the other measures .
      • Anyway, I saw that we have a lot to do, both for an open version, as for a commercial version better elaborated in the sense (precision).
      • Over in the Air with HC 05 / The entire implementation followed the guidelines of the links I made available, there are details that need to be studied further. Example: time spent in pairing. Pair automatically with a predefined list of devices.

What was the changes

  1. The main code;
  2. External reset button when something went wrong, like a bug;
  3. MPU 6050
  4. Posicion Corret MPU6050
  5. Examples code to simulate individual part of the code:
  1. Libraries Created

Analysis of the power consumption

CodeDomino Acording of the test made at 25/10/2018 at 23:07. The power consumption was around ~95mA when it is stopped waiting to receve the first command, however, when the first command comes up, The power minimun consumption when it was working at around 495mA e max was 700mA at the end of the way. There is a pico of energy, when the bobine of the motors turns off. The Lipo Batery 2S de 1300mAh has a range aprox in 4 hours of work. O.B.S.: It's still necessary wacht his behavior, because all of the informatios is just piece of ideia, however, i considerated all experience that i had at the long way doing the tests.

  • Calculate Base when it is stopped: Lipo 1000mAh--> 1 / 0,095 = 10.526 * 60min = 631 minutes ou 10 horas stopped.
  • Calculate Base when it is works: Lipo 1000mAh--> 1 / 0,5 = 2 * 60min = 120 minutes ou 2 hours.

Calculates to show how the robot moves

  • --> May you can ask <--
  • How many steps are to turn the wheel self around into 360º? --> go to **step number 2 **
  • How many steps are to turn the robot self around into 360º?? --> go to step number 4
Step 1 - Motor
1º We need to know, which will be the model of the step motor to know how many degrees per step. 
2º We are going to divide 360° by degrees steps of the type of motor to get how many steps are necessary to turn the wheel self around into 360°.
O.B.S.: It is important to add one variable to incrise(+) a margin of error, because there are few oscillations.

Exemples Type of motor Stpes
FullStep = 11,25° / 64 => 0.1757° 28BYJ-48 0.1757°
1Step = 5.625 --> FullStep = 2 * 5.625° => 11,25° ---> 360 / 0.1757° 28BYJ-48 p' = 2000 steps
Step 2 - The Wheel                                  
1º We need the information of the diameter of the wheel to get radius.
2º At the formula C" = 2 * PI * r --> we can get the log distance at 360°.

Step 3 - The Car
1º We need to get the diameter between of the two wheel, to get radius.
2º t the formula C' = 2 * PI * r --> we can get the log distance at 360°, however, on its own axis.

Step 4 - Revolution                   
1º revolution = C" / C' --> How many stpes the wheel of the car, will have to do to the car turns 360° on its own axis.

Step 5 - Steps 
1º P" = p' * revolution --> At P" We can get how many steps to turn 360°.

O.B.S.: It is important to add one variable to incrise(+) a margin of error, because there are few oscillations. Recomended >= 0.01

Important details, everything that go to relate about moviment of the curve, we use the variable called e_360 and straight movement r_360.

Hardware

  1. The main board from the original project;
  2. Bluetooth HC 05 plus General Components;
  3. MPU6050.

Software

  1. VsCode;
  2. Arduino IDE;
  3. SolidWorks.

The biography studied:

3D Wheel

Productivity metrics and automatic time tracking for programmers

Engine reduction mechanism

Batery Level

RFID record and write

Dynamic allocation memory

Incremental encoder - animation

Right Angle Triangle Theorem SOH CAH TOA

Over in the Air com HC 05

MPU6050

Protoypes Images and Videos

Click on the text below to watch on Youtube Channel
Images

Contact

Atention If you go email me, please put as subject the name of the project, in this case: (CodeDominor Remixer) Requests

Name Email Mobile
Yuri Lima y.m.lima19@gmail.com +353 83 419.1605