No device found on COM5 with Bossac on Winwdows 7

Hi all !

I tried to upload a program in my Arduino Due with Bossac, but it does not work.

My command line is as follows:

C:\ARM\arduino-1.5.1r2\hardware\tools\bossac.exe -port=COM5 -U false -e -w -v -b C:\Users\Me\AppData\Local\Temp\build8940831537078293554.tmp\Blink.cpp.bin -R

Bossac displays the following message:

No device found on COM5

However, whenever I run the command line, the TX LED blink for about one second.

I work under Windows 7 and I use bossac.exe provided with Arduino Due IDE.

When I use the Arduino IDE Due, on COM5 there is no problem. But the command line I get the message "No device found on COM5".

I do not understand what happens !

I uplaod successful program only 2 times only with the command line.

Thank you for your help.

Nassa.

Hello Nassarane. Try --port=COM5 instead of -port=COM5. It could be a syntax issue.

Oh sorry !

I made ??a mistake in this post.
In fact my command line is:

C:\ARM\arduino-1.5.1r2\hardware\tools\bossac.exe --port=COM5 -U false -e -w -v -b C:\Users\Me\AppData\Local\Temp\build8940831537078293554.tmp\Blink.cpp.bin -R

I try to add 2 options -d et the messages displayed are :

Send auto-baud
Set binary mode
No device found on COM5

I don't understand why this command line doesn't work...

Nassa.

Next thing I would recommend is to do the following: With the board powered, press the erase button and after a second, press also the reset button. Keep them pressed for another second. Then power cycle the board and try again the bossac. Good luck!

Palliser, thanks very much for your help !

I erased and reset your my board and I relaunch my commad line.
The messages displayed are :

Erase flash
Write 9748 bytes to flash
[==============================] 100% (39/39 pages)
Verify 9748 bytes of flash
[==============================] 100% (39/39 pages)
Verify successful
Set boot flash true
CPU reset.

The program uploaded is running correctly ! Yes !

But if I try to relaunch my command line, It doesn't work !!!
I must erase and reset my board before upload my program...

But, I don't understand why the message displayed is different of Arduino IDE:

Erase flash
Write 9748 bytes to flash

[                              ] 0% (0/39 pages)
[=======                       ] 25% (10/39 pages)
[===============               ] 51% (20/39 pages)
[=======================       ] 76% (30/39 pages)
[==============================] 100% (39/39 pages)
Verify 9748 bytes of flash

[                              ] 0% (0/39 pages)
[=======                       ] 25% (10/39 pages)
[===============               ] 51% (20/39 pages)
[=======================       ] 76% (30/39 pages)
[==============================] 100% (39/39 pages)
Verify successful
Set boot flash true
CPU reset.

And why I must erase and reset my board each time I want to upload a program ?

Thanks.

Nassa.

I learned from this forum that it is mandatory to have the memory erased to make the Bossac bootloader run. In the case of the Arduino, the Due executes a soft erase command when the IDE opens and closes the COM port. May be someone here have grasp more details on this matter.

Thanks very much Palliser,

I found the interesting information on the Arduino Due web page :

  • Programming port: To use this port, select "Arduino Due (Programming Port)" as your board in the Arduino IDE. Connect the Due's programming port (the one closest to the DC power jack) to your computer. The programming port uses the 16U2 as a USB-to-serial chip connected to the first UART of the SAM3X (RX0 and TX0). The 16U2 has two pins connected to the Reset and Erase pins of the SAM3X. Opening and closing the Programming port connected at 1200bps triggers a “hard erase” procedure of the SAM3X chip, activating the Erase and Reset pins on the SAM3X before communicating with the UART. This is the recommended port for programming the Due. It is more reliable than the "soft erase" that occurs on the Native port, and it should work even if the main MCU has crashed.

Thanks.

Nassa.

In my experience, We should use Native USB on Deu to upload sketch into Due on Windows 7&8. Also, need to press the erase button for a few seconds before uploading.

Hi,

Here's a script for Windows to send erase flash request and upload program :

@mode com5:1200,n,8,1
@sleep 1
@C:\arduino-1.5.1r2\hardware\tools\bossac.exe %*

Copy this MS-DOS script in the "upload.bat" file and replace bossac.exe by upload.bat in your Eclipse External Tools.
(Here, it is the com5 is used, change the value and the bossac path if necessary)

Nassa.

1 Like

Oops : you can use this simplified command line :

@mode com5:1200
@sleep 1
@C:\arduino-1.5.1r2\hardware\tools\bossac.exe %*

Nassa.

Not necessary to set your com port with this sript :

@mode %2:1200
@sleep 1
@C:\arduino-1.5.1r2\hardware\tools\bossac.exe %*

Nassa.

This problem disappeared for me when I removed DC power to the DUE and let the board be powered only by the USB port.

I originally connected power to the Due as well as plugging in the USB port.

Hi Friends,

I had made a an Arduino Due compatible Design using ATSAM3X8E but my USB interface does not work at all. I compared Schematics, with Arduino Due, read ATSAM3X8E design check list but did not find any issue.

Detailed issue can be seen here:
http://forum.arduino.cc/index.php?topic=328843.0

I have two prototype boards with ATSAM3X8E but both do not work for USB interface. However, I can always program the ATSAM3X8E chip using Arduino IDE over UART interface. But dont know whats wrong with USB interface.

Please have a look at my schematic in the given link above and let me know if you can find any issue?