Update documentation and scripts to match xmosdfu changes

This commit is contained in:
Oscar Bailey
2020-10-27 15:28:32 +00:00
parent 60e23eb5cd
commit eb9a90574e
3 changed files with 27 additions and 9 deletions

View File

@@ -39,3 +39,18 @@ Raspberry Pi
A makefile is provided for Raspbian. libusb is required and can be installed using the ``apt-get`` command from previous Linux section.
.. literalinclude:: Makefile.Pi
Windows
-------
To build on Windows, you must first install Visual Studio 2019 Build Tools with
C++ support. `This is available from Microsoft's website. <https://visualstudio.microsoft.com/downloads/#build-tools-for-visual-studio-2019>`_
To build, open a Developer Command Prompt via the start menu and navigate to the
xmosdfu folder. The command to build is as follows:
``nmake /f Makefile.Win32``
This Makefile contains the following:
.. literalinclude:: Makefile.Win32

View File

@@ -4,6 +4,9 @@ Using the DFU loader - macOS (via the XMOS DFU loader)
The XMOS DFU loader is provided as source as part of the XMOS USB Audio software
framework, see :ref:`usb_audiosec_building_xmos_dfu`.
NOTE: Windows requires the installation of libusbK drivers on the DFU endpoint.
We recommend using `Zadig <https://zadig.akeo.ie/>`_.
Set up the image loader
-----------------------
@@ -18,7 +21,7 @@ Download new firmware
To program the new firmware run the command:
``./xmosdfu XMOS_L2_AUDIO2_PID --download new_firmware.bin``
``./bin/xmosdfu XMOS_L2_AUDIO2_PID --download new_firmware.bin``
Replace ``XMOS_L2_AUDIO2_PID`` with product ID of your target device. Invoke
``xmosdfu`` with no arguments to get a list of all supported product IDs.
@@ -35,7 +38,7 @@ present.
Run the command:
``./xmosdfu XMOS_L2_AUDIO2_PID --upload currentfirmware.bin``
``./bin/xmosdfu XMOS_L2_AUDIO2_PID --upload currentfirmware.bin``
The file ``currentfirmware.bin`` contains the latest upgrade image. This file is
an exact copy of the data from the flash and can be downloaded to the device
@@ -47,6 +50,6 @@ Reverting firmware to factory image
To revert the device back to its factory (i.e XFLASH) installed state from the
new firmware, run the command:
``./xmosdfu XMOS_L2_AUDIO2_PID --revertfactory``
``./bin/xmosdfu XMOS_L2_AUDIO2_PID --revertfactory``
The device will now be running, and only contain the factory firmware.

View File

@@ -73,42 +73,42 @@ system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version
echo ""
echo "*** DFU download new firmware 1 ***"
$PROGDIR/xmosdfu $device_pid --download $update1
$PROGDIR/bin/xmosdfu $device_pid --download $update1
sleep 2
echo "Version Read:"
system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version
echo ""
echo "*** DFU download new firmware 2 ***"
$PROGDIR/xmosdfu $device_pid --download $update2
$PROGDIR/bin/xmosdfu $device_pid --download $update2
sleep 2
echo "Version Read:"
system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version
echo ""
echo "*** DFU upload existing firmware ***"
$PROGDIR/xmosdfu $device_pid --upload upload.bin
$PROGDIR/bin/xmosdfu $device_pid --upload upload.bin
sleep 2
echo "Version Read:"
system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version
echo ""
echo "*** DFU revert to factory ***"
$PROGDIR/xmosdfu $device_pid --revertfactory
$PROGDIR/bin/xmosdfu $device_pid --revertfactory
sleep 2
echo "Version Read:"
system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version
echo ""
echo "*** DFU download uploaded firmware ***"
$PROGDIR/xmosdfu $device_pid --download upload.bin
$PROGDIR/bin/xmosdfu $device_pid --download upload.bin
sleep 2
echo "Version Read:"
system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version
echo ""
echo "*** DFU revert to factory ***"
$PROGDIR/xmosdfu $device_pid --revertfactory
$PROGDIR/bin/xmosdfu $device_pid --revertfactory
sleep 2
echo "Version Read:"
system_profiler SPUSBDataType|grep -A10 "$device_grep_string" |grep Version