Mittwoch, 12. Dezember 2018

Xiaomi BlackShark Global Files for Root arrived.

Alright. New stuuuuuuff. Today i received an OTA Update on my Shark. Which i could succesfully download to my Computer.
Current Version is called G66X1809121OS00MPX
New Version is called G66X1811240OS00MPX

 BEWARE! THIS IS JUST AN UPDATE NO FULL ROM!

With that i was able to extract the ZIP File which gave me the following Files.

care_map.txt
compatibility.zip
META-INF
payload.bin
payload_properties.txt


I extracted the Payload.bin with payload_dumper
Thanks to this post

Which resulted in the following Files:

.gitkeep
abl.img
aop.img
bluetooth.img
boot.img
cmnlib.img
cmnlib64.img
custom.img
devcfg.img
dsp.img
dtbo.img
hyp.img
keymaster.img
modem.img
qupfw.img
storsec.img
system.img
tz.img
vbmeta.img
vendor.img
xbl.img
xbl_config.img


So this might mean we are able to install Magisk with the boot.img file extracted from the ZIP. Currently im unsure if im willing to risk a brick. But on second thought i can reinstall the original boot.img if its not working.

I will keep you updated.


Kind Regards,

Invi







Newest files right here as always:

https://drive.google.com/drive/folders/1onCg5zJaV9r5yXobHLyyhHCO83R4qDOs?usp=sharing

Dienstag, 13. November 2018

Xiaomi Black Shark Global Dev Test Menu

So there seems to be a special dev Menu for testing the Blackshark before it will be shipped.

This Menu can be reached through the following combination being typed into your call numpad

*#*#6484#*#*

After that you will be in a Menu with a Big Blue Button stating CIPHER MMI START TEST
This will start all the Tests. You need the Adapter for the Headset and your charger in reach if you want to do this.
You could also click on TEST Result in the lower right to see all tests and do them one by one.
Solution what does what provided below.

After that the following Menu will appear.





Since its all chinese here is what each button will do:

Row 1 left: Tests if Headset is connected
Row 1 right: Tests Headset functions
Row 2 left: Tests Vibration
Row 2 right: Tests if Sim Cards are recognized
Row 3 left: Tests if phones is charging (You can also see if the charger is recognized as QC3.0)
Row 3 right: TP capacity test (Dont know what that one is but it passed)
Row 4 left: GPS Test
Row 4 right: Tests the Bluetooth (Checking for available devices)
Row 5 left: Tests the WIFI (Checking for available networks)
Row 5 right: Audio Test (Choose what you hear)
Row 6 left: Speaker Test (Choose what you hear. Caution louder then the Audio Test)
Row 6 right: Button Check (Volume up, down, power, Gaming mode, Virtual buttons)
Row 7 left: Camera test
Row 7 right: Camera 2 test
Row 8 left: Front cam test
Row 8 right: Test Color indicator top right for new messages
Row 9 left: Flashligt Test (Two in the back one in the front)
Row 9 right: Mic 1 Recording Test (click record say something click again and wait if you hear it)
Row 10 left: Mic 2 Recording Test
Row 10 right: Mic 3 Recording Test
Row 11 left: Light Sensor Test (Shine it with 500 Lux)
Row 11 right: Light Sensor Test (Cover Sensor)
Row 12 left: Position Sensor Test (Dont know what exactly)
Row 12 right: Another Position Sensor
Row 13 left: Another Position Sensor
Row 13 right: Fingerprint Check
Row 14 left: Display check (for Dead pixels i suppose click vol up/down to scroll through the images)
Row 14 right: Display brightness check
Row 15 left: Check if the Blackshark Logo on the back is flashing in different colors
Row 15 right: Touchscreen Check (Tap the tiles and draw an X from top left to bottom right and Top right to bottom left)


For each test you will have a PASS and FAIL Button at the bottom. Dont worry if you click FAIL on something nothing will happen.

Samstag, 27. Oktober 2018

More on the Xiaomi Black Shark

Here is some other Stuff i already figured out.

The Xiaomi Black Shark is no ordinary booting Phone.
It is one of the A/B Phones. Here is some stuff from the TWRP Compile thread on this:


Thanks to Dees_Troy for the Post


Installing / Flashing TWRP on A/B devices:

Since all known A/B devices do not have a separate recovery partition, you will eventually have to flash TWRP to the boot partition. On the Pixel 1 and 2, we use fastboot boot to temporarily boot TWRP without flashing TWRP. We are then supplying a zip to allow users to flash TWRP to both slots. You can download one of these zips from our website and update the zip as needed to support your devices. Eventually we will add tools to TWRP to allow users to flash recoveries on these devices without needing to use zips.

Recently, I worked on the Razer Phone. The Razer Phone unfortunately does not support fastboot boot. Instead, users have to determine their currently active boot slot using
Code:
adb shell getprop ro.boot.slot_suffix
then use
Code:
fastboot --set-active=_a
to switch slots to the inactive slot. From here, the user can
Code:
fastboot flash boot twrp.img && fastboot reboot
to get into TWRP. Once in TWRP they can then go to the reboot page and change back to their originally active slot, make a backup, then install TWRP. Using the inactive slot allows users to get a good, unmodified backup of their device before installing TWRP.


adb shell getprop ro.boot.slot_suffix gives me back

shark:/ $ getprop ro.boot.slot_suffix
_a


With digging around a bit more in the adb shell i got this.

cd /dev/block/bootdevice/by-name/

ls -lisa


drwxr-xr-x 2 root root 1580 1970-01-01 22:00 .
drwxr-xr-x 4 root root 1740 1970-01-01 22:00 ..
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 ALIGN_TO_128K_1 -> /dev/block/sdd1
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 ALIGN_TO_128K_2 -> /dev/block/sdf1
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 ImageFv -> /dev/block/sde51
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 abl_a -> /dev/block/sde8
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 abl_b -> /dev/block/sde27
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 aop_a -> /dev/block/sde1
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 aop_b -> /dev/block/sde20
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 apdp -> /dev/block/sde42
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 bluetooth_a -> /dev/block/sde5
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 bluetooth_b -> /dev/block/sde24
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 boot_a -> /dev/block/sde11
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 boot_b -> /dev/block/sde30
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 cdt -> /dev/block/sdd2
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 cmnlib64_a -> /dev/block/sde13
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 cmnlib64_b -> /dev/block/sde32
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 cmnlib_a -> /dev/block/sde12
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 cmnlib_b -> /dev/block/sde31
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 custom_a -> /dev/block/sde19
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 custom_b -> /dev/block/sde38
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 ddr -> /dev/block/sdd3
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 devcfg_a -> /dev/block/sde14
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 devcfg_b -> /dev/block/sde33
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 devinfo -> /dev/block/sde40
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 dip -> /dev/block/sde41
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 dsp_a -> /dev/block/sde9
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 dsp_b -> /dev/block/sde28
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 dtbo_a -> /dev/block/sde17
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 dtbo_b -> /dev/block/sde36
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 frp -> /dev/block/sda5
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 fsc -> /dev/block/sdf5
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 fsg -> /dev/block/sdf4
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 hyp_a -> /dev/block/sde3
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 hyp_b -> /dev/block/sde22
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 junklog -> /dev/block/sda12
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 keymaster_a -> /dev/block/sde10
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 keymaster_b -> /dev/block/sde29
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 keystore -> /dev/block/sda4
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 limits -> /dev/block/sde46
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 logdump -> /dev/block/sde50
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 logfs -> /dev/block/sde48
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 mdtp_a -> /dev/block/sde7
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 mdtp_b -> /dev/block/sde26
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 mdtpsecapp_a -> /dev/block/sde6
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 mdtpsecapp_b -> /dev/block/sde25
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 misc -> /dev/block/sda3
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 modem_a -> /dev/block/sde4
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 modem_b -> /dev/block/sde23
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 modemst1 -> /dev/block/sdf2
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 modemst2 -> /dev/block/sdf3
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 msadp -> /dev/block/sde43
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 oeminfo -> /dev/block/sda10
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 persist -> /dev/block/sda2
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 pstore -> /dev/block/sda11
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 qupfw_a -> /dev/block/sde15
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 qupfw_b -> /dev/block/sde34
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 ramdump -> /dev/block/sda13
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 sec -> /dev/block/sde39
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 splash -> /dev/block/sde45
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 spunvm -> /dev/block/sde44
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 ssd -> /dev/block/sda1
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 sti -> /dev/block/sde49
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 storsec_a -> /dev/block/sde18
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 storsec_b -> /dev/block/sde37
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 system_a -> /dev/block/sda6
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 system_b -> /dev/block/sda7
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 toolsfv -> /dev/block/sde47
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 tz_a -> /dev/block/sde2
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 tz_b -> /dev/block/sde21
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 userdata -> /dev/block/sda14
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 vbmeta_a -> /dev/block/sde16
lrwxrwxrwx 1 root root   16 1970-01-01 22:00 vbmeta_b -> /dev/block/sde35
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 vendor_a -> /dev/block/sda8
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 vendor_b -> /dev/block/sda9
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 xbl_a -> /dev/block/sdb1
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 xbl_b -> /dev/block/sdc1
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 xbl_config_a -> /dev/block/sdb2
lrwxrwxrwx 1 root root   15 1970-01-01 22:00 xbl_config_b -> /dev/block/sdc2
This might come in hand for those able to compile TWRP.

More Files can be found in the Google Drive right here

/vendor/etc/fstab.qcom

Filetree with all accessible Files and Locations from ADB




[HowTo] Unlock Xiaomi Black Shark Bootloader [Global Version]

Hi Guys,

today i figured i would spend some time and check if i could unlock the Bootloader of my Xiaomi Black Shark. I have the Global 8GB/128GB Version.

This does NOT work for the Chinese Version.

I was succesfull and here is how i did it.

DISCLAIMER! THIS MIGHT VOID YOUR WARRANTY AND WILL DELETE ALL YOUR DATA AND SETTINGS!

You need the following stuff:

What you need:
Your Xiaomi Black Shark
Drivers installed (you can use the miunlock tool for that but dont need it to unlock the Bootloader)
ADB installed.
A Backup tool.

If you want to unlock the bootloader do the following:

First Backup all your files and Settings.

Go to Settings/System/About the Phone and Tap on the Build Number to gain Dev Settings
In the Dev Settings enbale USB Debugging and OEM Unlock.

Connect your device to your computer.
Install the ADB Drivers if you did not already do so
Open a command prompt as admin

Type in
[CODE]adb devices [/CODE]
to see if your device is recognized. If not try again to install them through the MiUnlock tool.

If it is recognized it will look like this:

[IMG="Console"]https://i.imgur.com/VVzTB0C.png[/IMG]

After that type

[CODE]adb reboot bootloader[/CODE]

as soon as your phone restarts remove it from the USB Cable. Otherwise it might want to reboot right after you tried it.
Connect it to the cable again as soon as you are in Fastboot.

In your console type

[CODE]fastboot flashing unlock[/CODE]

Type

[CODE]fastboot reboot bootloader[/CODE]
or use the menu of the Bootloader to reboot to the Bootloader. As you will see your device is now unlocked.






















There you go your Xiaomi Black Shark has now an unlocked Bootloader.

Donnerstag, 29. März 2018

Mi Band 2 Bluetooth Issue and possible Solutions

So. A while ago my MiBand 2 stopped connecting to my phone.
I unpaired it and tried to reconnect the band but to no avail.

Here are the things i tried currently maybe they will work for you if you face the same issues.

Its important to always unpair the MiBand2 first.
First disable Bluetooth on your device.
Then install BToolkit. It will show you all paired devices.
If your MiBand is listed as paired press on the MiBand Symbol and choose Unpair.

Then clear the cache of the MiFit App and reinstall it.

If you are lucky it works.

If no try to rename your Device in the Bluetooth Settings and try the steps again.

If this did not work either you could try to use a Third Party App to see if it is an issue with the Band itself.

Install Bluetooth LE Scanner from the App Store. If you scan for deveices it should find the MiBand 2 after a while. If not your MiBand might be the issue here.

You can try different things now. Connect your MiBand to your PC and search again. Or wait for it to discharge fully. For that you need to put it either in the Fridge or just wait till its fully discharged.
Let it rest for another 2-3 Weeks before charging it again. If you are lucky your phone will find it again.

If you found your Mi Band with the LE Scanner try this.
Install Fix-it for Mi Band 2. It will tell you to uninstall Mi Fit. Do so.
After that it will search for your MiBand 2.
If it has been found the App will tell you to install a different App.
If it did not work you need to fill in the Mac Adress of your Mi Band 2 and connect it.

After that start the Notify & Fitness App.
You can either start using this App or you can try to Update the Firmware on your Mi Band 2.

Computer shows domain but is not in ActiveDirectory

So while installing some of our clients i came across a new Problem.
The Computers are joined automatically via script to into the Domain where then a Computer Account for each client gets created.

Well at least should.

Some clients seem to not create a Computerobject in the AD while others do.
The Problem is if you are running the Domain Join Script again it will return that the Client already is a Member of the Domain.

Since i had some time today at work i could invest in this i searched the Web for a Solution to Unjoin the Domain and join the Client into the Workgroup which is possible via GUI but apparently not via netdom / Powershell.

Thanks to a Post from Rems @ www.petri.com I came across this post:

https://www.petri.com/forums/forum/windows-scripting/general-scripting/66141-remove-pc-from-domain-without-being-connected-to-dc?p=444547#post444547

In order to get it working my script looks like the following

 start /B /W wmic.exe /interactive:off ComputerSystem Where "Name='%computername%'" Call UnJoinDomainOrWorkgroup FUnjoinOptions=0
start /B /W wmic.exe /interactive:off ComputerSystem Where "Name='%computername%'" Call JoinDomainOrWorkgroup name="WORKGROUP"

After that i reboot the Computer with our Deployment Console and let it join the Domain again which works like a Charm.


Hope i can help someone else with this.


Kind Regards,

Patrick

Dienstag, 7. März 2017

Windows 10 NVMe m.2 SSD and the boot Problem

So. It`s been a while.

A while ago i decided i wanted a new PC. After i built it i came across a flaw in my design or better the Design of the PC-Case i was using.

I had problems with the Sata SSDs i used. The case was built so you could apply two ssds to the bottom of the case. Unfortunately the opening used so you could hook the two ssds up to power and to the mainboard are poorly designed so that if you try to recable something at the back you might pull out the sata cable or power cable from the SSD.

Therefore i decided to switch to m.2 SSDs which i thought would be nice for my OS and Data to have them in a RAID.

Good thing my Mainboard was able to create a RAID with the M.2 SSDs.

But when i tried to copy over the Windows Partition from my normal SSD and then tried to boot i could not find the M2 SSDs in the Boot Manager of my UEFI Bios.

While digging around i found out that the ASRock Z170 Extreme7+ i used has a RAID Driver i could use to Install a new Windows. I tried that and the OS Showed up. Unfortunately a clean install and i would love to use my Old Install.

While i digged around some more i came across another Problem. It seems my Old SSD is in MBR Mode rather then in GPT which i would need to have it working on the M.2 SSDs.

So the next step today when i come home is. Change the Format from MBR to GPT without Data Loss (hopefully). And then Install the NVMe Driver so i can copy it over to the Raid SSDs which will be then hopefully recognized in my BIOS.


For the Raid Installation on M.2 SSDs have a look here http://www.thessdreview.com/daily-news/latest-buzz/understanding-m2-3xraid0-nvme-boot-performance/2/

If you can not see your SSDs when trying to install Windows try the Steps Karl posted in the comments on Disqus http://disq.us/p/13l9cc0


 I will create a more detailed Instruction with pictures when im back home.