diff options
author | Robert Kukla <roolku@rockbox.org> | 2009-12-19 19:37:06 +0000 |
---|---|---|
committer | Robert Kukla <roolku@rockbox.org> | 2009-12-19 19:37:06 +0000 |
commit | 275d960b04ea74f45e97331408644c4ec4be6d8f (patch) | |
tree | 680c10846b9c2edc7d22d038260ede19576be1f3 | |
parent | dc010201a5020b8b468a1a24a8fafb45a8986530 (diff) | |
download | rockbox-275d960b04ea74f45e97331408644c4ec4be6d8f.tar.gz rockbox-275d960b04ea74f45e97331408644c4ec4be6d8f.zip |
FS#8286 - utilise the buttons on the gigabeat cradle
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24080 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | firmware/target/arm/s3c2440/gigabeat-fx/button-meg-fx.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/firmware/target/arm/s3c2440/gigabeat-fx/button-meg-fx.c b/firmware/target/arm/s3c2440/gigabeat-fx/button-meg-fx.c index 0e69cbd420..55fdad1159 100644 --- a/firmware/target/arm/s3c2440/gigabeat-fx/button-meg-fx.c +++ b/firmware/target/arm/s3c2440/gigabeat-fx/button-meg-fx.c | |||
@@ -155,6 +155,18 @@ int button_read_device(void) | |||
155 | buttonlight_on(); | 155 | buttonlight_on(); |
156 | } | 156 | } |
157 | 157 | ||
158 | /* the cradle buttons */ | ||
159 | buttons = ~GPFDAT & 0xc0; | ||
160 | if (buttons) | ||
161 | { | ||
162 | if (buttons & (1 << 6)) | ||
163 | btn |= BUTTON_A; | ||
164 | |||
165 | if (buttons & (1 << 7)) | ||
166 | btn |= BUTTON_POWER; | ||
167 | buttonlight_on(); | ||
168 | } | ||
169 | |||
158 | return btn; | 170 | return btn; |
159 | } | 171 | } |
160 | 172 | ||