Design and Implementation for a MP3 Player Based on Embeded Linux
A Dissertation Submitted to Nanjing Institute of Technology
For the Academic Degree of Bachelor of Science
By MinXian Zheng
Supervised by
Lecturer AiJun Sha
KangNi College Nanjing Institute of Technology
Jun 2013
摘 要
伴随嵌入式系统的持续发展以及普通用户对多媒体应用越来越旺盛的需求,具有多媒体播放功能设备逐渐成为嵌入式系统中必不可少的重要功能。此毕业设计将设计一个基于嵌入式Linux的MP3播放器,系统硬件采用基于ARM架构的开发板。
论文首先介绍了嵌入式操作系统的最新发展、嵌入式Linux、ARM的特点以及Qt等的相关知识。重点介绍了如何使用开源播放器MPlayer、解码库libmad、Qt Creator工具来开发一个有图形界面的MP3播放器。还介绍了如何移植U-boot、Linux内核、Qt和文件系统,并在移植好之后烧写到开发板之上,得到一个能独立运行在开发板上的MP3播放器。
系统测试表明,该MP3播放器能实现如下功能:“播放”、“暂停”、“停止”、“音量调节”、“退出程序”和“歌曲播放时间”,系统运行稳定,基本达到了设计要求。
关键词:嵌入式Linux;移植;Linux ;Qt
Abstract
Along with the sustainable development of the embedded system and the increasingly demands for multimedia applications, an electronic equipment has a functions of playing songs gradually become indispensably.This design will introduce an implemention for a MP3 player, based on embedded Linux system and an ARM architecture development board.
This Paper introduces the latest development for embedded operating system, embedded Linux, the characteristics of the ARM, Qt and other related knowledges.Especially,this paper displays how to use the open source player MPlayer, a decoding library called libmad, Qt Creator tools to develop a graphical interface of an MP3 player.In this paper, the work of transplant the boot, the Linux kernel, Qt, and file systems is also introduced. After all system images are burned into the development board, one development board can run a MP3 player is obtained.
System test shows that this MP3 player can realize the following function:
\\,\\Control\\and \Songs Playing State\
Keywords: embeded Linux;transplant;Linux;Qt
目 录
第一章 绪 论 .................................................... 1
1.1 课题研究背景和意义 ....................................... 1 1.2 嵌入式系统发展和现状 ..................................... 2
1.2.1 嵌入式操作系统 ..................................... 2 1.2.2 嵌入式Linux和Linux ................................ 3 1.2.3 ARM的介绍 .......................................... 3 1.2.4 Qt的介绍 ........................................... 4 1.3 论文所做的工作和结构 ..................................... 5
1.3.1 论文所做的工作 ..................................... 5 1.3.2 论文结构 ........................................... 6
第二章 系统总体方案设计 ......................................... 7
2.1 系统框架概述 ............................................. 7 2.2 开发板硬件介绍 ........................................... 7
2.2.1 主要硬件及其参数 ................................... 8 2.2.2 接口资源 ........................................... 8 2.2.3 NAND和NOR Flash的相关介绍: ....................... 9 2.2.4 S3C2440的启动方式说明 ............................. 10 2.3 用于本设计MP3播放器的硬件架构 .......................... 10 第三章 嵌入式Linux的开发流程 ................................... 12
3.1 开发环境的搭建概述 ...................................... 12
3.1.1 硬件平台 .......................................... 12 3.1.2 软件平台 .......................................... 12 3.2 安装软件平台和搭建开发环境的步骤 ........................ 12
3.2.1 虚拟化平台的介绍与安装 ............................ 13 3.2.2 RedHat介绍及其在VMware中的安装 ................... 14 3.2.3 安装VMware Tools .................................. 16
3.2.4 安装交叉编译器 .................................... 17 3.3 Bootloader和U-boot的介绍 ........................... 18 3.3.1 烧写U-boot ........................................ 19 3.3.2 向NAND Flash烧写U-boot ........................... 21 3.4 使用FTP下载工具 ........................................ 23 第四章 系统详细设计 ............................................. 24
4.1 关于移植的原理和介绍 .................................... 24 4.2 U-boot、内核和文件系统的移植。 .......................... 24 4.3 开源播放软件MPlayer的安装和移植 ........................ 25
4.3.1 在X86平台上安装MPlayer ........................... 25 4.3.2 向ARM平台移植MPlayer ............................. 26 4.4 设计基于Qt/E的播放器图形 ............................... 30
4.4.1 Qt的实现原理和优势 ................................ 30 4.4.2利用Qt Creator 开发应用程序流程 ................... 32 4.4.3 程序模块间关系图 .................................. 33 4.4.4 程序的编写和实现 .................................. 33 4.4.5 关键代码分析 ...................................... 35 4.4.5 编译和运行 ........................................ 41
第五章 系统调试和解决 ........................................... 43
5.1 系统调试及运行 .......................................... 43 5.2 本次毕业设计中遇到的问题和解决 .......................... 44 第六章 总结与展望 ............................................... 46 参考文献 ........................................................ 47 致谢 ............................................ 错误!未定义书签。 附录 A 源代码 ................................................... 48
附录A.1 main.cpp ............................................ 48 附录A.2 mplayer.h ........................................... 48 附录A.3 mplayer.cpp ......................................... 49
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说综合文库基于嵌入式Linux的MP3播放器的设计与实现毕业设计论文在线全文阅读。
相关推荐: