Maple Mini (clones) - Programming from [.bin] with [usb]

Stophe
Posts: 10
Joined: Mon Aug 03, 2015 12:54 pm

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby Stophe » Thu Aug 06, 2015 11:10 am

This is what I got, there is a few differences actually :
A:\Stophe>dfu-util -l
dfu-util 0.8

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2014 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to dfu-util@lists.gnumonks.org

Found DFU: [1eaf:0003] ver=0201, devnum=4, cfg=1, intf=0, alt=1, name="DFU Program FLASH 0x08005000", serial="LLM 003"
Found DFU: [1eaf:0003] ver=0201, devnum=4, cfg=1, intf=0, alt=0, name="DFU Program RAM 0x20000C00", serial="LLM 003"


and

D:\Temp\build1002012548081470735.tmp>dfu-util -d 0x1EAF:0x0003 -a 1 -D sketch_aug06a.cpp.bin -R
dfu-util 0.8

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2014 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to dfu-util@lists.gnumonks.org

Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
Opening DFU capable USB device...
ID 1eaf:0003
Run-time device DFU version 0110
Claiming USB DFU Interface...
Setting Alternate Setting #1 ...
Determining device status: state = dfuIDLE, status = 0
dfuIDLE, continuing
DFU mode device DFU version 0110
Device returned transfer size 1024
Copying data from PC to DFU device
Download [=========================] 100% 12100 bytes
Download done.
state(8) = dfuMANIFEST-WAIT-RESET, status(0) = No error condition is present
Done!
Resetting USB to switch back to runtime mode


acutally my previous .bat file was doing

Code: Select all

dfu-util -a1 -d 0x1EAF:0x0003 -D prg.bin
which is maybe a mistake. (the blank space missing or the -R missing). I get the Com port back for a while.

So I got the arduino IDE to write this :

Edit: I recompiled, I lost the message and it's not coming back. I'll reboot my computer, and redo those few steps.

User avatar
RogerClark
Posts: 5614
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby RogerClark » Thu Aug 06, 2015 12:08 pm

you are using an incompatible version of dfu-util

it only works with the version in the repo.

Stophe
Posts: 10
Joined: Mon Aug 03, 2015 12:54 pm

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby Stophe » Thu Aug 06, 2015 3:10 pm

My bad !
So right now I have what you had :
A:\Stophe>dfu-util -l
dfu-util - (C) 2007-2008 by OpenMoko Inc.
This program is Free Software and has ABSOLUTELY NO WARRANTY

Found DFU: [0x1eaf:0x0003] devnum=255, cfg=0, intf=0, alt=0, name="DFU Program R
AM 0x20000C00"
Found DFU: [0x1eaf:0x0003] devnum=255, cfg=0, intf=0, alt=1, name="DFU Program F
LASH 0x08005000"

But there, the same message as from arduino
dfu-util - (C) 2007-2008 by OpenMoko Inc.
This program is Free Software and has ABSOLUTELY NO WARRANTY

Opening USB Device 0x1eaf:0x0003...
Found Runtime: [0x1eaf:0x0003] devnum=255, cfg=0, intf=0, alt=1, name="DFU Progr
am FLASH 0x08005000"
Setting Configuration 1...
Claiming USB DFU Interface...
Setting Alternate Setting ...
Determining device status: error get_status: usb_control_msg: sending control me
ssage failed, win error: Un pÚriphÚrique attachÚ au systÞme ne fonctionne pas co
rrectement.
:|

Edit : currently googling the thing... which is not really a success.

User avatar
RogerClark
Posts: 5614
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby RogerClark » Thu Aug 06, 2015 10:03 pm

very strange

try another cable
try another usb port

try a different computer that does not have too much other development software etc on it.

zmemw16
Posts: 1099
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby zmemw16 » Thu Aug 06, 2015 10:33 pm

RogerClark wrote:you are using an incompatible version of dfu-util

it only works with the version in the repo.


spotting this i went off to check what i've got installed .... /usr/bin has
-rwxr-xr-x 1 root root 13936 Oct 4 2014 dfu-prefix
-rwxr-xr-x 1 root root 13952 Oct 4 2014 dfu-suffix
-rwxr-xr-x 1 root root 43000 Oct 4 2014 dfu-util

stephen@i7:/usr/bin$ ./dfu-util
dfu-util 0.8

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2014 Tormod Volden and Stefan Schmidt

attempting to run from tools/linux/dfu-util gives
stephen@i7:~/sketchbook_stm32/hardware/Arduino_STM32/tools/linux/dfu-util$ ./dfu-util
bash: ./dfu-util: cannot execute binary file: Exec format error

stephen@i7:~/sketchbook_stm32/hardware/Arduino_STM32/tools/linux/dfu-util$ file *
dfu-prefix: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=00bf7e97d0c1f723bf4fd42b15e4e604faed5623, not stripped
dfu-suffix: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=6a2247e79caa6ce6791dd0fef8a63a7e4290bab2, not stripped
dfu-util: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=c58354ce3ca661a39bc97aacb5beffa73cf5dfb3, not stripped

any chance of x86-32 ? or does the debian package dfu-util_0.8-1_i386.deb suffice ?

/usr/bin/dfu-util does report devices correctly.

stephen

User avatar
RogerClark
Posts: 5614
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby RogerClark » Thu Aug 06, 2015 10:41 pm

Stephen,

Thats odd.

I thought the version in the repo, was the 32 bit version that I compiled on my Linux mint x32 machine.

The source for dfu is in the repo.

look in tools/src and recompile it, and see if that fixes it for you.

Note. look in the wiki, there are instructions for downloading and building the latest copy of dfu util etc,
but the sources in the repo should be fine, as they were updated yesterday with a Pull Request by @fergul to address an issue with the line endings in the automake or autoconfig scripts.

zmemw16
Posts: 1099
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby zmemw16 » Fri Aug 07, 2015 12:43 am

oh it gets better...
most surprised by root password request and seeing apt-get being run.
i was expecting something like wget for a tgz && tar xpf dfu*.tgz && cd dfu-util && ./autogen.sh ...... etc etc type of invocation

stephen@i7:~/sketchbook_stm32/hardware/Arduino_STM32/tools/src$ ./build_dfu-util.sh
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
build-essential is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
libusb-1.0-0-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
autoconf is already the newest version.
automake is already the newest version.
autotools-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
./build_dfu-util.sh: line 8: cd: dfu-util: No such file or directory
./build_dfu-util.sh: line 9: ./autogen.sh: No such file or directory
./build_dfu-util.sh: line 10: ./configure: No such file or directory
make: *** No targets specified and no makefile found. Stop.
cp: cannot stat ‘src/dfu-util’: No such file or directory
cp: cannot stat ‘src/dfu-suffix’: No such file or directory
cp: cannot stat ‘src/dfu-prefix’: No such file or directory

now i've copied dfu-util directory from your 060815-0842 build of yesterday, which has the source files in it

NB build-essentials should actually be build-essential, changed it here

now it builds and file shows
dfu-util: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=9224b7d0baa7b7dca954890f70197ccc032f42a5, not stripped

istr target format is an option to configure
i thought it was going to install the deb src package into dfu-util and build from that. so i'm off to google how that's done

are you running a debian x64 system?

trying to be helpful i thought i'd attach my build tree
nope - different story tgz too large at 430k so i split the file, parts have invalid file extension
tried to the binaries - Invalid file extension: dfu-prefix
copied and renamed to *.bin - Invalid file extension: dfu-prefix.bin

stephen

User avatar
RogerClark
Posts: 5614
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby RogerClark » Fri Aug 07, 2015 12:51 am

I'm running Linux Mint x32

There are at least 2 other Linux users, @ahull and @RickKimball , but I'm not sure what flavours of linux they use

Actually 99% of the time I use WIndows, I just tripple boot on of my machines to test Linux stuff when necessary

fredbox
Posts: 84
Joined: Tue Jul 07, 2015 4:44 pm

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby fredbox » Fri Aug 07, 2015 3:24 am

Linux Mint 17.2 Cinnamon 64 bit user here.
No issues at all uploading to the Maple mini board.
Occasionally, I have to press reset while uploading, but most of the time it works just fine.

I started out by doing a git clone of Roger's repo. About once a week (or after he has posted an update) I do a git pull to load the latest changes.
Board: Maple Mini
Bootloader Version: "Bootloader 2.0 (20k RAM. 120k Flash)"

Code: Select all

Sketch uses 20,628 bytes (16%) of program storage space. Maximum is 122,880 bytes.
Global variables use 4,384 bytes of dynamic memory.
dfu-util 0.8
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2014 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to dfu-util@lists.gnumonks.org
Opening DFU capable USB device...
ID 1eaf:0003
Run-time device DFU version 0110
Claiming USB DFU Interface...
Setting Alternate Setting #2 ...
Determining device status: state = dfuIDLE, status = 0
dfuIDLE, continuing
DFU mode device DFU version 0110
Device returned transfer size 1024
Copying data from PC to DFU device
dfu-util: Invalid DFU suffix signature
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
Download   [                         ]   0%            0 bytes
... (bunch of lines deleted) ...
Download   [=========================] 100%        20628 bytes
Download done.
state(8) = dfuMANIFEST-WAIT-RESET, status(0) = No error condition is present
Done!

User avatar
martinayotte
Posts: 1170
Joined: Mon Apr 27, 2015 1:45 pm

Re: Maple Mini (clones) - Programming from [.bin] with [usb]

Postby martinayotte » Fri Aug 07, 2015 3:27 am

I'm actually an Linux 64bits user.
It it can help, here is dfu-util-0.7.zip, although I didn't follow the whole thread.
Attachments
dfu-util-0.7.zip
(51.21 KiB) Downloaded 51 times
Last edited by martinayotte on Fri Aug 07, 2015 1:59 pm, edited 1 time in total.


Return to “Maple mini”

Who is online

Users browsing this forum: No registered users and 2 guests