1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2002 by Linus Nielsen Feltzing
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
27 #include "mp3_playback.h"
31 #include "statusbar.h"
33 #include "timefuncs.h"
35 #ifdef HAVE_LCD_BITMAP
39 #include "powermgmt.h"
42 #if CONFIG_KEYPAD == IRIVER_H100_PAD
49 #if defined(HAVE_RECORDING) && CONFIG_CODEC == SWCODEC
50 #include "pcm_record.h"
53 enum playmode ff_mode
;
55 void status_init(void)
60 void status_set_ffmode(enum playmode mode
)
62 ff_mode
= mode
; /* Either STATUS_FASTFORWARD or STATUS_FASTBACKWARD */
65 enum playmode
status_get_ffmode(void)
67 /* only use this function for STATUS_FASTFORWARD or STATUS_FASTBACKWARD */
68 /* use audio_status() for other modes */
72 int current_playmode(void)
74 int audio_stat
= audio_status();
76 /* ff_mode can be either STATUS_FASTFORWARD or STATUS_FASTBACKWARD
77 and that supercedes the other modes */
81 if(audio_stat
& AUDIO_STATUS_PLAY
)
83 if(audio_stat
& AUDIO_STATUS_PAUSE
)
90 if(audio_stat
& AUDIO_STATUS_RECORD
)
92 if(audio_stat
& AUDIO_STATUS_PAUSE
)
93 return STATUS_RECORD_PAUSE
;
100 audio_stat
= get_radio_status();
101 if(audio_stat
& FMRADIO_PLAYING
)
104 if(audio_stat
& FMRADIO_PAUSED
)
105 return STATUS_RADIO_PAUSE
;
111 #if defined(HAVE_LCD_CHARCELLS)
117 void status_set_record(bool b
)
122 void status_set_audio(bool b
)
127 void status_set_param(bool b
)
132 void status_set_usb(bool b
)
137 #endif /* HAVE_LCD_CHARCELLS */