Giter VIP home page Giter VIP logo

smartcar-unicycle's Introduction

smartcar-Unicycle-0.0

传感器

惯性测量单元

基本思路

  1. 陀螺仪测量x、y、z三个轴向角速度,采用简单滑动滤波处理
  2. 加速度计测量x、y、z三个方向加速度,采用简单滑动滤波处理
  3. 根据三角关系用加速度计测量数据推算x、y轴上的角速度
  4. 将加速度计推算获得的角速度与陀螺仪测得的角速度通过卡尔曼滤波进行融合,获得较为精确的x、y轴向角速度
  5. 对融合后的角速度进行积分,获得x、y轴相上的旋转角度
大致情况
  1. 在稳定状态下能获得较为精确的角速度与速度
  2. 当移动时会出现较高延迟,可能与滑动滤波有关
  3. 由于z轴偏航角较为复杂,还未做处理
  4. 由于时间关系,暂时只使用简单的滑动滤波对数据进行处理

编码器

基本思路
  1. 周期中断内读取编码器ADC值
  2. 对ADC值进行处理,获取角速度值
  3. 对ADC值进行处理,获取速度值
  4. 对速度值进行积分,获取里程

大致情况

  1. 还未对编码器进行实际测试,效果不清楚
  2. 还未对编码器采集值进行任何滤波

受控控制

动量轮

驱动方式

  1. 采用内置无刷驱动,所以不需要自己额外处理无刷电机,只需控制方向引脚和PWM引脚即可;
  2. 方向为 1 时前进,为 0 时后退;(顺逆转还记不太清)
  3. 特殊注意,PWM值为(10000 - pwm);其 pwm 控制与以往电机相反。

运动分析

  1. 两个动量轮同向旋转,由于角动量守恒,使车身反向房侧翻,由此控制小车左右旋转
  2. 两个动量轮赋予不同的转速,较快的一方向外的离心力较大,使车前后倾斜

大致情况

小车还无法维持左右平衡,大概推测如下:

  1. 小车左右的pid参数仍不合适,输出不够,响应太慢
  2. 小车前后平衡还未做处理,因前后不稳定导致侧翻
  3. 小车速度还未闭环,响应跟不上

行进轮

还未对行进轮做任何处理。

调试

目前主要以来TFT屏简单地显示内容、目前主要靠烧录代码来改变参数、拨码开关辅助调试。

smartcar-unicycle's People

Contributors

akitomoya277 avatar

Stargazers

 avatar

Watchers

 avatar

smartcar-unicycle's Issues

1.0版本计划

0.1版本计划——简单调参菜单

大致目标

实现矩阵键盘修改小车参数,并能保存在flash中掉电不丢失。

任务分步

CH455

  • 实现CH455的iic通讯

  • #2

矩阵键盘

  • 实现矩阵键盘的数据输入

  • 实现矩阵键盘的界面控制

FLASH

  • 实现数据的读取
  • 实现数据的写入

IPS

  • 实现数据的显示
  • 实现控制信息的显示

Menu

  • 选择变量
  • 修改参数

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.