[USB OTG] [11DEC13] [PATCH] Externally Powered USB OTG - Nexus 4 Original Android Development

Externally Powered USB OTG - Nexus 4
This is an all-in-one patch to enable externally powered OTG (technically usb host mode) support. It's built off either the stock kernel or Franco's kernel sources, and should work with any ROM (that these kernels otherwise support). Refer to the second post for details on modifications and additions.
Again, power MUST be supplied externally, as there is no way for the phone to provide it.
Requirements:
Power MUST be supplied to both the USB device and phone. The easiest way would be by using an OTG Y-cable:
If using a traditional OTG cable, a USB Y-cable can be used:
Some powered USB hubs also send power up to the host and can be used directly with a regular OTG cable.
I am not endorsing any specific product or seller. Links are provided solely as examples, and are by no means definitive. As long as the phone and device both get 5V (charger, computer, etc.), and the data pins are connected, host mode will work (provided enough current can be supplied).
Installation:
Simply install the zip in recovery. Script will automatically install/patch necessary files. Must reinstall any time ROM is updated.
To uninstall, simply reflash your ROM. Data wipe is not necessary. If for some reason that's not an option, use the flashable unmod script to remove ROM-side modifications. Flash your kernel of choice afterwards (must flash "reset" kernel first if flashing an "anykernel").
Recovery:
(Optional)
For support in recovery, I've created a sort of "any-any" script. It replaces the recovery's kernel with the boot one. Therefore, by flashing this after the main patch, OTG will effectively be enabled in recovery (after a reboot). However, it is on the actual recovery itself to provide support for usb drives-- TWRP does. Otherwise, you'll have to manually mount any drives via linux console commands.
For your own safety/sanity, ensure the main patch works before flashing this. If recovery fails to boot after flashing, it can easily be replaced by using GooManager or similar. Worst case scenario, a new recovery can always be flashed via fastboot.
Downloads:
(Changelog at end of second post)
MAKE SURE TO DOWNLOAD THE RIGHT VERSION FOR YOUR ROM.
I don't keep track of all the different ROMs so it's on you guys to figure out which one is appropriate. The -CM builds have the two "CAF" commits that are now required for CM and its derivatives (unless they have specifically reverted the associated commits).
Franco-CM builds make use of a ramdisk mod script, which may have unpredictable results. Be ready in case it doesn't boot.
Current:
4.4.x: 2013.12.11 1604ET: [fk r199] [fk r199-CM]
4.4.x: 2013.12.06 1445ET: [aosp r7]
4.4: 2013.12.03 1522ET: [fk r197] [fk r197-CM]
4.4: 2013.12.01 1855ET: [aosp r6]
recoverymod.zip
Old:
4.3: 2013.10.27 1518ET Franco r193: [JWR] [JSS/JLS] [JWR-CM] [JSS/JLS-CM]
4.3: 2013.10.17 1957ET STOCK: [JWR] Stock kernel with OTG -- Only for stock rom
4.2: 2013.07.29 1101ET Franco r165: [JDQ]
ziddey-otg-unmod-20131002.zip
Bugs / Notes:
An OTG cable has the ID pin grounded out, which is used to trigger usb host mode. However, ID pin detection is broken in the Nexus 4 (although working for Slimport detection). Instead, we rely on detection of a "proprietary" charger (voltage on the data pins) in order to determine when to enable host mode.
Self-powered devices (e.g. digital cameras) don't send power to the phone. This will cause the device to not be detectable. Therefore, external power is still required.
Slimport cannot work concurrently with usb data due to hardware limitations (Slimport takes over the usb data pins).
USB drive will automatically mount at /storage/usbdisk0 (also accessible at /usbdisk and /mnt/usbdisk). Media scanning should occur automatically. Make sure to unmount before removal to avoid data loss.
Stock Android only supports FAT for storage. NTFS/exFAT/ext4 partitions may require the use of a third party app like StickMount (CM now supports these partitions natively!).
There appears to be a minor bug in the AOSP code that prevents available space from being reported in Settings->Storage->USB Storage. The screenshot is of CM10.1, which has this fixed
Current builds do not allow for host mode without charging. Use this as a workaround:
RussianBear said:
For those that want to stop usb charging, create a script modifying this to either 1 (disabled) or 0 (enabled). Works for me Not responsible for your phone(s) exploding.
echo 1 > /sys/module/pm8921_charger/parameters/disabled
echo 0 > /sys/module/pm8921_charger/parameters/disabled
Click to expand...
Click to collapse
Standard Disclaimer-- Flashing this patch is at your own risk, and carries no warranty or liability on my part. The assumption is that you will perform due diligence before flashing and make any necessary backups if required.
Screenshots:
Credits:
CaptainMuon, for proving that host mode is possible on the Nexus 4.
Franco, for his kernel, which this patch is based off.
garyd9, for his command to patch platform.xml.
Chainfire, for his usb host wisdom, and article on secondary storage write permissions.
arpruss, for his compiled zip-for-android
All you guys for testing!

Patch Overview:
Kernel with modified msm_otg.c -- This will REPLACE whatever kernel you currently have installed. If you flash a different kernel on top, you will obviously lose OTG capability. This contains the necessary workaround to enable usb host mode ("OTG").
Modified init.mako.rc/init.mako.usbdisk.rc -- Required for creating usb drive directories.
Precompiled modified storage_list.xml -- Allows unmounting usb drive in Settings->Storage. Hex offsets for storageDescription patched during flash.
Addition to build.prop -- Enables downloading apps from play store that require usb host mode support.
Addition to platform.xml -- Workaround to allow apps write access to usb drives
Addition to handheld_core_hardware.xml -- Activate android.hardware.usb.host.xml
android.hardware.usb.host.xml -- Enables Android API support for usb host mode.
fstab.mako (4.3) / vold.fstab (4.2) -- Required for automounting usb drive
Modules cifs.ko, ff-memless.ko, hid-dr.ko, hid-logitech.ko, and xpad.ko (/system/lib/modules). Manually insmod as needed or create an appropriate init.d script to load on boot. These are only required for certain gamepads. Refer here for more information.
Patch Details:
There seems to be an issue with detecting the state of the ID pin on the OTG cable, so we need to come up with an alternate way of determining when to switch to host mode. drivers/usb/otg/msm_otg.c (kernel) is responsible for detecting the charger type and setting host mode, among other tasks. I noticed that when connected to a powered OTG cable, the charge type becomes USB_PROPRIETARY_CHARGER (vs USB_DCP_CHARGER when connected to the wall, and USB_SDP_CHARGER to a computer). This will be the condition that we use to trigger host mode.
Standard OTG cables will have the ID pin shorted to ground. There are also usb accessory charger adapters (ACA) that provide different resistances between these pins to signal functionality (see http://en.wikipedia.org/wiki/USB_On-The-Go#OTG_Micro_Plugs). Support for accessory charger detection isn't enabled in the kernel originally, and doesn't seem to work properly anyway. However, one of the modes is essentially what we're trying to achieve (ID_A): "A charger and a B-device are attached. The OTG device is allowed to charge and enter host mode." So I've added code when USB_PROPRIETARY_CHARGER is detected to simulate the case of ID_A being detected. Following through the code for host mode, certain events are handled differently when ACA support is enabled (specifically, suspension of host mode). In these instances, we need to simulate ACA support since ID_A is technically dependent on it (run into issues with the usb controller getting stuck in a suspended state otherwise). Now we have host mode with charging working properly.
Finally, we need a method of detecting when the OTG cable is unplugged so the device can switch out of host mode. Fortunately, since power (vbus) detection does work, we can use that. Normally, changes in vbus state are ignored while in host mode, so we need to address that. From there, we simulate ACA detection for the case of no ID_A, which is just clearing the ID_A bit and charger. Afterwards, it'll automatically reset the usb state, ready to start all over again.
The dirty hacks to msm_otg.c are complete, and externally-powered OTG is functional.
Refer here for actual changes: https://github.com/ziddey/mako/commits/nightlies-4.3-JSS
No changes are needed to the kernel's .config. Do not enable Drivers->USB->OTG support (we get our support through "OTG support for Qualcomm on-chip USB controller" which is already enabled) or Support for ACA (does not work and most users don't have the proper adapter anyway).
Now we run into a problem with usb storage. Since there is no /system/etc/vold.fstab, usb drives get automatically mounted to /mnt/shell/emulated/0 (at least in CM10.1), which overloads the emulated sdcard, and causes major problems. So we create /system/etc/vold.fstab:
Code:
dev_mount usbdisk /storage/usbdisk0 auto /devices/platform/msm_hsusb_host/usb2
Update:
In 4.3, Google did away with vold.fstab, instead unifying mounting with fstab.mako (on the ramdisk). The replacement line would be:
Code:
/devices/platform/msm_hsusb_host/usb2 /storage/usbdisk0 auto defaults voldmanaged=usbdisk0:auto
Click to expand...
Click to collapse
Update:
In 4.4, mountpoint is set to auto instead of /storage/usbdisk0, and will be taken care of by vold / fuse daemon.
Click to expand...
Click to collapse
But /storage/usbdisk0 does not exist, so it will fail to mount. We will be using /init.mako.rc to create this directory and symlink associated legacy ones. This file resides in a ramdisk (which combines with the kernel to form boot.img), so we need to modify that instead of /init.mako.rc on the device itself (since it wouldn't be able to persist through a reboot). As well, we define the environmental variable SECONDARY_STORAGE. Below the analogous /storage/sdcard0 lines, add:
Code:
export SECONDARY_STORAGE /storage/usbdisk0
mkdir /storage/usbdisk0 0666 system system
symlink /storage/usbdisk0 /usbdisk
symlink /storage/usbdisk0 /mnt/usbdisk
Update:
In 4.4, usb disks must be further FUSE mounted. Rather than insert the script into init.mako.rc, it will now reside in init.mako.usbdisk.rc and be imported to init.mako.rc (strictly for ease/neatness and not standard convention):
Code:
# USB Storage -ziddey
on init
mkdir /mnt/media_rw/usbdisk0 0700 media_rw media_rw
mkdir /storage/usbdisk0 0700 root root
export SECONDARY_STORAGE /storage/usbdisk0
# Support legacy paths
symlink /storage/usbdisk0 /usbdisk
symlink /storage/usbdisk0 /mnt/usbdisk
service fuse_usbdisk0 /system/bin/sdcard -u 1023 -g 1023 -d /mnt/media_rw/usbdisk0 /storage/usbdisk0
class late_start
disabled
Click to expand...
Click to collapse
In order to enable Settings->Storage->USB Storage, res/xml/storage_list.xml in /system/framework/framework-res.apk needs to be modified. We should be able to simply inject an encoded version of our modified storage_list.xml. I'm not sure if it's possible to simply encode a single file, so I decompiled framework-res.apk in order to make the following addition to res/xml/storage_list.xml (inside StorageList):
Code:
<storage android:mountPoint="/storage/usbdisk0"
android:storageDescription="@string/storage_usb"
android:primary="false"
android:removable="true" />
After recompiling, we should now be able to extract our newly encoded storage_list.xml for use with any ROM's framework-res.apk.
To allow downloading apps from the market that require usb host support, we need to add the following to /system/build.prop:
Code:
ro.usb.host=1
To enable android api support for usb host, we need to create /system/etc/permissions/android.hardware.usb.host.xml with the following:
Code:
<?xml version="1.0" encoding="utf-8"?>
<permissions>
<feature name="android.hardware.usb.host" />
</permissions>
Now to "activate" this file, we add to /system/etc/permissions/handheld_core_hardware.xml:
Code:
<feature name="android.hardware.usb.host" />
Google assigned a different permission group for secondary storage devices (e.g. usb drives), media_rw, for which user apps cannot have write access (Chainfire has a good article on the issue here). We need to modify /system/etc/permissions/platform.xml to allow write access. Add the line in red ("officially" used by Samsung):
Code:
<permission name="android.permission.WRITE_EXTERNAL_STORAGE" >
[color=red]<group gid="media_rw" />[/color]
<group gid="sdcard_rw" />
</permission>
That's it! Externally powered usb host mode should be fully functional.
For full disclosure, these are the changes to the kernel config vs stock (really just NTFS and modules):
Code:
echo "CONFIG_INPUT_JOYSTICK=y" >> .config
echo "CONFIG_JOYSTICK_XPAD=m" >> .config
echo "CONFIG_JOYSTICK_XPAD_FF=y" >> .config
echo "CONFIG_JOYSTICK_XPAD_LEDS=y" >> .config
echo "CONFIG_INPUT_FF_MEMLESS=m" >> .config
echo "CONFIG_HID_LOGITECH=m" >> .config
echo "CONFIG_LOGITECH_FF=y" >> .config
echo "CONFIG_LOGIRUMBLEPAD2_FF=y" >> .config
echo "CONFIG_LOGIG940_FF=y" >> .config
echo "CONFIG_LOGIWHEELS_FF=y" >> .config
echo "CONFIG_HID_DRAGONRISE=m" >> .config
echo "CONFIG_DRAGONRISE_FF=y" >> .config
echo "CONFIG_CIFS=m" >> .config
echo "CONFIG_NTFS_FS=y" >> .config
# echo "CONFIG_USB_DEBUG=y" >> .config
sed 's/\(CONFIG_USB_STORAGE_DEBUG\)=y/# \1 is not set/' -i .config
Changelog:
4.4: 2013.12.01 0349ET: [fk r196] [fk r196-CM] [aosp r5] aosp includes gamepad kernel modules.
4.4: 2013.11.29 0219ET: [fk r195] [fk r195-CM] CM build attempts to patch Franco ramdisk mods on the fly, so be prepared if things go south.
4.4: 2013.11.21 1922ET: [fk r194] [aosp r2] Update to 4.4 configuration for mounting usbdisk.
4.3: 2013.10.22 2201ET r191: [JWR] [JSS/JLS] Allow potentially faster charging in host mode, re-add manual host mode
4.3: 2013.10.22 2204ET r191-CM: [JWR] [JSS/JLS] ^ + 2 "CAF" commits for CM compatibility
4.3: 2013.10.09 2148ET r190: [JWR] [JSS/JLS] Re-enable USB debug messages
4.3: 2013.10.01 1954ET r188: [JWR] [JSS/JLS] Zipalign framework-res.apk
ziddey-otg-r183-09141713.zip ziddey-otg-r183-JSS-09141713.zip Add SECONDARY_STORAGE env., do ramdisk patching during flash, include CIFS module -- rebase to r183.
ziddey-otg-r182-09041823.zip ziddey-otg-r182-JSS-09041823.zip Remove module unloading support, patch handheld_core_hardware.xml -- rebase to Franco r182.
ziddey-otg-r178-08240234.zip ziddey-otg-r178-JSS-08240238.zipDisable modversions, enable kernel wakelock stats-- rebase to Franco r178.
JSS15J 4.3.0 2013.08.13 1533ET: ziddey-otg-r174-08131533.zip First release for JSS15J. Updated to 4.3's new unified fstab (native mounting support). Using an "anyramdisk" method for compatibility with different ROMs (specifically, different su implementations). Based off Franco r174.
2013.07.29 1101ET: ziddey-otg-r165-07291101.zip Maintenance build-- rebase to Franco r165.
2013.07.14 2015ET: ziddey-otg-r163-07142015.zip Allow automatic host mode without charging-- rebase to Franco r163.
2013.07.08 1420ET: ziddey-otg-r162-07081420.zip Update storage_list.xml for compatibility with new CM nightlies-- rebase to Franco r162.
2013.06.28 1551ET: ziddey-otg-M3-06281551.zip Maintenance build-- rebase to Franco M3.
2013.06.27 0427ET: ziddey-otg-r156-06270427.zip Re-enable read-only NTFS support in kernel.
2013.06.06 1736ET: ziddey-otg-r151-06061736.zip Releases will now include modules ff-memless.ko, hid-dr.ko, hid-logitech.ko, and xpad.ko (/system/lib/modules). Manually insmod as needed or create an appropriate init.d script to load on boot. Rebase to Franco r151.
2013.05.25 0749ET: ziddey-otg-05250749.zip Fix compatibility issue with CWM (MTP crashes).
2013.05.23 2119ET: ziddey-otg-05232119.zip Start charging immediately when entering host mode. This resolves issues with proprietary chargers.
2013.05.22 2305ET: ziddey-otg-05222305.zip Rebase to Franco's r140. Revert checks for actual proprietary chargers in favor of manually disabling automatic host mode (temporary). Issue "# echo disable > /sys/kernel/debug/msm_otg/aca" to disable automatic host mode (enable to re-enable).
2013.05.17 0107ET: ziddey-otg-05170107.zip Added check for other proprietary charger case. Rebase to Franco's r137.
2013.05.15 0124ET: ziddey-otg-05150124.zip Attempt to detect actual proprietary chargers (Apple-compatible) and charge properly. Rebase to Franco's r136.
2013.05.09 1729ET: ziddey-otg-05091729.zip Should now patch precompiled storage_list.xml to address incorrect strings (Internal Storage/USB Storage). Re-enabled verbose usb debugging messages (dmesg).
2013.05.06 1846ET: ziddey-otg-05061846.zip Maintenance build. Based off Franco's current nightlies branch (r134?). Updated storage_list.xml to match current CM nightlites. Removed freshen flag to hopefully address issues with framework-res.apk not being patched (thanks sga999). Verbose usb debugging messages not enabled (unaltered r134 config)
2013.04.07 0355ET: ziddey-otg-04070355.zip Now modifies /system/etc/permissions/platform.xml to allow app write access to usb storage (thanks garyd9 for script code). Kernel build number reverted to 105 to match Franco's M1 build number.
2013.03.27.2338ET: ziddey-otg-03272334.zip Allow host mode when slimport connected (must manually enable for now. not sure if it actually works, so please report results.) Prevent forced host mode from entering suspended state so it won't get stuck (perhaps worth reinvestigating if we ever get internal power working). Allow forcing mode via /sys/kernel/debug/msm_otg/mode regardless of current state (original code had conditions that were unreasonable. it is designed to be used for debugging after all..). Forgot to reset the build number; should be 105. Would only potentially matter if using Franco's app.
2013.03.23 2000ET: ziddey-otg-03231951.zip All-in-one update now enables android api for usb host mode. Should automatically rescan media library when usb storage is connected. Kernel updated to Franco M1 (milestone), and will probably stay here for a while.
2013.03.17 1548ET: otg-aio-20130317.zip All-in-one flashable zip that includes modified kernel/ramdisk, vold.fstab, and precompiled storage_list.xml for framework-res.apk (thanks arpruss for precompiled zip-for-android). Kernel unchanged from last release (Franco r102 base), but removed unrelated line previously added to default.prop in ramdisk
2013.03.14 1648ET: otg-franco-boot-03141621.img Should have fixed all issues involving unpopulated hubs, unplugged devices, host mode timeout, and charging. Changed main mount point to /storage/usbdisk0 since that seems to be the new standard (manually update vold.fstab accordingly). Based on Franco's git as of 3/12 (after r102)
2013.03.11 2244ET: otg_boot_r3.img Interim build to address wall charging issues (do not attach/detach devices while otg cable connected to phone)
2013.03.09 0739ET: otg_boot_r2.img Should charge (faster) in host mode
2013.03.08 1128ET: otg_franco.zip Initial release in this thread.
2013.03.07 1350ET: franco-otg-201303071328.img "Pre-alpha" build posted in CaptainMuon's thread. Forces disabling of host mode on device unplug.
2013.03.07 1102ET: franco-otg-201303071032.img "Pre-alpha" build posted in CaptainMuon's thread. Forces host mode on detection of "proprietary" type charger (vs usb = sdp, wall = dcp).
References:
Typical Configuration Examples | Android Developers: http://source.android.com/devices/tech/storage/config-example.html
External Storage Technical Information | Android Open Source: http://source.android.com/tech/storage/
chainfire[dev~blog] - Is Google blocking apps writing to SD cards?: http://www.chainfire.eu/articles/113/Is_Google_blocking_apps_writing_to_SD_cards_/

Re: [OTG] [08MAR13] [DIRTY HACKS] OTG Kernel / Ramdisk / Framework (Seeking Devs)
Just for clarification this still requires external power via a y cable right?
Sent from my Nexus 4 using XDA Premium HD app

Yes, still requires external power. Currently, the hack triggers host mode when detecting "USB_PROPRIETARY" charger.

ziddey, is it possible for you to make a framework file for the stock rom? Also, you've given us .img files before. I'm assuming we can flash these .zip files during recovery (e.g. twrp)?
EDIT: I just tried this without the framework file since I'm on stock rom. I flashed the kernel through twrp, but the otg_vold zip would not flash (just said "failed"). Maybe it's not supposed to?. I manually put it in /system/etc. Let me know if I should have been able to flash it.
It works as you described, with usbdisk, no stickmount required. However, the phone is no longer charging like it did with your prior kernels. Maybe that should have been expected, but I certainly liked the fact that I had that "feature" before (with my cable from post #40...it did NOT charge with other OTG or Y-cables).
Strange, but a flash drive works, but a microsd card reader does not. It was working with your prior kernels. EDIT: It seems to be finicky, but I can get that microsd card reader to work also.
Thanks so much for your efforts!

Re: [OTG] [08MAR13] [DIRTY HACKS] OTG Kernel / Ramdisk / Framework (Seeking Devs)
Nice work man.. Will give a try
Sent from my Nexus 4 using xda app-developers app

Made some updates. Should now charge (faster) in host mode.
otg_boot_r2.img: http://d-h.st/Oky Modified kernel/ramdisk based on 3/1 git clone of Franco's kernel

an idea
what happens if you make a manual switch for usb host mode? like when we need to plug usb, we change the state?

sga999 said:
ziddey, is it possible for you to make a framework file for the stock rom? Also, you've given us .img files before. I'm assuming we can flash these .zip files during recovery (e.g. twrp)?
Click to expand...
Click to collapse
Gone back to image files again. One less step to do this way.
EDIT: I just tried this without the framework file since I'm on stock rom. I flashed the kernel through twrp, but the otg_vold zip would not flash (just said "failed"). Maybe it's not supposed to?. I manually put it in /system/etc. Let me know if I should have been able to flash it.
Click to expand...
Click to collapse
You're right; I hadn't tested it, and assumed I'd be able to just hack up a different zip for use. Pulled it for now.
It works as you described, with usbdisk, no stickmount required. However, the phone is no longer charging like it did with your prior kernels. Maybe that should have been expected, but I certainly liked the fact that I had that "feature" before (with my cable from post #40...it did NOT charge with other OTG or Y-cables).
Click to expand...
Click to collapse
I'm surprised you didn't have issues with the prior builds. I don't think I ever changed anything. That said, it should be fixed now. Let me know how it works.
Strange, but a flash drive works, but a microsd card reader does not. It was working with your prior kernels. EDIT: It seems to be finicky, but I can get that microsd card reader to work also.
Click to expand...
Click to collapse
Likely an issue on your end since I don't think anything was changed that would cause this. Are you trying to use both the flash drive and microsd at the same time? I'm not sure how that'd be handled-- upon insertion of the second drive, either nothing happens, or it overloads the first drive. As it is, I'm guessing my implementation of usbdisk isn't properly done.
Thanks so much for your efforts!
Click to expand...
Click to collapse
No problem! More of a personal challenge/desire. Really hoping that a real dev takes notice.

ereghro said:
what happens if you make a manual switch for usb host mode? like when we need to plug usb, we change the state?
Click to expand...
Click to collapse
You mean like CaptainMuon's build, where you change /sys/kernel/debug/msm_otg/mode?
Originally, there were issues with that method after unplugging the OTG cable, but that may have been fixed with the hacks to the OTG_STATE_A_IDLE case. It's possible that the other modifications will now cause problems with with the debug mode, but I'm imagining it just makes it unnecessary (except for debugging purposes) since it's not actually triggering a_host based on the ID pin, but rather by the detected charger.
Is there a particular reason you want to use a manual switch? I can re-enable it in the next build.

ziddey said:
Gone back to image files again. One less step to do this way.
You're right; I hadn't tested it, and assumed I'd be able to just hack up a different zip for use. Pulled it for now.
I'm surprised you didn't have issues with the prior builds. I don't think I ever changed anything. That said, it should be fixed now. Let me know how it works.
Likely an issue on your end since I don't think anything was changed that would cause this. Are you trying to use both the flash drive and microsd at the same time? I'm not sure how that'd be handled-- upon insertion of the second drive, either nothing happens, or it overloads the first drive. As it is, I'm guessing my implementation of usbdisk isn't properly done.
No problem! More of a personal challenge/desire. Really hoping that a real dev takes notice.
Click to expand...
Click to collapse
ziddey, I don't think you answered about me wanting a stock version of framework-res. I tried to create it with the Framework Flasher that you suggested, and it seemed to complete successfully. But when I flash it, it stops at the Nexus 'X' logo...it does a little vibration every minute or so, but never comes out of that. I even used that same tool to decompile, recompile WITHOUT any changes, sign it, etc., but the result is the same. So....either the tool isn't really working or I'm doing something else wrong. Any special instructions on how to flash the update.zip...or what it must be flashed with? I tried flashing it alone, then tried with your kernel (2 separate steps in twrp).
I haven't had enough time yet to get in much testing, but YES! Charging has returned!
No, I'm not trying both devices at the same time, so I don't know what is going on with the microsd. I'll keep trying to figure it out.
I'd like to know how to see logs of what's going on, like when you say there is "overload" (or other problems). Can you tell me what you're looking at to see errors, status, etc.?
I understand how you feel about the personal challenge. I'm that way too....I love to see things work and won't quit! But unfortunately, I don't have the expertise to help you here. But I'll certainly test it! I can't understand why dev's aren't joining you. And I may be the only one downloading your files (based on counts on dev-host). Very strange.

Did you update the apktool components? The components in wesf90's Framework Flasher (http://forum.xda-developers.com/showthread.php?t=1432152) are old and don't support JB4.2.
Down the new apktool and dependencies from http://code.google.com/p/android-apktool/downloads/list and replace the ones in wesf90's kit. That's all I did, and it seemed to work fine for me.

ziddey said:
Did you update the apktool components? The components in wesf90's Framework Flasher (http://forum.xda-developers.com/showthread.php?t=1432152) are old and don't support JB4.2.
Down the new apktool and dependencies from http://code.google.com/p/android-apktool/downloads/list and replace the ones in wesf90's kit. That's all I did, and it seemed to work fine for me.
Click to expand...
Click to collapse
I updated apktool and aapt. And everything ran perfectly. Most people who had not updated yet said it failed somehow, then after updating, it worked. But I updated the tools first, never got errors, so I think it's creating the update.zip properly. So I'll ask this one more time, and if you don't want to or can't do this, please let me know. Can you create the framework-res.apk zip file for the stock rom for me? Maybe I would then be able to compare my update.zip to yours and see what went wrong.
If I already have your kernel installed, can I just bring up twrp recovery and flash the single update.zip for the framework? Or is it more complicated than that? I'm thinking I must be missing something about how to flash the update.zip.
Can you tell me how to see logs that show the overload and other issues? Again, please just let me know, and if you don't want to answer this, I'll stop asking.
I appreciate all that you've done, and I certainly don't want to ask you too much. I just need to know if you're missing the questions or don't want to answer...which is fine.

sga999 said:
I updated apktool and aapt. And everything ran perfectly. Most people who had not uproperlyyet said it failed somehow, then after updating, it worked. But I updated the tools first, never got errors, so I think it's creating the update.zip properly. So I'll ask this one more time, and if you don't want to or can't do this, please let me know. Can you create the framework-res.apk zip file for the stock rom for me? Maybe I would then be able to compare my update.zip to yours and see what went wrong.
If I already have your kernel installed, can I just bring up twrp recovery and flash the single update.zip for the framework? Or is it more complicated than that? I'm thinking I must be missing something about how to flash the update.zip.
Can you tell me how to see logs that show the overload and other issues? Again, please just let me know, and if you don't want to answer this, I'll stop asking.
I appreciate all that you've done, and I certainly don't want to ask you too much. I just need to know if you're missing the questions or don't want to answer...which is fine.
Click to expand...
Click to collapse
Sounds like the update script is fine, the problem is with your framework. Either it's not being recompiled properly or the changes you're making are causing problems. What versions of the tools are you using?

So if this requires external power, would an external hdd with external power source work, in theory? Or does the USB itself need to carry a current to make it work?

MWBehr said:
Sounds like the update script is fine, the problem is with your framework. Either it's not being recompiled properly or the changes you're making are causing problems. What versions of the tools are you using?
Click to expand...
Click to collapse
I've tried it with no changes at all, i.e. decompile and recompile with no changes (my post #11 describes this in more detail). So as you said, the recompile must not be working.
My versions are:
aapt.exe v0.2
apktool.jar 1.5.2 but unfortunalely, frameworkflasher's runme.bat always does "echo version 1.4.3" (this threw me off for a while!)
I only replaced aapt.exe and apktool.jar. Are there other .exe or .dll files that need to be replaced also? Maybe I'm just doing an incomplete job of updating the files.
Thanks for your help.

sga999 said:
Can you create the framework-res.apk zip file for the stock rom for me?
Can you tell me how to see logs that show the overload and other issues?
Click to expand...
Click to collapse
Upload your framework-res.apk and I'll try to mod it. Not sure why it's not working for you though.
I haven't combed through the logs to look for when it's mounted, but since you created vold.fstab, it shouldn't be an issue. Maybe it didn't affect the stock rom anyway. If it did mount at /mnt/shell/emulated/0, internal storage would no longer be accessible. I had issues even opening Android settings, nevermind storage. Of course, you could simply check your mounts with the mount command, or use df to see mounts / disk space.
hp420 said:
So if this requires external power, would an external hdd with external power source work, in theory? Or does the USB itself need to carry a current to make it work?
Click to expand...
Click to collapse
In theory, yes. However, I'm imagining that a powered external hdd isn't going to be sending power out the usb port, and since the charger type is currently used to force host mode, it won't switch automatically. This could be a potential reason for the debug /sys/kernel/debug/msm_otg/mode, so I'll enable it in the next build. Unfortunately, I'm imagining that it still won't work though, seeing how it'd get stuck in a_idle. However, it does give me some ideas for trying to trace the root issue, or at least figuring out another workaround.

ziddey said:
Upload your framework-res.apk and I'll try to mod it. Not sure why it's not working for you though.
Click to expand...
Click to collapse
ziddey, here are links to my framework-res.apk and the update.zip. They are unmodified stock, i.e. I let framework flasher decompile, recompile without any changes, sign, etc. You may have no interest in the update.zip, but if what you create "matches" mine (not sure if a byte by byte compare will work), I don't think it will help for you to give yours to me. But again, just ignore that .zip if you want to.
I'm not very familiar with uploading, so if I'm not supposed to put direct links here, let me know.
http://www.mediafire.com/?wxcnozb2e5u8wps
http://www.mediafire.com/?visp1jzai8aqisp
What I mean about the log is that I don't know what log you look at. I know there's logcat, dmesg, maybe others, but I've never looked at them. So I wanted to learn a little more by looking at the same thing you look at when you notice various errors.
Thanks for your help.

edit: DO NOT DOWNLOAD. Tested by sga999 and does not work.
http://d-h.st/Z2s md5sum: 2b07609be9c462a0f4ba54c141dc2e88
your update.zip db087c101a8c07aa3606102128c96051
mine 19642b12da5a6fd372280c3e33fa8247
Report if that works. May be of interest to others. Is that stock 4.2.2 JDQ39?

ziddey said:
http://d-h.st/Z2s md5sum: 2b07609be9c462a0f4ba54c141dc2e88
your update.zip db087c101a8c07aa3606102128c96051
mine 19642b12da5a6fd372280c3e33fa8247
Report if that works. May be of interest to others. Is that stock 4.2.2 JDQ39?
Click to expand...
Click to collapse
Yours fails also! I have given it about 6 minutes, and it's stuck on the 'X'. I've waited longer than that before, maybe 10 minutes, but I don't ever think it should take more than a couple of minutes, right? UPDATE: I've now waited 11 minutes.
Yes, I gave you /system/framework/framework-res.apk from stock 4.2.2 JDQ39. That's what I'm running.
I have the unsigned and signed apk's saved from the various steps of Framework Flasher. It would be interesting to know where it goes wrong. I'm pretty sure the signed apk has the same problem, but I can't be sure I installed it properly (I read various posts about putting it in /system, fixing properties, cut/paste into /system/framework). It reboots immediately after I do the paste.
I would guess that the recompile is somehow not working. I suppose I could try to go through the individual steps on my own...but I sure had hoped to use this tool, just like you did!
Thanks for creating it for me...at least it's not something I was doing wrong with the tool!

Related

[Q] installing custom kernel

Hi i was just looking for some quick clarification if anyone is willing.
Boot into Clockwork Recovery. -DONE
Navigate to "mounts and storage". -DONE
Select "mount USB storage". -DONE
Copy /usr/src/tegratab/boot-custom-kernel.zip to the mounted filesystem. -HOW?
I tried adb push /usr/src/tegratab/boot-custom-kernel.zip /sdcard I dont believe it worked since nothing actually happened. I didnt even get my command line back. Im just waiting though, its been about 10 minutes though, I really dont think anything is happening. Actually it just finished, and now my tab is locked up. After I fix this I hope someone will be able to tell me how to properly install this. Also when I go into the android system then turn on usb storage device and try and drag and drop it says its going to take 3 hours?
I cant seem to figure out how to copy my file to "the mounted filesystem" I dont get a filesystem that I can drag and drop my zip into, I dont see or know of a command to do it through the terminal. So how can I accomplish this?
Thanks!
DKS1282 said:
Hi i was just looking for some quick clarification if anyone is willing.
Boot into Clockwork Recovery. -DONE
Navigate to "mounts and storage". -DONE
Select "mount USB storage". -DONE
Copy /usr/src/tegratab/boot-custom-kernel.zip to the mounted filesystem. -HOW?
Click to expand...
Click to collapse
Need details--
Whose kernel is this? Is it for the gTab? Where was it compiled from (source)? Is it stable? Has it been tested? Why is the guy telling you to copy the zip file onto the internal SD via ClockworkMod when you can do it more easily by other means? Can I have a look at the contents of the zip file?
really? in order to install it you have to know all that? The zip file is over 1.5 gigs.. How do you propose I get it to you?
DKS1282 said:
really? in order to install it you have to know all that? The zip file is over 1.5 gigs.. How do you propose I get it to you?
Click to expand...
Click to collapse
This kernel better be able to sing and dance for you if it's that big. What the hell is in there? I want to see what's in there now.
DKS1282 said:
really? in order to install it you have to know all that? The zip file is over 1.5 gigs.. How do you propose I get it to you?
Click to expand...
Click to collapse
This is why I asked you for the details. A compiled kernel for the gTab, along with the most useful modules, plus the installer program, is about 3MB, max.
The complete Linux kernel source, uncompressed, is around 450MB. Compressed, it is ~100MB. A compressed 1.5GB file would therefore contain a heck of a lot more than just the kernel sources. What were you expecting to happen here? Ram a boat-load of source into the tablet and it should automatically compile and install everything for you?
Actually no... I followed a link and followed directions and I actually thought I was doing well till I saw the size of the file... Im actually going to work on recompiling the kernel again. It was a version of pershoots but I think the tutorial I was working off of is incorrect as are most of them on the net. Im learning but sadly not at the pace I would like, Im new to linux and android. Thank you all for the help so far. I'll post what ive done here in a lil bit and I was wondering if I would be able to get advice on how to install it... Ill even link the tutorial I follow. Here it is http://forum.xda-developers.com/showthread.php?t=916198
Now that Ive gone over it again its an issue in the zipping... For some reason my 28.7M file zips to 1.6gb WTF? Here is the command I used
From inside the file where the contents is to be zipped zip -r /usr/src/tegratab/boot-custom-kernel *
Yes evey time I zip it it comes out to 1.6 gigs. The system file is is pretty small but after its been ziped it actually takes most of the 1.6gb... Could I possible send the meta file, kernel file, and system file? Or maybe someone could tell me how to correctly do this? Ive followed the directions in that link and thought I was getting a legit output but I guess that im not even close.
GOOD NEWS EVERYBODY! I can save you 15% on car insurance...
Actually I was able to figure out what has happened... There were some symlinks that didnt get removed so it grabbed everything in that link and zipped it as well... after I fixed the issue it zipped correctly and I was even able to get it to install... Sadly the prolific driver for the 2303 is still not included even though it shows on the kernel menuconfig as being included, I guess Im going to try again and make it modular and see if I can get the driver file to install that way.. Ill let you know how it goes and also upload and link it if I can get it to work in case someone else wants to grab it and build off it. Im also planning on helping out the forums a little bit...
Thank you again.
DKS1282 said:
Sadly the prolific driver for the 2303 is still not included even though it shows on the kernel menuconfig as being included...
Click to expand...
Click to collapse
Attach the .config (kernel configuration file) so I can look at it.
Does running dmesg on the new kernel show the driver loading/initializing?
Are the /dev/ttyUSB* device files present? Are the permissions for those serial devices correct? I'm not sure what they ought to be, but try making them read+write for all--at least while you are testing things: chmod 666 /dev/ttyUSB* as root.
Here is actually the zipped kernel file. When it compiles it does show the drivers being installed, I just cant get the device to recognize the Prolific cable. Ive tried including them, Ive tried modular, im not sure how to make it work, or if there is something im missing entirely. Thanks again.
http://www.mediafire.com/?nil9bh3spu6sp78
DKS1282 said:
Here is actually the zipped kernel file.
Click to expand...
Click to collapse
The binary is no use to me--I don't have your hardware. The .config file is what I need.
When it compiles it does show the drivers being installed, I just cant get the device to recognize the Prolific cable.
Click to expand...
Click to collapse
The real test is the dmesg output, not whether the driver is being compiled in.
However, I think your problem is that you've compiled the wrong driver. What you need is the driver for "Prolific PL-2301/2302 based cables" which is included by enabling:
config USB_NET_PLUSB
which depends on
config USB_USBNET and
config EXPERIMENTAL
The module will be called plusb.ko, I think.
Sorry for being really uneducated on this. But I can not find any of thoes that you listed in the kernel. Also I cant even find the config file. I know where im targeting it from command line but if I try to move it it says file not found, and if I try and go there visually the file isnt there.
Id love to be able to upload what you want to see, and Id love to be able to add in the items you just suggested. But alas. neither seems possible.
Its honestly odd to me.. Ive been reading a couple different posts on the net that say you install this driver for the Prolific 2303. But not the PL2303.... So why is it included when it doesn't do what its supposed to do? Ive tried a lot of different methods and none of them work. It sucks cause I see people using it. Maybe Its not the kernel and its the android OS? I really have 0 clue at this point and about to just give my resignation at my employment.
The .config file will be present in the kernel's main directory (/usr/src/tegratab/gtab-2632/.config) if you have already built a kernel.
It looks like there are 2 drivers for Prolific hardware in the source tree. One is for host-to-host cables with Prolific chips (which is not enabled by default, and which, I think, is what you want), and the other for a Prolific USB serial port adapter (which is already enabled by default).
To build the module for the first, do a make menuconfig, then select:
Device Drivers > Network device support > USB Network Adapters > Prolific PL-2301/2302 based cables
However, you should verify what you have before you build the module. Do a "lsusb" then check the USB device IDs against the USB ID database in /var/lib/usbutils/usb.ids on a regular Linux machine.
Hints:
0. See pershoot's hints to another user here and further along in the same thread.
1. Make sure that you have downloaded the correct pershoot kernel: froyo or gingerbread.
2. You don't need to include all the modules in your kernel zip file. Just overwrite the kernel proper (zImage), the wireless driver (bcm4329.ko) and then add only the prolific driver module. Otherwise you're just wasting space on the /system partition.
3. Sign the zip file after creating it.
Thank you so much for the attempt.
But my .config file is not located where you have directed me. I checked there before, I could send you a screen shot showing you this.
Thank you for showing me where the driver for the cables where, I would not have checked network adapters looking for USB.... Alas, this has not solved my problem. The cable is still undetected by the OS. Although almost EVERY other usb is detected.
Im really not sure why this wont work. It installs 100% fine I have 0 issues on this, but the Prolific 2303 usb to serial cable will not show up in log cat or anything.. Although when i adb shell and do lsusb I see it and it has a device ID and everything.
Thank you again for the help..
DKS1282 said:
But my .config file is not located where you have directed me.
Click to expand...
Click to collapse
It is created in the kernel's top-level directory (ie. the same directory as the file REPORTING-BUGS) after you do "make menuconfig".
If you still can't find it, do,
find /some/path/ -name .config
after you've finished "make menuconfig". Replace /some/path/ with your kernel source dir (or / to search everything that is mounted).
Alas, this has not solved my problem. The cable is still undetected by the OS. Although almost EVERY other usb is detected.
Click to expand...
Click to collapse
If the driver is built as a module then the kernel will recognize it only after you have loaded the module. Load the correct module first, either plusb.ko or pl2303.ko, depending on your hardware, then check for detection/initialization messages from the module by issuing a "dmesg" command immediately after the "insmod /some/path/driver.ko" command.
Im really not sure why this wont work. It installs 100% fine I have 0 issues on this, but the Prolific 2303 usb to serial cable will not show up in log cat or anything.. Although when i adb shell and do lsusb I see it and it has a device ID and everything.
Click to expand...
Click to collapse
Still lacking details:
1. Did you download the correct kernel--Froyo/GB?
2. Are you sure you're running the new kernel after flashing the zip file?
3. Did you insmod the correct module?
4. What is the USB device ID shown?
5. Did you run dmesg--not logcat--after you insmod'ed the correct module? Can I see that dmesg output?
I can not find a .config file anywhere on this computer. it just does not exist.
Yes I am using a gingerbread version.
Insmod does not install anything for me. Although I installed the modules before even packaging the kernel. Ive verified this by checking in the the correct driver files once installed.
I dont remember the device Id exactly but its something similar to 067b:2303
I didnt run dmesg, honestly, this is way beyond me. I have absolutely no clue what im doing at all... I wasnt even hired for this job.. I was supposed to create an app that will use this specific cable on this specific device, although they did not give me the device able to use the cable... So now I have to figure out how to do this, and im just going to resign and tell them im not a hacker im a developer. Thank you very much for your effort but I am turning in my resignation here now at the end of the day. Thank you again and I'll give you thanks.
You had asked a while back if dev/ttyUSBx has shown, and I did get that to show last night. its dev/ttyUSB0 Ive tried to use a usb to serial api but the app couldn't open the serial port... Im guessing because android does not support that (since they dont really support anything) I personally dont even understand why these things sell... Its a giant useless phone that can not make phone calls. Im in the wrong business I need to sell useless products to consumers.
DKS1282 said:
I can not find a .config file anywhere on this computer. it just does not exist.
Click to expand...
Click to collapse
You a) didn't search correctly, b) haven't built the kernel yet, or, c) done a "make mrproper" and cleaned up.
Yes I am using a gingerbread version.
Click to expand...
Click to collapse
Which ROM?
I dont remember the device Id exactly but its something similar to 067b:2303
Click to expand...
Click to collapse
You cannot be vague about this. Run a Terminal emulator on the gTablet (download one from Market if needed), then type in the command in bold:
Code:
$ [B]lsusb[/B]
Send me the output of lsusb.
I didnt run dmesg,...Thank you very much for your effort but I am turning in my resignation here now at the end of the day.
Click to expand...
Click to collapse
Steady on, mate--we'll get you sorted: Just send me the lsusb output and I'll build a kernel for you--if the current kernel sources include the driver code.
You had asked a while back if dev/ttyUSBx has shown, and I did get that to show last night. its dev/ttyUSB0 Ive tried to use a usb to serial api but the app couldn't open the serial port...
Click to expand...
Click to collapse
Does the app have permissions to read/write the device? Use the chmod command I gave in an earlier post to give permissions.
Next: once the actual hardware is connected to the Prolific cable, is data appearing on /dev/ttyUSB0? Run,
Code:
$ [B]hexdump -C /dev/ttyUSB0[/B]
to see if any data appears.
But, this depends on the device. Some devices need to be triggered, either electrically or by sending commands to the port, before they will send anything back. Other devices will spit data out as soon as power is applied to them.
Which kind is yours?
lsusb returns 067b:2303
My device needs to have data sent to it in order for it to start spitting out data. Otherwise there is nothing happening. It requires a 16bit hex "Start Command". So of course $ hexdump -C /dev/ttyUSB0 returns nothing.
I have the kernel I built here, as well as the gingerbread 2.3.4 rom i am using, and Ive also included the Gaps I needed to install into 2.3.4 to activate the USB feature. (why isnt that feature standard since its really the only difference for 2.3.3 and 2.3.4?
http://www.mediafire.com/?1phzkmvhtr0li
Thank you again.
Honestly you know what would fix all of this... Being able to install windows 7 on this tablet. I know the viewsonic view pad has a dual boot android / windows 7 how cool is that?
DKS1282 said:
lsusb returns 067b:2303
My device needs to have data sent to it in order for it to start spitting out data. Otherwise there is nothing happening. It requires a 16bit hex "Start Command". So of course $ hexdump -C /dev/ttyUSB0 returns nothing.
Click to expand...
Click to collapse
That's assuming that /dev/ttyUSB0 is the correct port, which may not be the case.
Right after the tablet has booted, load both the Prolific kernel modules (or only plusb.ko, if the other is built into the kernel--you still haven't sent me your .config file), attach the Prolific cable to the tablet, then attach the actual device to the cable, then run a
Code:
$ [B]dmesg > /mnt/sdcard/dmesg.txt[/B]
command. Attach the dmesg.txt so I can look at it.
Couldnt do it. Lost the job. Thanks anyway.

[GUIDE] Using external USB wifi

I got fed up with crappy wireless reception in a hotel and decided to use my RTL8187 based Alfa USB wireless adapter with my Prime. Here's how it works, pretty rough and open to improvement but it works.
Set up a chroot (ubuntu/debian will work); everything is done within that chroot
Compile and install the drivers for your usb adapter (see the Kernel modules thread for instructions)
apt-get install wicd-curses (or wicd-cli if you prefer), wpasupplicant and dbus plus any of its dependancies
Turn off the broadcom wifi that's controlled by android
insmod your modules (in my case eeprom_93cx6.ko, mac80211.ko, rtl8187)
start dbus and wicd (/etc/init.d/dbus start; /etc/init.d/wicd start)
run wicd-curses (or wicd-cli), refresh the network list and connect to your network
configure dns for android to your dns or to googles (setprop net.dns1 8.8.8.8)
???
Profit
To stop using external usb wifi, reverse the steps; basically:
stop wicd and dbus (/etc/init.d/wicd stop; /etc/init.d/dbus stop)
kill any running dhcp clients (killall dhclient)
rmmod your modules (in my case eeprom_93cx6.ko, mac80211.ko, rtl8187)
To be able to insert mac80211 without it complaining about missing symbols for ewma_init and ewma_add, I had to add lib/average.c to the mac80211 module; it's pretty simple, here's how i did that:
Go to your prime kernel source tree (e.g. /usr/src/linux)
cp lib/average.c net/mac80211/
Edit net/mac80211/Makefile and add average.o to the list of objects for mac80211-y (don't miss the trailing backslash if you add it halfway)
For simplicity sake I've added the modules for an rtl8187 based usb nic to this post. These are built against the 9.4.2.7 kernel source, and work fine for the 9.4.2.11 release (current ICS release as of Feb 07 2012).
Oh and I don't recommend doing this with androids wifi turned on, it kind of breaks it until you reboot your tab. So if you're smart you'll script the above and spit out a nice warning that your broadcom module is still loaded and then exit. I had no problems switching between external USB wifi and built-in wifi as long as I only turned one of them on exclusively.
Enjoy solid wifi on your prime
,can you show screenshots of how much of an improvement it was using a USB wifi device vs. Stock wifi. You should relay this info in the kernel modules thread n SaturnDe can probably clean it up or simplify more or make it easier to implement. He could add it to his driver packs and make a new ATP tweaks version. For quick app enabling of this USB wifi method. This is very cool. I really would like to see how much of an improvement in reception thisngives.
You can't use the external wifi together with the android wifi control, it isn't compatible. So screenshots make no sense. This is why you need the chroot and wicd-curses; that's where you configure your wifi connection, not in android.
As for the increase in reception, it depends on your usb adapter. If you have one with an external antenna that is 6 feet long, you can figure out how much of an improvement that would be. Nothing is stopping you from connecting an even bigger wifi antenna if you want. So, reception increase could be anywhere from a few dB up to long range 5km wifi using powerful long range antennas.
infernix said:
You can't use the external wifi together with the android wifi control, it isn't compatible. So screenshots make no sense. This is why you need the chroot and wicd-curses; that's where you configure your wifi connection, not in android.
As for the increase in reception, it depends on your usb adapter. If you have one with an external antenna that is 6 feet long, you can figure out how much of an improvement that would be. Nothing is stopping you from connecting an even bigger wifi antenna if you want. So, reception increase could be anywhere from a few dB up to long range 5km wifi using powerful long range antennas.
Click to expand...
Click to collapse
Lol, I believe you're being told to do it yourself 'darin. I have a nice little wifi usb adapter, I'll give this all a whirl later on after work.
Certainly not a solution for myself, but a simple workaround for those uncomfortable with modding and who don't mind annoying sticks coming from their tablets/laptops. Not saying anything against this, I just always hated using older laptops with usb adapters and don't see me liking it more on a smaller, more stream-lined device.
buxtahuda said:
Certainly not a solution for myself, but a simple workaround for those uncomfortable with modding and who don't mind annoying sticks coming from their tablets/laptops. Not saying anything against this, I just always hated using older laptops with usb adapters and don't see me liking it more on a smaller, more stream-lined device.
Click to expand...
Click to collapse
FWIW, this can also be used to run aircrack or other wifi security analysis tools with, which aren't able to ever run with the builtin broadcom adapter. So it has other uses too
infernix said:
FWIW, this can also be used to run aircrack or other wifi security analysis tools with, which aren't able to ever run with the builtin broadcom adapter. So it has other uses too
Click to expand...
Click to collapse
Has anyone tried doing so with their ATP? I'd be very interested to know. I've had a bunch of problems with the build-in card in terms of using the bt5 pentest suite so this might potentially solve some of those problems
Yeap, done with BT5 for arm and ALFA AWUS036H (Rtl8187), apt-get the aircrack tool and bang! : monitoring mode enables
Thanks a lot to the OP for the modules !
what version of linux are you guys using? I was trying to install wicd-cli and wicd-curses through my bt5 and had no success. wicd-curses just can't install on arm bt5 for some reason stating that some dependant libraries are incompatible. wicd-cli gives me an fopen error during install and then craps out when I try to run it.
Thanks for the info, one question tho.
Did you have to do anything special to get the wicd client to run, I get the error 'cannot connect to dbus socket' or something to that effect..
I have tried wicd-cli, -curses, and -gtk
Any help would be appreciated.
Dear Sirs,
This may be newbish, but where can I get the source for the kernel modules the op mentioned. I have obtained my kernel source for my phone, but can't seem to find the source I actually need to compile, rtl8187, etc.
Update:
Alright, I found them, they are part of the compat-wireless package. http://www.aircrack-ng.org/doku.php?id=compat-wireless
I still can get it to compile, but I guess I need to learn a little about cross compiling.
I did find a kernel for my device with the modules already built in, used and voila. Cracked a wep key in about 5-10 minutes. I was happy, happy, happy. Then, a ruinous moment occurred. Almost the very second aircrack-ng finished cracking the key, my phone came up with a low battery warning, I was using a awus036h wifi adapter and it was draining my battery fast, I had about 50% to begin and had the 14% warning hit me about 10 minutes in, funny thing is the warning is usually 14%, but this time was 13%, go figure? Anyway seconds after the warning my phone just blanks, turns off. I plug it in and reboot and the battery is at 0% and stuck there, so a word of warning:
An external wifi adapter my require more usb host juice then the battery can safely supply. I have seen people using powered hubs to circumvent draining the phone battery, I would defintiely recommend the practice.
Ok, if the last poster was noobish then i dont even know where i would be because i need help just deciphering wtf OP said.
I realize the drivers for each wireless adapter are going to be a little different... because each wireless adapter is different, but can someone translate this into non geek? I dont even know where to begin.
Can this work using the ubuntu/backtrack/linux installers from the market? Ive muddled my way through that and got linux working that way, or is this completely different?
I just wanted to say THANKS! I now have my Alpha card working in Monitor mode on my TF300T Transformer PAD and man it feels good! I have never been able to get this to work and have been trying to use an external card in backtrack for a loooong time! Thank you 1 million times!
Hi! Thanks for instructions. I got compile and install driver for my G-Sky (rtl8187) on AllWinner A10 (Ainol Aurora II) with android 4.0.4 and 3.0.8 kernel. All network settings were done with tablet's terminal (without PC). Only one problem remains - I can't undestant connecting to wpa networks - it's too difficult. Here: http_://nuzhen-sovet.ru/content/podklyuchenie-vneshnego-wi-fi-adaptera-k-planshetu-na-android-4 you can read my manual with connection to nonWPA networks on russian (read with google translate).
I am wondering if something like this could be used for the folks concerned with bt\wifi fallout. There are plenty of bluetooth dongles out there that are small enough to leave in the dock full time. I have the fallout I just dont use bluetooth enough to care.
BlackUbuntu 12.04 V4: http://kat.ph/blackubuntu-12-04v4-for-android-s3-tested-t7252750.html
So how would I go about this on the galaxy s3 l710.
My alfa card reads on pcap app.
Hi everyone.
I plan on using the Bolse adapter : http://www.mybolse.com/products_more.asp?id=96 that has an Android driver with my Galaxy Note2.
Do I have to go through all these steps with it considering it has an Android driver?
Thanks
infernix said:
I got fed up with crappy wireless reception in a hotel and decided to use my RTL8187 based Alfa USB wireless adapter with my Prime. Here's how it works, pretty rough and open to improvement but it works.
Set up a chroot (ubuntu/debian will work); everything is done within that chroot
Compile and install the drivers for your usb adapter (see the Kernel modules thread for instructions)
apt-get install wicd-curses (or wicd-cli if you prefer), wpasupplicant and dbus plus any of its dependancies
Turn off the broadcom wifi that's controlled by android
insmod your modules (in my case eeprom_93cx6.ko, mac80211.ko, rtl8187)
start dbus and wicd (/etc/init.d/dbus start; /etc/init.d/wicd start)
run wicd-curses (or wicd-cli), refresh the network list and connect to your network
configure dns for android to your dns or to googles (setprop net.dns1 8.8.8.8)
???
Profit
To stop using external usb wifi, reverse the steps; basically:
stop wicd and dbus (/etc/init.d/wicd stop; /etc/init.d/dbus stop)
kill any running dhcp clients (killall dhclient)
rmmod your modules (in my case eeprom_93cx6.ko, mac80211.ko, rtl8187)
To be able to insert mac80211 without it complaining about missing symbols for ewma_init and ewma_add, I had to add lib/average.c to the mac80211 module; it's pretty simple, here's how i did that:
Go to your prime kernel source tree (e.g. /usr/src/linux)
cp lib/average.c net/mac80211/
Edit net/mac80211/Makefile and add average.o to the list of objects for mac80211-y (don't miss the trailing backslash if you add it halfway)
For simplicity sake I've added the modules for an rtl8187 based usb nic to this post. These are built against the 9.4.2.7 kernel source, and work fine for the 9.4.2.11 release (current ICS release as of Feb 07 2012).
Oh and I don't recommend doing this with androids wifi turned on, it kind of breaks it until you reboot your tab. So if you're smart you'll script the above and spit out a nice warning that your broadcom module is still loaded and then exit. I had no problems switching between external USB wifi and built-in wifi as long as I only turned one of them on exclusively.
Enjoy solid wifi on your prime
Click to expand...
Click to collapse
Well, after i read most replies, most don't understand how to get things set up, please describe it a bit more, organize things, like section for requirements, etc.
Explain to Kernel and Kernel Modules and how to build them
For everyone who didn't Understand Step 2, I Will explain and tell you how to do that, Please read it all to Understand:highfive::
What is Kernel?
A Kernel is Simply a Bridge Between Software and Hardware.
So The Drivers are Inside the Kernel itself?
For Short, Yes. In Linux Overall (Android, Ubuntu, etc.), Drivers are Included Inside the Kernel it self, Some say for Performance Improvements.
Your Phone's Android Kernel Include all the Drivers required for your phone to function, And for the Devices that Support USB-OTG there are a Plenty of Drivers Included, However, Drivers like the one's for the RTL8187 Most likely won't be included.
What are Kernel Modules?
Kernel Modules are Files that have *KO Extension That can be loaded Through insmod and Unloaded through rmmod Command-Line Commands, These files is to Extend the Functionality of the Kernel Without Touching/Editing it at all,It Just does some effect Until the Modules are Unloaded/Device Rebooted, Kernel Modules useful Either by Adding a Driver or by adding other things..[/B]
What are the Disadvantages of Kernel Modules?
Well, There's no Difference Expect you need to reload the Kernel Modules after a Reboot or Module Unload, Some Tutorials Show you how can you add a command to load these Modules after each boot up
So A Kernel Module is the Solution for adding a driver without modifying the kernel?
Yes, Kernel Modules is the Solution here, Each USB Device needs it's own Kernel Modules, so you can't Download a Module and Use it, You need to Compile yours.
What is the Requirements to build a Kernel Modules?
1.You need Linux Environment, Use either the Chrooted Linux On you phone, or, better use Ubuntu or any linux Distro on a Computer, Build the Module, and load it on the Chrooted Linux on your phone,
2.You need an Internet Connection in the Linux Environment.
3.You need the Driver Source code for your USB Device. Get them from the Manufacturer if he offer them, if he doesn't, You need to Look in the internet until you find one, if you were unable to find the Source code for you Device but found similar Devices Driver source code, see if the Other Device Driver is Compatible with yours usually a Single Driver work on many Devices, you need to look by your own way
4.You Also need some Programs to install in Order to be able to Compile the Kernel Module, Enter these Commands in a Terminal, Pressing Enter after each Line, and make sure you have the Internet Connection:
HTML:
sudo apt-get install fakeroot
sudo apt-get install build-essential
sudo apt-get install dpkg-dev
sudo apt-get install linux-headers-$(uname -r)
For the most Important Part, make the Kernel Module?
1.Unpack the Kernel source code, if it's Extension is bz2 then use:
HTML:
tar jxvf <package-name>
Where <package-name> is the Compressed File name, and make sure you put it in the Home Folder, if it's Extension is gz or tgz the Unpack it with:
HTML:
tar zxvf <package-name>
2. Second, Find config.mk and Open it with gedit or whatever Text editor you like, at first, there is two lines about WPA Support, make sure they end with y rather than n, Save and close.
3.Third, and last, is to Compile the Kernel Module, Open Terminal and use cd command to get inside the folder that contains the Source code, and Simply Execute:
HTML:
sudo make
And now you own the Kernel module, Now copy the Kernel Module to the root of your Internal Storage, Open up a Terminal and Type:
HTML:
cd /mnt/sdcard
insmod <kernel-module-name>.ko
And make sure Internal Wi-Fi is OFF and now your Kernel Module works, Follow the Guys steps to get it working on Chrooted distro
Troubleshooting:
If you find a similar Device Driver Source Code and after Compiling it doesn't work plug the Device in, Open a Terminal and type:
HTML:
sudo lsusb
and Find your Device in the Output and you should find Numbers for it Looks Like 0x148F,0x2070 or whatever, Write them down.
After Step 2 Follow These Steps:
Find usb_main_dev.c and Under #ifdef Section add the Following Line:
HTML:
{USB_DEVICE(0x148F,0x2070)}, /* Your Device name, this is just a Comment. */
Where You should replace 0x148F,0x2070 with the String you just wrote down.
And then Continue Other Steps and it should work.
Please Click "Thanks" Button if i Helped you
Also, if you had any Problems and fixed them Just tell me so i can add them to Troubleshooting Section.
Hi! Im going on vacation in 2 weeks and I want this to work on my Nexus 5. I run CM12. I think I can manage the kernel part myself (there are a lot of nexus 5 kernels which include the driver of my wifi dongle: TP-Link WN722N). but I don't know how to do the next steps (for example step 4 and 5). Can someone give me a detailed tutorial with command lines? I am familiar with terminal.
My step again:
Nexus 5 running CM12
Wifi dongle: TP-Link WN722N
thanks in advance!
Sorry for the extremely noob question, but will this make the wifi adapter work in the chroot or on the entire device?

[DEV] Ubuntu 11.10 for A43/A101 [RELEASE 1]

Last summer I got Ubuntu 11.04 working on my A43 but didn't post anything about it. With the progress made on kexec and the new kboot bootloader, it is now possible to have multiple kernels for multiple OS'es. This means it just got a whole lot easier to boot Ubuntu without losing the ability to run OpenAOS or UrukDroid Android OS'es.
As far as I'm aware, Ubuntu doesn't work on the 2.6.29-omap1 kernel that Archos uses and is the base for most other development on gen8. However, for A43 and A101 users, OpenAOS member Nicktime made some headway in porting the 2.6.37+ kernel to gen8, but appears to have abandoned the project. I've cloned his repository and have been working to add features that he did not finish implementing. However, his kernel did have the ability to boot an Ubuntu rootfs and it works very well for desktop Linux distributions (this also works on Debian and I would assume other ARM distros as well).
As I have been unable to build an Ubuntu 11.10 rootfs using the rootstock method that Ubuntu describes here, I've started working with the HP TouchPadBuntu rootfs from this thread. This rootfs boots well on my TouchPad and I've removed the TP-specific items from it and added the gen8 items as necessary. The display is working and the touchscreen works as well (calibrated correctly as I copied my calibration from my 11.04 install). It boots into Unity 2D which is the default. I'm having issues getting the wl1271 wireless module up, I have had it running once but NetworkManager said device was not ready despite being able to iwlist scan and see a list of AP's and then connect to them manually.
RELEASE 1
You will need the rootfs and the modifications.
To install, mount your destination partition (should be at least 4GB and ext3 formatted) to a location, then run the following:
Code:
cd /media/UbuntuPartition (change this to wherever your Ubuntu partition is mounted)
tar xzf /path/to/TouchPadBuntuRootfs.tgz ./
tar xzf /path/to/Gen8Modifications.tar.gz ./
If you do not have a microSD card in the slot, you need to edit the file etc/fstab and change anything mmcblk1 to mmcblk0, this is because the SD card will identify as mmcblk0 if it exists, but if it does not exist then the internal storage gets identified as mmcblk0 instead. This is a kernel issue I have yet to find a solution to.
Kernels for Release 1
These boot from partition 3 of internal memory (/dev/mmcblk2p3)
Normal and Rotated 90 Degrees
This boots from partition 1 of external sdcard (/dev/mmcblk0p1)
Normal
These files do not need an initramfs, but to flash to device or to use with kboot you need one anyways. Simply create an empty (0 byte) file named 'initramfs.cpio.gz' and use it for this purpose.
INFO ON KERNEL MMC/SD INITIALIZATION
mmc0 (mmcblk0pX) - Micro SD card
mmc1 (mmcblk1pX, mmcblk2pX) - System and Data blocks of internal memory
mmc2 - wl1271 SDIO interface
I installed the rootfs to an 8GB microSD and boot it using root=/dev/mmcblk0p1 on the kernel command line.
USEFUL LINKS
http://dev.openaos.org/wiki/Gen8Linux2.6.37
https://github.com/CalcProgrammer1/archos-gen8-kernel-2.6.37
http://forum.xda-developers.com/showthread.php?t=1304475
http://www.omappedia.org/wiki/OMAP_WiLink_Connectivity_Home
http://www.omappedia.org/wiki/MAC802.11_based_Wilink
TIPS AND TRICKS
Disk Usage Power LED:
It is possible to make the Power LED function as a disk usage LED. This will let you know when the system is reading or writing to the memory and can be incredibly helpful in determining whether your system has locked up or is just being slow.
Simply write "mmc0" or "mmc1" (depending on what interface you wish to monitor) to:
/sys/class/leds/power/trigger (maybe power_led can't remember)
This can be changed in the kernel source in the file "archos-leds.c" as well if you want it to apply during boot time.
Charging the battery on A43:
(as root)
echo 1 > /sys/devices/platform/battery/usb_online
echo 3 > /sys/devices/platform/battery/charge_level
Enabling WiFi:
The wl1271 driver from linux-wireless requires firmware files to be placed in /lib/firmware. These files can be downloaded from here. The MAC address on the wl1271 is not stored on the actual wireless chip and instead resides in a configuration file on the system data directory in a file called system/persist.archos.WIFI_mac. This file is in the form:
Code:
Wifi MAC XX:XX:XX:XX:XX:XX
To extract just the MAC address, use
Code:
cut -f3 -d" " /media/data/system/persist.archos.WIFI_mac
Then, to set the MAC of the actual device you can do
Code:
ifconfig wlan0 hw ether `cut -f3 -d" " /media/data/system/persist.archos.WIFI_mac
ifconfig wlan0 up
I'm doing this in /etc/rc.local which is run on boot. This means the WiFi card is prepared when the system boots. However, NetworkManager still sees the card as "not ready" and you must Disable Networking and then Enable Networking before it will start showing AP's. After doing this, the WiFi works properly.
Screen Rotation:
The A43's display is 480x854 ("tall screen" orientation). For Ubuntu it is likely more useful to have a widescreen 854x480 orientation. Fortunately, this is not hard. It involves adding two parameters to your kernel's command line (either via kboot or by adding them to .config and recompiling your kernel). THIS DOES NOT ROTATE THE TOUCHSCREEN INPUT, so make sure you have an alternate input device when using rotation (BT keyboard/mouse, USB keyboard/mouse).
Code:
omapfb.vrfb=y omapfb.rotate=1
Enabling Audio:
This is pretty easy. Audio is installed and ready to go, the only issue is that the default settings in the mixer for this chip happen to disable the output entirely. To fix this, open ALSA Mixer (alsamixer) and turn on either speakers or headphones, then turn on Left Mixer and Right Mixer (hit 'M' to unmute/mute a channel). Finally, turn up the 'PCM' volume and start playing music. I recommend getting rid of Pulse Audio, but I'm still trying to figure out the best way to do so as it uses a lot of resources and provides little benefit.
PowerVR SGX 530 GPU:
The OMAP 3630 CPU has an on-board PowerVR SGX 530 graphics processor. TI provides an SDK that contains the userspace driver libraries as well as the open-source kernel drivers. There are three modules that must be built (pvrsrvkm.ko, omaplfb.ko, bufferclass_ti.ko) and loaded into the system. Then the userspace stuff must be installed. There is information here that should help. So far I've got the drivers to compile, but they aren't properly loading yet. More work to be done on getting the modules to work.
RC.LOCAL START-UP SCRIPT
This script should enable everything at boot time and should make Ubuntu easier to use on gen8 tablets. It starts WiFi and Bluetooth as well as enables USB charging.
Code:
#!/bin/sh -e
#
# rc.local
#
#MAC_ADDRESS='00:22:33:44:55:66'
MAC_ADDRESS=`cut -f3 -d" " /media/data/system/persist.archos.WIFI_mac`
ifconfig wlan0 hw ether $MAC_ADDRESS
ifconfig wlan0 up
modprobe btwilink
sleep 10
hciattach /dev/ttyS0 texas 3000000
/etc/init.d/network-manager restart
echo 1 > /sys/devices/platform/battery/usb_online
echo 3 > /sys/devices/platform/battery/charge_level
exit 0
You must have /media/data mounted in your /etc/fstab file, the entry should look like this:
Code:
/dev/mmcblk1p4 /media/data ext3 defaults 0 0
If this entry isn't in /etc/fstab, the /media/data partition will not be available at the time rc.local is run, and it will fail trying to read the MAC address. Alternatively, you can uncomment the hard-coded MAC address and use that but it's not as clean.
First off, Thanks for the effort you've put in, I just cant wait to get this up and running on my 101. Hopefully I'll have some time this weekend to sort it out but I've questions, How well does it perform? Is unity actually working? & have you tried any other distros? The reason i ask is because i was gonna buy a linux tab running plasma active but if i could eventually run it reasonably well on my 101 i'd hold out and save a couple.
Cheers again and nice work.
It runs fairly well. Unity works (2D only at the moment, not 3D), but whether that's a good thing or not I'll leave up to you (personally I don't like the Unity interface at all, and I find it slow when in 2D mode). I have GNOME 3.0 Fallback installed which runs pretty smooth and fast as it is fairly lightweight. You can use any non-3D-accelerated interface at the moment (Xfce, fluxbox, LXDE, MATE/GNOME2, etc). I've heard of people running plasma active on other non-accelerated systems (including the HP TouchPad, which is where I got my starting image). I haven't bothered as I prefer a traditional desktop-style interface.
That said, if you're willing to test I'd love feedback on how this performs on A101. I don't have an A101 and I am not sure of the status of A101 support. I'm taking Nicktime's word for it that the kernel supports A101. The actual Ubuntu image should be pretty independent of the device but the kernel needs to specifically support each individual board.
To start I'd just download the TouchPadBuntu rootfs I posted (which despite its name doesn't have anything TouchPad related in it and should at very least boot to login screen on the Archos 2.6.37 kernel without modifications). I'll hopefully get a package of modifications up soon including drivers for WiFi, Bluetooth, and a script to get everything running properly at boot.
As for 3D acceleration, I think it should be possible. There are apparently user-space drivers for OMAP3 that will work under Ubuntu. The bigger issue is getting a version of Compiz/Unity3D/Gnome Shell/whatever accelerated desktop you prefer that is compile for OpenGL ES.
Hey dude, could you give me some instructions as to how you installed the roofs.tgz to the memory card? I've got the new boot loader installed and I'm mad to get this going this weekend. Cheers in advance.
P.s. if there is a link to a tut for it that'd be excellent because I don't mind searching for myself just couldn't find any info on it. Thanks.
EDIT:
First post updated, see it for full installation details and feel free to post any questions or problems you have during or after installation. I really want to know how well this plays on A101 devices, as I don't have one to test with. Also, anyone with kernel experience that wants to take on adding additional devices, go for it! It would be great to get A70 support at least, as that is a popular device that has seen Debian/Angstrom activity in the past.
I tar'd the files to the sdcard, created a folder inside OS called ubuntu and placed the zimage & intramfs inside but it wont boot? I probably missed something so feel free to tear me one .
Wasn't even thinking...Duh...the kernels provided assume the root device is /dev/mmcblk2p3 (my Ubuntu partition on internal SD card). You probably want /dev/mmcblk0p1 (first partition on external SD card). I'll build a new kernel and post it soon, or you can take a shot at compiling your own kernel (my GitHub sources need work, for now I'd go with Nicktime's sources at Gitorious as I realized I broke some things).
Kboot should have a cmdline option where you can specify a kernel command line (and thus a root device) but I couldn't get it to work. To clarify, you ARE seeing the kernel boot messages right? If you aren't then kboot probably isn't set up correctly. Try booting another kernel (such as OpenAOS boot menu) from kboot and see if that works.
EDIT: here
CalcProgrammer1 said:
As for 3D acceleration, I think it should be possible. There are apparently user-space drivers for OMAP3 that will work under Ubuntu. The bigger issue is getting a version of Compiz/Unity3D/Gnome Shell/whatever accelerated desktop you prefer that is compile for OpenGL ES.
Click to expand...
Click to collapse
I know they
http://www.linaro.org/
are working on the Open GL ES port of Unity 3D.
Maybe u can find some sources there
And KDE should also have a builf of KDE Plasma wiht OpenGL ES.
Maybe you could add it? would be awesome.
Archos 70
Does/Will this work on the Archos 70? I'm trying to get it working but all I'm getting is static on my screen when Kboot tries to boot Ubuntu. This could be my fault and I could have just messed up the installation but I don't think so.
Thoughts?
shrewdlove said:
Does/Will this work on the Archos 70? I'm trying to get it working but all I'm getting is static on my screen when Kboot tries to boot Ubuntu. This could be my fault and I could have just messed up the installation but I don't think so.
Thoughts?
Click to expand...
Click to collapse
If you read the first post, you will see that this currently only works with A43 and A101. This is due to the kernel I'm using, which was ported by an OpenAOS user who hasn't been active in 6 months. Chances of him resuming his project are slim, so I've forked his kernel progress but don't have an A70 to work with. I could attempt to add A70 support to the kernel but I would be blind to the progress and would need testers. There aren't a ton of changes necessary, mainly just need to add the right LCD driver to make the screen work and then update the board file with the changes that have been made to the A43/A101 boards.
Unfortunately, I don't have much time as of late, I've got a senior design project and school work to deal with, plus I've been working on getting CM9 ICS to compile for gen8, and I've also been working on the HP TouchPad Ubuntu port. Adding A70 support to the kernel is low priority for me, but if any A70 owners want to take a stab at the kernel go right ahead, I'll gladly accept changes to the kernel. As far as Gen8 Ubuntu is concerned, my current focus is getting the SGX GPU up and running with TI's Graphics SDK. If successful, this GPU should be able to run hardware-accelerated Unity 3D and Compiz for a fast, fancy desktop experience.
shrewdlove said:
Does/Will this work on the Archos 70? I'm trying to get it working but all I'm getting is static on my screen when Kboot tries to boot Ubuntu. This could be my fault and I could have just messed up the installation but I don't think so.
Thoughts?
Click to expand...
Click to collapse
I've the exact same problem with my 101, at first I thought it was an issue with kboot but its able to boot uruk and bull. Every time I choose to run ubuntu it stalls with a static on the screen and I have to force a re-boot. I'm using a 2GB sd with only one partition if thats any help and the zimage in question is the one for boot from sd.
Any input?
Oh! Just looked at my kernel configuration again and I forgot to enable A101 support in the configuration file. I'll build a new kernel later today with A101 support enabled! Sorry about that. Should fix A101 but A70 still needs some real work before it will be supported.
EDIT:
Here it is
http://www.box.com/s/18d0e43877b5877ce79f
CalcProgrammer1 said:
Oh! Just looked at my kernel configuration again and I forgot to enable A101 support in the configuration file. I'll build a new kernel later today with A101 support enabled! Sorry about that. Should fix A101 but A70 still needs some real work before it will be supported.
Click to expand...
Click to collapse
Dude, don't apologize. I, and this community, appreciate what your doing. I'd love to have the knowledge to compile my own kernel and have a fully functional distro on this device, but I don't yet have that ability. You do, so any time you give up your time and effort to provide us with something new and cool is fricking brilliant. Keep working and let us know how you get on, but don't cause yourself too much hassle.
Thanks.
I've updated my previous post with an image with A101 support included. I have no way to test it. If any A101 users could take a short video or picture of the device booting Ubuntu I would like to see how it works on that device. I've also looked a bit into A70 support and it looks like the necessary modifications would be relatively straightforward, seeing as all the gen8's have essentially the same core hardware (OMAP3, Wolfson Audio, WL1271 WiFi/BT, MicroSD, POWER/VOL+/-, Power LED, etc). The primary difference (and probably most significant code change required) is the LCD panel, but seeing how the A43 got the short end of the stick on this one, the A70 should be easier to port (A43 has a DSI-interfaced serial LCD while the other gen8's have a DPI parallel LCD, DSI support is flaky at best in this kernel release).
Managed to get it to boot to ubuntu login screen but my usb keyboard doesnt get picked up, I dont know if the touch screen should register at this point but for me it doesnt. I've no bt keyboard but I can't see the device when I scan for bt from my phone either. If you want, I can take a vid of it booting to this point and send it to you. Just in case I get it to work, what are the login details (password) ?
The login is ubuntu/ubuntu (user/pass). I haven't tested the USB yet, and I'm not sure how the A101's host port is set up (the A43 supports USB OTG host but has no dedicated host port). It is a kernel issue for sure. As for the touchscreen, the A101 I think uses a USB touchscreen, so again with the USB issue. You can try forcing automatic login by modifying one of the files on the rootfs (would have to look up which one, can't remember, but should be possible). The fact that it boots is great and the fact that the panel works is also great. I'll look into USB host some more when I get a chance.
Cheers for getting back to me. Is there anyway we can pull something from either the bodhi image or android itself? or would it have to be changed at the kernel?
Pretty sure this is kernel level, the USB driver is being compiled differently than on the stock kernel (musb_hdrc should be a module, but this kernel it is built in, preventing you from loading in different modes). I booted up my A43 with a USB mouse attached, the kernel detected the mouse but then disconnected it before it could be used.

[WIDGET][SCRIPT][ROOT] Force USB Charging toggle script

Here is a small script that toggle force usb charging option from pershoot kernel :
Code:
#!/system/bin/sh
export STATE=`cat /sys/class/power_supply/battery/force_usb_charging`
if [ $STATE == 0 ]
then echo 1 > /sys/class/power_supply/battery/force_usb_charging
echo "Enable USB Charging"
else echo 0 > /sys/class/power_supply/battery/force_usb_charging
echo "Disable USB Charging"
fi
It needs root permission and a suitable kernel such as pershoot's.
PS: first step in the XDA community
It will be nice if you could explain how to use this script (one of the several ways).
Sorry to forgot the documentation part, here it is :
It can be used with any terminal apps with root access, just copy the content into a file (toggle_usb.sh for instance) and launch it in root terminal with :
Code:
sh toggle_usb.sh
A more user friendly way is to use Script Manager with SMWidget to add it on your homescreen. I use it this way so I could disable charging when the tab is plugged only for a file transfert.
Will this work on other devices? Like say the acer a100 or acer a500. Considering getting one of those but don't like that neither will charge usb.
If this only works for galaxy tab, how come? Just curious why force usb works on galaxy tab and not other devices.
It might work on other devices if the charging chipp support it and if the kernel has driver for. For the Galaxy Tab,The stock kernel and many others shipped with custom rom don't allow usb charging.
If supported by your hardware the script should work, it only use standard script and kernel related configuration.
EDIT:
The Acer a100 et a500 have a dedicated charger wich deliver 12V which is far more than a USB port can deliver (5V), I seriously doubt they put a dc-dc converter to connect the usbport to the charging chip.
Envoyé depuis mon GT-P7500 avec Tapatalk
Widget Apps
Hello,
I've tried to make it more user friendly, so I created a small widget apps using my previous script. It's my first real apps for Android, it still has some flaws.
Known Issues :
when adding the widget the file is at unknown state, need to hit the refresh button
Design is perfectible especially icons...
I would like to thanks the authors of the android-widget-development-tutorials availlable on google code.
not on tab 3
ebolalex said:
Here is a small script that toggle force usb charging option from pershoot kernel :
Code:
#!/system/bin/sh
export STATE=`cat /sys/class/power_supply/battery/force_usb_charging`
if [ $STATE == 0 ]
then echo 1 > /sys/class/power_supply/battery/force_usb_charging
echo "Enable USB Charging"
else echo 0 > /sys/class/power_supply/battery/force_usb_charging
echo "Disable USB Charging"
fi
It needs root permission and a suitable kernel such as pershoot's.
PS: first step in the
Well so far as I can see the folder called battery here apears as a file that is un openable to root explorer, the terminal will go in but there is no editing allowance as the files are locked, command chmod return a bad mode eror, since force_usb_charging does not exist I thought np ill creat on... long story short I made a file by that name in storage then used cp to copy that file to the destination mentioned (after chmod the sys class power_supply to write for all, ) battery would not as I mention take such command. All in all I still have not created the file force_usb_charging with a 1 as cat. So question........ how can I create the file in the directory. I am rooted, all my work in terminal has been su, I see the # show me as rooted, and I can alter the permissions. (Ps sorry dude with svsfsswitch.apk did absolutly nothing as the file did not exist, nor did the script above) is the smt 210r that different from othet machines? Lol retorical q, sorry . Tyvm for the help in advance. With time ill learn this linux /android stuff out.... summery how to creat a file in the sys/class/power_supply/battery called force_usb_charging containing the number 1.....
Click to expand...
Click to collapse
grummbunger said:
ebolalex said:
Here is a small script that toggle force usb charging option from pershoot kernel :
Code:
#!/system/bin/sh
export STATE=`cat /sys/class/power_supply/battery/force_usb_charging`
if [ $STATE == 0 ]
then echo 1 > /sys/class/power_supply/battery/force_usb_charging
echo "Enable USB Charging"
else echo 0 > /sys/class/power_supply/battery/force_usb_charging
echo "Disable USB Charging"
fi
It needs root permission and a suitable kernel such as pershoot's.
PS: first step in the
Well so far as I can see the folder called battery here apears as a file that is un openable to root explorer, the terminal will go in but there is no editing allowance as the files are locked, command chmod return a bad mode eror, since force_usb_charging does not exist I thought np ill creat on... long story short I made a file by that name in storage then used cp to copy that file to the destination mentioned (after chmod the sys class power_supply to write for all, ) battery would not as I mention take such command. All in all I still have not created the file force_usb_charging with a 1 as cat. So question........ how can I create the file in the directory. I am rooted, all my work in terminal has been su, I see the # show me as rooted, and I can alter the permissions. (Ps sorry dude with svsfsswitch.apk did absolutly nothing as the file did not exist, nor did the script above) is the smt 210r that different from othet machines? Lol retorical q, sorry . Tyvm for the help in advance. With time ill learn this linux /android stuff out.... summery how to creat a file in the sys/class/power_supply/battery called force_usb_charging containing the number 1.....
Click to expand...
Click to collapse
Hi grummbunger,
The /sys folder is a special filesystem handled by the linux kernel itself (by the means of its drivers), it provide information and control on peripheral. So If you do not have a specific fil in your /sys you could not create it. My Script was intended to work with Pershoot kernel, if you do not use it, the driver may not be loaded or might use a different file.
I would asked you which ROM and Kernel you are using to test it, but unfortunately i don't have access to a galaxy tab anymore...
Could you post me the list of file availlable in your battery folder ?
Welcome in the community, I hope you'll find the way to hack into your device to suit your needs
Click to expand...
Click to collapse
samsung usb charge enabling
ebolalex said:
grummbunger said:
Hi grummbunger,
The /sys folder is a special filesystem handled by the linux kernel itself (by the means of its drivers), it provide information and control on peripheral. So If you do not have a specific fil in your /sys you could not create it. My Script was intended to work with Pershoot kernel, if you do not use it, the driver may not be loaded or might use a different file.
I would asked you which ROM and Kernel you are using to test it, but unfortunately i don't have access to a galaxy tab anymore...
Could you post me the list of file availlable in your battery folder ?
Welcome in the community, I hope you'll find the way to hack into your device to suit your needs
Click to expand...
Click to collapse
android version 4.1.2 (could not find a pershoot rom to run on a 7 inch samsung tab3, and before flashing at all i wanna make sure that the setting can't be applied without flashing as that is really a last resort.) but i am totally ok with flashing if it is nessesary. i have rockettab ready to go, but have no idea if that would help at all with this situation.
kernel 3.4.5-1304745-user
found that the link "battery" goes to sys/devices/platform/sec-battery/power_supply/battery there are many files there that report status of power and such i found, some of the files names are like:
batt_charging_source batt_lp_charging Charge_now charge_type soip_activated soip_level status talk_gsm wc_enable wc_status. etc...
tyvm for your interest in helping my problem!
Click to expand...
Click to collapse
grummbunger said:
ebolalex said:
android version 4.1.2 (could not find a pershoot rom to run on a 7 inch samsung tab3, and before flashing at all i wanna make sure that the setting can't be applied without flashing as that is really a last resort.) but i am totally ok with flashing if it is nessesary. i have rockettab ready to go, but have no idea if that would help at all with this situation.
kernel 3.4.5-1304745-user
found that the link "battery" goes to sys/devices/platform/sec-battery/power_supply/battery there are many files there that report status of power and such i found, some of the files names are like:
batt_charging_source batt_lp_charging Charge_now charge_type soip_activated soip_level status talk_gsm wc_enable wc_status. etc...
tyvm for your interest in helping my problem!
Click to expand...
Click to collapse
In fact the kernel you need to install must support charging from any sources. It should be specified in the kernel feature list. Stock kernel won't let you do this or it would work out of the box.
Be aware that your Usb port must provide enough power to charge your device.
You're welcome.
Click to expand...
Click to collapse
ebolalex said:
grummbunger said:
In fact the kernel you need to install must support charging from any sources. It should be specified in the kernel feature list. Stock kernel won't let you do this or it would work out of the box.
Be aware that your Usb port must provide enough power to charge your device.
You're welcome.
Click to expand...
Click to collapse
Well it is a dell usb with power share at 1.2 a a wall charger is 2, the battery is 4000ma, I digress though I have in fact found the battery lasts for well over the time I need so I am all good. Thanks again for the responce!
Click to expand...
Click to collapse
If your kernel supports init.d scripts you can save script to /system/etc/init.d and it will be automatically launched on device boot. You have to delete extension from script name and prefix is number from 00 to 99
Hi,
Any way to get this working on kitkat rom (carbon kk)?
Phone is photon q, in the original sprint rom burried under hidden menu's the is a app to do it, so it must be possible in some way....any ideas?
Thanks!

[UTIL] Kexecboot Bootloader for Galaxy Note i717 - Boot Multiple Kernels

Well, it only took 2 years lol!
What is Kexec?
Kexec (kernel-execute) is a function of the Linux kernel that allows it to act as a bootloader to boot other kernels. Unfortunately, the standard implementation of kexec doesn't work quite right on most ARM devices due to poor driver support for hardware resets. The workaround is kexec-hardboot, a patch set that allows a kernel to be staged in RAM before performing an actual hardware reset through the phone's bootloader. Upon reboot the kexec-supporting kernel will check the magic location in RAM to see if a previously stored kernel is available, and if so, it will transfer execution to that kernel instead of booting itself.
Why use Kexec
It's a second-stage bootloader. The standard Android bootloader only allows two kernels to be installed at once - boot and recovery. This means that if you want a working recovery, you're only allowed one real OS kernel. If you want to dual-boot (or tri-boot or more) you're screwed. Kexec provides an answer to this. By replacing the boot kernel, kexec (with the kexecboot GUI) acts as a "second stage bootloader" allowing you to boot any number of kernels from any available storage devices. For instance, you have kexecboot in your boot partition and you can keep a kernel for Android installed in your Android system partition as well as an Ubuntu kernel and root filesystem on your SD card and be able to switch between Android and Ubuntu at boot time.
What is kexecboot
http://imgur.com/4GYomKX
Kexecboot is a graphical front-end for kexec. I have modified it to work with the kexec-hardboot patches. It scans all available storage devices for a boot.cfg file in which you define kernels, ramdisks, and kernel commandlines. You control it using volume up and down to move cursor, power to select.
Download
Get it here: https://mega.co.nz/#F!0ct3EaTD!wHWnGo1M_2smyKdzGMIYmw
The code
Kernel builder: https://github.com/CalcProgrammer1/kernel_quincyatt_kexec
This repository contains all the things you need to build a flashable kexecboot/kexec-hardboot enabled kernel image. It contains the ramdisk with the kexecboot binary and a script to package a flashable zip file. Included as submodules are the kernel source itself (kexec-hardboot branch, required to build the image) and the kexecboot source (optional, not used by default as you must build it using an ARM system, a pre-built binary is included if you don't want to build your own). The kernel source includes a defconfig called kexec_quincyatt_defconfig that sets the required config options for building a kexec-hardboot kernel.
Kexecboot Configuration File
Kexecboot replaces your boot kernel, so when you power up your phone it will go straight to the Kexecboot screen. The issue is now to provide kernels for kexecboot to boot into. This requires some work on your part, as you will have to store the kernel files (zImage and initrd) in a partition and write a configuration file to tell kexecboot where they are. This configuration file may contain multiple kernels, allowing you to have several different kernels available for the same OS or multiple OSes entirely. If you're coming from an Android system that distributes their kernel as a boot.img, you can use the abootimg program to extract it into a separate zImage and initrd.img binary.
The configuration file must be located on the path /boot/boot.cfg. This is relative to whatever partition/disk you are on, so for instance if you're setting up Android to boot from kexecboot, you would put your configuration file in /system/boot/boot.cfg (/data/boot/boot.cfg would work as well). You can also put a boot.cfg file on your SD card as long as you follow the /boot/boot.cfg path. Kexecboot automatically scans all available partitions for a boot.cfg file before it starts and builds a list of all available kernels across all detected boot.cfg files, so you may have Android in your /system partition and Debian on your SD card and both kernel lists will be shown together.
The Kexecboot web site provides a nice tutorial: http://kexecboot.org/documentation/how_to_write_config
The Note i717 bootloader passes a fairly long string of kernel arguments to the boot kernel. Since kexecboot overrides this for the kexec-booted kernel, you must provide this boot string in your boot.cfg file. Additionally, you may edit or add arguments to the command string here (such as setting console=tty0 instead of the default console=null so you can use the framebuffer console).
For example, here is my /system/boot/boot.cfg for CyanogenMod 11 (with kernel and initrd.img, extracted via abootimg, in /system/boot/)
Code:
# kexecboot configuration file
# CM11 default kernel
LABEL=CyanogenMod 11
KERNEL=/boot/zImage
INITRD=/boot/initrd.img
APPEND="androidboot.hardware=qcom usb_id_pin_rework=true no_console_suspend=true zcache [email protected] [email protected] sec_debug.reset_reason=0x1a2b3c00 pmem_sf_addr=0x7a000000 pmem_sf_size=0x6000000 console=null sec_debug.enable=0 sec_debug.enable_user=0 appsbark=0 msm_watchdog.enable=1 msm_watchdog.bark_time=30 msm_watchdog.bite_time=31 vmalloc=512m hw_rev=12 lpj=67702 androidboot.emmc=true androidboot.serialno=32c245ca androidboot.baseband=csfb"
I'm not sure how much of that you actually need, but you do need at least some of it because with an empty APPEND= it does not boot. You also do have to put the quotation marks around it or else parsing of one of the options will fail.
I'll admit limited understanding of what you're accomplishing here, but seems to me that this could lead to dual booting on the Note. Nice work.
Good luck.
Nice work! Thanks for the work you've done thus far. Unfortunately I have no way to help you out other than morale support! :highfive:
lactardjosh said:
I'll admit limited understanding of what you're accomplishing here, but seems to me that this could lead to dual booting on the Note. Nice work.
Good luck.
Click to expand...
Click to collapse
Pretty much what it comes down to, testing kernels and roms without having to flash into nand. I can't wait for dualbooting from Sd on the Note.
I have ORD , please help!!
My main goal here is native Linux, but if kexec works then you can boot custom Android dev kernels, native Linux kernels, other mobile OS'es, etc. The SGSIII team seems to have found some interesting kexec solutions for the Verizon SGSIII due to its locked bootloader. They've posted a good deal of kexec patches which I'm trying to bring to the Note, including a custom kexec-hardboot option that fully reboots the device into the new kernel (apparently to make sure the radio and such are working).
CalcProgrammer1 said:
My main goal here is native Linux, but if kexec works then you can boot custom Android dev kernels, native Linux kernels, other mobile OS'es, etc. The SGSIII team seems to have found some interesting kexec solutions for the Verizon SGSIII due to its locked bootloader. They've posted a good deal of kexec patches which I'm trying to bring to the Note, including a custom kexec-hardboot option that fully reboots the device into the new kernel (apparently to make sure the radio and such are working).
Click to expand...
Click to collapse
Wonderful, wonderful work!!! :thumbup::thumbup::thumbup:
Sent from my SAMSUNG-SGH-I717 using xda premium
Uh...It all sounded like this:
dual kernel (i'm gonna brick) kexec will allow (me to brick my phone).....with native linux applications ('im gonna brick my phone cause i'm stupid)....LOL
while i know what your doing, that in no way means i will ever understand it...LOL
But i will thank you in advance for what sounds like a sick mod for our notes...
Many thanks Dev !!!!
Kexec is actually (if done right) a good way *not* to brick your phone. To run kernels, you usually have to flash them to a restricted boot section of the memory, and if you flash all non-working kernels (to download, recovery, and main) then you have no way to use your phone, as it won't boot up. If you use kexec, your working kernel is safely stored on the boot partition and your development kernels can be wherever, and if it doesn't boot you can just hold down POWER to hard reboot into your good kernel.
The problem is that it doesn't seem to be working, I think I have the kexec support built properly but haven't been able to boot any kernels without it crashing.
CalcProgrammer1 said:
Kexec is actually (if done right) a good way *not* to brick your phone. To run kernels, you usually have to flash them to a restricted boot section of the memory, and if you flash all non-working kernels (to download, recovery, and main) then you have no way to use your phone, as it won't boot up. If you use kexec, your working kernel is safely stored on the boot partition and your development kernels can be wherever, and if it doesn't boot you can just hold down POWER to hard reboot into your good kernel.
The problem is that it doesn't seem to be working, I think I have the kexec support built properly but haven't been able to boot any kernels without it crashing.
Click to expand...
Click to collapse
I know you'll crack it ....
And when you do ....you'll be the galaxy note GOD !!!....LOL
your effort is much appreciated Sir ....even if I'm scared to use it , but will anyway ...lol
So I'm still confused as to why my kexec didn't work. I'm going to build a TouchPad kernel with it enabled and repeat the test on it, since I have a known-good kernel to boot against. I'll let you know how that goes.
Sent from my SAMSUNG-SGH-I717
Ok, so long-time-no-see but I'm reviving this post! Now that my Note 3 is happily running Cyanogenmod I have no urgent need for my Note 1 and can hack on it!
So far I haven't gotten kexec working, but I do have:
1. Kexecboot (graphical kexec frontend) is working, detects OS images appropriately
2. Framebuffer Console (text-mode display, USB OTG keyboard supported for interactive command line)
3. Overriding bootloader command line (to enable the fbconsole you need console=tty1 but the bootloader passes console=null)
4. Framebuffer console rotation (boot up in landscape or portrait, no way to switch without recompiling at the moment)
5. Most of kexec-hardboot ported from the HP TouchPad port, no clue if it's promising or not as so far it just crashes after a while of nothing
6. Ubuntu 13.04 (desktop edition) rootfs installed on SD card in a chroot, also taken from HP TouchPad
What I'm working on:
1. Kexec-hardboot port (needed to use kexec properly and boot kernels)
2. Fixing fbconsole glitching (framebuffer console displays garbled text that slowly clears up, no clue why...reading /dev/fb0 repeatedly clears up the display immediately and is a dirty hack that works well enough for testing)
3. Networking (either USB Ethernet or integrated WiFi, going to try backported brcmfmac driver)
4. Ubuntu (that's the long-term plan here)
5. Note 3 S800 port if I get everything figured out here
CalcProgrammer1 said:
Ok, so long-time-no-see but I'm reviving this post! Now that my Note 3 is happily running Cyanogenmod I have no urgent need for my Note 1 and can hack on it!
So far I haven't gotten kexec working, but I do have:
1. Kexecboot (graphical kexec frontend) is working, detects OS images appropriately
2. Framebuffer Console (text-mode display, USB OTG keyboard supported for interactive command line)
3. Overriding bootloader command line (to enable the fbconsole you need console=tty1 but the bootloader passes console=null)
4. Framebuffer console rotation (boot up in landscape or portrait, no way to switch without recompiling at the moment)
5. Most of kexec-hardboot ported from the HP TouchPad port, no clue if it's promising or not as so far it just crashes after a while of nothing
6. Ubuntu 13.04 (desktop edition) rootfs installed on SD card in a chroot, also taken from HP TouchPad
What I'm working on:
1. Kexec-hardboot port (needed to use kexec properly and boot kernels)
2. Fixing fbconsole glitching (framebuffer console displays garbled text that slowly clears up, no clue why...reading /dev/fb0 repeatedly clears up the display immediately and is a dirty hack that works well enough for testing)
3. Networking (either USB Ethernet or integrated WiFi, going to try backported brcmfmac driver)
4. Ubuntu (that's the long-term plan here)
5. Note 3 S800 port if I get everything figured out here
Click to expand...
Click to collapse
Long time in the making. Glad to see you're still at it. Hope you are able to get it working. Would be pretty cool. Good luck
If you can get this working up to kernel with freedreno I'd be all over working on getting Plasma Active onto this thing. I've missed having a real linux phone since my n900 died.
Got Bluetooth working from the command line!
Code:
# rfkill unblock all
# hciattach /dev/ttyHS0 any
# hcitool scan
It detected my Note 3 which I had set to visible! Hopefully I can pair a BT keyboard with this and lose the USB OTG dependency. Still working on figuring out WiFi, I have the brcmfmac driver from 3.13 backports compiled and loaded but the WiFi chip isn't being detected so the driver never creates an interface for it. The chip is a Broadcom BCM4330 WiFi/Bluetooth chip, and although both WiFi and Bluetooth share the same chip they use different interfaces to the SoC (UART for BT and SDIO for WiFi).
I plan on doing more research into getting the hardware working before I do any more work on kexec. It will be much easier to debug kexec I think knowing how to use WiFi/BT/USB/etc. The only hardware I'm not going to attempt at all is the modem as I don't use this device as a phone anymore and don't have a SIM card in it. That said, all the rmnetX entries that I think are modem interfaces show in ifconfig -a so maybe it is working.
My kernel source is here:
https://github.com/CalcProgrammer1/ubuntu-kernel-quincyatt
The kexec branch will have the kexec hardboot patches once I figure them out. I've also got a folder set up with a script to automatically build the kernel zImage, build the modules, build the backport driver modules, build the ramdisk from a ramdisk root folder, build the boot.img, and then package that up in a flashable .zip. I'll upload parts of this system as I complete them. I also have an Ubuntu rootfs on my external ext4 (or was it 3?) SD card that I ripped straight off my TouchPad. For now I'm just using a busybox shell in my ramdisk, dropping out of kexecboot into ash, setting up a chroot for the SD card, and chrooting into the Ubuntu rootfs that way. It's not ideal since Ubuntu's init process doesn't run but it does allow me to run all the installed utilites from said rootfs.
Edit: Rii Mini Bluetooth Keyboard paired and working! It was a roundabout way of doing so because dbus and upstart don't work in chroot so I had to use an old package called bluez-compat which provides the hidd command. I sideloaded the .deb with a flash drive. The command to pair a keyboard:
Code:
# hcitool scan
Scanning ...
XX:XX:XX:XX:XX:XX Bluetooth device name
# hidd --connect XX:XX:XX:XX:XX:XX &
XX:XX:XX:XX:XX:XX will be a hex value that is your keyboard's address. You find the address with the scan command and enter it on the hidd command to connect. I didn't have to enter any kind of passcode or pairing key, after running hidd it just started working.
http://imgur.com/2sV3TJr
I got it! I finally managed to get kexec hardboot working! I had to rewrite a bit of code in the kexecboot program to support kexec-hardboot better but I now have a bootloader that is working correctly, if slowly. I'll be posting my kernel source soon (it's a branch off of CyanogenMod's msm8660-common kernel) as well as my modifications to kexecboot itself. The kexec-tools binary I took out of the HP TouchPad port unmodified so I don't have the source for that (though it shouldn't be hard to find). I'll be looking into a Note 3 port soon, basically used the Note 1 as the guinea pig for this experiment.
If, somehow, you could adapt this for the ATT Mega 6.3 so as to bypass the locked tight bootloater.....you would be considered a hero!! People would build statues of you....write songs and name their children after you!!!!!?
Sent from my SM-T310 using XDA Premium 4 mobile app
Unfortunately you require an unlocked bootloader to install the kexecboot kernel. This isn't going to be a magic bullet for locked bootloaders. People have tried. For devices with exploitable bootloaders, it may help as you won't have to fake-sign kexec-booted kernels though.
CalcProgrammer1 said:
Unfortunately you require an unlocked bootloader to install the kexecboot kernel. This isn't going to be a magic bullet for locked bootloaders. People have tried. For devices with exploitable bootloaders, it may help as you won't have to fake-sign kexec-booted kernels though.
Click to expand...
Click to collapse
Grasping at straws, My Friend. Hoping that maybe this could be something like SafeStrap and could be d/l and installed as an APK.
Sent from my SAMSUNG-SGH-I527 using XDA Premium 4 mobile app
Got Debian booting! I also figured out how to get WiFi working from a non-Android Linux OS so this is definitely on track towards a full desktop OS!
To-do:
* X server, preferably with Freedreno GPU driver eventually
* Audio (q6.* firmware files and possibly an ALSA config)
* Startup scripts for Bluetooth initialization
* Figure out how to rotate the screen
dparrothead1 said:
If, somehow, you could adapt this for the ATT Mega 6.3 so as to bypass the locked tight bootloater.....you would be considered a hero!! People would build statues of you....write songs and name their children after you!!!!!?
Sent from my SM-T310 using XDA Premium 4 mobile app
Click to expand...
Click to collapse
I wont be having anymore children to name, but I can do a dog. He is too stoopid to know the difference. I can say aluminum foil and he will come running.
Sent from my SAMSUNG-SGH-I527 using XDA Free mobile app

Categories

Resources