Re: In the same situation "sunxi-fel -l" and "sunxi-fel -list" give a different result.

590 views
Skip to first unread message

Bernhard Nortmann

unread,
Dec 13, 2016, 6:00:56 AM12/13/16
to John...@xs4all.nl, linux-sunxi
Hi John!

Am 12.12.2016 um 21:08 schrieb John W. Kitz:
> Alejandro, Bernhard,
>
> When using the prebuilt Win32 binaries of "sunxi-fel", which I downloaded
> from
> "https://ci.appveyor.com/project/linuxsunxi/sunxi-tools/build/artifacts" I
> noticed that in the same situation "sunxi-fel -l" and "sunxi-fel -list" give
> a different result.
>
> That is when "sunxi-fel -list" yielded "ERROR: Allwinner USB FEL device not
> found!", "sunxi-fel -l" yielded no output whatsoever.
>
> Regards, Jk.
>

"sunxi-fel -list" is invalid command syntax. The utility only accepts "-l",
"--list" and "list". The "-list" you used is essentially the same as any
other invalid command, say "sunxi-fel foobar".

Unfortunately, the command line parameter handling of sunxi-fel is a bit
quirky. When no valid option-style argument is found, the program will
process remaining arguments only after trying to open an USB connection to
the first device in FEL mode that it detects. This fails in your case,
which is why you end up with "Allwinner USB FEL device not found" instead
of "Invalid command -list".

"sunxi-fel -l" is intended to be 'silent' when no devices are detected.
This is to allow checking for FEL devices within a batch file, where the
exit status would determine if any were found. To actually report failure
you should add the verbose option, i.e. "sunxi-fel -v -l" would tell you
"No Allwinner devices in FEL mode detected".

Did you follow the driver installation procedure as described at
http://linux-sunxi.org/FEL/USBBoot#Using_sunxi-fel_on_Windows ?
To check if your device gets detected at all, please run the listdevs.exe
that is enclosed in the download archive. Make sure that your SoC shows
up with a USB ID of "1f3a:efe8". If that's the case and the proper WinUSB
driver is assigned, sunxi-fel should be able to access it.

Regards, B. Nortmann


John W. Kitz

unread,
Dec 13, 2016, 6:20:29 AM12/13/16
to am...@geeks.cl, bernhard...@web.de, linux-sunxi
Alejandro, Bernhard,

It appears I wasn't entirely accurate, or complete rather, in my email
below.

When the board is NOT in FEL mode:

- listdevs results in "18d1:0003 (bus 2, device 2) path: 5"

- sunxi-fel -l results in no output whatsoever
- sunxi-fel --list results in no output whatsoever

- sunxi-fel --l results in "ERROR: Allwinner USB FEL device not found!"
- sunxi-fel -list results in "ERROR: Allwinner USB FEL device not found!"

When the board IS in FEL mode (using the switch during power on):

- listdevs results in "1f3a:efe8 (bus 1, device 4) path: 5"

- sunxi-fel -l results in "libusb_open() ERROR -12: Operation not supported
or unimplemented on this platform."
- sunxi-fel --list results in "libusb_open() ERROR -12: Operation not
supported or unimplemented on this platform."

- sunxi-fel --l results in "ERROR: Allwinner USB FEL device not found!"
- sunxi-fel -list results in "ERROR: Allwinner USB FEL device not found!"

All the above on Windows 7 SP1 64 bits on AMD64, using a
CubieBoard2-20151211-EMMC.

This is, as I understand from your email, as expected. I have downloaded a
copy of the driver and will take it from there.

Thanks and regards, Jk.

Bernhard Nortmann

unread,
Dec 13, 2016, 7:44:02 AM12/13/16
to John...@xs4all.nl, linux-sunxi
Hello John,

I intend to fix this "inconsistent" behaviour by explicitly reporting
invalid options (that sunxi-fel did not recognize). See
https://github.com/linux-sunxi/sunxi-tools/pull/87/commits/1d2182c

That should get rid of "ERROR: Allwinner USB FEL device not found!" in
situations where you might not be expecting it, and would point out stuff
like "--l" or "-list" as invalid.

Btw: The ERROR -12 you got is expected - as long as no proper USB driver
was assigned on Windows. Running Zadig as described should fix that.

Regards, B. Nortmann

Bernhard Nortmann

unread,
Dec 13, 2016, 7:46:07 AM12/13/16
to John...@xs4all.nl, linux-sunxi
P.S.: For testing purposes, you can find updated binaries under
https://ci.appveyor.com/project/n1tehawk/sunxi-tools/build/v1.4%20%2346/artifacts

Bernhard Nortmann

unread,
Dec 17, 2016, 11:15:20 AM12/17/16
to John...@xs4all.nl, linux-sunxi
Hi John!

Has this been solved for you and/or were you able to test the reworked
binaries?
>P.S.: For testing purposes, you can find updated binaries under
>https://ci.appveyor.com/project/n1tehawk/sunxi-tools/build/v1.4%20%2346/artifacts


Regards, B. Nortmann

John W. Kitz

unread,
Dec 18, 2016, 7:41:40 AM12/18/16
to bernhard...@web.de, linux-sunxi
Bernhard,

> P.S.: For testing purposes, you can find updated binaries under https://ci.appveyor.com/project/n1tehawk/sunxi-tools/build/v1.4%20%2346/artifacts

I haven't tried them yet. But if I do and if I have any additional questions as a result of that I'll let you know.

Regards, Jk.

Reply all
Reply to author
Forward
0 new messages