yashsingh1/xdaforums huggingface dataset:
[Shield Android TV General] hallydamaster:
Well, I am trying to put all the calculations into schematics to, and hopefully make an auto patcher for different HDD/SSD sizes.

I have dumped the partition array+GPT header into a file to try and get an overview of it all.

To begin with, I tried to replicate the CRC32 values in the header.

The CRC32 of the header itself (zero'ing out the value itself) comes out as expected already in the header.

The CRC32 of the partition array though doesn't. The CRC32 should be the value of the 16384 bytes just before the 512 bytes that is the GPT header, but it doesn't match the value coming from the original Shield HDD.

Then I tried taking the 16384 bytes of another HDD in GPT I had, and there the CRC32 matches the value of the 16384 bytes, so now I am a little puzzled!

What value did you decide to use, and how did you calculate it?
[Shield Android TV General] Luxferro:
For the CRC32 of the partition array, you need to only select the 32 entries (from beginning to the end), each entry is 128 bytes, so you need to select all the bytes even the zeros at the end of the last entry. But not the 512 bytes of zeros that follow the partition entries, and before the GPT Header.

I've created a nice spreadsheet does all the calculations (minus the CRC32's), based on the total byte size of a HD. I'll share it when I clean it up some.

edit: also, the partition table entries don't start at the beginning of the 32 sectors (16384 bytes). For whatever reason, nvidia chose to start 23 sectors into the allocated space for the entries.
[Shield Android TV General] Luxferro:
Here's a picture to show how far of an area to select for calculating the CRC32 of the partition entries.

The top part of the red box (area selected for CRC32) would be around the A2.... entry of the 1st partition, and the bottom is around the last entry, and the following 64 bytes of zeros (each entry is 128 bytes total).

The 4 bytes highlighted in the data are the end point for the /data partition, which has to be changed to reflect the new HD size - kinda off topic for your question, but figured I'd explain why it was highlighted.
[Shield Android TV General] Luxferro:
Here's a link to my spreadsheet. You only need to enter in the bytes of the HD (cell colored red), and all the variables are calculated (minus the CRC32's), and shown in cells colored purple: https://docs.google.com/spreadsheets/d/1QysvIlVcuxYUroMpY7q0_VeIqOLEgJiZjnXNU1T_Ilw/edit?usp=sharing

There's a lot of other info on it, that doesn't have much to do with the calculations. Just general info, ect.

edit: Please don't request access for edit privileges. If I opened it up for everyone to edit, all the formulas could easily be ruined. The best thing to do for those that want to use the spreadsheet is to make a copy to your own google drive, this way you can edit it, and modify it however you want.
[Shield Android TV General] hallydamaster:
Always a couple of steps in front of me! ;)

No need to assemble my own schematics then, this is fantastic work. This should give us all the tools needed to migrate to any HDD/SSD size we want. :good:
[Shield Android TV General] Luxferro:
Thanks! It's been a work in progress for a few days now. I wanted to make it more presentable before sharing it, but figured screw it. It's good enough as is for anyone interested in learning how it all works - just takes some initiative.

If you want to take it to the next level, and create an automated patcher. I suggest just dumping the last 5120 bytes of the original hard drive to work with. Then the first pieces of data in the file will be the first partition entry, following by the 31 others, and then the gpt header.

dd if=shield.img bs=512 skip= 976773158 of=satv_pt_gtp.bin

Then to calculate the CRC32 of the partition tables you need to work with the first 4096 bytes of that file (no need for skipping over lots of zero's).
[Shield Android TV General] badman1223:
Shield Pro

Hello,

Just wondering what format the drive needs to be in before placing the bin files?
[Shield Android TV General] oldshanshi:
Personal feeling is not new hard drive does not need to be formatted. The new hard disk is preferably converted to GPT partition and format into NTFS. At least I do. hard drive(HDD\SSHD\SSD)
[Shield Android TV General] efegue:
Is it possible to find an hdd cable for the 16GB NAND shield? :)
[Shield Android TV General] hallydamaster:
One could try something like this, it has 20 pin FCC connector:

https://ko.aliexpress.com/item/NEW-For-Samsung-Laptop-Q45-Q70-HDD-Cable-OEHC067-BA41-00725A-SATA-Connector-Cable/1753052759.html
[Shield Android TV General] efegue:
Found this also, looks like the same cable and cheaper.

http://www.ebay.com/itm/SATA-HDD-Ha...174793?hash=item51d0b99749:g:gv8AAOSwqu9VG7Ld

Assuming this works, I would also need to flash bootloader from nVidia Shield Pro, right? To be able to boot from the HDD.

They state it's an FPC cable, will it work, or it needs to be "FCC", I don't know what these words mean, anyway.

Thanks!

EDIT: looks like FCC/FPC is the same thing. I'll order one of this cables and report back. If someone knows if the 16GB shield is able to boot from HDD I would appreciate, or if we can make it look like the shield pro, that would fix it, I guess, I don't really care about the 16GB NAND.
[Shield Android TV General] hallydamaster:
If it has 20 pins it might be the same yes.

There is not much point in making it boot from HDD, better to just boot it as usual, and then having the HDD as a storage option.

You would have to modify the DTB to make it work as well. And again, this still might not be enough as yahoo2016 has measured the voltages from pins 1-6 giving 0V, so there might be other things to do as well:

http://xdaforums.com/shield-tv/general/sata-header-16gb-model-internal-hdd-t3137960/page5
[Shield Android TV General] efegue:
Thanks for your info, I'll be following that post to see if the guys manage to do it :)
[Shield Android TV General] compyy:
Any progress on 1TB or 2TB drive ?

I am planning to buy 2TB SSD, would be ideal if i can boot shield with it.
[Shield Android TV General] hallydamaster:
You just use the spreadsheet Luxferro provided in this post:

http://xdaforums.com/showpost.php?p=67996717&postcount=189

Then you hexedit your GPT header to match your SSD, it should work.
[Shield Android TV General] finalman123:
To the people who plan to use the sata ribbon cable adaptor listed afew posts before and the adapter XF2M-2015-1A from mouser.com neither will work in combination as both pin 1 and 2 are GND on the sata data side of the adaptor where as only pin 1 is GND on the sata data side on the nvidia shield.

Shame though as without that issue it would've been perfect at least for the sata data side of things.

However if your just soldering wires between the ribbon cable and the shield then that'll work.
[Shield Android TV General] compyy:
Great, can someone make a small tutorial step by step with this new method, I am new dont want to brick my device.
[Shield Android TV General] alexalanis:
Hi, so let me know if I'm ok with the steps.

1) Make an image of the original SSHD naming it "shield.img"

2) Using this commands:

"dd if=shield.img bs=512 count=4647070 of=satv_system.bin"

"dd if=shield.img bs=512 skip= 976773158 of=satv_pt_gtp.bin"

3) Connect the new SSD or HDD and using this commands: (X is letter of the new SSD/HDD)

"dd if=/dev/zero of=/dev/sdX" (for SSD skip this step)

"dd if=satv_system.bin of=/dev/sdX"

4) Hex edit satv_pt_gpt.bin (Here we use the the spreadsheet Luxferro) I changed the value of the Disk Size but there are a lot purple values as new, do we have to change all purple values?

After Hex edit "dd if=satv_pt_gpt.bin of=/dev/sdX" and here is what I don't understand, do we need to put "seek=2,147,483,638"?

Another doubt is, do we need to change the values of CRC2?

Thanks hallydamaster and Luxferro

Alex
[Shield Android TV General] hallydamaster:
I actually have started building a small guide, but it really takes time as I am doing it step by step.

I would personally not do "dd if=/dev/zero of=/dev/sdX" as this would write to every sector of the disk, and that is not recommended in a SSD.

You really do have to edit, and write in all the hex values in purple, that is essential.

The satv_pt_gtp.bin should have a size of 5120 bytes which translates to 10 sectors. So you take the total sector count and subtract 10 to that value, and put it in the seek value.
[Shield Android TV General] alexalanis:
Excellent, I will try it today late, and see if I can make it work, about CRC2 do we need to edit them?

When you think your guide will be ready? hehe

Thank you again for your help

Alex
[Shield Android TV General] hallydamaster:
I was hoping to have something written up during the week.

You will have to edit in the CRC32 of both the GPT header and the partition array. Otherwise the layout is incomplete.
[Shield Android TV General] alexalanis:
Hi Luxferro, Hi hallydamaster,

So I just did the satv_system.bin and satv_pt_gtp.bin, and then I tried to hexedit the gpt, but I have some doubts.

Here is the full picture

In the picture I marked in yellow my doubts, your offset is different than mine, and the "û4U" instead of "0õ÷U",

also my shield.img is 465GB (502,487,166,976 bytes), satv_system.bin is 2.21GB (2,379,299,840 bytes) and satv_pt_gtp.bin is 5KB (5120 bytes), is everything ok?

Thank you again for all your help and make it this the best way to change the HDD from our NSTV.

Alex
[Shield Android TV General] Luxferro:
Ignore the offset in my picture, because it's not the same size as the file your comparing it to. In that picture of mine, that is just the 32 sectors that are allocated for partition table entries. On my spreadsheet I suggested dumping the partition tables, along with the gpt header, starting from the 1st partition table entry (not the beginning of space that's allocated for partition tables, since the beginning entries are all zeros).

Those bytes where you are seeing "û4U" instead of "0õ÷U" are unique to every device (most likely) - Unique partition GUID.
[Shield Android TV General] alexalanis:
I think I will wait for a guide, lol, I'm lost now, ehehehe

Thank you anyway

Alex
[Shield Android TV General] anchung.chen:
Does anyone know how to remove that SATA ribbon cable from the connector on the main board ? I like to remove it to give me more room to work.

Thanks you.
[Shield Android TV General] hallydamaster:
I was using a good 20 minutes trying to separate the hdd from the SATA cable until it just popped out of the connector by itself.

I just determined from there, that this is the way to do it. You just pull it out.
[Shield Android TV General] Luxferro:
There's a black latch that fllips up on the connector. But you should really try to avoid messing with it. Flex cables can start to make poor contact if you remove them, or mess with them, too much. I put kapton tape on the connector and the cable to prevent it from any stress on it when swapping drives.
[Shield Android TV General] anchung.chen:
I got it, like this one https://www.youtube.com/watch?v=C9PwK9eGrCY.
[Shield Android TV General] hallydamaster:
[MENTION=2163004]Luxferro[/MENTION]

Hi there, I wrote you a PM, but it doesn't come up in my sent PM's so I'm not really sure it was sent.

Can you confirm whether or not you recieved it?
[Shield Android TV General] Luxferro:
Just saw it and replied.
[Shield Android TV General] ahmed68:
hi everybody

after all what we do the mac address for lan , wan, bt and Serial Number not correct. i found where the mac save but I cant found where the Serial Number . any body can help plz.
[Shield Android TV General] alexalanis:
Excellent guide hallydamaster,

Just two doubts:

1st. When calculating the CRC32 of the partition array, you said the selection is from U.D.A., 4 lines down and go to the start of the file, so it will be from Offset(h) 00000000 to 00000FF0?

2nd. What configuration are you using on the HxD? 16 ANSI hex?

Thank you again, I'm working on it.

Alex
[Shield Android TV General] hallydamaster:
Thank you for trying out the guide.

1. Yes, the selection is from offset(h) 00000000 to 00000FF0.

2. I haven't touched any of that. I use 16 bytes pr. row, and yes it's ANSI, not ASCII.

I'm going to correct these things, thanks for pointing out, and good luck with the guide.
[Shield Android TV General] ahmed68:
I try dd if=lastpart2TB.bin of=/dev/sdaX bs=512 skip=3907029158 in 2tb not work

dd lastpart2TB.bin.bin cant skip
[Shield Android TV General] alexalanis:
Ok, so I'm using a EVO 840 1TB

fdisk -l shows this:

Disk /dev/sdf: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors

Units: sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 512 bytes

I/O size (minimum/optimal): 512 bytes / 512 bytes

I used the bytes on Luxferro spreadsheet and follow all steps from your guide, but the problem I have now is when I put the lastpart.bin it says this:

root@GA-890FXA-UD5:/media/Alex/nVIDIA Shield TV# dd if=lastpart.bin of=/dev/sdf bs=512 skip=1953525158

dd: lastpart.bin: cannot skip to specified offset

0+0 records in

0+0 records out

0 bytes copied, 0.000574345 s, 0.0 kB/s

What am I doing wrong?

Thanks for helping me out :)

Alex
[Shield Android TV General] hallydamaster:
Hey, sorry guys.. Everything is fine, you just have to use seek instead of skip in the last step. MY BAD! :-/

Gonna correct it.
[Shield Android TV General] alexalanis:
lol, my bad!!

Alex
[Shield Android TV General] hallydamaster:
It was mine actually, I wrote skip.

Please update me with your status! :)
[Shield Android TV General] alexalanis:
It's working perfect!!! amazing!!! the speed before was like having a ferrari with a 4 gear transmission and now is 8 or 9 gear.

Just have a little problem, it just recognized me 455gb of my 1TB SSD

Thanks hallydamaster

Alex
[Shield Android TV General] hallydamaster:
That is quite peculiar. What exactly did you do after installing the drive in the SATV?

Did it just boot or did you have to do something?

Also, is your SATV bootloader unlocked?
[Shield Android TV General] alexalanis:
I just boot it up, it's locked

Alex
[Shield Android TV General] hallydamaster:
If I were you, I would go unlock it. I am almost certain that would do the trick.

It will take a long time unfortunately.
[Shield Android TV General] ahmed68:
thank you so much

its work for 2tb with

dd if=lastpart2TB.bin of=/dev/sdaX bs=512 seek=3907029158
[Shield Android TV General] hallydamaster:
That's great! Do you have the full space at your disposition?
[Shield Android TV General] ahmed68:
yes 1,8tb

thank so much, great job .
[Shield Android TV General] anchung.chen:
Hi All:

Thank Luxferro, Tilator and hallydamaster for your hard works, so we could replace the SSHD on shield-pro-tv with any SSD or HDD.

I wrote a small program to do all calculations and generate the new lastpart.bin directly.

see http://xdaforums.com/showpost.php?p=68209006&postcount=3
[Shield Android TV General] alexalanis:
After the unlock, everything is ok now.

Thanks Luxferro, Tilator and hallydamaster
[Shield Android TV General] JazzMartian:
No doubt! Thanks for all your contributions fellas.

This mod was a pleasant surprise when I stumbled across this thread. It cemented my decision to go with the Pro model (even though it's technically possible with the 16GB/Base model). Soldering is just always a huge turnoff for me, even though I need to get good at it, for the types of things I want to do. I just haven't messed with a soldering iron in almost 15 years. It would be "ideal" to perform this mod on the 16GB/Base model, as you would have an extra 16GB of storage, and save $100, but it's just too risky for me at my skill set right now.

I'm hoping to be able to perform this mod on the Pro model w/o too much trouble. The last I checked this thread, you could only use a 500GB SSD or HDD. I haven't gone back through the thread, but it looks like now there's No Limit like Master P's old record label. Fantastic!!! I'm thinking (if I can afford it) of going with a 2TB SSD.

Thanks again for sharing the findings of your experimentation and work fellas!
[Shield Android TV General] K-RAD:
Anyone tried doing a sector-to-sector copy by dd in Clonezilla? Heard it might work as well without all this hacking and probably in Windows as well?
[Shield Android TV General] hallydamaster:
I know that someone tried this in the beginning, and their copies didn't boot for some reason. I can't see why that wouldn't work though. Maybe Nvidia removed some limitations.

Are you holding back on this because of the Linux part? It would be straightforward even with just a live USB setup.

It might be possible to use DD for Windows as well, I should maybe try build a guide around that?
[Shield Android TV General] K-RAD:
I think it would be worth a try
[Shield Android TV General] K-RAD:
I would like to know how much of a difference a SSD would bring to the Pro version compared to the SSHD it has inside. Anyone did any kind of comparisons?

I am planning to use it only for Plex and am wondering if it's worth buying a SSD for it or not, as it would add the cost of another half of an STV Pro or more
[Shield Android TV General] hallydamaster:
I have added a DD for Windows part in the guide. If you try this, please give me some feedback if something is not working or unclear, thank you.
[Shield Android TV General] ahmed68:
I found this
[Shield Android TV General] hallydamaster:
Yes, that is the version of DD for Windows that I have used in my guide.
[Shield Android TV General] oldshanshi:
My connection line is broken. I open the mold to make the connection line。New connection lines can be.
[Shield Android TV General] Nehemoth:
Wouldn't a disk to disk clonation block by block works for this?
[Shield Android TV General] anchung.chen:
Hi oldshanshi:

Just curious about the second picture, Is this the original FLEX Cable from Nvidia ? How do you remove the flex ribbon cable completely on the side of SATA connector ? Thank you for your kind reply.
[Shield Android TV General] oldshanshi:
This is not a product of NV, is to re open mold production. To find the factory.
[Shield Android TV General] hallydamaster:
Just making sure I understand correctly. Is that an aftermarket SATA FFC for the SATV?

Where did you get it?
[Shield Android TV General] anchung.chen:
Hi oldshanshi:

After finding the factory to make your SATA ribbon Cable, Would you like to sell it ?

I would definitely like to buy 4 of these SATA ribbon cables.
[Shield Android TV General] oldshanshi:
Of course, can be sold, but to wait a few days. Because now you see these are just made samples.

---------- Post added at 03:37 PM ---------- Previous post was at 03:24 PM ----------

No, this is not an aftermarket SATA FFC for the SATV。 This is according to the original model replica.（My English is bad. I do not know if you can understand. Sorry.）
[Shield Android TV General] hallydamaster:
It's ok, I think I understand you now.

But, if you can/are allowed to, please share where to buy it when it hits the market. :)

I am sure some people are very interested in this cable!
[Shield Android TV General] oldshanshi:
https://item.taobao.com/item.htm?id=537879306182

---------- Post added at 08:20 AM ---------- Previous post was at 08:19 AM ----------

https://item.taobao.com/item.htm?id=537879306182
[Shield Android TV General] Stevie G:
Getting this error message

according to local laws and regulations or policy platform, under this limit orders to buy goods.
[Shield Android TV General] oldshanshi:
There was a mistake in the previous settings. You can try again. If you have the wrong message, please give me a screenshot.
[Shield Android TV General] anchung.chen:
hi oldshanshi:

Want to buy your SATA ribbon cable, but need to apply for Taobao acount first.

Would you like to sell SATA ribbon cable + XF2M-2015-1A FFC Connectors ? It is much convenient for SATV non-pro users, although the soldering of 0.5 mm SMT component is not a easy task.
[Shield Android TV General] oldshanshi:
FFC connectors are looking for and testing. Over a few days will provide (ribbon cable+FFC SATA) link. If you can recommend that you register an account. Registration is free of charge. If there are any other better way, please provide me with a reference.
[Shield Android TV General] oldshanshi:
FFC Connectors model is different from you.
[Shield Android TV General] anchung.chen:
Don't know what you mean on these picture ?

And get the error message for your taobao link.
[Shield Android TV General] oldshanshi:
Try this link.

https://item.taobao.com/item.htm?spm=686.1000925.0.0.mVpfJz&id=538428705730

---------- Post added at 05:41 PM ---------- Previous post was at 05:40 PM ----------

Try this link.

https://item.taobao.com/item.htm?spm=686.1000925.0.0.mVpfJz&id=538428705730
[Shield Android TV General] Tilator:
Hello everybody,

This has gone huge steps further since I visited here last time. Nice work !!

There are two more thing I have thought. First one is everybody who have this device should consider taking copy of vital parts of SSHD while it still works. That's because then there is chance to recover from disk disaster. Without a copy it's not possible. It only takes some 3GB size from some place to store this backup.

Second thing is, might it be good idea to collect working end part binaries here somewhere for different size disks? If there was a library of ready binaries available for most common disk sizes, it would fit most cases and not everyone needs to do all calculation and hex editing any more.
[Shield Android TV General] Marski1969:
I'm very happy finding this tread!

Thanks for all the guys working on this "problem".

[MENTION=7386697]Tilator[/MENTION] ->Its smart! A few disks are already known and its static information.

- Samsung 850 EVO 500GB

- Samsung 850 EVO 250GB

- 2TB harddrive brand>?

I'm not sure what to use. A 500Gb EVO or the 250GB EVO.

I use Hyperspin Mame, NeoGeo wheel and SPMC on that disk so a Samsung 250GB EVO should be enough.

All my Movies and Series are on a NAS. Maybe in the future some transcoding on the shield for plex.

Greetings Mars
[Shield Android TV General] RebeccaV:
Hi,

It works on a Samsung 850 PRO SSD 1TB.

I can tell you: It's FAST! I have also a Samsung Portable T3 1TB (Movies) connected and buffering problems are past!

Many thanx for all who helped me!

Rebecca