[Q] Access Cell Modem - AT&T, Rogers, Bell, Telus Samsung Galaxy S III

I have a galaxy s3 connected to centos 6. I want to access the cellular modem. I have installed the android development kit and rooted the samsung s3. I can get a root shell using 'adb shell'. I installed busybox for 'microcom' but I cant get the serial port to work.
[email protected]:/ # microcom -t 5000 -s 115200 /dev/ttyGS0
< just stalls till I type control-C>
[email protected]:/ #
[email protected]:/ # cat /proc/tty/drivers
/dev/tty /dev/tty 5 0 system:/dev/tty
/dev/console /dev/console 5 1 system:console
/dev/ptmx /dev/ptmx 5 2 system
/dev/vc/0 /dev/vc/0 4 0 system:vtmaster
rfcomm /dev/rfcomm 216 0-255 serial
g_serial /dev/ttyGS 238 0-3 serial
usbserial /dev/ttyUSB 188 0-253 serial
acm /dev/ttyACM 166 0-31 serial
msm_serial_hsl /dev/ttyHSL 244 0-2 serial
msm_serial_hs /dev/ttyHS 245 0-1 serial
pty_slave /dev/pts 136 0-1048575 pty:slave
pty_master /dev/ptm 128 0-1048575 pty:master
pty_slave /dev/ttyp 3 0-255 pty:slave
pty_master /dev/pty 2 0-255 pty:master
smd_tty_driver /dev/smd 252 0-36 serial
unknown /dev/tty 4 1-63 console
thanks,
Yile

Related

BA and synce (linux)

Hi I have a blueangel (vodafone vpx)
I cant synchronise with linux, please help me if you have an idea,
look what I did (guides from synce):
[email protected]:~ # cat /proc/bus/usb/devices > /tmp/after
-- I connected it ---
[email protected]:~ # diff /tmp/before /tmp/after
21a22,29
> T: Bus=02 Lev=02 Prnt=02 Port=03 Cnt=01 Dev#= 4 Spd=12 MxCh= 0
> D: Ver= 1.00 Cls=ff(vend.) Sub=ff Prot=ff MxPS=16 #Cfgs= 1
> P: Vendor=0bb4 ProdID=0a05 Rev= 0.00
> C:* #Ifs= 1 Cfg#= 1 Atr=c0 MxPwr= 2mA
> I: If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=ipaq
> E: Ad=81(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
> E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
>
[email protected]:~ # /sbin/modprobe ipaq
[email protected]:~ # rmmod ipaq
[email protected]:~ # modprobe ipaq
[email protected]:~ # synce-serial-config ttyUSB0
You can now run synce-serial-start to start a serial connection.
[email protected]:~ # dccm -p marcac
[email protected]:~ # synce-serial-start
synce-serial-start is now waiting for your device to connect
-- Now the device shows that it cannot connect to the computer.
synce and pda2k
This should help you, it's in catalan and I guess you won't understand the entire post, but the shell commands are easily recognised, so follow them and if you need me to translate something just ask:
http://pof.eslack.org/blog/2005/03/17/connectar-i-sincronitzar-la-pda2k-amb-linux/

NTT Hikari iFrame WDPF-701ME

This thread is about Android-based NTT Hikari iFrame WDPF-701ME.
WDPF-701ME is a 7-inch tablet with 265Mb RAM and 1Gb flash.
Although it is originally sold with a rather high price tag (24150 yen as I am writing this) it is widely available on a second hand market under 4000 yen.
NTT does distribute GPLed sources for the device which can also be downloaded at multiupload dot com slash H01S3I4YRG.
The device needs special USB cable with TTA-20 connector (COWON S9-USB CABLE fits).
When plugged it gets identified as
Code:
usb 1-1: new high speed USB device number 8 using ehci_hcd
usb 1-1: New USB device found, idVendor=18d1, idProduct=0002
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1: Product: Media Persona
usb 1-1: Manufacturer: Broadcom
usb 1-1: SerialNumber: NTTWDPF701ME
scsi5 : usb-storage 1-1:1.0
scsi 5:0:0:0: Direct-Access Broadcom Media Persona 0100 PQ: 0 ANSI: 2
sd 5:0:0:0: [sdc] Attached SCSI removable disk
Rooting is simple:
Code:
~ $ adb push rageagainstthecage-arm5.bin /dpfdata
~ $ adb shell
And then:
Code:
$ cd /dpfdata
$ chmod 755 rageagainstthecage-arm5.bin
$ ./rageagainstthecage-arm5.bin
Don't forget to fix SUID bit on su:
Code:
~ $ adb install Superuser.apk
~ $ adb shell
$ chmod 4755 /bin/su
Firmware updates come in a proprietary format. MAC address belongs to MOIMSTONE Co., LTD of Korea.
MTD layout:
Code:
Creating 14 MTD partitions on "bcm_umi-nand":
0x000000000000-0x000000080000 : "boot1"
0x000000080000-0x000000100000 : "boot2"
0x000000100000-0x000000200000 : "ctrl"
0x000000200000-0x000001200000 : "nvdata"
0x000001200000-0x000001500000 : "k0"
0x000001500000-0x000001800000 : "k1"
0x000001800000-0x000009800000 : "root0"
0x000009a00000-0x000011880000 : "root1"
0x000011880000-0x000038e80000 : "userdata"
0x000038e80000-0x000058e80000 : "dpfdata"
0x000058e80000-0x000060e80000 : "firmwarestorage"
0x000060e80000-0x000068e80000 : "factoryreset"
0x000068e80000-0x000068f00000 : "serialdata"
0x000009800000-0x000009a00000 : "vcfw"
More info later.

cm12.1-20151109-NIGHTLY-nicki: can't change ttl

hello,
I have installed CM 12.1-20151109-NIGHTLY-nicki, enabled root but can't change ttl value. Is netfilter module missing in kernel?
[email protected]:/ # grep ^ro.cm.version /system/build.prop
ro.cm.version=12.1-20151109-NIGHTLY-nicki
error example:
[email protected]:/ # iptables -t mangle -I POSTROUTING -j TTL --ttl-set 65
iptables: No chain/target/match by that name.
how to add/install the module to the android system to be able modify TTL values?
[email protected]:/ # iptables -t mangle --list|grep -i ttl
1|[email protected]:/ #
It seems to be not avaialble in the CM12.1
when I checked it on my asus zeonfon2 runing on stock Android 5.0, the module is there and I can modify TTLs.
[email protected]:/ # iptables -t mangle --list|grep -i ttl
TTL all -- anywhere anywhere TTL set to 65
TTL all -- anywhere anywhere TTL set to 65
TTL all -- anywhere anywhere TTL set to 65

Anyway to configure CEC remote commands from TV?

Hi
I love my firestick, it does so much more than what my previous raspberry pi (running kodi) could do. However one thing the pi could do was offer perfect CEC control via my TV's remote and one goal I have is to use a single (harmony) remote to control my entire AV setup.
The firestick does offer some level of CEC support but seems to vary hugely between different TVs, in my case on my Panasonic plasma tx-p42g30 I can only get the play/pause button to work (edit: the rewind, fast forward and stop buttons also work). So something is working but maybe not mapped properly?
Surely there must be somekind of file which can be edited to help map the CEC controls correctly? can anyone shed any light?
I had problems with a Panasonic TX-L37GN13 too.
CEC is called Viera-Cast on Panasonic TV's.
Perhaps we should create an topic in the developer board from amazon.
Where are you from? The US support should be much better then EU support.
Greetings by Idijt
I_did_it_just_tmrrow said:
I had problems with a Panasonic TX-L37GN13 too.
CEC is called Viera-Cast on Panasonic TV's.
Perhaps we should create an topic in the developer board from amazon.
Where are you from? The US support should be much better then EU support.
Greetings by Idijt
Click to expand...
Click to collapse
Whatever you think might get the ball rolling, it's one of those things before rooting was more accessible I'd assumed it'd be locked out feature to mod, but presumably with root it's a possibility now? I recall on the raspberry Pi i copied over a certain config file to enable additional buttons on my TV remote so hoping the same can be done.
I'm from the UK
My Panasonic XXX is currently not here.
Can you try to:
1. enable adb
2. open adb on a pc and type in
Code:
adb shell
or
Code:
adb shell
3. enable Panasonic's CEC and make sure you can use the less commands wich are usable
4a. type in shell
Code:
su
if you had root
4b. type in the shell
Code:
cat /proc/bus/input/devices
and tell us the output
5. There should be a line wich a named input, like input8 or input3.
6. type in the shell
Code:
cat THE_WHOLE_PATH_TO_THAT_INPUT_FILE
and tell us if he react if press on valid (working) buttons and non working buttons.
If there are some hieroglyphics with the non working buttons, we should be able to mention theese buttons in the right keyfiles.
Greetings by Idijt
I_did_it_just_tmrrow said:
I had problems with a Panasonic TX-L37GN13 too.
CEC is called Viera-Cast on Panasonic TV's.
Perhaps we should create an topic in the developer board from amazon.
Where are you from? The US support should be much better then EU support.
Greetings by Idijt
Click to expand...
Click to collapse
I_did_it_just_tmrrow said:
My Panasonic XXX is currently not here.
Can you try to:
1. enable adb
2. open adb on a pc and type in
Code:
adb shell
or
Code:
adb shell
3. enable Panasonic's CEC and make sure you can use the less commands wich are usable
4a. type in shell
Code:
su
if you had root
4b. type in the shell
Code:
cat /proc/bus/input/devices
and tell us the output
5. There should be a line wich a named input, like input8 or input3.
6. type in the shell
Code:
cat THE_WHOLE_PATH_TO_THAT_INPUT_FILE
and tell us if he react if press on valid (working) buttons and non working buttons.
If there are some hieroglyphics with the non working buttons, we should be able to mention theese buttons in the right keyfiles.
Greetings by Idijt
Click to expand...
Click to collapse
I've tried the commands via ADBfire and opening the adb shell - on 'su' I get a not found error (I don't have root)
On the 'cat /proc/bus/input/devices' command I get the following:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
godsakes said:
I've tried the commands via ADBfire and opening the adb shell - on 'su' I get a not found error (I don't have root)
On the 'cat /proc/bus/input/devices' command I get the following:
Click to expand...
Click to collapse
Why did you stop at Step 5?
Like I told you, do step 6,
Code:
cat /devices/virtual/input/input1
and tell us if he react if you press on valid (working) buttons and/or non working buttons.
If there are some hieroglyphics with the non working buttons, we should be able to mention theese buttons in the right keyfiles.
I can not check this before weekend.
Perhaps you dont have the right to "cat" the input1 without su/without root, but I think you should.
Greetings by Idijt
I_did_it_just_tmrrow said:
Why did you stop at Step 5?
Like I told you, do step 6,
Code:
cat /devices/virtual/input/input1
and tell us if he react if you press on valid (working) buttons and/or non working buttons.
If there are some hieroglyphics with the non working buttons, we should be able to mention theese buttons in the right keyfiles.
I can not check this before weekend.
Perhaps you dont have the right to "cat" the input1 without su/without root, but I think you should.
Greetings by Idijt
Click to expand...
Click to collapse
I'm afraid I get "no such file or directory" with that command...
Point me to the safest rooting guide and I'll give it a another try once rooted
godsakes said:
I'm afraid I get "no such file or directory" with that command...
Click to expand...
Click to collapse
Perhaps you need to mount the system partition to rw (read, write) and it is currently ro (read only).
To change this mount you need root but you should be able to read thethe read the input.
Please make again the first cat step and be sure, that you cat in the next step the right input + path from the amazon-cec device.
Perhaps the inputs are connected to devices on device startup.
godsakes said:
Point me to the safest rooting guide and I'll give it a another try once rooted
Click to expand...
Click to collapse
Point youself to the, perhaps availible, right rooting method or guide. Sorry but this is your device, you know your current stock FW and this is not the thread topic.
I own a stick with root, but hardware rooted with emmc adapter. If you life in germany or a neighbour country I can help you.
I hope we can leave this topic by its own topic
It really could be possible to add some keys from the tv remote.
Greetings by Idijt
Ok, I've since used king root to root the stick
Now when i type 'SU' the command line does indicate the user (if that's the right word?) is root
But I still get the same error... could you just double check I've done the right commands
Your commands seems to be right. I am not the 100% Linux pro but I am 80% sure that I do that on this way with a Xiaomi Bluetooth Controller.
Can list the area's?
Code:
su
ls /devices/
ls /devices/virtual/
ls /devices/virtual/input/
Each line after the other.
If that not work, tell us. You can check this too with another Input and device. Did you got always that error?
ByTheWay: you can just Copy the Text out of the shell/adb and put them here into a Code Block. This also very nice for people who are searching for some words.
Any other here who can help us?
Greetings by Idijt
I_did_it_just_tmrrow said:
Your commands seems to be right. I am not the 100% Linux pro but I am 80% sure that I do that on this way with a Xiaomi Bluetooth Controller.
Can list the area's?
Code:
su
ls /devices/
ls /devices/virtual/
ls /devices/virtual/input/
Each line after the other.
If that not work, tell us. You can check this too with another Input and device. Did you got always that error?
ByTheWay: you can just Copy the Text out of the shell/adb and put them here into a Code Block. This also very nice for people who are searching for some words.
Any other here who can help us?
Greetings by Idijt
Click to expand...
Click to collapse
same error with all 3 of those commands, I've tried a couple of variations of the previous step but again same error
Code:
[email protected]:/ $ su
su
[email protected]:/ # ls /devices/
ls /devices/
/devices/: No such file or directory
1|[email protected]:/ # ls /devices/virtual/
ls /devices/virtual/
/devices/virtual/: No such file or directory
1|[email protected]:/ # ls /devices/virtual/input/
ls /devices/virtual/input/
/devices/virtual/input/: No such file or directory
1|[email protected]:/ # cat /proc/bus/input/devices
cat /proc/bus/input/devices
I: Bus=0005 Vendor=0000 Product=0000 Version=0008
N: Name="amazon_touch"
P: Phys=
S: Sysfs=/devices/virtual/input/input0
U: Uniq=
H: Handlers=event0
B: PROP=0
B: EV=b
B: KEY=400 0 0 0 0 0 0 0 0 0 0
B: ABS=2650000 1000000
I: Bus=0003 Vendor=0000 Product=0000 Version=0001
N: Name="amazon-cec"
P: Phys=
S: Sysfs=/devices/virtual/input/input1
U: Uniq=
H: Handlers=kbd event1
B: PROP=0
B: EV=3
B: KEY=3ff 0 0 400000 2fc000 c3060 0 0 0 10004 210000 192 40000c01 9e3781 0 8010
0000 10000002
I: Bus=0005 Vendor=0000 Product=0000 Version=0008
N: Name="kcmouse"
P: Phys=
S: Sysfs=/devices/virtual/input/input2
U: Uniq=
H: Handlers=mouse0 event2
B: PROP=0
B: EV=7
B: KEY=70000 0 0 0 0 0 0 0 0
B: REL=103
[email protected]:/ # cat /devices/virtual/input/input2
cat /devices/virtual/input/input2
tmp-mksh: cat: /devices/virtual/input/input2: No such file or directory
1|[email protected]:/ # cat devices/virtual/input/input1
cat devices/virtual/input/input1
tmp-mksh: cat: devices/virtual/input/input1: No such file or directory
1|[email protected]:/ # cat //devices/virtual/input/input1
cat //devices/virtual/input/input1
tmp-mksh: cat: //devices/virtual/input/input1: No such file or directory
1|[email protected]:/ #
All u have here is
[email protected]:/ # ls -la /sys/devices/virtual/input/input1/
drwxr-xr-x root root 2016-06-23 22:39 capabilities
drwxr-xr-x root root 2016-06-23 22:39 event1
drwxr-xr-x root root 2016-06-23 22:39 id
-r--r--r-- root root 4096 2016-06-23 22:39 modalias
-r--r--r-- root root 4096 2016-06-23 22:39 name
-r--r--r-- root root 4096 2016-06-23 22:39 phys
drwxr-xr-x root root 2016-06-23 22:39 power
-r--r--r-- root root 4096 2016-06-23 22:39 properties
lrwxrwxrwx root root 2016-06-23 22:39 subsystem -> ../../../../class/input
-rw-r--r-- root root 4096 2016-06-23 22:39 uevent
-r--r--r-- root root 4096 2016-06-23 22:39 uniq
BTW.
I've also got hard times with CEC with my sammy 40c650 . Only FF and REW are recogized by AFTS .
There is clear visibility on triggered events but no visibility on direct input (lack of tool)
[email protected]:/ # getevent -li /dev/input/event1
Can't enable monotonic clock reporting: Invalid argument
add device 1: /dev/input/event1
bus: 0003
vendor 0000
product 0000
version 0001
name: "amazon-cec"
location: ""
id: ""
version: 1.0.1
events:
KEY (0001): KEY_ESC KEY_ENTER KEY_DOT KEY_F5
KEY_KPENTER KEY_UP KEY_PAGEUP KEY_LEFT
KEY_RIGHT KEY_DOWN KEY_PAGEDOWN KEY_MUTE
KEY_VOLUMEDOWN KEY_VOLUMEUP KEY_POWER KEY_PAUSE
KEY_STOP KEY_HELP KEY_MENU KEY_BACK
KEY_EJECTCD KEY_PLAYPAUSE KEY_RECORD KEY_REWIND
KEY_FASTFORWARD KEY_SOUND KEY_MEDIA KEY_UNKNOWN
KEY_OPTION* KEY_INFO KEY_FAVORITES KEY_EPG
KEY_SUBTITLE KEY_ANGLE KEY_RED KEY_GREEN
KEY_YELLOW KEY_BLUE KEY_CHANNELUP KEY_CHANNELDOWN
KEY_LAST KEY_CONTEXT_MENU KEY_NUMERIC_0 KEY_NUMERIC_1
KEY_NUMERIC_2 KEY_NUMERIC_3 KEY_NUMERIC_4 KEY_NUMERIC_5
KEY_NUMERIC_6 KEY_NUMERIC_7 KEY_NUMERIC_8 KEY_NUMERIC_9
input props:
<none>
Output on button pressing (only FF and REW give out anything)
[email protected]:/ # getevent -l /dev/input/event1
Can't enable monotonic clock reporting: Invalid argument
EV_KEY KEY_REWIND DOWN
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_REWIND UP
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_FASTFORWARD DOWN
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_FASTFORWARD UP
EV_SYN SYN_REPORT 00000000
The correct input device for cec on your FireStick is: /dev/input/event1.
If you want to change the behavior of your remote keys you can create a file named amazon-cec.kl under: /system/usr/keylayout.
However, don't know how this is on the FireTV and FireTV2. On the FireTV2 i don't get any responses using getevent and evtest and i dont own a FireTv Gen 1.
Edit:
Haven't seen the last post. Try using evtest on /dev/input/event1. It shows you the keycodes so you can assign them in the layout file.
for my old tv it would look like this:
Code:
# Copyright (C) 2010 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Custom Keylayout for Sony Bravia KDL-*EX72* cec function on FireStick
# NOTE
# This mainly mapps menu to the options button and home to the home button,
# additionaly we assign keys to the special buttons (red, blue, info etc.).
# To make our life easier we just assign F1-F7 to those keys.
# Comments contain original values as per evtest /dev/input/event1
# NOTE: F1-F7 seem to not get passed to Kodi!? As Workaround we use A-F
key 96 DPAD_CENTER #KPEnter (Real Enter)
key 103 DPAD_UP #Up
key 105 DPAD_LEFT #Left
key 106 DPAD_RIGHT #Right
key 108 DPAD_DOWN #Down
key 128 MEDIA_STOP #Stop
key 139 HOME WAKE_DROPPED #Menu
key 158 BACK WAKE_DROPPED #Back
key 164 MEDIA_PLAY_PAUSE #PlayPause
key 168 MEDIA_REWIND #Rewind
key 208 MEDIA_FAST_FORWARD #Fast Forward
key 357 MENU #Option
key 358 F #Info - KEY_INFO
key 365 E #EPG - KEY_EPG
#key 370 SUBTITLE #Subtitle - KEY_SUBTITLE
key 398 A #Red Button - KEY_RED
key 399 B #Green Button - KEY_GREEN
key 400 C #Yellow Button - KEY_YELLOW
key 401 D #Blue Button - KEY_BLUE
key 402 PAGE_UP #Channel Up
key 403 PAGE_DOWN #Channel Down
key 512 0 #Numeric 0
key 513 1 #Numeric 1
key 514 2 #Numeric 2
key 515 3 #Numeric 3
key 516 4 #Numeric 4
key 517 5 #Numeric 5
key 518 6 #Numeric 6
key 519 7 #Numeric 7
key 520 8 #Numeric 8
key 521 9 #Numeric 9
Reading the above 2 posts and using the command 'getevent -1 /dev/input/event1'
I can get some reporting - but only for the buttons already recognised (play, rewind, fastforward, stop), I also have a play/pause button on my remote but it's recognised as the same command as the play button
Code:
[email protected]:/ $ su
su
[email protected]:/ # getevent -l /dev/input/event1
getevent -l /dev/input/event1
Can't enable monotonic clock reporting: Invalid argument
EV_KEY KEY_PLAYPAUSE DOWN
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_PLAYPAUSE UP
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_REWIND DOWN
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_REWIND UP
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_STOP DOWN
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_STOP UP
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_FASTFORWARD DOWN
EV_SYN SYN_REPORT 00000000
EV_KEY KEY_FASTFORWARD UP
EV_SYN SYN_REPORT 00000000
Try using evtest and look if the keycodes are indentical or not and remap them how you like.
I dont recommend using getevent for other use than getting the correct input device. If you press some button it only shows some kind of default value for the keyevent reported from your input device.
If you use evtest on /dev/input/event1 you can see what i mean by looking at the top of the output.
@WheelchairArtist done & done
[email protected]:/ # evtest /dev/input/event1
Input driver version is 1.0.1
Input device ID: bus 0x3 vendor 0x0 product 0x0 version 0x1
Input device name: "amazon-cec"
Supported events:
Event type 0 (Sync)
Event type 1 (Key)
Event code 1 (Esc)
Event code 28 (Enter)
Event code 52 (Dot)
Event code 63 (F5)
Event code 96 (KPEnter)
Event code 103 (Up)
Event code 104 (PageUp)
Event code 105 (Left)
Event code 106 (Right)
Event code 108 (Down)
Event code 109 (PageDown)
Event code 113 (Mute)
Event code 114 (VolumeDown)
Event code 115 (VolumeUp)
Event code 116 (Power)
Event code 119 (Pause)
Event code 128 (Stop)
Event code 138 (Help)
Event code 139 (Menu)
Event code 158 (Back)
Event code 161 (EjectCD)
Event code 164 (PlayPause)
Event code 167 (Record)
Event code 168 (Rewind)
Event code 208 (Fast Forward)
Event code 213 (Sound)
Event code 226 (Media)
Event code 240 (Unknown)
Event code 357 (Option)
Event code 358 (Info)
Event code 364 (Favorites)
Event code 365 (EPG)
Event code 370 (Subtitle)
Event code 371 (Angle)
Event code 398 (Red)
Event code 399 (Green)
Event code 400 (Yellow)
Event code 401 (Blue)
Event code 402 (ChannelUp)
Event code 403 (ChannelDown)
Event code 405 (Last)
Event code 438 (?)
Event code 512 (?)
Event code 513 (?)
Event code 514 (?)
Event code 515 (?)
Event code 516 (?)
Event code 517 (?)
Event code 518 (?)
Event code 519 (?)
Event code 520 (?)
Event code 521 (?)
Testing ... (interrupt to exit)
Event: time 452.538264, type 1 (Key), code 139 (Menu), value 0
Event: time 452.538274, -------------- Report Sync ------------
Event: time 462.140498, type 1 (Key), code 139 (Menu), value 1
Event: time 462.140507, -------------- Report Sync ------------
Event: time 478.609635, type 1 (Key), code 357 (Option), value 0
Event: time 478.609643, -------------- Report Sync ------------
Event: time 490.073024, type 1 (Key), code 357 (Option), value 1
Event: time 490.073032, -------------- Report Sync ------------
Event: time 503.634929, type 1 (Key), code 357 (Option), value 0
Event: time 503.634937, -------------- Report Sync ------------
Event: time 513.041136, type 1 (Key), code 168 (Rewind), value 1
Event: time 513.041146, -------------- Report Sync ------------
Event: time 513.260947, type 1 (Key), code 168 (Rewind), value 0
Event: time 513.260955, -------------- Report Sync ------------
Event: time 514.352655, type 1 (Key), code 208 (Fast Forward), value 1
Event: time 514.352663, -------------- Report Sync ------------
Event: time 514.576434, type 1 (Key), code 208 (Fast Forward), value 0
Event: time 514.576442, -------------- Report Sync ------------
there is no amazon-cec.kl under /system/usr/keylayout/ (also tested all in https://source.android.com/devices/input/key-layout-files.html) . I've downloaded Sony Bravia amazon-cec ,rebooted and nothing changed . Also creating Vendor_0000_Product_0000_Version_0001.kl keylayout (same as detected device ) give nothing ... no new button recognized ever .
Did u gave the amazon-cec file the right permissions and set the right owner? Also make sure to not forget the .kl at the end.
Also in my file the buttons u pressed (as seen in your post) are mapped the exact same way.
You could try to switch keycodes 139 and 208 to see if the layout file works.
Just for the record, today i updated my amazon-cec.kl file because it didn't work with my new stick on android 5, maybe that was your problem with my file?
If you still need/want to remap the buttons here is the new file (removed depracted WAKE_DROPPED flag and remapped Subtitle to G):
Code:
# Copyright (C) 2010 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Custom Keylayout for Sony Bravia KDL-*EX72* cec function on FireStick
# NOTE
# This mainly mapps menu to the options button and home to the home button,
# additionaly we assign keys to the special buttons (red, blue, info etc.).
# To make our life easier we just assign F1-F8 to those keys.
# Comments contain original values as per evtest /dev/input/event1
# NOTE: F1-F8 seem to not get passed to Kodi!? As Workaround we use A-G
key 96 DPAD_CENTER #KPEnter (Real Enter)
key 103 DPAD_UP #Up
key 105 DPAD_LEFT #Left
key 106 DPAD_RIGHT #Right
key 108 DPAD_DOWN #Down
key 128 MEDIA_STOP #Stop
key 139 HOME #Menu
key 158 BACK #Back
key 164 MEDIA_PLAY_PAUSE #PlayPause
key 208 MEDIA_REWIND #Rewind
key 168 MEDIA_FAST_FORWARD #Fast Forward
key 357 MENU #Option
key 358 F #Info - KEY_INFO
key 365 E #EPG - KEY_EPG
key 370 G #Subtitle - KEY_SUBTITLE
key 398 A #Red Button - KEY_RED
key 399 B #Green Button - KEY_GREEN
key 400 C #Yellow Button - KEY_YELLOW
key 401 D #Blue Button - KEY_BLUE
key 402 PAGE_UP #Channel Up
key 403 PAGE_DOWN #Channel Down
key 512 0 #Numeric 0
key 513 1 #Numeric 1
key 514 2 #Numeric 2
key 515 3 #Numeric 3
key 516 4 #Numeric 4
key 517 5 #Numeric 5
key 518 6 #Numeric 6
key 519 7 #Numeric 7
key 520 8 #Numeric 8
key 521 9 #Numeric 9
I switched the Rewind and FastForward buttons so you can check if it gets accepted.
You could also check logcat for any hints:
Code:
logcat | grep amazon-cec

Block Device/Partition & other dev information Thread

Hi people,
I would like to collect some dev info for the M2 which may help in future development efforts - maybe tweak the official ROMs to be less idiotic, or develop new ROMs, apps, etc.
If any of you can contribute info similar to what I have shown below, it would be greatly appreciated. I will collate and analyze the info from your replies and add it to these first couple of posts so that it serves as the main repo of this dev info.
*** DISCLAIMER *** Please do not attempt to collect any info from your device if you are not confident about or familiar with how to root your device or how to use shell commands in a root terminal shell. Any and all damage you may cause to your device in the pursuit of gathering this information is solely your responsibility and I will be neither responsible nor accountable for any such damage.
Still reading? Good. I commend your enthusiasm :good:
Guide: Block Device/Partition Information
Introduction
Here are some links explaining what Android partitions are and what they do. While some of the info in the links refers to other devices or has been superseded by changes to Android since the article was written, the basic information itself holds good:
http://www.all-things-android.com/content/review-android-partition-layout
http://donandroid.com/android-partitions-sdcard-boot-recovery-cache-data-system-misc-1043
https://sites.google.com/site/tomsgt123/adb-fastboot/understanding-android
This information is important because:
It will help us to map the contents of the official UPDATE.APP to the proper locations on the ROM Storage where they must be flashed.
It will help the developers of the Huawei Update Extractor tool to create an extractor profile specific for our M2 8.0 or 10.0 devices.
EDIT: I have actually already done this for the M2-802L, see my post on the Huawei Update extractor tool thread. Now we just need to wait for worstenbrood to integrate it into a new release of the Extractor.
It will help in the development of new ROMs.
How to get the partition info on your device
Prerequisites:
Your device needs to be rooted.
You need to be able to get a root shell terminal on your phone, either using adb or using a terminal emulator app like "Termux" or "Terminal Emulator for Android". If you're going to be using a Terminal Emulator app on your phone, you'll find that the Hacker's Keyboard app will make your life much much easier when dealing with shells on the phone (ever tried to type any control character sequence at all, like CTRL+C, using all those cute fancy soft keyboards on the play store?)
You need to know how to use a terminal emulator and be comfortable with using shell commands (see Disclaimer above).
Method
Using ADB to get a root shell on your phone:
Ensure that you have the drivers for the phone installed on the computer. If not,
For Windows: just install the HiSuite app from Huawei to get the drivers. You can uninstall HiSuite immediately after it's installed (it's a useless piece of dreck, only useful for the drivers it installs) but the drivers will remain installed.
For Linux: The Android SDK for Linux should give you the generic ADB drivers. Then see this webpage for setting a proper USB device ID for Huawei devices in case you have issues. I have not yet tested this for myself, BTW.
Ensure that you have adb on your computer. If not,
For Windows: you can grab it from the Unlock guide thread.
For Linux: The Android SDK for Linux should have given you this already. If not, something is very very wrong with your universe.
Ensure that your phone is rooted. Follow the above-linked guide if you need to only if you are confident about being able to perform what's required and don't mind voiding your warranty and risking permanent damage to your phone and sanity. If your phone is not rooted, this is not going to work.
Connect your phone to the computer via USB.
Open up a command prompt. On Windows, this involves typing "cmd" in the search bar. On Linux, fire up the terminal app of your choice. I recommend gnome-terminal. Then navigate to the directory where the adb executable is located.
Check whether your device is recognized by adb. Type the following command:
Code:
adb devices
Your output should look something like this (the device ID in the output below will be particular to your phone):
Code:
List of devices attached
AAA0A1234567890 device
If your output doesn't look like the above, you may have a problem with the setup, and subsequent steps may not work. But we'll see.
Obtain a shell into your phone from adb:
Code:
adb shell
This should return a prompt into a shell on your phone which looks something like this:
Code:
[email protected]:/ $
Now convert that plain old shell into a root shell (you are rooted by now, aren't you?):
Code:
su
You should now be in a root shell, as evidenced by the following output (notice that the $ in the previous output changed to #):
Code:
[email protected]:/ #
Using a Terminal Emulator app on the phone to get a root shell:
Fire up the terminal emulator app on your phone (see the "Prerequisites" section above for a couple of suggestions on good terminal emulators I've personally used).
Type the following to get into a root shell in the terminal:
Code:
su
You should now be in a root shell, as evidenced by your prompt changing from $ to #.
Now we actually get to business! If you successfully got a root shell, it's time to issue the command to get the device partitions and their mappings! Type the following command exactly as shown (the cleverer folk can simple copy-paste it):
Code:
ls -l /dev/block/platform/hi_mci.0/by-name | tr -s ' ' | cut -d' ' -f6-8 > /storage/sdcard0/mypartitions.txt
The above command should put a list of partitions and their mappings into a text file called mypartitions.txt on the root directory of your phone's internal SD card mountpoint (if you want it put on your external SD card mountpoint, replace /storage/sdcard0/mypartitions.txt in the command with this: /storage/sdcard1/mypartitions.txt and you should find it placed accordingly).
The file mypartitions.txt can now be transferred from your phone to your computer via USB (or you can open it directly on your phone using a text editor) and add the info to a reply here.
Good luck!
Information on individual devices
Block Device/Partition Information for individual devices
Mediapad M2 8.0 (M2-802L)
Block Device/Partitions
Code:
vrl -> /dev/block/mmcblk0p1
vrl_backup -> /dev/block/mmcblk0p2
mcuimage -> /dev/block/mmcblk0p3
reserved0 -> /dev/block/mmcblk0p4
fastboot -> /dev/block/mmcblk0p5
modemnvm_factory -> /dev/block/mmcblk0p6
nvme -> /dev/block/mmcblk0p7
oeminfo -> /dev/block/mmcblk0p8
splash -> /dev/block/mmcblk0p9
modemnvm_backup -> /dev/block/mmcblk0p10
modemnvm_img -> /dev/block/mmcblk0p11
modemnvm_system -> /dev/block/mmcblk0p12
securetystorage -> /dev/block/mmcblk0p13
3rdmodemnvm -> /dev/block/mmcblk0p14
3rdmodemnvmback -> /dev/block/mmcblk0p15
reserved1 -> /dev/block/mmcblk0p16
modem_om -> /dev/block/mmcblk0p17
splash2 -> /dev/block/mmcblk0p18
misc -> /dev/block/mmcblk0p19
modemnvm_update -> /dev/block/mmcblk0p20
recovery2 -> /dev/block/mmcblk0p21
reserved2 -> /dev/block/mmcblk0p22
teeos -> /dev/block/mmcblk0p23
trustfirmware -> /dev/block/mmcblk0p24
sensorhub -> /dev/block/mmcblk0p25
hifi -> /dev/block/mmcblk0p26
boot -> /dev/block/mmcblk0p27
recovery -> /dev/block/mmcblk0p28
dtimage -> /dev/block/mmcblk0p29
modem -> /dev/block/mmcblk0p30
modem_dsp -> /dev/block/mmcblk0p31
dfx -> /dev/block/mmcblk0p32
3rdmodem -> /dev/block/mmcblk0p33
cache -> /dev/block/mmcblk0p34
hisitest0 -> /dev/block/mmcblk0p35
hisitest1 -> /dev/block/mmcblk0p36
hisitest2 -> /dev/block/mmcblk0p37
system -> /dev/block/mmcblk0p38
cust -> /dev/block/mmcblk0p39
userdata -> /dev/block/mmcblk0p40
CPU Info (gathered by CPU-Z)
Code:
CPUs : 8
SoCs : 1
CPU 0 : AArch64 Processor rev 3 (aarch64)
Name : HiSilicon Kirin 930
CPUs : 8
Core set 0 : ARM Cortex-A53
Core set 0 Nb Cores : 4
Core set 0 Max Clock : 2016 MHz
Core set 0 Impl.id : 0x41
Core set 0 Arch.id : 0x8
Core set 0 Var.id : 0
Core set 0 Part.id : 0xd03
Core set 0 Rev.id : 3
Core set 0 Revision : r0p3
Core set 1 : ARM Cortex-A53
Core set 1 NbCores : 4
Core set 1 Max Clock : 1516 MHz
Core set 1 Part.id : 0xd03
Arch : 4x ARM Cortex-A53 @2.02 GHz+4x ARM Cortex-A53 @1.52 GHz
Codename :
Process : 28 nm
GPU Vendor : ARM
GPU Renderer : Mali-T624
Model : HUAWEI M2-802L (M2)
Manufacturer : HUAWEI
Board : mozart
Hardware : hi3635
Android Ver. : 5.1.1
Kernel Arch. : armv7l
Battery capacity : 4650
--- CPUInfos ---
abi : armeabi-v7a
abi2 : armeabi
supported abis : [arm64-v8a, armeabi-v7a, armeabi]
supported 32-bit abis : [armeabi-v7a, armeabi]
supported 64-bit abis : [arm64-v8a]
Processor : AArch64 Processor rev 3 (aarch64)
processor : 0
processor : 1
processor : 2
processor : 3
processor : 4
processor : 5
processor : 6
processor : 7
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 wp half thumb fastmult vfp edsp neon vfpv3 tlsi vfpv4 idiva idivt
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 3
Hardware : Hisilicon Kirin 930
--- Debug Infos ---
16=667000000
17=120000000
18=0
19=120000000 240000000 360000000 400000000 667000000 800000000
20=cluster0=42
21=cluster1=25
22=gpu=37
23=modem=44
24=ddr=82
25=system_h=34
26=system_l=15
27=flash_led=29
28=charger=34
29=pa_0=30
30=Battery=29000
56=cluster0=41
57=cluster1=25
58=gpu=37
59=modem=44
60=ddr=82
clock 0=1516800
clock2 0=151600
clock 1=1516800
clock2 1=151600
clock 2=1516800
clock2 2=151600
clock 3=1516800
clock2 3=151600
clock 4=2016000
clock2 4=201600
clock 5=2016000
clock2 5=201600
clock 6=2016000
clock2 6=201600
clock 7=2016000
clock2 7=201600
Reserved
Reserved
Reserved 2

Categories

Resources