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



Donate

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
|-+  Rockbox Development
| |-+  New Ports
| | |-+  Cowon D2
« previous next »
  • Print
Pages: 1 ... 19 20 [21] 22 23 ... 65

Author Topic: Cowon D2  (Read 636487 times)

Offline shotofadds

  • Developer
  • Member
  • *
  • Posts: 368
Re: Cowon D2
« Reply #300 on: April 12, 2008, 02:20:15 PM »
As I understand it, the Rockbox UI already averages the battery measurements. So there's no need to do that inside the driver.

I have no particular opinion on which battery-reading method is best: we could use either of the two values from the PCF, or adc_read(1). I just used the simplest to work out, as I don't think it's too critical at the moment.

Maybe we should do some more tests....
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: Cowon D2
« Reply #301 on: April 13, 2008, 12:38:49 AM »
hey,
So I've started fiddling with the touchpad on the mr500 and have started working on the touchscreen button keymap. I've split the screen up into a 3x3 grid so we have 9 buttons (I've been told the D2 should be big enough to do the same).

attached is the patch which is mostly mr500 specifc but hopefully shows how I tihnk the touchpads should work...

there is a function set_touchpad_mode() which lets screens change between stylus and button mode. in button mode the regular leymap files will be used. in stylus mode the screen will have to figure out what the user pressed....

for the keymaps would it make sense to use one file for both touchpad targets, although it looks like we will have to add a bit of #ifdeffing for the 2 targets because the mr500 only has one real button while the d2 has 4 (the remote keymap for the mr500 will stay in a seperate file to make it a bit cleaner)?

as for the mappings themselves... this is what I have so far (and from my 30s of testing it seems to work)
up/down is top and bottom center. select is middle. cancel is bottom right, menu is top left, contect menu is hold select


edit: attachment updated to include sim fixes... the numpad buttons are used for the 9 touchpad buttons (D2 sim probably wont ocmpile with this change though....) and the sim will convert mouse -> button depending on the touchpad mode like the target should.
* touchpad.diff.txt (18.93 kB - downloaded 240 times.)
« Last Edit: April 13, 2008, 03:08:04 AM by jdgordon »
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline shotofadds

  • Developer
  • Member
  • *
  • Posts: 368
Re: Cowon D2
« Reply #302 on: April 13, 2008, 08:06:41 AM »
Yep, the D2 screen should be big enough for 9 'button' areas, assuming you don't have MASSIVE fingers. ;D

I'm not sure if combining the keymap files is a good idea - for example it should also be possible to use the D2's physical buttons to navigate menus and operate basic screens. IMHO that could lead to a huge mess of #ifdef's if and when any more touchscreen targets come along.

I think all screens (& plugins) should default to 'button' mode unless they explicitly ask for 'touch point' mode, so I'm not sure there's any need for a setting in the menus.

I'll try to concoct a D2 touchscreen driver to work with this patch over the next few days. I'm having some trouble with interrupts from the PCF chip at the moment (it all stops working after ~30 seconds) so I might need to do some creative thinking first...

ps. (minor niggle) doesn't Rockbox generally use UK English? BUTTON_CENTER grates slightly here. ;)
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: Cowon D2
« Reply #303 on: April 13, 2008, 08:27:10 AM »
well, the D2 only has 4 real buttons right? and the mr500 only has 1, so I dont think the extra ifdefs would be such a big problem (certainly less painful than keeping the touchpad keymaps in sync, which they should be).

yeah, screens should default to setting the button mode unless they are specifically set up for stylus mode.
The lists though could do with a setting to choose which mode (seen as both work now), and the wps would also need a setting (I have an idea how to do stylus mode there, and there is a patch somewhere, but its being held out of svn untill one of the targets gets playback going).

as for CENTER/RE, yes, I couldnt remember which is which... I prefer UK english also, I'll change it.
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Cowon D2
« Reply #304 on: April 13, 2008, 12:13:27 PM »
Possibly "Touchmaps" should be kept separate from "Keymaps" in some way, so the touchscreen can be kept in sync, but the buttons can be handled independently?
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: Cowon D2
« Reply #305 on: April 13, 2008, 08:31:55 PM »
not sure what you mean by that...

What I was saying is that we should force touchpad targets to have a common button mapping for the touchscreen to make everything easier.. (1 manual, 1 keymap file, easier to move between targets, etc). sure they will all have differences, but we can either use #ifdef TARGET, or use the keymap system to check for touch buttons first then move to the target keymap.c file for its real buttons (which I don't think is needed while we only have 2 touchpad targets...)
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Cowon D2
« Reply #306 on: April 13, 2008, 08:35:58 PM »
Your second suggestion is more or less what I was trying to propose. I think it's probably not a bad idea to assume we'll have more touchscreen targets (PDAs if as-an-app happens, for one), so treating the touchscreen controls as something completely separate from the keymap defines (since there's really only ever going to be one set of maps for the touchscreen, while physical buttons will always vary by target).
Logged

Offline linuxstb

  • Developer
  • Member
  • *
  • Posts: 1163
Re: Cowon D2
« Reply #307 on: April 13, 2008, 10:22:28 PM »
Quote from: jdgordon on April 13, 2008, 08:27:10 AM
as for CENTER/RE, yes, I couldnt remember which is which... I prefer UK english also, I'll change it.

The convention is to use US English for C symbols, and British English for user-visible text.  So in this case it should be BUTTON_CENTER (but referred to as "centre" in the manual and any LANG strings).
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: Cowon D2
« Reply #308 on: April 14, 2008, 03:36:17 AM »
did a bit more work on this today.

keymap-touchpad.c is shared and only deals with the touchpad codes.. what should happen is the action code goes through that file, then if the button hasnt been found it goes to the tartgets keymap file.. seems to work but not fully tested.
* touchpad.diff.txt (22.4 kB - downloaded 238 times.)
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline Yeeze

  • Member
  • *
  • Posts: 40
Re: Cowon D2
« Reply #309 on: April 14, 2008, 06:33:45 AM »
I am not sure but I think when talking about the controls, we might also consider "gesture" support...

There is no need to implement the recognition now, but we should think about the defines to keep them in the keymap or so...
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Cowon D2
« Reply #310 on: April 14, 2008, 06:37:39 AM »
Rockbox already has the ability for actions to be defined as "one  button preceded by another button" as far as I know. This should at least allow for very simple gestures (center to left, center to right, top-middle to center) with the 3x3 grid style button map, with a lot less work (I would *guess*) than a complex full gesture system would require, and could probably cover the majority of jobs you'd want to do with it.
Logged

Offline cybergrind

  • Member
  • *
  • Posts: 23
Re: Cowon D2
« Reply #311 on: April 14, 2008, 06:55:32 AM »
IMHO: we have combinations of two buttons (if you about keymaps), but, maybe we need more (eg. left->right gesture should contain mid-left, mid-center, mid-right or top-... or bottim-...).
more simple method - define gestures like vectors, not combinations of two or more buttons, when we have start point, angle, end-point - in simple gestures.

and conceptions with TS-buttons didn't contain such features as drag-n-drop, selection of item or selection of area... but it more simple in implementation =)
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: Cowon D2
« Reply #312 on: April 14, 2008, 07:00:28 AM »
the grid buttons are more being used to quickly get the touchpad working in all screens. If gestures happen they would most likly be done in the stylus mode, although depending on a few things simple left<->right and up<->down could work in button mode.
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Cowon D2
« Reply #313 on: April 14, 2008, 07:03:57 AM »
I think, for example, in the WPS, anything "left center" could be "seek backward" while a gesture from "center center" to "center left" could be "previous track". With a 3x3 grid, you have 12 intersections between the grid blocks. As long as you actually can treat is as _PRE so that going from one block to another works, you can add a lot of "gesture"-like functions.
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: Cowon D2
« Reply #314 on: April 14, 2008, 07:09:56 AM »
the _PRE stuff shouldnt be a problem at all... I'm more concerned with how offten the touchpad sends its buttons... I think it might actually be too slow to work reliably...

also diagnal gestures are almost certainly out of the question using this method...

shotofadds: (and really anyone i guess)... does this look workable and should it be commited? and should the BUTTON definitions be put in button.h instead of button-target.h to make sure all touchpad targets setup the correct button defines?
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

  • Print
Pages: 1 ... 19 20 [21] 22 23 ... 65
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  New Ports
| | |-+  Cowon D2
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.104 seconds with 15 queries.