summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/as3525/sansa-m200v2
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/arm/as3525/sansa-m200v2')
-rw-r--r--firmware/target/arm/as3525/sansa-m200v2/adc-target.h24
-rw-r--r--firmware/target/arm/as3525/sansa-m200v2/backlight-target.h37
-rw-r--r--firmware/target/arm/as3525/sansa-m200v2/button-m200v2.c43
-rw-r--r--firmware/target/arm/as3525/sansa-m200v2/button-target.h54
-rw-r--r--firmware/target/arm/as3525/sansa-m200v2/system-target.h28
-rw-r--r--firmware/target/arm/as3525/sansa-m200v2/timer-target.h38
6 files changed, 224 insertions, 0 deletions
diff --git a/firmware/target/arm/as3525/sansa-m200v2/adc-target.h b/firmware/target/arm/as3525/sansa-m200v2/adc-target.h
new file mode 100644
index 0000000000..bea0272496
--- /dev/null
+++ b/firmware/target/arm/as3525/sansa-m200v2/adc-target.h
@@ -0,0 +1,24 @@
+/***************************************************************************
+ * __________ __ ___.
+ * Open \______ \ ____ ____ | | _\_ |__ _______ ___
+ * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+ * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+ * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+ * \/ \/ \/ \/ \/
+ * $Id$
+ *
+ * Copyright (C) 2008 ??
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ ****************************************************************************/
+#ifndef _ADC_TARGET_H_
+#define _ADC_TARGET_H_
+
+#endif /* _ADC_TARGET_H_ */
diff --git a/firmware/target/arm/as3525/sansa-m200v2/backlight-target.h b/firmware/target/arm/as3525/sansa-m200v2/backlight-target.h
new file mode 100644
index 0000000000..9533d0a6b5
--- /dev/null
+++ b/firmware/target/arm/as3525/sansa-m200v2/backlight-target.h
@@ -0,0 +1,37 @@
+/***************************************************************************
+ * __________ __ ___.
+ * Open \______ \ ____ ____ | | _\_ |__ _______ ___
+ * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+ * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+ * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+ * \/ \/ \/ \/ \/
+ * $Id$
+ *
+ * Copyright (C) 2008 ??
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ ****************************************************************************/
+#ifndef BACKLIGHT_TARGET_H
+#define BACKLIGHT_TARGET_H
+
+static inline bool _backlight_init(void)
+{
+ return true;
+}
+
+static inline void _backlight_on(void)
+{
+}
+
+static inline void _backlight_off(void)
+{
+}
+
+#endif
diff --git a/firmware/target/arm/as3525/sansa-m200v2/button-m200v2.c b/firmware/target/arm/as3525/sansa-m200v2/button-m200v2.c
new file mode 100644
index 0000000000..cd31d06720
--- /dev/null
+++ b/firmware/target/arm/as3525/sansa-m200v2/button-m200v2.c
@@ -0,0 +1,43 @@
+/***************************************************************************
+ * __________ __ ___.
+ * Open \______ \ ____ ____ | | _\_ |__ _______ ___
+ * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+ * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+ * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+ * \/ \/ \/ \/ \/
+ * $Id$
+ *
+ * Copyright (C) 2008 by ??
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ ****************************************************************************/
+
+#include "config.h"
+#include "cpu.h"
+#include "button.h"
+#include "adc.h"
+
+void button_init_device(void)
+{
+
+}
+
+int button_read_device(void)
+{
+ int btn = BUTTON_NONE;
+
+ return btn;
+}
+
+bool button_hold(void)
+{
+ /* TODO */
+ return false;
+}
diff --git a/firmware/target/arm/as3525/sansa-m200v2/button-target.h b/firmware/target/arm/as3525/sansa-m200v2/button-target.h
new file mode 100644
index 0000000000..acf80b2ed7
--- /dev/null
+++ b/firmware/target/arm/as3525/sansa-m200v2/button-target.h
@@ -0,0 +1,54 @@
+/***************************************************************************
+ * __________ __ ___.
+ * Open \______ \ ____ ____ | | _\_ |__ _______ ___
+ * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+ * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+ * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+ * \/ \/ \/ \/ \/
+ * $Id$
+ *
+ * Copyright (C) 2007 by Dave Chapman
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ ****************************************************************************/
+
+#ifndef _BUTTON_TARGET_H_
+#define _BUTTON_TARGET_H_
+
+#include <stdbool.h>
+#include "config.h"
+
+#define HAS_BUTTON_HOLD
+
+void button_init_device(void);
+int button_read_device(void);
+bool button_hold(void);
+
+/* Main unit's buttons */
+#define BUTTON_MENU 0x00000001
+#define BUTTON_VOLUP 0x00000002
+#define BUTTON_VOLDOWN 0x00000004
+#define BUTTON_PLAYPAUSE 0x00000008
+#define BUTTON_REPEATAB 0x00000010
+#define BUTTON_LEFT 0x00000020
+#define BUTTON_RIGHT 0x00000040
+#define BUTTON_SELECT 0x00000080
+
+#define BUTTON_MAIN (BUTTON_MENU|BUTTON_VOLUP|BUTTON_VOLDOWN\
+ |BUTTON_PLAYPAUSE|BUTTON_REPEATAB|BUTTON_LEFT\
+ |BUTTON_RIGHT|BUTTON_SELECT)
+
+#define BUTTON_REMOTE 0
+
+/* Software power-off */
+#define POWEROFF_BUTTON BUTTON_MENU
+#define POWEROFF_COUNT 40
+
+#endif /* _BUTTON_TARGET_H_ */
diff --git a/firmware/target/arm/as3525/sansa-m200v2/system-target.h b/firmware/target/arm/as3525/sansa-m200v2/system-target.h
new file mode 100644
index 0000000000..b712d1c124
--- /dev/null
+++ b/firmware/target/arm/as3525/sansa-m200v2/system-target.h
@@ -0,0 +1,28 @@
+/***************************************************************************
+ * __________ __ ___.
+ * Open \______ \ ____ ____ | | _\_ |__ _______ ___
+ * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+ * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+ * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+ * \/ \/ \/ \/ \/
+ * $Id$
+ *
+ * Copyright (C) 2008 ??
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ ****************************************************************************/
+#ifndef SYSTEM_TARGET_H
+#define SYSTEM_TARGET_H
+
+#include "system-arm.h"
+
+#define CPUFREQ_MAX 250000000
+
+#endif /* SYSTEM_TARGET_H */
diff --git a/firmware/target/arm/as3525/sansa-m200v2/timer-target.h b/firmware/target/arm/as3525/sansa-m200v2/timer-target.h
new file mode 100644
index 0000000000..b81da57885
--- /dev/null
+++ b/firmware/target/arm/as3525/sansa-m200v2/timer-target.h
@@ -0,0 +1,38 @@
+/***************************************************************************
+* __________ __ ___.
+* Open \______ \ ____ ____ | | _\_ |__ _______ ___
+* Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+* Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+* Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+* \/ \/ \/ \/ \/
+* $Id$
+*
+* Copyright (C) 2008 ??
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+* KIND, either express or implied.
+*
+****************************************************************************/
+#ifndef TIMER_TARGET_H
+#define TIMER_TARGET_H
+
+bool __timer_set(long cycles, bool set);
+bool __timer_register(void);
+void __timer_unregister(void);
+
+#define __TIMER_SET(cycles, set) \
+ __timer_set(cycles, set)
+
+#define __TIMER_REGISTER(reg_prio, unregister_callback, cycles, \
+ int_prio, timer_callback) \
+ __timer_register()
+
+#define __TIMER_UNREGISTER(...) \
+ __timer_unregister()
+
+#endif /* TIMER_TARGET_H */