SAM-BA 2.10 on Ubuntu 10.10 Communication Error.

Microchip in-system programming solution: SAM-BA

Moderators: nferre, fab

Posts: 4
Joined: Fri Feb 12, 2010 11:45 pm

SAM-BA 2.10 on Ubuntu 10.10 Communication Error.

Wed Nov 17, 2010 1:31 pm

Hello Forum,

I have a problem with programming an AT91SAM7X256-EK board using SAM-BA 2.10.

I have previously used version 2.8 of SAM-BA on Ubuntu 9.04 successfully, but I needed
to update the OS as I was experiencing several unrelated problems. Now I am trying to get my
development environment working again.

As a sanity check I installed SAM-BA 2.10 on my wife's laptop (Windows 7).
It worked fine and flashed the image onto the board which then run as expected.
I am not a big MS fan so would rather not invest in Windows 7 for my sacred Linux box.

I installed the following packages as per the Linux readme:

tcl 8.4.16-2
tclx8.4 8.4.0-3
tk 8.4.16-2

I have successfully loaded the usbserial module and the edited output of lsusb contains:

Bus 003 Device 004: ID 03eb:6124 Atmel Corp. at91sam SAMBA bootloader offered

Tail of dmesg:

[ 4091.396550] usb 3-2: new full speed USB device using uhci_hcd and address 4
[ 4091.553042] usbserial_generic 3-2:1.0: Generic device with no bulk out, not allowed.
[ 4091.553066] usbserial_generic: probe of 3-2:1.0 failed with error -5
[ 4091.553231] usbserial_generic 3-2:1.1: generic converter detected
[ 4091.553500] usb 3-2: generic converter now attached to ttyUSB0

When I try and invoke SAM-BA with the following command line I get a Communication error

host$ ./sam-ba /dev/ttyUSB0 at91sam7x256-ek
-I- Waiting ...
-I- TCL platform : Linux
-I- SAM-BA CDC 2.10 on : linux
-I- Retrieved arguments from command line :
-I- argv 0 : /dev/ttyUSB0
-I- argv 1 : at91sam7x256-ek
-I- argv 2 :
-I- Connection : /dev/ttyUSB0 (target(comType) = 3)
-I- Board : at91sam7x256-ek
-I- Traces Level : 4
-I- target(handle) : file5
Read device Chip ID at 0xfffff240 --- get 0x271b0940
-I- Found processor : at91sam7xc256 (Chip ID : 0x271b0940)
Read device Chip ID at 0xffffee40 --- get 0x00000000

<Communication error pop-up here>

Now I expect that the error message is related to the value returned from address 0xFFFFEE40
no matching what SAM-BA expects. I have grep'ed through the TCL source supplied with SAM-BA
but could not find the corresponding messages.

Could anyone please provide me with a couple of hints as to how I can debug this?
I am happy to dig around, it's just that the Linux documentation is non-existent and I need to
know if I am heading in the right direction.

Thanks in advance for any help given!

Posts: 4
Joined: Fri Feb 12, 2010 11:45 pm

Re: SAM-BA 2.10 on Ubuntu 10.10 Communication Error.

Mon Nov 22, 2010 11:49 pm

Hello Forum,

I managed to get this working using version 2.8 of sam-ba.

Apply the patch found here: ... tch=sam+ba

Follow the instructions given by amenabletochange in the thread found here:

forum/viewtopic.php/f,26/t,19128/st,0/s ... /start,15/

His instructions are very helpful.

I could not get 2.10 running and I got more information about mailing list etiquette then
I did about how to help debug version 2.10 with the new SAM-BA driver from the Linux USB
mailing list. Sometimes working with open source is made more difficult because of the attitudes of
certain members of the 'community' than the technical problems themselves :-(

Good luck!

Return to “SAM-BA”

Who is online

Users browsing this forum: No registered users and 1 guest