Bricked my B3 after u-boot flash [Solved]

Got problems with your B2 or B3? Share and get helped!
Gordon
Posts: 1407
Joined: 10 Aug 2011, 03:18

Re: Bricked my B3 after u-boot flash

Post by Gordon » 03 Jan 2016, 09:17

If you are compiling yourself, there's no saying what the checksum will be. Different compiler and linker may result in other code optimizations and alternate order of the individual elements.

mintz
Posts: 25
Joined: 31 Dec 2012, 08:03

Re: Bricked my B3 after u-boot flash

Post by mintz » 15 Jan 2016, 16:55

Sorry for just post & disapeared like that. Things just suddenly came up around xmas and new year time.

Anyhow, I've soldered the cable to the board just as instructed but cannot seem to get PuTTy to connect (nothing shows at all in terminal). This might be a stupid question but does the board need to be on or off and is it ok for the harddrive to be attached?

Here's some pictures:

The soldering
Image

The cable
Image

Windows device (picture got cropped because of forum post width, just right click > view image)
Image

putty
Image

mintz
Posts: 25
Joined: 31 Dec 2012, 08:03

Re: Bricked my B3 after u-boot flash

Post by mintz » 15 Jan 2016, 17:40

Voilà! I switched TX and RX cables and suddenly getting output from my beloved B3. I think the information on the Wiki page might have switched the two cables.

Here's the output. Please guide me to restore to a proper u-boot.

Image

Code: Select all

U-Boot 2013.01.01-b3-rodeus-g53a85c9 (Sep 06 2015 - 21:18:33)
BUBBA|3

SoC:   Kirkwood 88F6281_A1
DRAM:  512 MiB
WARNING: Caches not enabled
SF: Detected M25P16 with page size 64 KiB, total 2 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0, egiga1
88E1116 Initializing on egiga0 @08 done
88E1116 Initializing on egiga1 @09PHY reset timed out
 done
Hit any key to stop autoboot:  0
Unknown command 'run' - try 'help'
Unknown command 'reset' - try 'help'
B3>

MouettE
Site admin
Posts: 292
Joined: 06 Oct 2011, 19:45

Re: Bricked my B3 after u-boot flash

Post by MouettE » 15 Jan 2016, 22:15

Apparently something went very wrong with your build. Let's try to reflash your b3 with a working version.

I built a working version based on the github tree (rodeus tag) which I tested myself; it is available on the excito install server : uboot-rodeus.zip

Unzip the file on a usb key and check that the u-boot.kwb file is in the install directory.

We're gonna try to flash from your broken U-Boot but it's likely it won't work (you will probably get more unknown command errors). Nevertheless you should try that first. If that doesn't work we will need to boot your b3 from the serial line and then flash. I will put this procedure in the following post.

Plug the key on the b3 and type the following commands from U-Boot; they will only work with the version above; make sure the output is identical to the one I provide, in doubt post here.

Code: Select all

B3> usb start
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 3 USB Device(s) found
       scanning bus for storage devices... 1 Storage Device(s) found

Code: Select all

B3> fatload usb 0:1 0x800000 /install/u-boot.kwb
reading /install/u-boot.kwb
........................

255772 bytes read

Code: Select all

B3> sf probe 0:0
2048 KiB M25P16 at 0:0 is now current device

Code: Select all

B3> sf erase 0 80000 

Code: Select all

B3> sf write 0x800000 0 3E71C

Code: Select all

B3> reset
resetting ...


U-Boot 2013.01.01-b3-rodeus-g53a85c9 (Jan 16 2016 - 01:59:03)
BUBBA|3

SoC:   Kirkwood 88F6281_A1
DRAM:  512 MiB
WARNING: Caches not enabled
SF: Detected M25P16 with page size 64 KiB, total 2 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0, egiga1
88E1116 Initializing on egiga0 @08 done
88E1116 Initializing on egiga1 @09PHY reset timed out
 done
Hit any key to stop autoboot:  0 
............
If all went well you device should boot.

MouettE
Site admin
Posts: 292
Joined: 06 Oct 2011, 19:45

Re: Bricked my B3 after u-boot flash

Post by MouettE » 15 Jan 2016, 22:46

If the procedure above doesn't work we need to go very low level and use the hardware bootloader to load u-boot from the serial line into the RAM, and from there we will run the flash procedure.

This can only be run on Linux.

Boot your PC on your favorite distribution and go into the U-Boot compilation tree (clone it from github if you need to). Then build the kwboot utility :

Code: Select all

charles@darkcix:~/projects$ git clone https://github.com/Excito/U-Boot-B3.git
Cloning into 'U-Boot-B3'...
remote: Counting objects: 8361, done.
remote: Compressing objects: 100% (4/4), done.
remote: Total 8361 (delta 4), reused 3 (delta 3), pack-reused 8354
Receiving objects: 100% (8361/8361), 14.39 MiB | 2.63 MiB/s, done.
Resolving deltas: 100% (2396/2396), done.
Checking connectivity... done.
charles@darkcix:~/projects$ cd U-Boot-B3/
charles@darkcix:~/projects/U-Boot-B3$ make tools/kwboot
cc     tools/kwboot.c   -o tools/kwboot
charles@darkcix:~/projects/U-Boot-B3$ cd tools/
charles@darkcix:~/projects/U-Boot-B3/tools$ wget -q http://install.excito.org/b3/uboot/beta/uboot-rodeus.zip
charles@darkcix:~/projects/U-Boot-B3/tools$ unzip uboot-rodeus.zip 
Archive:  uboot-rodeus.zip
   creating: install/
  inflating: install/u-boot.kwb      
For the next step your B3 power plug needs to be removed and the usb key containing the working u-boot version should be plugged (see previous post). I suppose you only have one usb-serial adapter as your screenshots show, the device should be /dev/ttyUSB0. You obviously need write access to it so run the following as root or add your user to the group with sufficient rights on the serial devices.

Code: Select all

charles@darkcix:~/projects/U-Boot-B3/tools$ ./kwboot -b install/u-boot.kwb -p -t -B 115200 /dev/ttyUSB0
Sending boot message. Please reboot the target.../
The last character should spin. Apply power on the B3 and wait for the upload to finish. Then quickly press enter at the "Hit any key to stop autoboot" prompt otherwise your B3 will start the OS.

Code: Select all

Sending boot message. Please reboot the target...-
Sending boot image...
  0 % [......................................................................]
  3 % [......................................................................]
  7 % [......................................................................]
 10 % [......................................................................]
 14 % [......................................................................]
 17 % [......................................................................]
 21 % [......................................................................]
 24 % [......................................................................]
 28 % [......................................................................]
 31 % [......................................................................]
 35 % [......................................................................]
 38 % [......................................................................]
 42 % [......................................................................]
 45 % [......................................................................]
 49 % [......................................................................]
 52 % [......................................................................]
 56 % [......................................................................]
 59 % [......................................................................]
 63 % [......................................................................]
 66 % [......................................................................]
 70 % [......................................................................]
 73 % [......................................................................]
 77 % [......................................................................]
 80 % [......................................................................]
 84 % [......................................................................]
 87 % [......................................................................]
 91 % [......................................................................]
 94 % [......................................................................]
 98 % [.......................................]
[Type Ctrl-\ + c to quit]


U-Boot 2013.01.01-b3-rodeus-g53a85c9 (Jan 16 2016 - 01:59:03)
BUBBA|3

SoC:   Kirkwood 88F6281_A1
DRAM:  512 MiB
WARNING: Caches not enabled
SF: Detected M25P16 with page size 64 KiB, total 2 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0, egiga1
88E1116 Initializing on egiga0 @08 done
88E1116 Initializing on egiga1 @09PHY reset timed out
 done
Hit any key to stop autoboot:  0 
B3>
The hardest part is done. Run the following commands to flash the device :

Code: Select all

B3> usb start
(Re)start USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 3 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found
B3> run usbflash
reading /install/u-boot.kwb
255772 bytes read in 44 ms (5.5 MiB/s)
SF: Detected M25P16 with page size 64 KiB, total 2 MiB
B3>
That should do it. Now reset the board and it should start normally:

Code: Select all

B3> reset
resetting ...


U-Boot 2013.01.01-b3-rodeus-g53a85c9 (Jan 16 2016 - 01:59:03)
BUBBA|3

SoC:   Kirkwood 88F6281_A1
DRAM:  512 MiB
WARNING: Caches not enabled
SF: Detected M25P16 with page size 64 KiB, total 2 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0, egiga1
88E1116 Initializing on egiga0 @08 done
88E1116 Initializing on egiga1 @09PHY reset timed out
 done
Hit any key to stop autoboot:  0 
3682680 bytes read in 140 ms (25.1 MiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-3.18.24-1
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3682616 Bytes = 3.5 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
..... bla bla bla linux booting .....
Press Ctrl-\ then c to exit kwboot. That's it you unbricked your b3 using a very cool procedure 8) 8)

Gordon
Posts: 1407
Joined: 10 Aug 2011, 03:18

Re: Bricked my B3 after u-boot flash

Post by Gordon » 16 Jan 2016, 05:05

mintz wrote:Voilà! I switched TX and RX cables and suddenly getting output from my beloved B3. I think the information on the Wiki page might have switched the two cables.
No, the wiki is correct. For the FTDI cables at least. I had the same issue with the blank screen when I adapted my cable to use the edge connector. Because of the size of the connector I had to drop the color coding of the wires towards the board and reverted to their identification as Tx or Rx. The thing is: what is transmitted (Tx) on one side, needs to be received (Rx) on the other. To pair two devices you therefore need to cross the wires, also referred to as null-modem. This introduces a definition problem: which side of the cable is represented when the connector states 'Tx'? The logical assumption is that if a wire on a USB-to-RS232 cable is stamped 'Tx', it is the Tx from the computer where the USB is plugged in. This is however not what you would intuitively do, because it means this wire needs to be connected to Rx on the board.

mintz
Posts: 25
Joined: 31 Dec 2012, 08:03

Re: Bricked my B3 after u-boot flash

Post by mintz » 16 Jan 2016, 12:39

IT'S ALIVE!!!
Image

The first procedure didn't work as we might have suspected so I followed the instruction on the second one. kwboot was compiled and ran without problem and I managed to "quick-time" the boot timer.

One problem was that it refused to read two of my USB-drives due to "invalid partition" at first and then "partition table not found" on the second. Both were re-formated to FAT in Linux but it didn't help. It did however read from my microSD card adapter.

The rest of the procedure went smoothly all the way up to OS boot. I decided to go with Debian jessie image 1.0. It also went flawlessly.

My lovely Bubba is alive again. You guys are the best! Huge thanks! :mrgreen: :mrgreen: :mrgreen: :mrgreen:

beatgr
Posts: 46
Joined: 01 Feb 2009, 15:25

Re: Bricked my B3 after u-boot flash [Solved]

Post by beatgr » 29 Jul 2021, 12:38

I acquired a NOS Excito B3 (no wireless) last week.
Given the age of this B3 server, it likely had the old version UBOOT, that would not support 3 TB or greater HD.
==
I successfully installed the Debian 10 (Buster) kernel, created by Charles (MouettE), yesterday.
Pre-configuring a static LAN in install.ini was well documented (it worked).
==
Today, I ventured into updating the UBOOT for support of larger Hard Drives (3 TB and greater).
I used the ZIP file posted by MouettE, in this thread. This was his working version based on the github tree (rodeus tag)
which he tested. You can download from the excito install server : uboot-rodeus.zip

UnZip the file on a USB key (previously FAT or FAT32 formatted).
Check that the file: u-boot.kwb file is contained in the in the /install directory of the USB.

Turn OFF Excito B3.
Insert USB into either back slot of B3.
Hold Down the Reset button for 2 seconds, while applying Power.
B3 should have a Green Light.
Wait about 2 minutes.
Turn Off B3.
When you Repower the B3, the Changed LED color (white) signifies successful install.
My previous Debian 10 (Buster) install booted normally.

greg

Post Reply