FORUMS
Remove All Ads from XDA

[HOWTO] Build CM10 For The I957

243 posts
Thanks Meter: 215
 
By nrvate, Senior Member on 3rd September 2012, 04:39 AM
Post Reply Email Thread
9th September 2012, 02:57 AM |#21  
Zabalba's Avatar
Senior Member
Flag Miami
Thanks Meter: 169
 
More
I'll give it a whirl. Can't wait to try out JB on this Tab!
 
 
9th September 2012, 03:16 AM |#22  
Senior Member
Thanks Meter: 348
 
More
CM9 made my i957 seem like it got fed project churned butter so Im sure this is going to make my head explode!! Thanks!

*Little too much?!? Oh well it should be the simple joys in life that get one excited.
9th September 2012, 04:15 AM |#23  
neubauej's Avatar
Senior Member
Thanks Meter: 95
 
More
Yeah, so like win and stuff.

I really can't thank you enough for making my tablet useful again.

Its a completely new device!

Thanks!! !


Edit; it seems HD YouTube videos don't work.
9th September 2012, 05:45 AM |#24  
Junior Member
Thanks Meter: 0
 
More
Even more pleased with the JB version, thanks again. One thing I've noticed; if the icons are to believed when WiFi is connected 4g remains connected. Can someone tell me how to verify if this is true and if there's a way to prevent it

Sent from my SAMSUNG-SGH-I957 using xda app-developers app
9th September 2012, 05:56 AM |#25  
neubauej's Avatar
Senior Member
Thanks Meter: 95
 
More
Quote:
Originally Posted by bonj

Even more pleased with the JB version, thanks again. One thing I've noticed; if the icons are to believed when WiFi is connected 4g remains connected. Can someone tell me how to verify if this is true and if there's a way to prevent it

Sent from my SAMSUNG-SGH-I957 using xda app-developers app

I don't have this issue at all.. wifi or 2g/3g/4g here.
9th September 2012, 07:05 AM |#26  
OP Senior Member
Thanks Meter: 215
 
More
Quote:
Originally Posted by neubauej

Yeah, so like win and stuff.
I really can't thank you enough for making my tablet useful again.
Its a completely new device!
Thanks!! !
Edit; it seems HD YouTube videos don't work.

Cheers! Can you share one that doesn't work? Man, youtube is a picky little -----

Ah, interesting... So I was having great luck earlier.. On cellular data. Tried again, happened to be on WiFi... No go.. WTF I say!
Looked at logcat... The HD videos I tried were attempting to show 1080P content. That causes a failure of the decoder to render the stream.

On cellular, it doesn't play "high quality" streams.. It gets the lower quality stream instead unless you go into youtube settings and tell it to do HQ over mobile (a checkbox)

I'm guessing the real problem here is something in the video subsystem is telling youtube it's capable of rending higher quality than the hardware/software combo actually can, then blows up when youtube tries to actually do so.

Will have to look at the code and see if there's something that could be improved... at least I have an idea of what's going on!

Code:
E/OMX-VDEC-1080P(  170):  Omx_vdec::Comp Init Returning failure, errno 19
E/OMXCodec(  170): failed to allocate node OMX.qcom.video.decoder.avc
E/OMXCodec(  170): failed to allocate node OMX.ittiam.video.decoder.avc
I/OMXCodec(  170): [OMX.google.h264.decoder] Non-Interlaced format detected
I/OMXCodec(  170): [OMX.google.h264.decoder] AVC profile = 100 (High), level = 31
I/OMXCodec(  170): [OMX.google.h264.decoder] Enable frame by frame mode
W/OMXCodec(  170): Failed to set frame packing format on component
I/OMXCodec(  170): [OMX.google.h264.decoder] video dimensions are 320 x 240
I/OMXCodec(  170): [OMX.google.h264.decoder] Crop rect is 320 x 240 @ (0, 0)
E/SoftAVC (  170): Decoder failed: -2
E/OMXCodec(  170): [OMX.google.h264.decoder] ERROR(0x80001001, -1007)
I/SoftAAC2(  170): Reconfiguring decoder: 44100 Hz, 2 channels
E/MediaPlayer( 1719): error (1, -2147483648)
E/MediaPlayer( 1719): Error (1,-2147483648)
W/YouTube ( 1719): MediaPlayer error during playback [what=1, extra=-2147483648]
Guessing this is the misdefined variable in hardware/qcom/media/mm-video/vidc/vdec/Android.mk
Code:
ifeq ($(TARGET_BOARD_PLATFORM),msm8660)
libOmxVdec-def += -DMAX_RES_1080P
libOmxVdec-def += -DPROCESS_EXTRADATA_IN_OUTPUT_PORT
libOmxVdec-def += -DTEST_TS_FROM_SEI
However.. a little research seems to suggest the MSM8660 is actually capable of 1080P decode.
Update: "OMX-VDEC-1080P" doesn't indicate it's actually trying to decode 1080P video, just that it was built with the above-shown MAX_RES_1080P definition. If I can only find where error "19" is defined.. geez! /dig -- Erm, that's actually a generic "no such device" (ENODEV) error returned from attempting to open() the video decoder device.. i think. Yup. Sho enuf.

Probably more to do with the codec, I'd guess... More investigation! <~ doh, scratch that!

Should have looked at dmesg long ago, this is actually an error induced inside a kernel function, which has some debugging enabled all the time (probably because other folks are trying to figure this broken stuff out too!)

Code:
<6>[ 1060.613403] msm_vidc_dec: Inside vid_dec_open()
<3>[ 1061.644805] vidc_timer_fn() Timer expired
<3>[ 1061.644897] vidc_timer_handler() Timer expired
<3>[ 1061.644927] vid_dec_vcd_open_done(): ERROR. handle_container is NULL
<3>[ 1061.644958] callback for vcd_open returned error: 2147483661
In kernel/samsung/msm8660-common/drivers/video/msm/vidc/common/dec/vdec.c .. There's the ENODEV return and the text we see in dmesg.. hmm.. I'm done for the day

Code:
        rc = vcd_open(vid_dec_device_p->device_handle, true,
                                  vid_dec_vcd_cb, client_ctx, flags);
        if (!rc) {
                wait_for_completion(&client_ctx->event);
                if (client_ctx->event_status) {
                        ERR("callback for vcd_open returned error: %u",
                                client_ctx->event_status);
                        rc = -ENODEV;
                        goto client_failure;
                }
Oh fun! In laymans terms: It's trying to use MSM hardware video decoding.. and straight out fails. From what I can tell based on the code flow (after building a kernel with lots of debug logging messages added in relevant functions) the hardware simply times out. The code attempts to open the video decoder device via an Ion memory buffer, but the hardware doesn't respond and the function times out hence the "timer expired" messages.

Man, this hardware video decoding stuff is nasty! Not only is there a bunch of in-flux source code, but also on dynamically loaded firmware resident on the filesystem (/system/etc/firmware/vidc_1080p.fw) -- So I also need to see if the firmware needs an update to play nice with the newer vidc code. There's also other video-related firmware, such as the playready BS for netflix, which almost certainly isn't going to work, but I don't do netflix.. Anyone own an att note sgh-i717?! I'm curious if the current nightly builds have this working, or if this is all around broken (ie: not a problem with the device, but just a hole in CM10 right now).

Maybe it's a better use of effort to see about building CM10 with hardware video decode disabled -- then maybe youtube and other software would simply use software decoding? A video player that uses software decoding plays 720p video quite nicely, but then again... there should be significant battery savings using hardware to decode. again, more investigation...

Oh codec licensing!! DieDieDie! So bsplayer and other video things that work, have their own built-in video codecs. I found that /system/etc/media_codecs.xml defines the available codecs for each stream time, and there's a software video h264 decoder listed.. problem is, it's nowhere to be found -- the .so doesn't exist and it's nowhere in the CM tree. It appears at some point the codec from Ittiam was included, but apparently that's no longer. Looks like it was a proprietary file on ancient devices?

On to looking at other android source trees besides CM -- maybe I can pick something up from AOKP or CAF... /ponder
9th September 2012, 07:16 AM |#27  
OP Senior Member
Thanks Meter: 215
 
More
Quote:
Originally Posted by bonj

Even more pleased with the JB version, thanks again. One thing I've noticed; if the icons are to believed when WiFi is connected 4g remains connected. Can someone tell me how to verify if this is true and if there's a way to prevent it

It's a little different in JB it seems... What I notice:

1) When WiFi is off and the cellular radio is connected, the bars turn blue to indicate verified connectivity, and it shows "3G", "H", "H+" or "4G" depending on the network mode. LTE is indicated as "4G".
2) When WiFi is enabled (and connected to an AP successfully), the network mode ("4G", etc) indicator goes away, but the signal bar(s) remain blue

You can drop to a terminal and issue:
Code:
ip route show
to verify what route the packet will take.

Also, when the cellular radio is connected, you'll see output like this, indicating the cellular radio (rmnet_sdio0) has an IP, but the wlan interface does not:

Code:
[email protected]:/ # ip address show rmnet_sdio0
11: rmnet_sdio0: <UP,LOWER_UP> mtu 1410 qdisc pfifo_fast state UNKNOWN qlen 1000
    link/[530]
    inet 10.38.95.219/29 scope global rmnet_sdio0
    inet6 fe80::b747:e2f6:d6e7:9621/64 scope link
       valid_lft forever preferred_lft forever
[email protected]:/ # ip a s wlan0
26: wlan0: <NO-CARRIER,BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state DORMANT qlen 1000
    link/ether 60:d0:a9:25:8d:13 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::62d0:a9ff:fe25:8d13/64 scope link
       valid_lft forever preferred_lft forever
But after WiFi is activated, the same command shows the IP address of the cellular radio has gone away and wlan0 now has an address:

Code:
[email protected]:/ # ip a s rmnet_sdio0
11: rmnet_sdio0: <> mtu 1410 qdisc pfifo_fast state DOWN qlen 1000
    link/[530]
[email protected]:/ # ip a s wlan0
26: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 60:d0:a9:25:8d:13 brd ff:ff:ff:ff:ff:ff
    inet 192.168.0.73/24 brd 192.168.0.255 scope global wlan0
    inet6 fe80::62d0:a9ff:fe25:8d13/64 scope link
       valid_lft forever preferred_lft forever
I wondered myself when I first got this working... wanted to make sure I wasn't going to push traffic over the cellular radio and rack up my usage when I'm at home.. Nice fast 5ghz wifi here with a 30mbit cable connect

Also, you can save some battery by going into airplane mode and then turning WiFi back on. That 100% turns the cellular radio off, and you can still re-activate WiFi in airplane mode. When airplane mode is off, and WiFi is connected, the cellular radio is still powered up, just doesn't have an established data connection (ie: you can still use it to make voice calls, and it still does all the non-data cellular functionality like tower hopping as you move, etc).

Hope that helps give you an idea of what's going on
9th September 2012, 02:42 PM |#28  
Senior Member
Flag Toronto
Thanks Meter: 13
 
More
first download attempt failed and the second one downloaded but failed when trying to install. would love to try this, I am currently running your cm9 and its awesome....

edit: re-downloaded and were all good, runs awesome
9th September 2012, 05:28 PM |#29  
neubauej's Avatar
Senior Member
Thanks Meter: 95
 
More
So after running this since last night the only things I've noticed are the camera as noted, YouTube HD as previously stated, hapatic feedback is present but very weak, and no crt animation?

Other than that this build seems very smooth and stable. Thanks again!
9th September 2012, 06:05 PM |#30  
Member
Thanks Meter: 5
 
More
Thank you, thank you, thank you. Now please port this to my phone

Sent from my SAMSUNG-SGH-I727 using xda app-developers app
9th September 2012, 09:21 PM |#31  
OP Senior Member
Thanks Meter: 215
 
More
Quote:
Originally Posted by neubauej

So after running this since last night the only things I've noticed are the camera as noted, YouTube HD as previously stated, hapatic feedback is present but very weak, and no crt animation?

Other than that this build seems very smooth and stable. Thanks again!

Well, it's worse than youtube HD -- hardware video decoding is inoperable -- It just so happens youtube is unwilling to use software decode, and gives up when hardware decode pukes! Another video player, for example bs player, attempts hardware decode, then falls back to software. Sort of app dependent...

Haptic is definitely on the list of things to toy with

CRT animation... you mean like on screen off, the "electron beam" thing? That appears to be purposely disabled in source, comments indicate it didn't work right on these qcom-based devices, but that is probably a relic from other devices, as most the msm8660-common stuff was developed on other similar devices (ie the skyrocket and note)
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes