96boards-hikey / tools-images-hikey970

22 stars 14 forks source link

recovery-flash.sh not work #1

Open randoms opened 6 years ago

randoms commented 6 years ago

The following command cannot flash base firmware. The script reported an error of file not found.

sudo ./recovery-flash.sh /dev/ttyUSBx

I found the following commends in the script, but the resources were not available.

UEFI dir. Downloaded from https://builds.96boards.org/snapshots/reference-platform/components/uefi-staging/ Eg: 26/hikey970/release/ Then, modify UEFI_BUILD_PATH accordingly.

I tried to build the required images myself. And the file not found issue was solved. But the script fail to run to completion and stick at "< waiting for any device >" . My OS is Ubuntu 16.04, and I don't have modemmanager installed.

How to fix it? Thanks.

randoms commented 6 years ago

I managed to make it work. Download the images from AOSP Download Page. Extract the rar file, and copy all image and bin files in the image directory to current directory.

change recovery-flash.sh line 9 from

UEFI_BUILD_PATH=/home/qubo/tools-images-hikey970

to

UEFI_BUILD_PATH=${PWD}

set the switches of the board to on on on off, and run

sudo ./recovery-flash.sh /dev/ttyUSBx
jainrahul1 commented 6 years ago

@randoms when i try to use recovery-flash.sh it gives following output Config name: tools-images-hikey970/config Port name: /dev/ttyXRUSB0 0: Image: ./sec_usb_xloader.img Downalod Address: 0x22000 1: Image: ./sec_usb_xloader2.img Downalod Address: 0x60049000 2: Image: ./l-loader.bin Downalod Address: 0x16800000 Serial port open successfully! Start downloading ./sec_usb_xloader.img@0x22000... file total size 122880 downlaod address 0x22000

It remains stuck in download address and nothing happen afterwards. Could you please advice what to do?

randoms commented 6 years ago

Sorry, I haven't met this.

kokleong98 commented 5 years ago

@randoms when i try to use recovery-flash.sh it gives following output Config name: tools-images-hikey970/config Port name: /dev/ttyXRUSB0 0: Image: ./sec_usb_xloader.img Downalod Address: 0x22000 1: Image: ./sec_usb_xloader2.img Downalod Address: 0x60049000 2: Image: ./l-loader.bin Downalod Address: 0x16800000 Serial port open successfully! Start downloading ./sec_usb_xloader.img@0x22000... file total size 122880 downlaod address 0x22000

It remains stuck in download address and nothing happen afterwards. Could you please advice what to do?

I have same problem same as jainrahul1. It stuck there for hours. How long does the flashing takes normally?

randoms commented 5 years ago

It takes only a few seconds normally.

kokleong98 commented 5 years ago

It takes only a few seconds normally.

Any special setting I need to set in my Ubuntu on the ttyXRUS0 serial communication when flashing?

jainrahul1 commented 5 years ago

Are you using flash-minimum-binaries.sh or flash-all-binaries.sh?

On Mon 15 Oct, 2018, 6:08 AM kokleong98, notifications@github.com wrote:

It takes only a few seconds normally.

Any special setting I need to set in my Ubuntu on the ttyXRUS0 serial communication when flashing?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/96boards-hikey/tools-images-hikey970/issues/1#issuecomment-429677511, or mute the thread https://github.com/notifications/unsubscribe-auth/AVEzzX1Z_LPnT8P4zEoRFZEAa9lrB-QJks5uk9j5gaJpZM4UBGDu .

kokleong98 commented 5 years ago

Are you using flash-minimum-binaries.sh or flash-all-binaries.sh? On Mon 15 Oct, 2018, 6:08 AM kokleong98, @.***> wrote: It takes only a few seconds normally. Any special setting I need to set in my Ubuntu on the ttyXRUS0 serial communication when flashing? — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#1 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/AVEzzX1Z_LPnT8P4zEoRFZEAa9lrB-QJks5uk9j5gaJpZM4UBGDu .

Hi jainrahul1,

I guess I have plug-in into wrong USB port. UART Debug USB port will show /dev/ttyXRUSB0 . The flashing USB port will show /dev/ttyUSB1.

Thanks for trying to help.