[Q] help build cp210x.ko on Iconia A500 3.2.1 - Acer Iconia A500

Hi,
I really need the cp210x.ko module, but I couldn't successfully build it properly for my Iconia A500 with 3.2.1 and 2.6.36.3+ kernel.. I get the following when I tried insmod my cp210x.ko build using ubuntu cross compiler approach:
cp210x: version magic '2.6.36.3+ preempt mod_unload ARMv5 ' should be '2.6.36.3+ SMP preempt mod_unload ARMv7 '
A little search showed that I need to build it in ARMv7, and need to set the kernel config to build SMP kernel. In this thread I saw a few modules offered but couldn't post reply as a new xda-developers user, so I post here. My A500 has already been rooted via the su (version 3) method posted few days ago.
Please help me build the cp201x.ko module - I am kinda stuck..
Bill

Bill,
Might I suggest you look at loading one of the many custom ROM's that will have what you want? If you are rooted, then install CWM (ACER Recovery from the marketplace) which should allow you to load custom ROM's. In order to load the cp201x.ko module you'd have to recompile the kernel and people doing this type of work normally are building custom ROM's.
Anyway, just my 2¢

Thanks for the advice. I am testing Thor ROM at the moment. Cool..
From what I can read and see within various ROMs /system/lib/modules, very few (out of total possible) kernel modules made it to these custom ROMs - mostly to get game controller to work, extra filesystems, or networking protocols. USB-to-serial modules are rare and certainly my search didn't turn up cp210x.
Cross-compiling the kernel source on Gentoo is mentioned to be better supported then ubuntu, due to its crossdev toolkit, as I'm trying to figure out how to specify target ARMv7 instead of ARMv5 I'm defaulting to when cross compiling from Ubuntu's arm-linux-gnueabi-*
I'm wondering if various nice ROM cooks have releases of their modified kernel source - or might be willing to help me build the just the cp210x as a .ko module, e.g. in the .config, "CONFIG_USB_SERIAL_CP210X=m" - I've found a post few months ago where a successful build and insertion of cp210x module was done but he had some problems when initiating communication on it - I fear the worst but hope for the best, and would like to try that myself as I've successfully talked to my device through the cp210x module on Linux.
Or, if any tips on how to build kernel (just the modules really) properly e.g. As Thor's ROM version number hints at need for some custom and virtualized build environment, I'm looking for the quick and dirty solution if cooking ROMs/kernel/ko's has steep learning curve..
Any help much appreciated!
Bill

It looks like I was speeding down the the wrong track last few days
Apparently the /proc/config.z copied off the a500 device was missing something - and how strange that is - so I had to enable SMP and choose Tegra 2 ARM processor using "make menuconfig" to get the vermagic on the build module (e.g. modinfo after successful make modules) to show ARMv7 and SMP, build from my Ubuntu cross-compiling setup. I haven't tested this new cp210x.ko on a500 yet (as it's currently running one of the customized ROMs that has different EXTRAVERSION/vermagic to the stock Acer kernel source version 2.6.36.3 that I'm based on.
I think it'd be really wonderful if various Android kernel and kernel module makers release their kernel config, sync'ed to each ROM or kernel release, so people like me may independently build special purpose kernel modules with more efficiency and accuracy (to target their customized kernel), and we can recontribute back to to a growing list of tested and working modules for corresponding devices.
Bill

Hmm... Silly. It looks like Thor's ROM already has cp210x build-in, not as a loadable module but compiled in. My device is reported to attach to ttyUSB0! How nice
Thanks!
Bill

For those who are interested, the cp210x.ko module build using latest mentioned approach, e.g. modified kernel config.z, generate module that appear to insert correctly into lightspeed and taboonay roms (neither has this USB-to-serial module) - with a little modification of the EXTRAVERSION variable in the Makefile.
Bill

CP210x and GT-P7500
Has anyone got CP210x module working with Samsung Tab GT-P7500? My problem is that the connected USB-device doesn't create node dev/ttyUSB*. I have spent lot of time trying to figure this one out.
I have tried 1) Manually compiling the linux kernel that has cp210x support as a module. After compiling the module I tried insmoding the cp210x.ko to a running kernel, but even though it seemed to load and unload all right, it did not give me the wanted results. It does not create device node /dev/ttyUSB*. I have also tried modifying ueventd.rc for adding this row, but I am guessing it is only relevant for permissions after the node is created.
Also 2) loading cyanogenmod 10 (which should have cp210x support) to tablet but it doesnot create the desired /dev/ttyUSB* node. I can see device file under dev/bus/usb/001/ but the node does not exist.
I am going to try making needed files for building custom kernel and inserting to tablet. However, I have 0 experience on this, I think it can be tough one.
Any help would be welcome, thanks.

Related

[REQUEST] DM9601 Ethernet driver for Tiamat 2.1.0 Tachi

I've tried compiling a USB Ethernet driver for use with the new Tiamat Tachi kernel without success. I've never had to set up an android kernel build environment, and the compilation errors out every time. Would someone be willing to build and upload the DM9601 .ko module for me and (hopefully) others to use? The Realtek 8150 driver was added to the kernel in 1.4.4, but owners of other cards have to build their own.
This also may be a good feature to have, being able to download pre-built .ko modules for requested drivers. I would make this point in the Tiamat thread, but lack the posts to do so. Thanks!

Kernel modules for Atheros AR9271 based usb wifi dongles(now in Hundsbuah's kernel)

UPDATE: These modules were added by request to Hundsbuah's kernel here:
http://forum.xda-developers.com/showthread.php?t=2246062
______________________________________________________________________
I was not going to post this because it has limited use for most TF300T owners but it can't hurt so here it is. The attached file(ath9k.tar.gz) contains kernel modules needed to get AR9271 based usb wifi dongles working on the latest stock TF300T kernel(Asus build 10.4.2.20, kernel version 3.1.10). I have tested the modules with this dongle: TP-Link TL-WN722N.
Uncompress the file and you will get an ath9k directory. Inside are the modules, 2 scripts for easy loading and unloading of the modules, and iwconfig compiled for Android. Getting the dongle working goes something like this:
Su to root. Copy htc_9271.hw to /system/etc/firmware. Run the scripts start_ath9k and stop_ath9k to load and unload the modules.
After the modules are loaded, insert the dongle into the keyboard full size usb port and run ifconfig and iwconfig as needed. If wlan0(default android wifi) is on then iwconfig will show the dongle as wlan1.
Note: I did not post this on the Dev forum because I did not develop these modules...I only changed a few lines in 2 modules before compiling them.
ath9k
I have one mtech atab7t tablet with 4.0.4 android(rooted) and 3.0.8+ kernel [email protected] can i add the driver somehow?
kerteszalex said:
I have one mtech atab7t tablet with 4.0.4 android(rooted) and 3.0.8+ kernel [email protected] can i add the driver somehow?
Click to expand...
Click to collapse
Not very likely...you would need to get your kernel source, add ath9k driver support to the kernel config, then fix any compile errors.
bads3ctor said:
Not very likely...you would need to get your kernel source, add ath9k driver support to the kernel config, then fix any compile errors.
Click to expand...
Click to collapse
you can able to make a tutor for me? i am new in these things :/
kerteszalex said:
you can able to make a tutor for me? i am new in these things :/
Click to expand...
Click to collapse
Hmmm...kernel module compiling in 1 easy lesson....not sure it's possible.
bads3ctor said:
Hmmm...kernel module compiling in 1 easy lesson....not sure it's possible.
Click to expand...
Click to collapse
I really need this usb wifi support for my tab :/ i purchased recently more powerful antennas for my router but this tablet lost the signal on the next room :/ sorry for my bad english
kerteszalex said:
I really need this usb wifi support for my tab :/ i purchased recently more powerful antennas for my router but this tablet lost the signal on the next room :/ sorry for my bad english
Click to expand...
Click to collapse
You need the kernel source for your tablet and a way to root your tablet. I did a cursory Google search for the kernel source for your tablet and I can't find it. If you can get the kernel source code for your tablet then it might be possible to compile ath9k modules. If you can't root that tablet then kernel modules won't be useful because there would be no way to load them.
bads3ctor said:
You need the kernel source for your tablet and a way to root your tablet. I did a cursory Google search for the kernel source for your tablet and I can't find it. If you can get the kernel source code for your tablet then it might be possible to compile ath9k modules. If you can't root that tablet then kernel modules won't be useful because there would be no way to load them.
Click to expand...
Click to collapse
the tablet comes with root.i can extract the kernel from it?
kerteszalex said:
the tablet comes with root.i can extract the kernel from it?
Click to expand...
Click to collapse
You need the kernel source code from the tablet manufacturer.
Hello! I have source code for my kernel (Nexus 7 4.2.2) and I successful built module cifs.ko and cp210x.ko, but i can't build module ath9_htc. I add in my nexus_defconfig file
CONFIG_ATH_COMMON=m
CONFIG_ATH9K_HW=m
CONFIG_ATH9K_COMMON=m
CONFIG_ATH9K_HTC=m
but after make modules command only atk.ko created.
Sorry for my english.
SpulN said:
Hello! I have source code for my kernel (Nexus 7 4.2.2) and I successful built module cifs.ko and cp210x.ko, but i can't build module ath9_htc. I add in my nexus_defconfig file
CONFIG_ATH_COMMON=m
CONFIG_ATH9K_HW=m
CONFIG_ATH9K_COMMON=m
CONFIG_ATH9K_HTC=m
but after make modules command only atk.ko created.
Sorry for my english.
Click to expand...
Click to collapse
I had to comment out a few lines of code in 2 modules to get mine to compile. On the TF300T, it has to do with LED code not present in the stock kernel that is referred to in 2 of the modules. If you use my modules on the TF300T, you will get no LED blinking on the WIFI stick when data is transmitted or received.
EDIT: Newegg has an Atheros AR9271 USB stick for $9.99 with a cradle.
http://www.newegg.com/Product/Product.aspx?Item=N82E16833166068
For anyone wondering what these modules are used for, read this:
http://forum.xda-developers.com/showthread.php?t=1714300
HELP!! Need Kernel Module ath9k for GT-N5110 Galaxy Note 8.0
HELP !!!
Could really use some help. For the life of me I can't compile a kernel module driver ath9k for my USB wireless adapter TL-WN722N. So it can be used by insmod on my rooted Galaxy Note 8.0 GT-N5110 on Kernel 3.0.31 Build BMC9 running android 4.1.2. The source code is available at opensource.samsung. and is listed as the GT-N5110 NA (north america) model. If some one could help me please? I would be forever in your debt... :good:
Hello
When trying to add modules via your script, it gives me an "exec format error" for each module. How can this be fixed?
Device: Asus Padfone A66, Android 4.1.1
hi I am getting some problem with this attach file, i decompressed it and got the directory. but what are the next stapes ? sorry but i am not getting that part to copy to system/etc/firmware. will u make clear the process stapewise?
Sorry for bothering this old thread. I'm trying to get this to work on my OnePlus 3 running Oxygen OS Nougat. I installed Linux on my phone and I would like to install the TP-LINK drivers on it as the inbuilt WiFi module on my phone does not support monitor mode. I connected this WiFi adapter and trying to get it to work. Please help.

Sero 7 Pro Modifying ROM for ad hoc Wi-Fi

I am posting here asking for help, assistance, coaching.
It seems to me that I have all the pieces to properly modify the Sero 7 Pro ROM to accept ad hoc Wi-Fi connections. I've spent several days trying to find a simple step-by-step guide for applying github patches to existing kernels and flashable ROM. I have come to believe that no such simple guide/aid exists because the process itself appears to be complex.
The Nexus 7 CyanogenMod has been successfully modified for ad hoc Wi-Fi. My research indicates that the Sero 7 and the Nexus 7 are similar enough that the same patches should be able to be applied to the Sero 7 ROM. The Nexus 7 and Sero 7 both:
Use Android Jelly Bean 4.2.X
Have the same processor, 1.3GHz NVIDIA Tegra 3
Use the same Wi-Fi Chip, Broadcom BCM4330
Kernels use the same Driver, Broadcom bcmdhd Version 5.90.195.104
What I have is the kernel source
http://hisense-usa.com/support/firmware/Sero%207%20Pro_kernel_opensource_us.tar.gz
The full Stock ROM, latest version
https://skydrive.live.com/redir?resid=F7DECBA5BB726100%21108
Patches applied to Nexus 7 CyanogenMod ROM with detailed discussion
http://www.thinktube.com/android-tech/46-android-wifi-ibss
Briefly summarizing the discussion and code contained in the above Thinktube webpage:
The Kernel is patched making changes to the bcmdhd Wi-Fi driver
The ROM is patched making changes
to the wpa_supplicant
a few additions to the Android framework and
some changes to the Settings App
So in concept it seems pretty straightforward. Where I am struggling is the whole github process of applying the patch to the Kernel source. Then compiling the modified Kernel source. And applying the remaining patches to the ROM with the newly modified Kernel.
I need someone willing to work with me on the github piece. Or alternately coach me through that process.
So the resounding lack of response tells me either I've posted on the wrong forum or it is indeed as complex and cumbersome as I suspected.
But I may have figured out how to accomplish it myself. I have NOT figured out the github process. But I do know a little Linux and do run a virtual Ubuntu machine.
So I :
1. manually modified the Broadcom bcmdhd in the kernel source line by line.
2. swapped the wpa_supplicant file in the Sero7 stock ROM with the one from the Nexus 7 CyanogenMod ROM.
3. extracted the needed sero7_defconfig and initramfs.cpio.gz files
4. compiled the modified kernel source code and created a new boot.img
5. inserted the new boot.img to complete the modification of the Stock ROM
And if this all works, I’ll post my fix in a new thread, perhaps “Sero 7 Pro hoc Wi-Fi Fix”
wpa_supplicant
bardell3600 said:
So the resounding lack of response tells me either I've posted on the wrong forum or it is indeed as complex and cumbersome as I suspected.
But I may have figured out how to accomplish it myself. I have NOT figured out the github process. But I do know a little Linux and do run a virtual Ubuntu machine.
So I :
1. manually modified the Broadcom bcmdhd in the kernel source line by line.
2. swapped the wpa_supplicant file in the Sero7 stock ROM with the one from the Nexus 7 CyanogenMod ROM.
3. extracted the needed sero7_defconfig and initramfs.cpio.gz files
4. compiled the modified kernel source code and created a new boot.img
5. inserted the new boot.img to complete the modification of the Stock ROM
And if this all works, I’ll post my fix in a new thread, perhaps “Sero 7 Pro hoc Wi-Fi Fix”
Click to expand...
Click to collapse
Oh boy! I've been waiting to hear if someone got the ad-hoc going on the Sero 7 Pro. I've posted asking for help doing this too but never seemed to get a working answer. Did you get yours working and if so could you please post the wpa_supplicant file for the Sero? I would sure like to wifi tether to the Sero. It's the only device I have that doesn't see my phone's wifi.
Thanks a bunch!
Bob

[Q] Flashing custom kernel only on my Nexus 7 (2013)

Hi,
my only goal is to use my Nexus 7 (2013 version, running kitkat) to view digital television (dvb-t).
Therefore, have I unlocked it (with complete erase grrr), then rooted it.
And finally, read about one hundred message threads on xda to know how to compile dvb modules for my kernel (3.4.0-gac9222c).
My problem, after all this work, is that it seems that Google did not compile its kernel with modules support.
After doing
# lsmod, I got the following error:
/proc/modules: No such file or directory.
This means apparently that there is no modules support for this kernel.
http://stackoverflow.com/questions/18818442/loading-kernel-modules-in-android-4-3
My 2 questions is the following:
(1) is it possible to flash a kernel image on my nexus 7 to get module support
(2) is it possible to do that without reflashing my ROM (my stock ROM is enough for my needs)
Cheers,
Louis
I am now in the process of recompiling my own kernel for my Nexus 7 2013, incorporating the DVB-T drivers that I need.
I found a very good tutorial for doing this: http://pete.akeo.ie/2013/10/compiling-and-running-your-own-android.html
The only problem is that the sources of dvb usb drivers in the Android kernel are not up-to-date.
I am searching an easy way to inject the last sources from git://linuxtv.org/media_build.git into the Android kernel?
The directory structure is different. I think i will be forced to update the Makefiles and the Kconfig files by hand, and add & replace .c and .h files manually. I someone has a better (more lazy) solution, I am interrested :victory:
Meanwhile, I play with an old Freecom usb DVB-T stick that is supported by old media sources in the Android kernel.
Wrong forum, here is the 2013 model's one: http://forum.xda-developers.com/nexus-7-2013

[SOLVED!] Bluetooth doesn't work after compiling a kernel based on LOS 18.1 sources.

I'm kinda new here, so please excuse me if this is not the best place to ask and it should instead be posted in another section.
First, a bit of context: I recently bought a refurbished H910 to practice android development since it was fairly cheap, and after testing its features and unlocking the bootloader to install custom roms, i opted to start compiling a kernel of my own with some changes to begin involving myself with the development side of things. For now, i am using the Lineage OS 18.1 kernel sources on github as a base for the kernel, then after making sure that the kernel compiled, i flashed it into the phone and basically everything works with the only exception being the bluetooth, and maybe the IR Blaster, but that one is working just like the stock kernels on different Android 11 roms.
Now getting to the issue itself in more details... it boils down to the phone's bluetooth refusing to turn on while running that custom kernel of mine on any Android 11 ROM, be it Lighthouse, Superior OS Xcalibur or Lineage 18.1, the bluetooth tile gets stuck on the "Turning on..." icon animation for a while and then returns to the disabled state. Reverting to the stock kernels or even using other custom kernels like Lyb's or Gamma make the Bluetooth work again without needing a wipe, which tells me that the problem is definitely somewhere in my kernel. I could of course test it on some Android 10 ROMs, but the outcome will most likely be the same.
I even took some logcats via ADB Shell but they are kind of broad and mostly explain that the service had some problems with "com.android.bluetooth service has died: psvc PER", followed by a "scheduled restart of crashed service com.android.bluetooth...". Both of which never happen on those ROM's stock kernels, where the bluetooth works as expected. I looked around on Lyb/Gamma kernel sources on github, and there aren't any major differences to the defconfigs for example with the bluetooth driver configuration also being just about the same.
I'm not sure if this will be of any help, but as for the toolchains and compilers, i am using clang 11.0.2 383902b1 as the main compiler, gcc 4.9 as the ARM32 cross-compiler, and gcc from 4.9 up to 10.3 as the AARCH64 cross-compiler, all running on Manjaro. I also changed that combination dozens of times, but to no avail.
So am i missing something during the compilation process? With all those things i already checked, i keep getting a feeling that something really simple is going over my head. Also, i can post the link to my github repository here if needed, there's a branch made specifically to check the BT since it has only the changes made to assure that the kernel compiles.
Edit: The problem was solved!!! It actually comes down to using the exact toolchains provided by the lineage OS source tree for the device (that might be optional, but it's how i managed to get it working) and checking if everything has been installed correctly. It seems some files failed to download the last time i did a 'repo sync' on the source and that was what might have caused this.

Categories

Resources