Jump to content

Advent Vega kernel source code now available!


Guest PaulOBrien

Recommended Posts

Guest univall

Well, the only thing missing right now is voice... Or, to improve voice... Voice support seems to freeze sometimes.. To this respect, I'd like to hear what you think is happening... The idea is to collect experiences. The only modem i have that supports voice is the EM770W, as the E169 does not support it... I know there are other modems that do also support voice, and voice support has proven to be hard to implement...

Few observations --

- Call dialed to tablet -- ring received on tablet, call established after a while, voice going through from the tablet to the phone but with a big (~5 seconds) latency and faint volume. The microphone icon is crossed out.

- Call dialed to phone - call ends abruptly. Compared to earlier, the modem is not hanging anymore. More tries to call are possible but with similar results. The speaker button is on mute when the call is dialed. On setting the speaker button on, hear a crackling sound much like the one heard at the time of reboot at the lock-screen. Call ends quite abruptly and soon, no chance of really checking if there is sound/voice on the call. But, I did hear the call end sound off the tablet speaker maybe two or three times. The microphone icon appears crossed out in the phone screen.

- 3g connection is somewhat stable and comes back on quite fast after a short idle - display time out. But after a long idle of 3-5 minutes, either hangs or takes a long while to come back on - entirely unpredictable. Needs a reboot to function again.

Edited by univall
Link to comment
Share on other sites

Guest ejtagle

Well, posting this here for completness sake... I am in the process of adding automatic volume control level to the voice function of the RIL. I do suspect that some of the problems are caused by a too low recording/playback level. ... It probably does not compile. A little bit later, i will fix it and try it in actual hw (this is the sort of thing that requires to be tested and debugged in real hw!)

The audio delay problems are somehow hard to fix... I have to try to reduce the resampling queue to reduce it, but it is hard to reduce it too much... Android has a limitation on the mic audio recording latency that is severely impacting us... Less than 2 seconds of buffering and the framework refuses to start recording...

huawei-generic-4set-v3.rar

Edited by ejtagle
Link to comment
Share on other sites

Guest univall

Well, posting this here for completness sake... I am in the process of adding automatic volume control level to the voice function of the RIL. I do suspect that some of the problems are caused by a too low recording/playback level. ... It probably does not compile. A little bit later, i will fix it and try it in actual hw (this is the sort of thing that requires to be tested and debugged in real hw!)

The audio delay problems are somehow hard to fix... I have to try to reduce the resampling queue to reduce it, but it is hard to reduce it too much... Android has a limitation on the mic audio recording latency that is severely impacting us... Less than 2 seconds of buffering and the framework refuses to start recording...

Attaching logcat -b radio. Dialing out ends immediately. Call in to the tablet established, volume is louder, good enough to hear from about 3-6 feet away from the tablet. But there are too many overlapping sounds including a continuing ringing of the call in spite of accepting it. It takes a while for the call to kick in and there is latency but somewhat better than the earlier version.

This may need more intensive checking though.

log-v3.txt

Link to comment
Share on other sites

Guest ejtagle

I will try to implement an audio interceptor to bypass Android well known audio latency issues. Directly accessing the audio driver should allow 20ms of latency, that compared with the Android framework, that creates at least 1 second of latency, should improve things quite a bit...

Link to comment
Share on other sites

Guest ejtagle

I will try to implement an audio interceptor to bypass Android well known audio latency issues. Directly accessing the audio driver should allow 20ms of latency, that compared with the Android framework, that creates at least 1 second of latency, should improve things quite a bit...

Well, now i know why some calls are ending unexpectly... The RIL is crashing (sometimes) when trying to start the audio voice loopback...

Nevertheless, posting my latest version. Still crashes on sometimes when trying to answer calls or place calls, but fixes some issues i found related to USSDs (off by one messages, when the last letter was not properly decoded...

huawei-generic-5set.rar

Edited by ejtagle
Link to comment
Share on other sites

Guest Oldbarzo

Hi all

Just to let you know. 3G working well on Vegabean 2.3 .

Am now out and about and sending this from an urban

location.

Stransky

Edit: Now in rural area 15 miles from nearest town and connection stable.

Edited by Oldbarzo
Link to comment
Share on other sites

Guest ejtagle

Hi all

Just to let you know. 3G working well on Vegabean 2.3 .

Am now out and about and sending this from an urban

location.

Stransky

Edit: Now in rural area 15 miles from nearest town and connection stable.

Now we go for Voice support. If we manage to fix the crashing issue, that should be the most we can get from the internal modem :) ... I know using a tablet as a phone is not the main purpose, but the voice capability could be useful sometimes ;)

Link to comment
Share on other sites

Guest univall

Agree in toto. Trying it with a wired headphones. Same observations as above. But it is exciting to see this is working!

Edited by univall
Link to comment
Share on other sites

Guest ejtagle

Agree in toto. Trying it with a wired microphone. Same observations as above. But it is exciting to see this is working!

It could be possible to use a wireless bluetooth headset/mic ;)

Link to comment
Share on other sites

Guest arya farjand

I try with wireless bluetooth handsfree and no voice .

USSD is not anable with stock dialer but with my operator widget i can dial USSD and it work .

and i think mic it's dissable in voice dial and just return voice

I test in viewpad 10s internal EM770W . VegaBean 2.3

Link to comment
Share on other sites

Guest univall
I try with wireless bluetooth handsfree and no voice .

USSD is not anable with stock dialer but with my operator widget i can dial USSD and it work .

and i think mic it's dissable in voice dial and just return voice

I test in viewpad 10s internal EM770W . VegaBean 2.3

My primitive Nokia bh-200 Bluetooth headset is paired but I am not sure if the headset services are on.

Maybe we can request Eduardo to look at the Bluetooth interface layer next. :D

Suggest you should try without a headset or with a wired headset. Since we are on a similar hardware, it will be interesting to compare notes.

Also, looking at Scanno's GIT status, not sure that he got the latest RIL from Eduardo in to the device tree and thus, Vegabean 2.3 maybe a small step behind from what is currently being tested.

Edited by univall
Link to comment
Share on other sites

Guest ejtagle

Until we fix voice support in the RIL, there is little point in testing voice calls.. Right now, the huawei ril crashes when starting voice support for the EM770W (ok, sometimes it does work... But i have to figure out the cause of the crash), and when it crashes, all cell modem activity ceases. It means 3G connection is lost, active calls are hang up ... So, until we fix this problem, there is no way to be sure if bluettoth mic/headphone will work.

But, as a matter of fact, if google voice works with a bluetooth headset/mic, then we can assume that when we fix the RIL voice support, it will also work with the 3G modem...

Link to comment
Share on other sites

Guest arya farjand

Ok i test my bluetooth handsfree "Jabra BT2045" it even dosnt work in Google Voice Search . it pair and show it's usable for phone in bluetooth setting but unfotunately no success .

nd another issue is about sleeping time . when tablet sleep if i call to tablet it's says Tablet is off . is there any chanse to make EM770W like phone stay awake in GSM/EDGE "2G Network" after deep sleep ?

and something strange about IMEI !! why it's always show "01" ??? as i know having True IMEI is necessary .

i dont know how to compile this huawei-generic and make libhuawei.so but if u make it and give it to me i can unsquashfs system.sfs and replace it for test . i'm here if you need another tester

Edited by arya farjand
Link to comment
Share on other sites

Guest ejtagle

Well, finally found the bug(s) that were causing the RIL to crash and fixed them. No more crashes!. Also found that the EM770W firmware has a bug that sometimes corrupts the audio voice stream. So, i implemented a workaround that tries to fix those audio segments..

Everything should be working. Due to the voice stream bug of the huawei modem firmware, sometimes it does not sound as clean as it should.. :(

Please, test! :)

huawei-generic-8set.rar

Link to comment
Share on other sites

Guest univall

Well, finally found the bug(s) that were causing the RIL to crash and fixed them. No more crashes!. Also found that the EM770W firmware has a bug that sometimes corrupts the audio voice stream. So, i implemented a workaround that tries to fix those audio segments..

Everything should be working. Due to the voice stream bug of the huawei modem firmware, sometimes it does not sound as clean as it should.. :(

Please, test! :)

will post test reports soon. please note that on compiling I am seeing (just a fyi) ---

No private recovery resources for TARGET_DEVICE shuttle

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/agc.c

target thumb C++: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/audiochannel.cpp

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/audioqueue.c

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/echocancel.c

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c

device/nvidia/shuttle/huawei-generic/audiochannel.cpp: In function 'void* modemAudioIOThread(void*)':

device/nvidia/shuttle/huawei-generic/audiochannel.cpp:121:25: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c: In function 'decodeUSSD':

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c:5921:2: warning: pointer targets in return differ in signedness [-Wpointer-sign]

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c: In function 'requestSendUSSD':

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c:6243:2: warning: pointer targets in passing argument 1 of 'strlen' differ in signedness [-Wpointer-sign]

bionic/libc/include/string.h:52:15: note: expected 'char const *' but argument is of type 'cbytes_t'

target SharedLib: libhuaweigeneric-ril (out/target/product/shuttle/obj/SHARED_LIBRARIES/libhuaweigeneric-ril_intermediates/LINKED/libhuaweigeneric-ril.so)

target Symbolic: libhuaweigeneric-ril (out/target/product/shuttle/symbols/system/lib/libhuaweigeneric-ril.so)

target Strip: libhuaweigeneric-ril (out/target/product/shuttle/obj/lib/libhuaweigeneric-ril.so)

Install: out/target/product/shuttle/system/lib/libhuaweigeneric-ril.so

[EDIT]

Difficult to be completely sure but this seems to be better but not by a big margin --

1) The call from tablet to phone did engage for longer but ended on its own in about 5-7 seconds

2) On the call made from phone to tablet: -

- The call takes a while to kick in after one accepts the call

- There are a lot of crackling noise/sounds

- The latency seems to have improved but the voice-sound is still lagging

- The voice on call coming off from the tablet speakers is faint. On the wired headphone is a bit better but with more 'bass' than expected needs more 'treble' or a somewhat higher pitch

- USSD is fast and you seem to have removed the @@@ from the response, so is neat.

All in all seems better than last one, but do not have a yard stick so I will make one.

If the previous one was 1/5 :: this one is 1.5/5. Maybe I am a little generous with the rating. ;-)

Someone else might get better results. Do you recommend I post the *.so files as requested by Arja above. Could you tell me which files should be posted that would help him run tests that will be useful to us/you.

log691.txt

Edited by univall
Link to comment
Share on other sites

will post test reports soon. please note that on compiling I am seeing (just a fyi) ---

No private recovery resources for TARGET_DEVICE shuttle

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/agc.c

target thumb C++: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/audiochannel.cpp

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/audioqueue.c

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/echocancel.c

target thumb C: libhuaweigeneric-ril <= device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c

device/nvidia/shuttle/huawei-generic/audiochannel.cpp: In function 'void* modemAudioIOThread(void*)':

device/nvidia/shuttle/huawei-generic/audiochannel.cpp:121:25: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c: In function 'decodeUSSD':

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c:5921:2: warning: pointer targets in return differ in signedness [-Wpointer-sign]

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c: In function 'requestSendUSSD':

device/nvidia/shuttle/huawei-generic/huaweigeneric-ril.c:6243:2: warning: pointer targets in passing argument 1 of 'strlen' differ in signedness [-Wpointer-sign]

bionic/libc/include/string.h:52:15: note: expected 'char const *' but argument is of type 'cbytes_t'

target SharedLib: libhuaweigeneric-ril (out/target/product/shuttle/obj/SHARED_LIBRARIES/libhuaweigeneric-ril_intermediates/LINKED/libhuaweigeneric-ril.so)

target Symbolic: libhuaweigeneric-ril (out/target/product/shuttle/symbols/system/lib/libhuaweigeneric-ril.so)

target Strip: libhuaweigeneric-ril (out/target/product/shuttle/obj/lib/libhuaweigeneric-ril.so)

Install: out/target/product/shuttle/system/lib/libhuaweigeneric-ril.so

[EDIT]

Difficult to be completely sure but this seems to be better but not by a big margin --

1) The call from tablet to phone did engage for longer but ended on its own in about 5-7 seconds

2) On the call made from phone to tablet: -

- The call takes a while to kick in after one accepts the call

- There are a lot of crackling noise/sounds

- The latency seems to have improved but the voice-sound is still lagging

- The voice on call coming off from the tablet speakers is faint. On the wired headphone is a bit better but with more 'bass' than expected needs more 'treble' or a somewhat higher pitch

- USSD is fast and you seem to have removed the @@@ from the response, so is neat.

All in all seems better than last one, but do not have a yard stick so I will make one.

If the previous one was 1/5 :: this one is 1.5/5. Maybe I am a little generous with the rating. ;-)

Someone else might get better results. Do you recommend I post the *.so files as requested by Arja above. Could you tell me which files should be posted that would help him run tests that will be useful to us/you.

You only need the libhuaweigeneric-ril.so. The rest is already in the ROM and there are no further dependencies.

Link to comment
Share on other sites

Guest arya farjand

ok I test

3G - ok "as same as Vegabean 2.3"

Sms - ok

Call in - ok

Call out - ok "when dial she said my creadit is low :D "

USSD - ok "better than 2.3 all code fine"

IMEI - No "just 01"

everything it's fine and i think it's good for now but some issue

- voice call has delay to send and recive voice even in near distance . for example when i call to tablet and talk to phone my voice comes to tablet after 1~2 sec but when i talk via tablet in other side after 5~10 sec i can hear my voice.

- there is some noise in call which i think it's more because of low mic quality and not for driver . so i will test it with another voice recorder and told you.

- 3G just work in tablet awake mode .

- Also 3G indicator need to fix.

- Blutooth handsfree is totaly unusable.

i have to work more and if i find anything i told you

thanks for your nice job

Edited by arya farjand
Link to comment
Share on other sites

Guest arya farjand

Sorry for incoherent subject . But i think another bootscreen would be fine .

I dont know with wich software i can build it if you know guide me it would be nice too have every product name and ability in boot screen

Edited by arya farjand
Link to comment
Share on other sites

Guest univall

ok I test

3G - ok "as same as Vegabean 2.3"

Sms - ok

Call in - ok

Call out - ok "when dial she said my creadit is low :D "

USSD - ok "better than 2.3 all code fine"

IMEI - No "just 01"

everything it's fine and i think it's good for now but some issue

- voice call has delay to send and recive voice even in near distance . for example when i call to tablet and talk to phone my voice comes to tablet after 1~2 sec but when i talk via tablet in other side after 5~10 sec i can hear my voice.

- there is some noise in call which i think it's more because of low mic quality and not for driver . so i will test it with another voice recorder and told you.

- 3G just work in tablet awake mode .

- Also 3G indicator need to fix.

- Blutooth handsfree is totaly unusable.

i have to work more and if i find anything i told you

thanks for your nice job

You seem to be getting somewhat better audio as well as better dial-out performance than I am on the Viewpad 10s. Wonder if I should try with another service provider as it may have something to do with cell reception in my area. Just wondering if that would affect the quality of voice/other sounds in the call.

Is noise cancellation already built in the RIL specific to the hardware or not possible with the EM770W that we have. The tablet unlike a smaller phone is held some distance away and may be more susceptible to ambient noise distortions.

Not only 3g, even the phone features work only in awake mode. Cannot receive call or SMS when sleeping as the modem switches off. When the tablet is brought back from sleep, the cell signal indicator is blank or greyed out and takes a while to come back. If the sleep has been long, say over 3-5 minutes only a reboot can bring the cell network back on. To counter this, I increased display time out to 30 minutes or more... no issues now for cell network, but battery runs out faster. Battery discharge can be extended a bit in this case by reducing the screen brightness to as low as possible so as to be able to see clearly. :-)

Edited by univall
Link to comment
Share on other sites

You seem to be getting somewhat better audio as well as better dial-out performance than I am on the Viewpad 10s. Wonder if I should try with another service provider as it may have something to do with cell reception in my area. Just wondering if that would affect the quality of voice/other sounds in the call.

Is noise cancellation already built in the RIL specific to the hardware or not possible with the EM770W that we have. The tablet unlike a smaller phone is held some distance away and may be more susceptible to ambient noise distortions.

Not only 3g, even the phone features work only in awake mode. Cannot receive call or SMS when sleeping as the modem switches off. When the tablet is brought back from sleep, the cell signal indicator is blank or greyed out and takes a while to come back. If the sleep has been long, say over 3-5 minutes only a reboot can bring the cell network back on. To counter this, I increased display time out to 30 minutes or more... no issues now for cell network, but battery runs out faster. Battery discharge can be extended a bit in this case by reducing the screen brightness to as low as possible so as to be able to see clearly. :-)

You can always introduce a wakelock. With advanced wifi lock for instance....

Link to comment
Share on other sites

Guest ejtagle

You can always introduce a wakelock. With advanced wifi lock for instance....

Probably, the 3G kernel driver is turning off the 3G modem ... Try

echo 1 > /sys/devices/platform/shuttle-pm-gsm/keep_on_in_suspend

.. regarding crackling noise, seems to be the EM770W firmware. Have to check if there is a way to detect it and try to fix it.... But there are no promises, as audio could simply be missing...

.. Latency is a big problem here. This is a known limitation of Android sound subsystem. At 8khz audio we are getting 1 second of delay in audio playback, and 2 seconds of delay in audio recordings... This si due to the huge buffers used internally in the android audio mixing framework... that can´t be reduced, unfortunately.

... One way reduce latency could be to capture audio at 48khz, and then subsample it in sw. As the android internal buffers do not expand wehn higher sampling rates are used, this means we could potentially reduce latency by x6 ...

Edited by ejtagle
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.