ARM技术论坛
登录
直播中
emitter
5年用户
1883经验值
擅长:可编程逻辑 存储技术
私信
关注
[资料]
基于ARM7 ADUC7020+MPU6050的计步算法
MPU6050
下文转载自网络:
最近在忙个人的国家级大学生创新创业,做的一个手环,这是比较流行的一个demo
但是,我试了一下,我的平台是STC12效果不是很好,可能用其他16位或者32位
单片机
跑的话效果更好,我自己也设计了一个算法,但是,写了两天效果不好,我打算
还是自己优化,毕竟后期自己也发核心论文,需要的可以下一下,最近做智能穿戴设备的老铁们。
单片机源程序如下:
/*********************************************************************
Author : J Scarlett
Date : Nov 2006
Files : main.c, display.c, ped.c
Hardware : ADuC7020
Descrip
ti
on : Implements a simple pedometer based on application
note AN-602
*********************************************************************/
#include
// Function Prototype with required function attribute.
extern void Monitor_Function(void);
extern void Display_Init(void);
//*********************************************************************
// Main Function for ADuC7020 Pedometer
// essentially performs startup functions
//*********************************************************************
int main (void)
{
POWKEY1 = 0x01;
POWCON = 0x06; // set to 653kHz core clock
POWKEY2 = 0xF4;
REFCON = 0x2; // use external reference
// (connected to Vdd)
//*********************************************************************
// Initialize Peripherals
//*********************************************************************
// GPIO Configuration
GP4DAT = 0x04000000; // P4.2 configured as an output.
// LED is turned on
GP0CON = 0x00000000; //
GP0DAT = 0xE0000000; // 0.7, 0.6, and 0.5 are outputs
// 0.7 = E, 0.5 = R/W*, 0.6 = RS
GP1DAT = 0xFF000000; // All P1 pins are outputs
ADCCON = 0x20; // Turn ADC on but do not enable
Display_Init(); // found in file "display.c"
Monitor_Function(); // found in file "ped.c"
//*********************************************************************
// Main Loop
//*********************************************************************
while(1)
{
}
} // main()
基于MPU6050的计步算法.zip
(2020-10-20 17:16 上传)
5.02 KB, 下载次数: 0
更多回帖
rotate(-90deg);
回复
相关帖子
MPU6050
STM32
MPU6050
平衡车的相关资料推荐
2022-02-10
885
基于
MPU6050
自带的DMP
算法
2022-02-10
1074
MPU6050
使用DMP问题现象有哪些
2022-02-10
574
ADUC7020
2021-10-13
1951
关于
MPU6050
的简介
2021-08-03
1067
适用于全面硬件开发环境的仿真器EVAL-
ADuC7020
QSZ
2020-04-26
1973
mpu6050
零飘值太大
2019-05-14
4196
基于
ARM7
的
ADuC
器件上仿真器能否支持调试基于Cortex-M3的
ADuC
器件?
2018-11-16
1932
MPU6050
的滤波
算法
怎么得到,我得到的
MPU
数据不稳定
2017-05-08
4628
想用
MPU6050
做
步
计
器,返回的波形眼睛可以看出走的
步
数,...
2013-06-29
5047
发帖
登录/注册
20万+
工程师都在用,
免费
PCB检查工具
无需安装、支持浏览器和手机在线查看、实时共享
查看
点击登录
登录更多精彩功能!
首页
论坛版块
小组
免费开发板试用
ebook
直播
搜索
登录
×
20
完善资料,
赚取积分