scripts icon indicating copy to clipboard operation
scripts copied to clipboard

[not an issue] On the Suzy-Q CCD unbricking process

Open yw662 opened this issue 2 years ago • 0 comments

Basically unbricking via CCD requires to run flashrom from hdctools at https://chromium.googlesource.com/chromiumos/platform/standalone-hdctools.

However in 4 weeks ago it is deprecated in favor of the docker version described here, and Ubuntu 20.10 recommended by the tutorial is also deprecated. And indeed it is much more easier to use the docker image than to compile it yourself.

This issue is to share how I use the docker version to run the flashrom, in an easy way. Lets' say you have installed docker (or docker-ce) on your machine, and it runs x86 containers since the image is x86 only.

So firstly, pull the image: docker pull us-docker.pkg.dev/chromeos-hw-tools/servod/servod:release (or sudo it if docker wants so) To make the image name shorter you may want to tag it (this is optional but no harm): docker tag us-docker.pkg.dev/chromeos-hw-tools/servod/servod:release servod:latest And run -it: sudo docker run --privileged --volume="/dev:/dev" -it servod bash (or, sudo docker run --privileged --volume="/dev:/dev" --volume="/home/<you>/Downloads:/Downloads" -it servod bash)

Now you are inside the container. you may try cbfstool or flashrom. It is all there, but no wget or curl. That's why I would recommend you to bind mount ~/Downloads to the container. You can download things from host and use them in side the container. Remember how we bind mount /dev. ls /dev/ttyUSB* should work the same. You should be able to see the 3 devices inside the container.

So now, echo "ccd open" | sudo tee -a /dev/ttyUSB0 > /dev/null. Download the things you need from the host, and run the same cbfstool or flashrom command inside the container. And that's it.

This process for me is good enough as how you would deal with android devices (just like fastboot, adb, or flash via 9008 mode, but from a docker container). It does feel like a waste to run android platform tools from a docker container though.

yw662 avatar Jan 21 '23 18:01 yw662