Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search




Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Thank You for your continued support and contributions!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  User Interface and Voice
| | |-+  Bring back the button mapping of the OFW in iPod Video
« previous next »
  • Print
Pages: 1 [2]

Author Topic: Bring back the button mapping of the OFW in iPod Video  (Read 5906 times)

Offline INGRAMLI

  • Member
  • *
  • Posts: 14
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #15 on: February 03, 2009, 10:22:04 AM »
So i am finally compiled the source code....the next question is, how is build a patch from scratch? in the wiki it seems only mentioned how to add existing patches, but not making new ones :)
Logged

Offline Febs

  • Global Moderator
  • Member
  • *
  • Posts: 2701
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #16 on: February 03, 2009, 10:27:07 AM »
http://www.rockbox.org/twiki/bin/view/Main/WorkingWithPatches#Creating_A_Patch
Logged
Rockbox Forum Guidelines
The Rockbox Manual
How to Ask Questions the Smart Way
Please do not send me support questions via PM.

Offline AlexP

  • Global Moderator
  • Member
  • *
  • Posts: 3688
  • ex-BigBambi
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #17 on: February 03, 2009, 11:08:38 AM »
In your case you don't really want to create a patch, as a patch is a file that shows what source code has been changed so you can distribute it to other people.  Just edit the code that you want to change directly, and then compile.
Logged
H140, F60, S120, e260, c240, Clip, Fuze v2, Connect, MP170, Meizu M3, Nano 1G, Android

Offline cool_walking_

  • Rockbox Expert
  • Member
  • *
  • Posts: 695
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #18 on: February 03, 2009, 05:28:50 PM »
Please document problems you have solved yourself so that future forum readers can benefit.  How did you fix the "Cygwin closing itself" issue?
Logged

Offline INGRAMLI

  • Member
  • *
  • Posts: 14
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #19 on: February 03, 2009, 05:39:35 PM »
Quote from: BigBambi on February 03, 2009, 11:08:38 AM
In your case you don't really want to create a patch, as a patch is a file that shows what source code has been changed so you can distribute it to other people.  Just edit the code that you want to change directly, and then compile.
I tried to understand what is being said in the keymap-ipod.c, but i cant find those code/definitions ...for instance, what is  meant by "BUTTON_REL"? and what is "static const struct button_mapping button_context_keyboard"?The whole file seems to be a whole brunch of codes rather than a ini file that could be understood in the Windows ???

edit: cool_walking_, the problem is related to the compatibility with Windows XP Pro in Japanese, when i switched back to English OS, the problem is solved. I guess Cygwin is not being written/tested to run in OS in language other than Eng.
« Last Edit: February 03, 2009, 05:42:46 PM by INGRAMLI »
Logged

Offline AlexP

  • Global Moderator
  • Member
  • *
  • Posts: 3688
  • ex-BigBambi
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #20 on: February 03, 2009, 06:05:39 PM »
Quote from: INGRAMLI on February 03, 2009, 05:39:35 PM
I tried to understand what is being said in the keymap-ipod.c, but i cant find those code/definitions ...for instance, what is  meant by "BUTTON_REL"? and what is "static const struct button_mapping button_context_keyboard"?The whole file seems to be a whole brunch of codes rather than a ini file that could be understood in the Windows ???

Why is Windows relevant at all?  You are looking in a Rockbox source file.  Try looking at the example keymap in that folder, it explains what some of it does.
Logged
H140, F60, S120, e260, c240, Clip, Fuze v2, Connect, MP170, Meizu M3, Nano 1G, Android

Offline INGRAMLI

  • Member
  • *
  • Posts: 14
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #21 on: February 03, 2009, 11:45:02 PM »
Quote from: BigBambi on February 03, 2009, 06:05:39 PM
Quote from: INGRAMLI on February 03, 2009, 05:39:35 PM
I tried to understand what is being said in the keymap-ipod.c, but i cant find those code/definitions ...for instance, what is  meant by "BUTTON_REL"? and what is "static const struct button_mapping button_context_keyboard"?The whole file seems to be a whole brunch of codes rather than a ini file that could be understood in the Windows ???

Why is Windows relevant at all?  You are looking in a Rockbox source file.  Try looking at the example keymap in that folder, it explains what some of it does.
example keymap in which folder?i cant really see it, and the name of this file is?
Logged

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 8759
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #22 on: February 03, 2009, 11:57:01 PM »
Quote from: INGRAMLI on February 03, 2009, 11:45:02 PM
Quote from: BigBambi on February 03, 2009, 06:05:39 PM
Quote from: INGRAMLI on February 03, 2009, 05:39:35 PM
I tried to understand what is being said in the keymap-ipod.c, but i cant find those code/definitions ...for instance, what is  meant by "BUTTON_REL"? and what is "static const struct button_mapping button_context_keyboard"?The whole file seems to be a whole brunch of codes rather than a ini file that could be understood in the Windows ???

Why is Windows relevant at all?  You are looking in a Rockbox source file.  Try looking at the example keymap in that folder, it explains what some of it does.
example keymap in which folder?i cant really see it, and the name of this file is?

"keymap-newtarget.c"

(took me 10 seconds to spot looking at the folder you described.  Next time check before asking)
Logged

Offline INGRAMLI

  • Member
  • *
  • Posts: 14
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #23 on: February 04, 2009, 12:11:06 AM »
Quote from: saratoga on February 03, 2009, 11:57:01 PM
Quote from: INGRAMLI on February 03, 2009, 11:45:02 PM
Quote from: BigBambi on February 03, 2009, 06:05:39 PM
Quote from: INGRAMLI on February 03, 2009, 05:39:35 PM
I tried to understand what is being said in the keymap-ipod.c, but i cant find those code/definitions ...for instance, what is  meant by "BUTTON_REL"? and what is "static const struct button_mapping button_context_keyboard"?The whole file seems to be a whole brunch of codes rather than a ini file that could be understood in the Windows ???

Why is Windows relevant at all?  You are looking in a Rockbox source file.  Try looking at the example keymap in that folder, it explains what some of it does.
example keymap in which folder?i cant really see it, and the name of this file is?

"keymap-newtarget.c"

(took me 10 seconds to spot looking at the folder you described.  Next time check before asking)
i can find this document, but it does not give explanation on the code that i asked above in plain language, for instance,

#include "config.h"
#include "action.h"
#include "button.h"

".........In ../action.h there is an enum with all the used ACTION_ codes......"
what is "enum"? and like this one,

"static const struct button_mapping button_context_standard"
i have totally no idea what does it mean, please, i want some explanations that can be read by non-programmers  :'(
Logged

Offline GodEater

  • Member
  • *
  • Posts: 2829
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #24 on: February 04, 2009, 02:24:56 AM »
There are no explanations that can be read by non-programmers, since what you're doing by editting that file is called "programming", which makes you a programmer.

What I understand from your posts is that you have no experience of C - and therefore need to go and read up on it. The Rockbox forums are not the place to teach you the basics of C programming. We can help with Rockbox specific stuff - but the questions you're asking are extremely basic - not specific to Rockbox yet.
Logged

Read The Manual Please

Offline INGRAMLI

  • Member
  • *
  • Posts: 14
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #25 on: February 04, 2009, 02:37:20 AM »
Quote from: GodEater on February 04, 2009, 02:24:56 AM
There are no explanations that can be read by non-programmers, since what you're doing by editting that file is called "programming", which makes you a programmer.

What I understand from your posts is that you have no experience of C - and therefore need to go and read up on it. The Rockbox forums are not the place to teach you the basics of C programming. We can help with Rockbox specific stuff - but the questions you're asking are extremely basic - not specific to Rockbox yet.
I understand that i do not have the basic knowledge to do programming, but i am only one step away from my target. Can u do me a favor by telling me which code is the one that takes the screen back to the folder where the song is previous chosen from the WPS(what i mean is, when the select button is chosen, the screen back to that song folder, and that is the one that i want to change in the keymap-ipod.c :)
Logged

Offline bluebrother

  • Developer
  • Member
  • *
  • Posts: 3362
  • creature
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #26 on: February 04, 2009, 02:40:11 AM »
Quote from: INGRAMLI on February 04, 2009, 02:37:20 AM
I understand that i do not have the basic knowledge to do programming, but i am only one step away from my target.
What makes you so sure about this claim?
Logged
Rockbox Utility development binaries (updated infrequently) · How to ask questions the smart way · We do not estimate timeframes.

Offline INGRAMLI

  • Member
  • *
  • Posts: 14
Re: Bring back the button mapping of the OFW in iPod Video
« Reply #27 on: February 04, 2009, 02:46:08 AM »
Quote from: bluebrother on February 04, 2009, 02:40:11 AM
Quote from: INGRAMLI on February 04, 2009, 02:37:20 AM
I understand that i do not have the basic knowledge to do programming, but i am only one step away from my target.
What makes you so sure about this claim?
because i managed to go one level up in the folder using button_menu instead of the default button_left (except in WPS), therefore i guess all i need is the code that have effect in the WPS which has button_select as default.

edit: finally i put an end to the quest.........here's what i have changed:

static const struct button_mapping button_context_standard[]  =
{ ACTION_STD_CANCEL,        BUTTON_MENU,                        BUTTON_NONE }



static const struct button_mapping button_context_wps[]  =
{ ACTION_WPS_BROWSE,    BUTTON_MENU|BUTTON_REL,             BUTTON_MENU },
    { ACTION_WPS_CONTEXT,   BUTTON_SELECT|BUTTON_REPEAT,        BUTTON_SELECT },
    { ACTION_WPS_MENU,          BUTTON_SELECT|BUTTON_REL,         BUTTON_SELECT },
    { ACTION_WPS_QUICKSCREEN,   BUTTON_MENU|BUTTON_REPEAT,      BUTTON_MENU },

the process is similar to reverse engineering, since i got virtually no knowledge related to C programming nor rockbox though... ;D
« Last Edit: February 04, 2009, 03:12:45 AM by INGRAMLI »
Logged

  • Print
Pages: 1 [2]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  User Interface and Voice
| | |-+  Bring back the button mapping of the OFW in iPod Video
 

  • SMF 2.0.6 | SMF © 2013, Simple Machines
  • XHTML
  • RSS
  • WAP2

Page created in 0.138 seconds with 66 queries.