Archive:MINIX A2: Difference between revisions
No edit summary |
mNo edit summary |
||
(19 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
{| | {| | ||
|- | |- | ||
| [[File:a2.png|400px]] || | | [[File:a2.png|400px]] || [[File:back_face_a2.png|550px]]<br/>This is the MINIX NEO A2 Remote.<br /> | ||
It has a full QWERTY keyboard on the back, which allows the use of the '''Search''' function in KODI.<br/> | |||
As much as we would like every button to work 'out of the box', we need to make changes to the keymaps files for several of the front facing buttons<br/> | |||
This task is necessary for the majority of RF remotes on the market.<br/> | |||
<br/> | |||
Keystrokes sent were discovered by enabling KODI's debugging feature, and monitoring the debug log<br /> | |||
The Actions associated with each button are completely within the user's discretion.<br /> | The Actions associated with each button are completely within the user's discretion.<br /> | ||
The example keymaps shown are only one possible permutation | The example keymaps shown are only one possible permutation | ||
Line 9: | Line 13: | ||
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
! Button !! Keycode !! | ! Button !! Keycode !! key name !! Desired KODI action !! keymap file !! keymaps entry(s) !! Notes | ||
|- | |- | ||
| [[File:b0.png|70px]] || | | [[File:b0.png|70px]] || 0xf0de || power || Power Menu || keyboard.xml || <power>ActivateWindow(shutdownmenu)</power> ||'''Works by default''' | ||
|- | |- | ||
| [[File:b00.png|70px]] || | | [[File:b00.png|70px]] || 0xf0b7 || volume_mute || Mute || keyboard.xml || <volume_mute>Mute</volume_mute> ||'''Works by default''' | ||
|- | |- | ||
| [[File:b1.png|70px]] || | | [[File:b1.png|70px]] || || || || || || Sends signal, but not recognized by KODI | ||
|- | |- | ||
| [[File:b2.png|70px]] || | | [[File:b2.png|70px]] || 0xf091 || F2 || Next Subtitle || keyboard.xml || <F2>NextSubtitle</F2>|| | ||
|- | |- | ||
| [[File:b3.png|70px]] || | | [[File:b3.png|70px]] || 0xf088 || home || Next Audio Language || keyboard.xml || <home>AudioNextLanguage</home>|| | ||
|- | |- | ||
| [[File:b_up.png|70px]] || | | [[File:b_up.png|70px]] || 0xf080 || up || Navigate Up || keyboard.xml || <up>Up</up>||'''Works by default''' | ||
|- | |- | ||
| [[File:b4.png|70px]] || | | [[File:b4.png|70px]] || || leftclick || Select || mouse.xml || <leftclick>Select</leftclick><br /><mousedragend>Select</mousedragend>||available starting in version 15 | ||
|- | |- | ||
| [[File:b_down.png|70px]] || | | [[File:b_down.png|70px]] || 0xf081 || down || Navigate down || keyboard.xml ||<down>Down</down> ||'''Works by default''' | ||
|- | |- | ||
| [[File:b_left.png|70px]] || | | [[File:b_left.png|70px]] || 0xf082 || left || Navigate Left || keyboard.xml ||<left>Left</left> ||'''Works by default''' | ||
|- | |- | ||
| [[File:b_right.png|70px]] || | | [[File:b_right.png|70px]] || 0xf083 || right || Navigate Right || keyboard.xml ||<right>Right</right> ||'''Works by default''' | ||
|- | |- | ||
| [[File:b5.png|70px]] || | | [[File:b5.png|70px]] || || rightclick || Back || mouse.xml || <rightclick>Back</rightclick><br /><mouserdragend>Back</mouserdragend>||available starting in version 15 | ||
|- | |- | ||
| [[File:b7.png|70px]] || | | [[File:b7.png|70px]] || 0xf00d || return || Search menu ||keyboard.xml ||<return>SendClick(8)</return> || Compromised choice, unfortunately a duplicate of this key<br/>exists on the back of the remote. Both keys are affected by custom keymap entry | ||
|- | |- | ||
| [[File:b6.png|70px]] || -- || -- || || || ||This button only<br />Enables/disables the Air-mouse | | [[File:b6.png|70px]] || -- || -- || || || ||This button only<br />Enables/disables the Air-mouse | ||
|- | |- | ||
| [[File:b9.png|70px]] || | | [[File:b9.png|70px]] || 0xf0b8 || volume_down || Volume Down || keyboard.xml || <volume_down>VolumeDown</volume_down>|| '''Works by default''' | ||
|- | |- | ||
| [[File:b8.png|70px]] || | | [[File:b8.png|70px]] || 0xf090 || F1 || Stop Playback || keyboard.xml || <F1>Stop</F1>|| | ||
|- | |- | ||
| [[File:b10.png|70px]] || | | [[File:b10.png|70px]] || 0xf0b9 || volume_up || Volume Up || keyboard.xml || <volume_up>VolumeDown</volume_up>|| '''Works by default''' | ||
|- | |- | ||
| [[File:b_11.png|70px]] || | | [[File:b_11.png|70px]] || 0xf0bb || prev_track || Page Up || keyboard.xml ||<prev_track>PageUp</prev_track> || | ||
|- | |- | ||
| [[File:b_12.png|70px]] || | | [[File:b_12.png|70px]] || 0xf0bd || play_pause || Pause / Play || keyboard.xml || <play_pause>PlayPause</play_pause> || '''Works by default''' | ||
|- | |- | ||
| [[File:b_13.png|70px]] || | | [[File:b_13.png|70px]] || 0xf0ba || next_track || Page Down || keyboard.xml || <next_track>PageDown</next_track> || | ||
|} | |} | ||
== Customized MINIX NEO A2 mouse.xml == | |||
<keymap> | |||
<global> | |||
<mouse> | |||
<leftclick>Select</leftclick> | |||
<rightclick>Back</rightclick> | |||
<middleclick>noop</middleclick> | |||
<doubleclick id="0">noop</doubleclick> | |||
<longclick id="0">noop</longclick> | |||
<wheeldown>noop</wheeldown> | |||
<wheelup>noop</wheelup> | |||
<mousedrag>noop</mousedrag> | |||
<mousemove>noop</mousemove> | |||
<mousedragend>Select</mousedragend> | |||
<mouserdragend>Back</mouserdragend> | |||
</mouse> | |||
</global> | |||
</keymap> | |||
== Customized MINIX NEO A2 keyboard.xml (additions)== | |||
If there are multiple keymap entries for the same key name, the last entry wins.<br/> | |||
I recommend placing manual entries at the end of the <keyboard> stanza inside <global><br /> | |||
This saves us the effort of finding and editing each original key assignment | |||
.... | |||
<F2>NextSubtitle</F2> | |||
<home>AudioNextLanguage</home> | |||
<return>SendClick(8)</return> | |||
<F1>Stop</F1> | |||
<prev_track>PageUp</prev_track> | |||
<next_track>PageDown</next_track> | |||
</keyboard> | |||
</global> | |||
.... | |||
== keyboard.xml per Window customization == | |||
Another valuable tool when editing '''keyboard.xml''': there are subsections which allow you to re-assign keys while in a particular 'Window'. <br/> For example let's look this default entry: | |||
.... | |||
<FullscreenVideo> | |||
<keyboard> | |||
.... | |||
<return>OSD</return> | |||
.... | |||
</keyboard> | |||
</FullscreenVideo> | |||
.... | |||
While a video is playing (fullscreen) the <return> key will bring up the OSD, instead of executing SendClick(8) as assigned in <global><br/> | |||
If this behaviour is not desired, an additional manual entry is required in the relevant subsection.<br/><br/> | |||
== keyboard.xml per Window customization, refining remote actions == | |||
Earlier I reassigned the <return> key within the <global> section of keyboard.xml.<br/> | |||
This had one negative side effect: After manually entering text, pressing <return> would not submit the text.<br/> | |||
[[File:VirtualKeyboard_window.png|350px]] | |||
The solution is to modify the action of the <return> key while in the '''VirtualKeyboard''' Window.<br/> | |||
Add one line to the <VirtualKeyboard> section of '''keyboard.xml'''<br/> | |||
.... | |||
<VirtualKeyboard> | |||
<keyboard> | |||
.... | |||
<return>Select</return> | |||
.... | |||
</keyboard> | |||
</VirtualKeyboard> | |||
.... | |||
== remote.conf example for amlogic boxes == | |||
/etc/amremote/remote.conf | |||
Example settings needed to map the power button (note - this only applies once the device has booted, the initial power on detection appears to be in hardware) | |||
.... | |||
factory_code = 0xfe010001 | |||
key_begin | |||
0x18 116 # power | |||
key_end | |||
.... |
Latest revision as of 02:44, 10 September 2020
Customized MINIX NEO A2 mouse.xml
<keymap> <global> <mouse> <leftclick>Select</leftclick> <rightclick>Back</rightclick> <middleclick>noop</middleclick> <doubleclick id="0">noop</doubleclick> <longclick id="0">noop</longclick> <wheeldown>noop</wheeldown> <wheelup>noop</wheelup> <mousedrag>noop</mousedrag> <mousemove>noop</mousemove> <mousedragend>Select</mousedragend> <mouserdragend>Back</mouserdragend> </mouse> </global> </keymap>
Customized MINIX NEO A2 keyboard.xml (additions)
If there are multiple keymap entries for the same key name, the last entry wins.
I recommend placing manual entries at the end of the <keyboard> stanza inside <global>
This saves us the effort of finding and editing each original key assignment
.... <F2>NextSubtitle</F2> <home>AudioNextLanguage</home> <return>SendClick(8)</return> <F1>Stop</F1> <prev_track>PageUp</prev_track> <next_track>PageDown</next_track> </keyboard> </global> ....
keyboard.xml per Window customization
Another valuable tool when editing keyboard.xml: there are subsections which allow you to re-assign keys while in a particular 'Window'.
For example let's look this default entry:
.... <FullscreenVideo> <keyboard> .... <return>OSD</return> .... </keyboard> </FullscreenVideo> ....
While a video is playing (fullscreen) the <return> key will bring up the OSD, instead of executing SendClick(8) as assigned in <global>
If this behaviour is not desired, an additional manual entry is required in the relevant subsection.
keyboard.xml per Window customization, refining remote actions
Earlier I reassigned the <return> key within the <global> section of keyboard.xml.
This had one negative side effect: After manually entering text, pressing <return> would not submit the text.
The solution is to modify the action of the <return> key while in the VirtualKeyboard Window.
Add one line to the <VirtualKeyboard> section of keyboard.xml
.... <VirtualKeyboard> <keyboard> .... <return>Select</return> .... </keyboard> </VirtualKeyboard> ....
remote.conf example for amlogic boxes
/etc/amremote/remote.conf
Example settings needed to map the power button (note - this only applies once the device has booted, the initial power on detection appears to be in hardware)
.... factory_code = 0xfe010001 key_begin 0x18 116 # power key_end ....