q for the devs. - Captivate Q&A, Help & Troubleshooting

i run linux at home but am by no means an expert, i was wondering if anyone has ever tried to incorperate dkms into android. it would be great to be able to change drivers in a kernel that is already on your phone. like voodoo sound. with new versions coming out all the time some kernel builders get the updates out faster than others, some kernels may work better on one phone or another but not include newest drivers supercurio is putting out.
would it be possible to make something like dkms compatable with android?
and if not where can i find information about compiling my own kernels for android?

DKMS is generally used for things like VGA drivers.. tried and true technologies... Legacy stuff... In the mobile world, the hardware of today is not used tomorrow. There are Kernel Modules (KO) files, but they are not DKMS. DKMS is used more for generic building. KO files load slower then standard kernel files.
When building for a mobile platform you always want the latest, greatest kernel, all manditory functions included, all options made as modules, and all others excluded. DKMS is used when you reuse the same hardware or functions over and over again. DKMS is basically for legacy use. You build something once and never have to build it again.
I dont' think it will make it's way onto phones until it's practical.

Related

[Q] Is gingerbread(Android 2.3) coming to the Galaxy S I9000?

Roms based on froyo or gingerbread?
The discussion in the thread "30/Jun r1 (JFB) - MoDaCo Custom ROM for Samsung Galaxy S with Online Kitchen" is a bit confusing so I thought it best to make it a new topic to get it straight.
Will it be possible to make roms based on froyo, gingerbread or any other coming android version, before Samsung makes an update? As I understand psychoace it will be ”near impossible to get roms from other sources like Sense roms or Froyo”. Others are not so sure.
This is important as Samsung is known for its lack of interest in OS updates. Who knows if they will take gingerbread to GS? If they won't can it be done by the really smart guys?
I don't think even HTC will update there top line to V3 (ginger bread). Froyo is coming any way to GS in near future. Now ginger bread should be possible too as GS is power full enough to run. When? we should wait and see. Nexus just got updated to 2.2.
Will see how things go in future.
Samsung has released there kernel sources and there software sources. I haven't had a chance to look in to it deeply but if it has the code of the drivers etc.. it should be possible to merge (with some work obviously) sources and to compile froyo.
kimatrix said:
Samsung has released there kernel sources and there software sources. I haven't had a chance to look in to it deeply but if it has the code of the drivers etc.. it should be possible to merge (with some work obviously) sources and to compile froyo.
Click to expand...
Click to collapse
But don't those drivers only work with 2.1 and just simply won't with any version higher unless samsung releases new source and drivers for 2.2 and then 3.0. So if say samsung never releases anything any source/drivers that work with 3.0 then you would be out of luck to actually get everything to work.
MrDSL said:
But don't those drivers only work with 2.1 and just simply won't with any version higher unless samsung releases new source and drivers for 2.2 and then 3.0. So if say samsung never releases anything any source/drivers that work with 3.0 then you would be out of luck to actually get everything to work.
Click to expand...
Click to collapse
That is true but if you have the full sources you are able to look what the differences are and maybe patch those by your self. Assume a wlan driver is using an function that has changed or is gone in 2.2, then you can try to patch that by finding the new one for it to work with. If you don't have the sources it's much harder to do those kind of things.
As I sad you have the sources so you can play by your self even if samsung does not do anything. It does not mean it's easy and it does not mean it can be done fast. But it does mean it could be done.
kimatrix said:
That is true but if you have the full sources you are able to look what the differences are and maybe patch those by your self. Assume a wlan driver is using an function that has changed or is gone in 2.2, then you can try to patch that by finding the new one for it to work with. If you don't have the sources it's much harder to do those kind of things.
As I sad you have the sources so you can play by your self even if samsung does not do anything. It does not mean it's easy and it does not mean it can be done fast. But it does mean it could be done.
Click to expand...
Click to collapse
But the video drivers are already compiled. Can they be easily decompiled? It's not a source file if it's already compiled.
psychoace said:
But the video drivers are already compiled. Can they be easily decompiled? It's not a source file if it's already compiled.
Click to expand...
Click to collapse
Can they be decompiled and made to work? Of course!
Will someone be motivated to do all this work? Unknown.
Besides drivers arent the only issue to getting a new version of Android on a phone. If you dont have source for any proprietary userland daemons/apps (like radio?) that communicate with the hardware you will be SOL on that as well.
MMMMMMMMM if we can do it for the G1 we can do it SGS...the question is when and how much work. The Galaxy S will be Samsung's flagship device for A YEAR so I'd hope to get Gingerbread...unless Samsung are really stupid. Especially with a lot of US launches, they'll be able to relaunch with Gingerbread as it comes is my hope.
psychoace said:
But the video drivers are already compiled. Can they be easily decompiled? It's not a source file if it's already compiled.
Click to expand...
Click to collapse
Who told you that??? The source code of the GPU as well as every other coprocessor is there.
The two .o file that started this all fiasco are ok and you as long as the make file include them in the build they would work perfectly.
All they have inside is a simple elf code to tell the s3c*** to do whatever it needs to do. A source code wouldn't have been beneficial as it would have to be compiled differently for a different ARM instruction set .
kitsune223 said:
Who told you that??? The source code of the GPU as well as every other coprocessor is there.
The two .o file that started this all fiasco are ok and you as long as the make file include them in the build they would work perfectly.
All they have inside is a simple elf code to tell the s3c*** to do whatever it needs to do. A source code wouldn't have been beneficial as it would have to be compiled differently for a different ARM instruction set .
Click to expand...
Click to collapse
But when you need drivers for 2.2 the source code would be optimal because these drivers are not going to work without some hacking.
They are going to work as they are non kernel bound ELF files.
Guys this isn't a driver ,if it was a kernel module ( or "driver" s you call it) it would have been a .ko file and had a slightly different structure ( use readelf on a kernel module and then on this to see the difference). So no matter what it is when can use the compiled version as it not kernel bound
From quick inspection it seems like the injection code for the s3c*** . so basically its there so the kernel could reference to it when the code tells it to do so . So Basicly all we have to do is put it in the proper place when building the kerne.
So please DON'T PANIC
well the TP2 just got 2.2 FroYo (2.1 has more working drivers ATM).. but if we have it, how would it be different for the SGS to get FroYo?
You need to remember that while other companies can update kernel quite easily ( all the work is done for them by the chip manufacturer and some member of the community ) this isn't possible here as this is a chip only used in one android/other linux platform device and the company making the device also make the chip.
So give them a few weeks to work on it
J-Hop2o6 said:
well the TP2 just got 2.2 FroYo (2.1 has more working drivers ATM).. but if we have it, how would it be different for the SGS to get FroYo?
Click to expand...
Click to collapse
let's just say it will be the first time a non Samsung Rom has worked on a Samsung Android phone.
psychoace said:
let's just say it will be the first time a non Samsung Rom has worked on a Samsung Android phone.
Click to expand...
Click to collapse
Not true.
Look here: http://forum.samdroid.net/f28/lkmod-v-2-5-1-based-jce-en-upd-03-30-a-336/
I see a custom ROM made for the i5700
Everything is possible.
clubtech said:
Not true.
Look here: http://forum.samdroid.net/f28/lkmod-v-2-5-1-based-jce-en-upd-03-30-a-336/
I see a custom ROM made for the i5700
Everything is possible.
Click to expand...
Click to collapse
Did I say custom rom? No i said specifically non samsung based roms on a samsung device. That custom rom is based off of a Samsung rom.
This is the closest we have got to a Hero rom on a Samsung device.
http://androidforums.com/all-things-root-behold-2/60408-port-htc-hero-behold-2-wip.html
He couldn't get Rosie to boot so who knows what other problems he would of had after that (from the picture you can see he never got any network connection)
So there don't say I didn't give you any hope.
Froyo is offical. That's good, but we need to be looking past it to Gingerbread.
Froyo is announcedm confirmed, and now dated for the end of September, and that's great. But to me, that's not the question we need to be asking Samsung anymore, we need to be thinking past that.
The question people need to be asking Samsung, so we can get them on the record committed to it now, is will you release a Gingerbread update for the phone as long as the hardware is capable of supporting it. The OS is only 2-3 months from being unveiled if Google sticks to their time table, and if the rumors are true it'll be a much bigger overhaul than 2.1-2.2 is.
So unless we want our phones to be outdated before the end of the year, we need to start making a push as a community to get a commitment from Samsung to support not just the OS that was released 4 months ago, but also the much bigger one that's right around the corner.
2.2 is good.. proves everyone wrong who said "ooh its Samsung, of course they won't release Froyo."
but somehow, I doubt that samsung will somehow not upgrade SGS to 3.0. If they do, it might be a few months (at least) after everyone else gets it. The reason is, they could have new flagship devices out that they wanna push to the mass-markets, so putting gingerbread on that will boost the sales.
However, considering that they marketed the SGS so well, and have it well on its way, they might just put gingerbread on it
seriously, i see ads for SGS EVERYWHERE online.
mjgunn said:
[....]
So unless we want our phones to be outdated before the end of the year
[....]
Click to expand...
Click to collapse
I totally expect that my phone will be outdated by then. That's a consequence of the world we live in But then again, i'm a nihilist

[Q] How to get started making captivate roms

Hey Guys,
I'm a developer for a living, and I'm interested in possibly working on a custom rom for my captivate. I was doing some research on how to get started, but the stuff I found was for HTC phones and involved using a starter that only works for HTC stuff.
Where can I go to find information on doing this? I'm largely interested in trying to port gingerbread, but my understanding was that until we have the full source this wasn't really possible (at least for something actually useable on a daily basis). I see supercurio is working on gingerbread, so information specific to this would be really helpful.
Thanks guys, and sorry if this should have been put in the QA section, I figured it was related to development, and could possibly be a sticky if it leads to useful info.
Pretty broad question. First requirement, is obviously...learn java.
I'm not sure if there's any specific "HOW-TO CODE YOUR OWN CAPTIVATE ROM" threads anywhere; there's general information available on http://developer.android.com , but modifying ROM's depends on the device it was written for.
As far as porting gingerbread, it will be very difficult without source and will definitely require quite a bit of kernel work. For information specific on this, supercurio would be the one to ask. Of course, the IRC's are also a great place to get information.
By the way, welcome to XDA! And I commend your motivation to develop stuff for the community here.
http://forum.xda-developers.com/showthread.php?t=869614
Doc over in the I9000 forums has the above thread started. I look there.
geokhentix said:
Pretty broad question. First requirement, is obviously...learn java.
I'm not sure if there's any specific "HOW-TO CODE YOUR OWN CAPTIVATE ROM" threads anywhere; there's general information available on http://developer.android.com , but modifying ROM's depends on the device it was written for.
As far as porting gingerbread, it will be very difficult without source and will definitely require quite a bit of kernel work. For information specific on this, supercurio would be the one to ask. Of course, the IRC's are also a great place to get information.
By the way, welcome to XDA! And I commend your motivation to develop stuff for the community here.
Click to expand...
Click to collapse
Again, I am a developer for a living. I know Java, I'm not looking for coding tutorials. I'm looking for information specifically regarding the captivate.
As far as gingerbread, it sounds like what you are saying is that what people like supercurio are working on is not really gingerbread? More of a Frankenstein created with the sdk, mashing together 2.2 kernels and what has been released for 2.3?
lbbo2002 said:
http://forum.xda-developers.com/showthread.php?t=869614
Doc over in the I9000 forums has the above thread started. I look there.
Click to expand...
Click to collapse
Looking at that thread, it appears the roms being made are just edited versions of already compiled roms? Is samsung not required to post the full source of their roms?
I'm assuming the issue with starting with the original android source, is that we wouldn't have drivers for half of the hardware in the phone. Is the only choice then to load the already compiled drivers from the samsung builds into the rom?
epoplive said:
Again, I am a developer for a living. I know Java, I'm not looking for coding tutorials. I'm looking for information specifically regarding the captivate.
As far as gingerbread, it sounds like what you are saying is that what people like supercurio are working on is not really gingerbread? More of a Frankenstein created with the sdk, mashing together 2.2 kernels and what has been released for 2.3?
Click to expand...
Click to collapse
There are different levels of making ROMs IMO.
You can combine work from others and make your own ROM. This requires no coding experience. For instance, I took JH7_OTA, dropped in Atinms Voodoo 3 kernel, removed bloatware, added my own custom framework (icons), etc., signed it and flashed it.
Then there is the whole Kernel side of things that requires an entire development environment (Linux) and C/C++ programming skills. I'm trying to get to this point. You can start by downloading the source and building it in your own environment familiarizing yourself with the codebase.
Indeed. Packing a ROM and making the contents of the ROM are two different sides of the spectrum. Even some minor framework modifications can be performed by the most tech-inept, as long as they have a good resource to work off of.
epoplive said:
Again, I am a developer for a living. I know Java, I'm not looking for coding tutorials. I'm looking for information specifically regarding the captivate.
As far as gingerbread, it sounds like what you are saying is that what people like supercurio are working on is not really gingerbread? More of a Frankenstein created with the sdk, mashing together 2.2 kernels and what has been released for 2.3?
Click to expand...
Click to collapse
I was only prodding fun when I mentioned learning Java, just to break the ice. All I'm saying is trial and error is the best way to learn Android if you're already a decent programmer. Without knowing what the source code looked like before Samsung owned it, we don't really have a base environment to work off of, which means we are modifying work that was already modified from stock; which is why it will be pretty hard to find a lot of definitive coding information about the Captivate.
Supercurio isn't making a frankenstein 2.2-2.3 hybrid. The kernel is where all of the information about your hardware resides. Supercurio needs to take the Gingerbread kernel from the Nexus S, and modify it to run with our hardware. You can't run a 2.3 ROM without a 2.3 kernel; so we CAN'T use a 2.2 kernel to run full gingerbread; and since a 2.3 kernel doesn't exist for the Captivate, he is using the Nexus s's kernel as a base, or as a reference to merge the differences between the two, creating a kernel that will support the Nexus S ROM on a phone that isn't the Nexus S.
epoplive said:
Looking at that thread, it appears the roms being made are just edited versions of already compiled roms? Is samsung not required to post the full source of their roms?
I'm assuming the issue with starting with the original android source, is that we wouldn't have drivers for half of the hardware in the phone. Is the only choice then to load the already compiled drivers from the samsung builds into the rom?
Click to expand...
Click to collapse
Correct. We don't have the source code for Froyo yet for the Captivate(or an OTA for that matter ), a lot of ROM's being made are based off of the SGS I9000 2.2 source, and because we have that source, we have a pretty much fully functional "captivated" i9000 kernel.
geokhentix said:
Indeed. Packing a ROM and making the contents of the ROM are two different sides of the spectrum. Even some minor framework modifications can be performed by the most tech-inept, as long as they have a good resource to work off of.
I was only prodding fun when I mentioned learning Java, just to break the ice. All I'm saying is trial and error is the best way to learn Android if you're already a decent programmer. Without knowing what the source code looked like before Samsung owned it, we don't really have a base environment to work off of, which means we are modifying work that was already modified from stock; which is why it will be pretty hard to find a lot of definitive coding information about the Captivate.
Supercurio isn't making a frankenstein 2.2-2.3 hybrid. The kernel is where all of the information about your hardware resides. Supercurio needs to take the Gingerbread kernel from the Nexus S, and modify it to run with our hardware. You can't run a 2.3 ROM without a 2.3 kernel; so we CAN'T use a 2.2 kernel to run full gingerbread; and since a 2.3 kernel doesn't exist for the Captivate, he is using the Nexus s's kernel as a base, or as a reference to merge the differences between the two, creating a kernel that will support the Nexus S ROM on a phone that isn't the Nexus S.
Correct. We don't have the source code for Froyo yet for the Captivate(or an OTA for that matter ), a lot of ROM's being made are based off of the SGS I9000 2.2 source, and because we have that source, we have a pretty much fully functional "captivated" i9000 kernel.
Click to expand...
Click to collapse
Ah, thanks, that's pretty much the information I was looking for.

[Q] Can't build CM6 from sources. Help please!

Hi,
I'm trying to build cyanogenmod 6 (froyo) from sources on github for G1.
Sidenote. The reason I'm trying to do this is i'd like to modify kernel parameters. I'm trying to make the phone talk to external device using built in serial port. I can do it with my current CM6, but it looks like serial debugger engages and starts responding to the device and also steals some of the data being sent to phone.
To build I used instruction posted at cyanogen wiki "HTC Dream & Magic: Compile CyanogenMod (OS X)" which covers gingerbread but checked out froyo-stable branch at first. I know that gingerbread version stopped supporting G1 at some point last year.
Without much success even after fixing manifest to point to updated repo urls from kernel.org to googles repo etc. The problem is that apache-http seems incompatible with old sources and it is referenced by head.
I also tried froyo branch, but it doesn't build as well because something seem to be broken for dream_sapphire, and it is not present in the devices anymore.
I've tried searching for compilation errors, and general build questions/instructions here and on cyanogen's forum, but looks like CM6 is not very active these days.
Can someone point me into right direction where to search for relevant info on building it? Would getting a proper revision help or should I combine stuff from several branches to make it work?
I've already spent quite a lot of time figuring out how build is being configured and how things stitch together but without much progress on the actual build.
And with times required to sync a whole repo and build it, it is becoming frustrating.
Any help would be muchly appreciated!
Regards,
Oleg
It's dead.
I also wanted to make a cm6 rom, but I couldn't get anything to work.
I got the addresses all updated but it looks like a bunch of the files have completely dissappeared. You may be able to make it skip those, but then it may not work completely.
Go for AOSP?
Now that's a shame. I wanted to build CM because I'm familiar with it and the other thing is that they have reasonable instructions about building it. But at least I don't need to waste my time trying to figure out how to fix it.
In fact I don't need any extras they provide, a bare android would suffice to me if all the sensors and connectivity would be available. But I'm not familiar with internals of building vendor specific stuff. My understanding was that I need proprietary parts together with AOSP to build a working ROM and that's one of the things CM guys did. Correct me if I'm wrong.
aliher1911 said:
Now that's a shame. I wanted to build CM because I'm familiar with it and the other thing is that they have reasonable instructions about building it. But at least I don't need to waste my time trying to figure out how to fix it.
In fact I don't need any extras they provide, a bare android would suffice to me if all the sensors and connectivity would be available. But I'm not familiar with internals of building vendor specific stuff. My understanding was that I need proprietary parts together with AOSP to build a working ROM and that's one of the things CM guys did. Correct me if I'm wrong.
Click to expand...
Click to collapse
Nope AOSP is as easy to build now
Go to the android site and follow directions
Google for "build android"
At the part when doing repo init you need to get the right branch
Go to "build for devices" then scroll down for recommended branches and look for the dream
One thing you'll need to do differently is do "make otapackage" instead of plain "make"
And once that's done you'll need to tweak the zip and get rid of the "recovery" folder and tweak the updater-script
Oh yeah, and I don't know exactly how you would do this part, but you'll need to get the source for a newer kernel in there, like ezterry kernel and use it with 2708+ radio/spl
Unless you wanna use the AOSP kernel & spl & radio which is old
What I did is just flash his kernel after the rom, but you want to do kernel stuff so yeah...
Sent from my HTC Dream using Tapatalk

Budding dev needs some help

Hello all. I've recently been trying to get into Android development, more specifically Kernel development. I've played around with some kitchens and looked at the GB kernel sources from Samsung and tweaked it around.
Previously I previously learned Java to a point where I can put basic lines down and also more advanced stuff but with a bit of help here and there.
I have one question though, what would be the recommended path for creating an ICS Kernel. My plan is to start of with something "stock" and build up but I'm not quite sure what to consider stock seeing as the S1 never got ICS officially. Would I have to use CM9's Kernel sources and if so where do I acquire them.
I also have a good understanding of Ubuntu and its terminal and have a functional idea of what I'm doing there.

[Kernel] Shield Portable Kernel Development [Incl. Guide]

Welcome to the first custom kernel for the KitKat Shield.​
This thread is for the development and building of the Shield Portable kernel.
This is not intended to download a build, post issues, and return when fixed.
Kernel Source:
https://github.com/StarKissed/starkissed-kernel-roth
Kernel Downloads:
https://goo.im/devs/playground/shieldroth
The kernel can be built using the commands below or the included script.
Code:
make tegra11_android_defconfig -j$CPU_JOB_NUM ARCH=arm CROSS_COMPILE=$TOOLCHAIN_PREFIX
make tegra114-roth.dtb -j$CPU_JOB_NUM ARCH=arm CROSS_COMPILE=$TOOLCHAIN_PREFIX
make -j$CPU_JOB_NUM ARCH=arm CROSS_COMPILE=$TOOLCHAIN_PREFIX
App & Donations:
StarKissed [SKU] on Google Play allows you to configure many of the options provided by this kernel. Issues or comments about the app can be posted at the XDA StarKissed app thread
Donations are not being collected through the forum. If you would like to donate, you may do so through StarKissed [SKU] on Google Play by using the donate options located in the top right (the green dollar bill guy).
[Kernel] Shield Kernel Development
The included ramdisk is for update 98. If you are on 72, this will most likely result in a bootloop. Using the 72 ramdisk will not work with this kernel, as the source is specific to "OTA 5" according to the Nvidia gitweb.
I recently updated the source and changed a few commands that may explain why current source resulted in non-working builds. I will be testing builds soon and then begin modifying the kernel once the core build is verified working.
Nice, I hope there will also be an overclocked kernel for 4.4. I know it's silly but I miss the 4.3 overclocked kernel.
rylen said:
Nice, I hope there will also be an overclocked kernel for 4.4. I know it's silly but I miss the 4.3 overclocked kernel.
Click to expand...
Click to collapse
All the code is there, it just loops. I'm not sure what's going on with it. The shield tablet version works.
Quick question. Any chance you could update the usb ethernet drivers in this? Specifically, I'm suffering from this bug on an ASIX 88772 on the official kernel, and it seems their driver is rather out of date. Thanks, and keep up the good work!
bakageta said:
Quick question. Any chance you could update the usb ethernet drivers in this? Specifically, I'm suffering from this bug on an ASIX 88772 on the official kernel, and it seems their driver is rather out of date. Thanks, and keep up the good work!
Click to expand...
Click to collapse
Won't do much good until it boots
True enough, just thought I'd bring it up since it's a fairly easy fix. In the meantime, I threw together a stock kernel with an updated driver to get by. I had one problem after another with the latest official driver, but the good folks at LKML had already put some work in on v4.1.0 several years ago. Using drivers/net/usb/asix.c and usbnet.c from the 3.4.106 source built without problems.
Beginning to think I may have to settle for building against the full source on this one. It boots fine when doing that, but not built alone. The shield tablet builds fine alone, so there's no explanation for it.
you are going to make a new build of your kernel? if you need help with the tests i can help.
YamazakiRobert said:
you are going to make a new build of your kernel? if you need help with the tests i can help.
Click to expand...
Click to collapse
Things are a bit crazy, but once I can get all of the changes fixed up and it'll build clean, I'm going to try to run it over night.
Slightly off-topic, but I'll ask you since you're the only other person I know building a shield kernel. I built nvidia's kernel, changing only the two drivers associated with my ethernet, but for some reason console mode has stopped working now. Have you ran into a similar problem? Plugging HDMI in pops up the selector, but clicking on console mode doesn't do anything - it just stays on the selector screen.
bakageta said:
Slightly off-topic, but I'll ask you since you're the only other person I know building a shield kernel. I built nvidia's kernel, changing only the two drivers associated with my ethernet, but for some reason console mode has stopped working now. Have you ran into a similar problem? Plugging HDMI in pops up the selector, but clicking on console mode doesn't do anything - it just stays on the selector screen.
Click to expand...
Click to collapse
It shouldn't be related. You may need to check the proprietary drivers. I believe HDMI is one.
Didn't bother to find out what the problem was, it just stuck around because I was doing dirty builds as I tested. Once I got a few other tweaks and had some time, I did a clean build and it resolved itself. Did you manage to get your kernel booting when building it by itself? I'm sure I'm doing something wrong there too, but I've been grudgingly building the entire device, since that at least works reliably.
What is so special about this kernel compared to stock ? goodjob already btw, you're one of the few who actually have a kernel
It's really sad how not much development is going on, it's such a good device there is only like 1 release at the original section :/

Categories

Resources