summaryrefslogtreecommitdiffstats
path: root/bootloader
diff options
context:
space:
mode:
authorMarcin Bukat <marcin.bukat@gmail.com>2011-05-30 21:10:37 +0000
committerMarcin Bukat <marcin.bukat@gmail.com>2011-05-30 21:10:37 +0000
commit976a1699da373f01dabc9353b34aef261ebf740f (patch)
tree5f1649ceb51d603471e6b1cf5dcb5192626897d6 /bootloader
parent8a5a2b82fd2d35e3eb7afa8f0dc875e3874988bb (diff)
downloadrockbox-976a1699da373f01dabc9353b34aef261ebf740f.tar.gz
rockbox-976a1699da373f01dabc9353b34aef261ebf740f.tar.bz2
rockbox-976a1699da373f01dabc9353b34aef261ebf740f.zip
Rockchip rk27xx port initial commit. This is still work in progress.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29935 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'bootloader')
-rw-r--r--bootloader/SOURCES3
-rw-r--r--bootloader/rk27xx.c45
2 files changed, 48 insertions, 0 deletions
diff --git a/bootloader/SOURCES b/bootloader/SOURCES
index 3e173386e7..9448515a58 100644
--- a/bootloader/SOURCES
+++ b/bootloader/SOURCES
@@ -69,4 +69,7 @@ main-pp.c
show_logo.c
#elif defined(MPIO_HD200) || defined(MPIO_HD300)
mpio_hd200_hd300.c
+#elif defined(RK27_GENERIC)
+rk27xx.c
+show_logo.c
#endif
diff --git a/bootloader/rk27xx.c b/bootloader/rk27xx.c
new file mode 100644
index 0000000000..37778db6dc
--- /dev/null
+++ b/bootloader/rk27xx.c
@@ -0,0 +1,45 @@
+#include "config.h"
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+#include "inttypes.h"
+#include "string.h"
+#include "cpu.h"
+#include "system.h"
+#include "lcd.h"
+#include "kernel.h"
+#include "thread.h"
+#include "backlight.h"
+#include "backlight-target.h"
+#include "font.h"
+#include "common.h"
+#include "version.h"
+
+extern int show_logo( void );
+void main(void)
+{
+
+ _backlight_init();
+
+ system_init();
+ kernel_init();
+ enable_irq();
+
+ lcd_init_device();
+ _backlight_on();
+ font_init();
+ lcd_setfont(FONT_SYSFIXED);
+
+ show_logo();
+ sleep(HZ*2);
+
+ while(1)
+ {
+ reset_screen();
+ printf("GPIOA: 0x%0x", GPIO_PADR);
+ printf("GPIOB: 0x%0x", GPIO_PBDR);
+ printf("GPIOC: 0x%0x", GPIO_PCDR);
+ printf("GPIOD: 0x%0x", GPIO_PDDR);
+ sleep(HZ/10);
+ }
+}