The first stage of the training project: based on the storage card music player V06
(1) Functional requirements It is added
on the basis of the card-based music player V0.5. This section is independently completed by the teacher. I have summarized the following knowledge points:
1. The data source comes from the media library audio
2. List music files (album cover picture, music name, artist, playing time)
3. The music list can be sorted by music identifier, title or playing time
4. Use the custom Service class to realize the playback and pause of music and the update of the progress
5. Communication between the interface class (Activity) and the service class (Service) through broadcast receivers
6. The main interface includes playlists, set play mode, display current music name, drag bar display and set play progress, display play progress value and play duration, include previous button, next button, play|pause button
(2) Operation effect
Authorize access to the external memory card in the project manifest file, set the application icon,
create resource file activity_splash_screen.xml,
create music name list item template music_name_list_item.xml
string resource file strings.xml,
create entity sub-package, in it Create a music entity class-Music
creates an app subpackage, and creates a music player application class in it-MusicPlayerApplication
creates an adapter subpackage, and creates a music adapter in it-MusicAdapter creates a
common application constant interface in the app subpackage-AppConstants
creates a service subpackage, Create a music play service class in it-MusicPlayService
main interface class-MainActivity
(1) Declare variables,
start the application, and check the effect