DFU loader for XMOS USB AUDIO - Linux?

If you have a simple question and just want an answer.
User avatar
Chendy
Active Member
Posts: 46
Joined: Tue Nov 02, 2010 4:53 pm

DFU loader for XMOS USB AUDIO - Linux?

Post by Chendy »

I'm wondering what approaches there is for updating/flashing firmware for a XMOS USB Audio device, without using a XTAG or other external tool. 

For windows and OSX it seems the "DFU Loader" does the job, but Linux?

Thanks

Senthil



zab
Junior Member
Posts: 4
Joined: Tue Jul 12, 2016 2:16 am

Post by zab »

308 views but no replies; seems there's interest in this.

+1 !!
Dyang
Member++
Posts: 17
Joined: Tue Nov 01, 2016 2:06 am

Post by Dyang »

Read the design_guide,

Macro :DFU
Description :Enable DFU functionality.
A driver required for Windows operation.
Default: 1 (Enabled)


,Maybe Linux doesn't need ?
zab
Junior Member
Posts: 4
Joined: Tue Jul 12, 2016 2:16 am

Post by zab »

Reading the build instructions for OSX:
https://www.xmos.com/support/boards?ver ... 441&page=4

Would it simply be a case of changing the Makefile flags to suit *nix?
User avatar
johned
XCore Addict
Posts: 185
Joined: Tue Mar 26, 2013 12:10 pm

Post by johned »

A kind customer has shared these instructions with me, to explain how they got this running under Ubuntu 17.04.

1. Install usblib:
sudo apt-get install libusb-1.0-0-dev

2. Tweak headers in ‘xmosdfu.cpp’ :
#include <libusb-1.0/libusb.h>

3. Build:
g++ -g -o xmosdfu xmosdfu.cpp `pkg-config --libs --cflags libusb-1.0`

Needs root privileges to run.

Best regards,
John
jseaber
Newbie
Posts: 1
Joined: Thu Aug 05, 2021 4:35 pm

Post by jseaber »

johned wrote: Tue Oct 10, 2017 11:24 am A kind customer has shared these instructions with me, to explain how they got this running under Ubuntu 17.04.

1. Install usblib:
sudo apt-get install libusb-1.0-0-dev

2. Tweak headers in ‘xmosdfu.cpp’ :
#include <libusb-1.0/libusb.h>

3. Build:
g++ -g -o xmosdfu xmosdfu.cpp `pkg-config --libs --cflags libusb-1.0`

Needs root privileges to run.

Best regards,
John
To save anyone a headache, the DFU loader compiles under Ubuntu 20.0.4 with these modifications, but produces unexpected results. Observations:

'xmosdfu --listdevices' works
'xmosdfu --download...' returns the error "Could not find/open device", despite the VID/PID appearing correctly in the list and the same code running fine under macOS. I've attempted to read through xmosdfu.cpp and see this error is thrown by:

Code: Select all

if (libusb_open(dev, &devh) < 0) 
                {
                    return -1;
                } 

So, libusb functionality differs in this setup. Additionally, 5 warnings are returned when compiling, which differ from the 6 warnings returned when compiling under macOS Big Sur. This again suggests a difference in the compiled version of libusb.

I'll update if/when we manage to resolve.