blob: 03a88c9fdccb868426b3c54f2c22b663cdab72bc [file] [log] [blame]
Daniel Stenberg1c0c8612002-05-17 12:22:24 +00001/***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
9 *
10 * Copyright (C) 2002 Robert E. Hak
11 *
Daniel Stenberg2acc0ac2008-06-28 18:10:04 +000012 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
Daniel Stenberg1c0c8612002-05-17 12:22:24 +000016 *
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
19 *
20 ****************************************************************************/
Markus Braunf150d992002-08-12 07:14:46 +000021#include <string.h>
Daniel Stenberg93b231c2002-09-12 13:33:59 +000022#include "lcd.h"
23#include "font.h"
Markus Braun9bf86f72002-08-09 11:57:31 +000024#include "kernel.h"
Markus Braunf150d992002-08-12 07:14:46 +000025#include "rtc.h"
Uwe Freese012d1d52002-12-18 18:47:11 +000026#include "powermgmt.h"
Daniel Stenberg1c0c8612002-05-17 12:22:24 +000027
Markus Braun22a7a2d2002-10-14 12:50:20 +000028#include "settings.h"
29
Björn Stenberg51b45d52008-10-15 06:38:51 +000030#include "metadata.h"
Daniel Stenberg1c0c8612002-05-17 12:22:24 +000031#include "icons.h"
32
Jens Arnold638dd672004-07-19 21:46:37 +000033const unsigned char bitmap_icons_5x8[][5] =
Markus Braunde8fbf02002-08-07 10:35:26 +000034{
Michael Sevakis0f5cb942006-11-06 18:07:30 +000035 [Icon_Lock_Main] =
36 {0x78, 0x7f, 0x49, 0x7f, 0x78}, /* Lock Main */
37 [Icon_Lock_Remote] =
38 {0x78, 0x7f, 0x49, 0x7f, 0x78}, /* Lock Remote */
39 [Icon_Stereo] =
40 {0x7f, 0x22, 0x1c, 0x22, 0x7f}, /* Stereo recording */
41 [Icon_Mono] =
42 {0x00, 0x1c, 0x22, 0x7f, 0x00}, /* Mono recording */
Martin Scarratt183499a2006-09-26 11:56:59 +000043#if CONFIG_CODEC != SWCODEC
Michael Sevakis0f5cb942006-11-06 18:07:30 +000044 [Icon_q] =
45 {0x1e, 0x21, 0x31, 0x21, 0x5e} /* Q icon */
Martin Scarratt183499a2006-09-26 11:56:59 +000046#endif
Markus Braunde8fbf02002-08-07 10:35:26 +000047};
48
Jens Arnold638dd672004-07-19 21:46:37 +000049const unsigned char bitmap_icons_7x8[][7] =
Markus Braunde8fbf02002-08-07 10:35:26 +000050{
Björn Stenbergb7638222002-10-08 10:10:16 +000051 {0x08,0x1c,0x3e,0x3e,0x3e,0x14,0x14}, /* Power plug */
Jens Arnold97a80492005-06-23 02:18:29 +000052 {0x1c,0x14,0x3e,0x2a,0x22,0x1c,0x08}, /* USB plug */
Björn Stenbergb7638222002-10-08 10:10:16 +000053 {0x01,0x1e,0x1c,0x3e,0x7f,0x20,0x40}, /* Speaker mute */
54 {0x00,0x7f,0x7f,0x3e,0x1c,0x08,0x00}, /* Play */
55 {0x7f,0x7f,0x7f,0x7f,0x7f,0x7f,0x7f}, /* Stop */
56 {0x00,0x7f,0x7f,0x00,0x7f,0x7f,0x00}, /* Pause */
57 {0x7f,0x3e,0x1c,0x7f,0x3e,0x1c,0x08}, /* Fast forward */
58 {0x08,0x1c,0x3e,0x7f,0x1c,0x3e,0x7f}, /* Fast backward */
59 {0x1c,0x3e,0x7f,0x7f,0x7f,0x3e,0x1c}, /* Record */
60 {0x1c,0x3e,0x7f,0x00,0x7f,0x3e,0x1c}, /* Record pause */
Anton Oleynikov2c836342005-11-19 20:45:32 +000061 {0x40,0xa0,0xa0,0xa0,0x7f,0x02,0x02}, /* Radio on */
62 {0x42,0xa4,0xa8,0xb0,0x7f,0x22,0x42}, /* Radio mute */
Linus Nielsen Feltzing0afe4ff2002-10-29 13:59:51 +000063 {0x44,0x4e,0x5f,0x44,0x44,0x44,0x38}, /* Repeat playmode */
64 {0x44,0x4e,0x5f,0x44,0x38,0x02,0x7f}, /* Repeat-one playmode */
Björn Stenbergb7638222002-10-08 10:10:16 +000065 {0x3e,0x41,0x51,0x41,0x45,0x41,0x3e}, /* Shuffle playmode (dice) */
66 {0x04,0x0c,0x1c,0x3c,0x1c,0x0c,0x04}, /* Down-arrow */
67 {0x20,0x30,0x38,0x3c,0x38,0x30,0x20}, /* Up-arrow */
Anton Oleynikov2c836342005-11-19 20:45:32 +000068 {0x7f,0x04,0x4e,0x5f,0x44,0x38,0x7f} /* Repeat-AB playmode */
Markus Braunde8fbf02002-08-07 10:35:26 +000069};
70
Michael Sevakis0f5cb942006-11-06 18:07:30 +000071#if CONFIG_CODEC == SWCODEC && defined(HAVE_RECORDING)
72const unsigned char bitmap_glyphs_4x8[][4] =
Martin Scarratt617b67e2006-09-02 17:30:30 +000073{
Michael Sevakis0f5cb942006-11-06 18:07:30 +000074 /* Keep digits together and first! */
75 [0] =
76 {0x00, 0x3e, 0x22, 0x3e}, /* 0 */
77 [1] =
78 {0x00, 0x24, 0x3e, 0x20}, /* 1 */
79 [2] =
80 {0x00, 0x3a, 0x2a, 0x2e}, /* 2 */
81 [3] =
82 {0x00, 0x22, 0x2a, 0x36}, /* 3 */
83 [4] =
84 {0x00, 0x0e, 0x08, 0x3e}, /* 4 */
85 [5] =
86 {0x00, 0x2e, 0x2a, 0x3a}, /* 5 */
87 [6] =
88 {0x00, 0x3e, 0x2a, 0x3a}, /* 6 */
89 [7] =
90 {0x00, 0x02, 0x02, 0x3e}, /* 7 */
91 [8] =
92 {0x00, 0x3e, 0x2a, 0x3e}, /* 8 */
93 [9] =
94 {0x00, 0x0e, 0x0a, 0x3e}, /* 9 */
95 [10 ... Glyph_4x8Last-1] =
96 {0x00, 0x00, 0x00, 0x00}, /* auto-blank */
97 [Glyph_4x8_k] =
98 {0x00, 0x3e, 0x10, 0x28}, /* k */
Martin Scarratt617b67e2006-09-02 17:30:30 +000099};
Martin Scarrattd7fa5692006-09-12 18:26:27 +0000100
Michael Sevakis0f5cb942006-11-06 18:07:30 +0000101const unsigned char bitmap_formats_18x8[Format_18x8Last][18]=
Martin Scarrattd7fa5692006-09-12 18:26:27 +0000102{
Michael Sevakis0f5cb942006-11-06 18:07:30 +0000103 [0 ... Format_18x8Last-1] = /* auto-blank */
104 {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
105 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, /* ___ */
Michael Sevakis0729b922006-11-24 19:49:04 +0000106 [Format_18x8_AIFF] =
107 {0x00, 0x3c, 0x0a, 0x0a, 0x0a, 0x3c, 0x00, 0x3e, 0x00,
108 0x3e, 0x0a, 0x02, 0x02, 0x00, 0x3e, 0x0a, 0x02, 0x02}, /* AIFF */
Michael Sevakis0f5cb942006-11-06 18:07:30 +0000109 [Format_18x8_MPA_L3] =
110 {0x00, 0x3e, 0x04, 0x08, 0x04, 0x3e, 0x00, 0x00, 0x00,
111 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, /* M__ */
112 [Format_18x8_WAVPACK] =
113 {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x20,
114 0x18, 0x20, 0x1e, 0x00, 0x0e, 0x10, 0x20, 0x10, 0x0e}, /* _WV */
115 [Format_18x8_PCM_WAV] =
116 {0x00, 0x1e, 0x20, 0x18, 0x20, 0x1e, 0x00, 0x3c, 0x0a,
117 0x0a, 0x0a, 0x3c, 0x00, 0x0e, 0x10, 0x20, 0x10, 0x0e}, /* WAV */
Martin Scarrattd7fa5692006-09-12 18:26:27 +0000118};
Michael Sevakis0f5cb942006-11-06 18:07:30 +0000119#endif /* CONFIG_CODEC == SWCODEC && defined(HAVE_RECORDING) */
Martin Scarrattd7fa5692006-09-12 18:26:27 +0000120
Jörg Hohensohnf5e7a762005-03-01 22:55:52 +0000121/* Disk/MMC activity */
Jens Arnold548755a2005-11-24 00:10:14 +0000122const unsigned char bitmap_icon_disk[12] =
Jens Arnold3867cf92008-06-27 21:40:06 +0000123#ifdef HAVE_FLASH_STORAGE
Jörg Hohensohnf5e7a762005-03-01 22:55:52 +0000124 {0x15,0x3f,0x7d,0x7B,0x77,0x67,0x79,0x7b,0x57,0x4f,0x47,0x7f};
Jens Arnold548755a2005-11-24 00:10:14 +0000125#else
Jens Arnoldce05add2007-04-15 22:16:28 +0000126 {0x00,0x00,0x00,0x1c,0x2e,0x4f,0x77,0x79,0x3a,0x1c,0x00,0x00};
Jens Arnold548755a2005-11-24 00:10:14 +0000127#endif
Jörg Hohensohnf5e7a762005-03-01 22:55:52 +0000128