add global proxy / cache settings to httpget class. This removes the need of passing...
[Rockbox.git] / firmware / export / hwcompat.h
blob52232c9cc8b31e175b94511063641d176ddc0e37
1 /***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
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 ****************************************************************************/
19 #ifndef HWCOMPAT_H
20 #define HWCOMPAT_H
22 #include <stdbool.h>
23 #include "config.h"
25 #if (CONFIG_CPU == SH7034) && !defined(SIMULATOR)
27 #define ROM_VERSION (*(short *)0x020000fe)
29 /* Bit mask values for HW compatibility */
30 #define ATA_ADDRESS_200 0x0100
31 #define USB_ACTIVE_HIGH 0x0100
32 #define PR_ACTIVE_HIGH 0x0100
33 #define LCD_CONTRAST_BIAS 0x0200
34 #define MMC_CLOCK_POLARITY 0x0400
35 #define TUNER_MODEL 0x0800
37 #ifdef ARCHOS_PLAYER
38 #define HW_MASK 0
39 #else /* Recorders, Ondios */
40 #define HW_MASK (*(short *)0x020000fc)
41 #endif
43 #ifdef CONFIG_TUNER_MULTI
44 static inline int tuner_detect_type(void)
46 return (HW_MASK & TUNER_MODEL) ? TEA5767 : S1A0903X01;
48 #endif
50 #endif /* (CONFIG_CPU == SH7034) && !SIMULATOR */
52 #ifdef ARCHOS_PLAYER
53 bool is_new_player(void);
54 #endif
56 #ifdef IPOD_ARCH
57 #ifdef IPOD_VIDEO
58 #ifdef BOOTLOADER
59 #define IPOD_HW_REVISION (*((unsigned long*)(0x0000405c)))
60 #else /* ROM is remapped */
61 #define IPOD_HW_REVISION (*((unsigned long*)(0x2000405c)))
62 #endif
63 #else /* !IPOD_VIDEO */
64 #ifdef BOOTLOADER
65 #define IPOD_HW_REVISION (*((unsigned long*)(0x00002084)))
66 #else /* ROM is remapped */
67 #define IPOD_HW_REVISION (*((unsigned long*)(0x20002084)))
68 #endif
69 #endif /* !IPOD_VIDEO */
70 #endif /* IPOD_ARCH */
72 #endif /* HWCOMPAT_H */