II
题目 基于安卓平台的手机计步器的设计
摘要
Android是一个针对移动设备的操作系统和软件平台,随着智能手机的兴起,渐渐成为了占有市场最大比重的移动平台操作系统,同时也越发地受到广大用户的青睐。Android采用 Linux 内核,由 Google 和开放手机联盟于2007年11月5日发布。容许使用 Java语言来开发和管理代码。作为一个年轻并且流行的移动应用平台,目前android软件的应用面还是比较广泛的,比如聊天,通讯,上网等等,但涉及传感器方面的应用软件还比较少。本文在分析讨论Android手机软件开发原理的同时,针对智能手机用户日常使用的实际情况,对用户手机的日常功能需求进行调查。发现对于经常走路上班或者锻炼的朋友来说拥有一款精美、功能齐全的计步器是非常必要的。将精确计量和智能运行技术完美结合,只需开启软件,通过感应器传来的信息,App能够变化算法,测得你的走路步数,速度以及消耗的卡路里量与行走历程。一款合适的计步器在无形中会量化用户的健身效果,帮助用户坚持锻炼以达到更好的健身效果。
关键词 Android 智能手机平台 计步器 Java
I
Title The design of mobile phone pedometer based on
the android platform
Abstract
Android is an operating system and software platform for mobile devices. With the development of Smartphone, it gradually became the biggest proportion in the market of mobile operating system. At the same time, it became more and more popular among users. Android uses the Linux kernel, announced on November 5, 2007 by Google and the open handset alliance, and it allow to use Java language to develop and manage the code. As a young and popular mobile application platform, the application of android is relatively wide; such as chat, communication and internet. However, the application of sensors is less. The thesis of this essay is to analyze and discuss the principle of software development of Android mobile phone. Also, the another purpose in this essay is to conduct an investigation in the daily functional demand for mobile phone users based on the situation of daily uses of smart phone users. The research shows that it is very important to have a fully functional pedometer for people who often walk to work or exercise. The pedometer makes a perfect combination of accurate measurement and intelligent operational technology, when the software are ready to run, it can use the massage which acquire from sensor to calculate the step frequency ,speed, the consumption of calories and walking journey of your walk. An appropriate pedometer can quantify user’s fitness effect in potentially; in this way it can make users to keep exercising in order to achieve better fitness effect.
Keywords android smartphone platform java pedometer
II
目录
1.前言 ............................................................... 1 1.1 智能手机系统开发背景 ............................................. 1 1.2 课题的目的与意义 ................................................. 2 1.3 本文主要研究内容 ................................................. 2 2.相关技术介绍 ....................................................... 4 2.1 开发工具及环境简介 ............................................... 4 2.1.1 开发工具 ..................................................... 4 2.1.2 开发环境 ..................................................... 5 2.2 ANDROID SDK常见公共类库介绍 ..................................... 6 2.2.1 Android的传感器 ............................................. 6 2.2.2 Android界面Activity介绍 ................................... 6 3.系统需求分析 ........................................................ 8 3.1 可行性研究 ...................................................... 8 3.1.1 经济可行性 .................................................. 8 3.1.2 技术可行性 .................................................. 8 3.1.3 操作可行性 .................................................. 9 3.2 性能需求分析 ................................................... 10 3.2.1 实用性原则 ................................................. 10 3.2.2 可扩展性与可维护性原则 ..................................... 10 3.2.3 安全可靠性原则 ............................................. 11 3.2.4 用户界面美观原则 ........................................... 11 3.3 数据需求分析 ................................................. 13 4.系统设计 ........................................................... 14 4.1 系统总体结构设计 ............................................... 14 4.2 系统静态模型设计 ............................................. 15 5.系统实现 ........................................................... 16 5.1布局界面的设计 .................................................. 16 5.1.1主界面的设计 ................................................ 16
III
5.1.2设置界面的设计 .............................................. 17 5.2 各功能的实现 ................................................... 18 5.2.1 计步开始及暂停 ............................................. 18 5.2.2 记录数据清零 ............................................... 18 5.2.3 设置步长 .................................................... 18 5.2.4 设置体重 .................................................... 19 5.2.5 设置运动状态 ................................................ 19 6.系统测试 ........................................................... 20 6.1 测试开始停止模块 ............................................... 20 6.1.1 测试准备 .................................................... 20 6.1.2测试过程 .................................................... 20 6.2 测试总结 ....................................................... 23 5.结论 .............................................................. 24 致谢 ................................................................. 25 参考文献 ............................................................. 26 附录 ................................................................. 27
IV