EV3 robot making 90 degree turns

Поделиться
HTML-код
  • Опубликовано: 8 сен 2024
  • After trying with no sensors • FLL EV3 Turn Accuracy:... here is a basic EV3 robot with two gyro sensors. This configuration uses one gyro to control the turns, and a second gyro just for data logging to compare readings afterwards. The black tape marks are for sensor logging, but are not being used for control. After driving a total distance of 3.16 meters, the robot returns to within 1 cm of the starting point, which is better than before I used the gyro.
    Logging the two motor encoders along with the gyro data for many runs, making 4 right-angle turns for a full 360 ends up with a maximum variation of +/- 2 degrees in heading at the end when using the gyro control. The data log file also shows the (Left-Right) motor rotation varied by the equivalent of +/- 4 degrees heading at the end, so the gyro is a factor of 2 more consistent than simple motor control in this case. This test used slow speeds and had no hard stops or starts. If you go faster or use more acceleration, I expect that difference would be even larger.
    This test runs about 30 seconds and I am always starting with a gyro recalibration. Even doing that, I found my gyros may drift as much as 5 degrees per minute during motion, but often they do better (unless you are near low-battery, in which case all bets are off.) The gyro sensor works as if it was slightly "sticky" so the reading is always steady if there is no robot motion at all. It did not change even leaving it sitting plugged in for 8 hours overnight.
    In addition to the expected slow gyro drift during motion, there are two additional unexpected errors, due to apparent bugs in the current EV3 and/or gyro firmware: 1) momentary "freeze" or "lag" where the angle reading sometimes does not update for many 10s of milliseconds during a turn, and more rare but much worse: 2) unrequested gyro reset/recalibration, which results in catastrophic runaway drift if it happens during a turn. You can see some documentation of this here: photos.app.goo...
    If you want to try a version of a robot with no hardware glitches like this, there are some simulators online. I try one out here: • FLL EV3 Line Follower...

Комментарии • 3

  • @kirkjn
    @kirkjn 4 года назад +1

    John, your videos are fantastic! After seeing your video regarding turn accuracy, I was going to give you these larger, smaller contact point (convex) wheel and tire setup, but you already evolved your experiments. These are great reference for anyone looking for explanations behind the mechanics. Well done sir!

  • @ahmetselim1166
    @ahmetselim1166 3 года назад

    Could you please show us the picture of this code I could only understand by looking at picture

    • @dancevideo2
      @dancevideo2  3 года назад

      Here is an example that walks you through the code. ruclips.net/video/8B1LwzkLKXs/видео.html