[Q] Ubuntu 12.04 flashing woes. - Verizon Samsung Galaxy S 4

Aaaallll righty. So im following a few different guides floating arround because it seems to be not a common thing for Ubuntu (12.04) users to want to flash roms onto their S4's.
Here's the main guide i'm following : http://forum.xda-developers.com/showthread.php?t=2290798
Turns out Odin doesn't communicate properly on Ubuntu, for some reason. It wont ever show me a Com port for connection. So it looks like Heimdall is my only option to get the first hook onto this beast of a phone. I'm currently stuck on step 2 of the guide noted above where it has me flash the VRUAMD2 kernel to get hook.
Code:
~$ heimdall detect
Device Detected
~$ sudo heimdall flash --kernel SCH-I545_MD2_423399_Kernel.tar.md5
...
Checking if protocol is initialised...
Protocol is not initialised.
Initialising protocol...
ERROR: Failed to initialise protocol!
This is my I/O for the current try, can anyone help? I've done my searching but there's nothing that is a direct match to what I want / need, which is to flash this damn MD2 Kernel, and get on with the mod. If anyone knows of a cleaner way to do these things, I'd like to know as well.
BTW: I know this isn't QUITE the right forum, but account permissions and what not prevent me from posting directly to the guide, # of posts and what not.

Related

[Q] Help me fix my heimdall installation?

I'm on linux (suse 11.4). I really want to get heimdall to work because my luck getting odin to work reliably with my windows XP dual boot isn't very good. I constantly have to reinstall the samsung drivers....
So, on linux....
I've compiled and installed the heimdall executable from source. It actually does work, except not really very well. In particular:
1. I can only flash as root. Q: how do I get write access to the phone for the normal user. I'm feeling like that's what the udev rules are for, but they are set as
Code:
SUBSYSTEM=="usb", SYSFS{idVendor}=="04e8", SYSFS{idProduct}=="6601", MODE="0666"
in both /lib/udev/rules.d/60-heimdall-galaxy-s.rules and /etc/udev/rules.d/50-android.rules.
2. I can't flash in download mode. This is weird. I put the phone in download mode and try to flash and this happens:
Code:
heimdall flash --modem ./modem.bin
Heimdall, Copyright (c) 2010, Benjamin Dobell, Glass Echidna
http://www.glassechidna.com.au
This software is provided free of charge. Copying and redistribution is
encouraged.
If you appreciate this software and you would like to support future
development please consider donating:
http://www.glassechidna.com.au/donate/
Claiming interface... Failed. Attempting to detach driver...
Claiming interface again... Success
Setting up interface... Success
Beginning session...
Handshaking with Loke... Success
Uploading modem
0%
Failed to send file part packet!
Modem upload failed!
Re-attaching kernel driver...
After that the phone is unreachable and boots up to the phone to PC screen. Trying to flash while at the phone to PC screen solves everything:
Code:
heimdall flash --modem ./modem.bin
Heimdall, Copyright (c) 2010, Benjamin Dobell, Glass Echidna
http://www.glassechidna.com.au
This software is provided free of charge. Copying and redistribution is
encouraged.
If you appreciate this software and you would like to support future
development please consider donating:
http://www.glassechidna.com.au/donate/
Claiming interface... Failed. Attempting to detach driver...
Claiming interface again... Success
Setting up interface... Success
Beginning session...
Handshaking with Loke... Success
Uploading modem
100%
Modem upload successful
Ending session...
Rebooting device...
Re-attaching kernel driver...
After that the phone boots normally. Q: Why won't it flash while in download mode?
I'm trying to get some confidence in this whole process so that I feel OK about flashing GB a boot loader. But I am obviously not there yet. Help!
OK. I fixed the permission issue by putting myself in the "dialout" group.
But the other issue remains. Why won't Heimdall flash in download mode, but will flash in phone-to-PC mode?
It looks like Heimdall detaches the kernel in the first attempt, but then fails to re-attach it (hence, phone-to-PC). But it is successful the second time? I don't get it.
For the record, this is Heimdall 1.1.1, and the ROM on the phone is BiWinning v2.
JJMT said:
OK. I fixed the permission issue by putting myself in the "dialout" group.
But the other issue remains. Why won't Heimdall flash in download mode, but will flash in phone-to-PC mode?
It looks like Heimdall detaches the kernel in the first attempt, but then fails to re-attach it (hence, phone-to-PC). But it is successful the second time? I don't get it.
For the record, this is Heimdall 1.1.1, and the ROM on the phone is BiWinning v2.
Click to expand...
Click to collapse
That's normal, I exclusively use Heimdall. I'm on Arch linux
crazy25000 said:
That's normal, I exclusively use Heimdall. I'm on Arch linux
Click to expand...
Click to collapse
Huh. OK, well it's good to know that other people see the same thing. I'm not sure that it should be viewed as "normal", though. All the online threads seem to think that we should be able to flash while in download mode.
Really, if I am going to flash a primary boot loader, I would probably have a heart attack if Heimdall reported the download "failed" (the first time).
Is it the same with Heimdall 1.2? I haven't tried that, as there doesn't seem to be source to build from.

[Q] CF-Auto-Root not rooting w/ Hiemdall and JB 4.1.1

I'd normally post this as a reply to Chainfires [2012.10.26] CF-Auto-Root v1.0 [GT-I930x/T/N][SHV-E210*][SHW-M440S] thread in the Galaxy S III Original Android Development subforum, but without 10 posts, I can't post to a development thread, so this is the best I can do for now...
I've a 1 week old SGS3 International (GT-i9300) that has upgraded to JB OTA, now running JB 4.1.1, baseband I9300XXDLID, Build number JRO03C.I9300XXDLJ4. I am unable to root my phone using Chainfires recommended method, as described in that thread. I see the software download to the phone, and then the phone reboots into CWM, and then sits at the CWM menu. Rebooting from CWM menus results in normal start of the phone, and everything working (apparently) normally. Update counter is incremented, and my phone is now detected as modified. However, root is not available, and there appears to be no SU binary on the phone.
Attempting to install SuperSU from the market doesn't work. Running Root Checker from the market confirms that the phone is not rooted.
I appear to be one of several people for whom this method is now failing (though the use of Linux rather than Windows makes me slightly unusual) and wanted to (a) report this to Chainfire, and (b) get some help on what to try next to make this work, as I really want to get root on my handset.
For information, the method I used:
I run Ubuntu, and have no access to a Windows PC, so I made the updates with Heimdall v1.3.1, which as others have noted (around post 120ish) does work and I also double-checked that that specific version could talk to the phone correctly (detect and print-pir both work as expected).
I took the latest CF Auto Root for my phone hardware from Chainfires site (at autoroot [dot] chainfire [dot] eu), and extracted the recovery and cache image files. switched the phone to download (PWR, Vol Down, Home) then Vol Up, plugged in the USB cable and ran "sudo heimdall flash --recovery recovery.img --cache cache.img", resulting in:
Code:
Initialising connection...
Detecting device...
Claiming interface...
Attempt failed. Detaching driver...
Claiming interface again...
Setting up interface...
Checking if protocol is initialised...
Protocol is not initialised.
Initialising protocol...
Handshaking with Loke...
Beginning session...
Session begun with device of type: 131072
Downloading device's PIT file...
PIT file download sucessful
Uploading RECOVERY
100%
RECOVERY upload successful
Uploading CACHE
100%
CACHE upload successful
Ending session...
Rebooting device...
Re-attaching kernel driver...
During code download, progress bars move on the phone as expected, and it then reboots into CWM, where it sits waiting for manual input. Rebooting the phone from CWM does not seem to result in root, even through the flash counter has been incremented and the phone is detected as modified.
I would appreciate some help, or a kindly moderator moving this to the right forum/thread and allowing me to continue the conversation over there.
Thanks
Richard

Overcoming problems while installing cm10.1 on tmobile s2

Last night I was helping a friend put CM10.1 on his t-mobile samusung galaxy s2 phone(hercules), but while following the directions on cyanogenmod's website I thought I had soft-bricked his device. I did a lot of searching and found people saying they had similar problems, but no solutions. So I figured I'd post what got this device working again.
So after step 5, "heimdall flash --recovery recovery.img --no-reboot", the device would only reboot directly back into odin mode saying "firmware upgrade encountered an issue. please select recovery mode..." crap. The instructions didn't give any advice about what to do if this happened so I started doing some searching and people said that you could still you odin, but odin would crash every time I tried to run it. Then I found a website saying that heimdall doesn't work with t-mobile's S2, so I'm thinking crap crap now (note that the heimdall version in cyanogenmod's instructions does work for the tmobile s2... I'll get to that later). So I then tried to get kies to connect to it and do a full recovery, but kies wouldn't connect. The device drivers would fail to install for the MSM8x60 device.
So I spent a lot of time just trying to reset the to see if that would do something but to no avail.
So what finally worked?
I went back to the cyanogenmod instructions and followed the instructions to install the drivers with the zadig tool. Then just to see if the heimdall tool is actually communicating with the device I ran the command "heimdall detect", and that responded with "Device Detected". So that looked good. Then I looked at the command options within heimdall (since I was beyond following someone else's instructions by now), and saw the download-pit command and thought that it would be a harmless command to see if heimdall was actually communicating with the device. So I ran "heimdall download-pit --output test.pit" and it spit out a bunch of stuff including at the bottom
Ending session...
Rebooting device...
Releasing device interface...​
And walla it reboots back into gingerbread and is working. I was then able to reboot into clockworkmod and finish the CM10.1 install with no problem.
Really I think the step 5 on the instructions just needs to be changed from
heimdall flash --recovery recovery.img --no-reboot​to
heimdall flash --recovery recovery.img​
Hopefully that helps someone else out there!

Galaxy S4 mini; lost on installing CyanogenMod 12.1

Hello there,
before getting into details: I am pretty new to the whole business of smart phones; so, if my request doesn't fit here ... please don't get too angry with; but tell me where else I could turn to.
In case this is a good place to ask my question; here we go:
I recently acquired a S4 mini (GT-I9195); currently runing Android 4.4.2; build number KOT49H.I9195XXUCOE4; and as subject says: I want to install cm 12.1; and I am getting nowhere.
I started with this wiki page wiki.cyanogenmod.org/w/Install_CM_for_serranoltexx
The wiki says:
Use heimdall to install the CM recovery image
Then, use that recovery image to install the actual CM build
And well, I am already failing with step 1.
My computer is running ubuntu 14.04; I first installed heimdall from the ubuntu repositories; and when following the instructions; I ended up with
heimdall ERROR: Failed to receive PIT file
Then I fetched the latest heimdall source from github; compiled ... and ran that; but result wasn't much different
heimdall ERROR: Protocol initialisation failed!
Then I tried to do everything with AndroidStudio / adb / fastboot.
I enabled USB debugging within the mobile phone ... and I could actually start an adb shell. I could also use adb to boot the S4 mini into recovery/download mode.
But when I do a "fastboot devices" then ... no devices are showing up at all.
I don't have a windows system; so I tried to get my VirtualBox windows to get it "talking" to the phone; maybe in order to use Odin instead of heimdall; but no luck there.
( I thought about using twrp ... and the wiki pages there basically talk about using Odin on windows)
Long story short: I am looking for the "easiest" way to get CM 12.1 on my S4 mini; preferably without rooting; and low risk of bricking ...
EDIT: with some more help from Uncle Google I figured how to setup my VBox Windows7 to run Odin.
I can start Odin (3.10.7) ... and trying this here: www.s4miniarchive.com/2013/11/how-to-install-twrp-on-samsung-galaxy-s4-mini-gt-i9195.html
The IMG is correct; it shows the MD5sum you can see here: forum.xda-developers.com/showthread.php?t=2449107
And, ah, when running Odin as adminstrator, I starts doing something; and PASSes.
I stop the mobile; and reboot ... and recovery is still showing me the old content?!
So, any idea, anybody?
Resolved
In the end, I got my VirtualBox to run with Odin successfully ... then installed TWRP ... and then figured that I need a different key stroke in order to startup recovery mode.
So, the important things I learned:
* heimdall really doesnt work with Galaxy S4 mini
* Odin (I tried 3.17) and TWRP do (where: Odin needs samsung mobile drivers; and you have to run it as admin!)
* there is a difference between download and recovery mode!

Unbrickable Ressurector wont load

Hi All, New to this forum and have not found a resolve reading the threads so if someone could correct me that would be awsome.
I am trying to un-hard brick our samsung galaxy player 5.0 intl. It attempted to boot with a flat battery along time ago and has been a brick since. i have periodically kept it charged in case one day i find a resolve.
I have been attempting to use Unbrickable Ressurector but cannot even get it to load.
Initial process:
I have installed ubuntu on a spare laptop.
Installed Java through command line and verified the install.
Downloaded Unbrickable Ressurector from: (github) downloaded as a zip file. 'hummingbird-hibl-master.zip'
changed the zip file permissions to allow executable.
Right clicked an run with Java. But nothing happens. A little bit of hard drive noise but nothing comes up.
In the threads there is mention of running the .jar file but there is no .jar file in this package. I have unzipped and searched the folders to no avail.
I have even tried renaming the zip file to .jar which yeilds the same result as above.
I think it may be that i'm simply stupid or am i missing something?
Any help greatly appreciated.
I have just tried installing java 6 instead of java 8 in case there was a compatibility issue. Set default application to Java 6 runtime. Icon pops up in side bar after double click on 'hummingbird-hibl-master.zip'
then after 14 seconds icon disappears.
Not sure what else to try. I must be missing something obvious?
SymondoR said:
Hi All, New to this forum and have not found a resolve reading the threads so if someone could correct me that would be awsome.
I am trying to un-hard brick our samsung galaxy player 5.0 intl. It attempted to boot with a flat battery along time ago and has been a brick since. i have periodically kept it charged in case one day i find a resolve.
I have been attempting to use Unbrickable Ressurector but cannot even get it to load.
Initial process:
I have installed ubuntu on a spare laptop.
Installed Java through command line and verified the install.
Downloaded Unbrickable Ressurector from: (github) downloaded as a zip file. 'hummingbird-hibl-master.zip'
changed the zip file permissions to allow executable.
Right clicked an run with Java. But nothing happens. A little bit of hard drive noise but nothing comes up.
In the threads there is mention of running the .jar file but there is no .jar file in this package. I have unzipped and searched the folders to no avail.
I have even tried renaming the zip file to .jar which yeilds the same result as above.
I think it may be that i'm simply stupid or am i missing something?
Any help greatly appreciated.
I have just tried installing java 6 instead of java 8 in case there was a compatibility issue. Set default application to Java 6 runtime. Icon pops up in side bar after double click on 'hummingbird-hibl-master.zip'
then after 14 seconds icon disappears.
Not sure what else to try. I must be missing something obvious?
Click to expand...
Click to collapse
Did you miss something? Yes, You missed the date on the OP which was DEC 2011!. The links are out of date and so are the instructions.
1. In 2011 I think maybe ubuntu 11.04/12.04 was current. So you might have trouble getting 14.04 or 16.04 to work.
2. The link for the download of Unbrickable Resurrector is not right. You are looking for a file called "UnBrickableResurrectorR36.jar" which is apparently been expunged from the internet. The current link, that is redirected to github.com, leads to the source code that will "compile" UnBrickableResurrectorR40.jar"( or whatever the lasted version was). So unless you've got some java 6 skills...
EDIT: I managed to find 1 copy of the file here:
https://www.4shared.com/file/1Gx6ZSXjei/UnBrickableResurrectorR40.html
Thanks meticulus for taking the time to reply. That got me out of a sticking point. Greatly appreciated. I know i'm trying to revive old tech but i also don't like being wasteful by just throwing it away. I hope to revive it so my daughter can use it as a ipod alternative. Here's hoping.
Hopefully i don't need any further help and this thread will help any other late comers to fixing the old galaxy player 5.0.
Thanks again.
Hi Meticulus. Progress update: Unbrickable Resurrector R40 now functional.
Connect SGP 5.0 intl.
Device recognised.
S5PC110 Detected.
Clicked : Perform Resurrection - Download Mode
Begin Resurrection Sequence
Requesting Permission to access device
Please wait......Uploading...
This is far as the process goes. Device does not go into download mode. Could i be missing something simple again?
SymondoR said:
Hi Meticulus. Progress update: Unbrickable Resurrector R40 now functional.
Connect SGP 5.0 intl.
Device recognised.
S5PC110 Detected.
Clicked : Perform Resurrection - Download Mode
Begin Resurrection Sequence
Requesting Permission to access device
Please wait......Uploading...
This is far as the process goes. Device does not go into download mode. Could i be missing something simple again?
Click to expand...
Click to collapse
1. It's been quite awhile since I used this but I believe that I used it with ubuntu 12.04 LTS. So first make sure you use that version.
2. Make sure you are NOT using virtualization software such as virtualbox or vmware. Either use a thumbdrive, dualboot, or just install ubuntu natively.
3. You man need to set permission on the USB device in udev. Sort of like this: http://ptspts.blogspot.co.il/2011/10/how-to-fix-adb-no-permissions-error-on.html
Use lsusb to find the exact IdVendor
4. Launch the file in the terminal like this: java -jar UnbrickableRessurectorR40.jar . This may* give you more output to tell what is going on.
Hi Again Meticulus. thanks for you instruction. I have managed to make some more headway from your help.
I performed a new native install of ubuntu 12.04 LTS and Java 6
Now Unbrickable Ressurector appears to work. It recognises the device and after password prompt brings up the now in download mode screen on the GUI window. Although the samsung player screen stays black.
I have now also installed Heimdall Frontend in ubuntu and in the process of learning how to use it and acquiring the correct pit file and firmware. It appears to recognise the player at this stage.
Just to refresh it is a Samsung Galaxy Player 5.0 International 16GB. Made in Korea.
I have pit file: GB70-GalaxyPlayer-16gb.pit
also G70intl.pit
I am thinking the first is a safer bet.
Firmware: G70XXKPL_CL1105219_REV01_user_low_ship_HOME.tar.md5
and: CODE_GB70KRKPG_CL762569_REV01_user_low_ship_HOME.tar
Although heimdall expects tar.gz file extensions. so i'm doing something wrong again.
I'm going to sleep on it and re approach in the morning. (I'm on the other side of the planet in good old New Zealand)
If you have any further advise to offer on correct firmware for this device any help is most appreciated.
SymondoR said:
Hi Again Meticulus. thanks for you instruction. I have managed to make some more headway from your help.
I performed a new native install of ubuntu 12.04 LTS and Java 6
Now Unbrickable Ressurector appears to work. It recognises the device and after password prompt brings up the now in download mode screen on the GUI window. Although the samsung player screen stays black.
I have now also installed Heimdall Frontend in ubuntu and in the process of learning how to use it and acquiring the correct pit file and firmware. It appears to recognise the player at this stage.
Just to refresh it is a Samsung Galaxy Player 5.0 International 16GB. Made in Korea.
I have pit file: GB70-GalaxyPlayer-16gb.pit
also G70intl.pit
I am thinking the first is a safer bet.
Firmware: G70XXKPL_CL1105219_REV01_user_low_ship_HOME.tar.md5
and: CODE_GB70KRKPG_CL762569_REV01_user_low_ship_HOME.tar
Although heimdall expects tar.gz file extensions. so i'm doing something wrong again.
I'm going to sleep on it and re approach in the morning. (I'm on the other side of the planet in good old New Zealand)
If you have any further advise to offer on correct firmware for this device any help is most appreciated.
Click to expand...
Click to collapse
".tar.md5" or ".tar" file must be flashed with Odin in Windows but those files are archives that can be opened via the Archive Manager in Ubuntu and the files extracted. As I said it's been awhile and I'm just talking from memory so do your homework but, basically each file in the archive is a raw dump of the partition. So system.img is the system partition, cache is cache and so on (zImage is kernel) and can be flash via heimdall. I am not very familiar with heimdall front end but from the Terminal, the command is something like:
"heimdall flash --system system.img" ( <---real iffy on exact syntax, something close to that.)
DO NOT FLASH PIT FILES!!! ( I have bricked my device many times and have never had to do this and you shouldn't do it unless you are sure that you have muffed up your partition table!)
Odin is available here and the drivers for windows too but the last time I used them Windows 7 was the thing so...
Techically if you can use Heimdall or Odin with any success, you are already in "Download Mode" and you do not need the Resurrector.
The Terminal command "heimdall --print-pit is a good test. If it can connect to the device and print the pit file with out error then Download mode is working and you can flash a stock ROM with ODIN and as long as it's the right one, your golden...
Hi Meticulus, Here's a quick result of a pit print:
Initialising connection...
Detecting device...
Claiming interface...
Attempt failed. Detaching driver...
Claiming interface again...
Setting up interface...
Initialising protocol...
Protocol initialisation successful.
Beginning session...
Some devices may take up to 2 minutes to respond.
Please be patient!
Session begun.
Downloading device's PIT file...
ERROR: Failed to receive PIT file size!
ERROR: Failed to download PIT file!
Ending session...
Rebooting device...
Releasing device interface...
Re-attaching kernel driver...
So I may have a bigger problem. Would that indicate a muffed partition? from what i have read elsewhere i may have a hardware failure which means RIP samsung player.
What originally bricked the device was an attempted boot with a dead flat battery. the device has never had any custom firmware flashed. Purely stock.
Will do some more research in the meantime.
SymondoR said:
Hi Meticulus, Here's a quick result of a pit print:
Initialising connection...
Detecting device...
Claiming interface...
Attempt failed. Detaching driver...
Claiming interface again...
Setting up interface...
Initialising protocol...
Protocol initialisation successful.
Beginning session...
Some devices may take up to 2 minutes to respond.
Please be patient!
Session begun.
Downloading device's PIT file...
ERROR: Failed to receive PIT file size!
ERROR: Failed to download PIT file!
Ending session...
Rebooting device...
Releasing device interface...
Re-attaching kernel driver...
So I may have a bigger problem. Would that indicate a muffed partition? from what i have read elsewhere i may have a hardware failure which means RIP samsung player.
What originally bricked the device was an attempted boot with a dead flat battery. the device has never had any custom firmware flashed. Purely stock.
Will do some more research in the meantime.
Click to expand...
Click to collapse
I can be sure but i would say yes, that does point to a partition. The only way to repair you partition table is if you can get into a custom recovery.
Your only hope is if you can flash a custom kernel:
http://www.meticulus.co.vu/p/galaxy-player-5-beanstalk-install-from.html
You can also extract the zImage from the .tar or .tar.md5 file and flash the zImage (kernel) with heimdall sort of like this:
heimdall flash --KERNEL zImage .
The kernel has custom recovery in it and if you can boot into it, you can use the partition tools to straiten yours out.
You might need this:
https://www.youtube.com/watch?v=Uzu4uDTDL5k
and you might want to read through this entire thread:
https://forum.xda-developers.com/showthread.php?t=2398120
Meticulus said:
I can be sure but i would say yes, that does point to a partition. The only way to repair you partition table is if you can get into a custom recovery.
Your only hope is if you can flash a custom kernel:
http://www.meticulus.co.vu/p/galaxy-player-5-beanstalk-install-from.html
You can also extract the zImage from the .tar or .tar.md5 file and flash the zImage (kernel) with heimdall sort of like this:
heimdall flash --KERNEL zImage .
The kernel has custom recovery in it and if you can boot into it, you can use the partition tools to straiten yours out.
You might need this:
https://www.youtube.com/watch?v=Uzu4uDTDL5k
and you might want to read through this entire thread:
https://forum.xda-developers.com/showthread.php?t=2398120
Click to expand...
Click to collapse
Thanks again Maticulus. I have been through all of the above to no avail. The last thread was interesting and tried to repeat the process there to see it the partitions were messed up.
Used adb-shell. (On Windows terminal)after installing Android devalopment suite. but Shows no connected devices. The player shows as SEC S5PC110 test B/D in device manager requiring drivers. Even though I have installed the samsung drivers.
I've also tried to use the zImage previously. Heimdall front end will only allow me to add the extracted file after adding the pit file. But in the end fails to upload the pit file.
Sorry for the low detail as I have decided to give up on this one. I appreciate your input to get me this far. You certainly went above and beyond to help and for that I thank you.
hopefully there is something in here to help someone else in a similar situation.

Categories

Resources