LPC1549 USB ISP fails with Linux

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC1549 USB ISP fails with Linux

959 Views
lltsu
Contributor II

Hello,

I'm unable to get the LPC1549 USB ISP bootloader to work on Kubuntu 15.10. When I connect the controller, my computer shows it as a USB MSC device correctly. After that either deleting the firmware.bin and dragging the new .bin file, or executing:

sudo mount /dev/sdb /media/usb

sudo rm -rf /media/usb/firmware.bin

sudo cp new_firmware.bin /media/usb

sudo umount /dev/sdb

But after restarting the controller, it stays in the bootloader without executing the new code. Strangely my computer doesn't recognize it as a USB device anymore and I have to manually shortcircuit ISP_0 to ground and reset the device for my computer to recognize it again.

There shouldn't be any problems with the firmware. I tried to flash the device on Windows 8.1 and it works flawlessly. Also, it looks like that https://community.nxp.com/thread/417507 has the same problem but it has been left unanswered.

Does anyone have any experience on flashing LPC1549 on Linux?

Labels (1)
0 Kudos
2 Replies

559 Views
lltsu
Contributor II

Okay, after a week I'm starting to think that there either is a bug in a Linux USB driver or LPC1549 USB ISP interface is made someway Window-compatible only. Is NXP staff reading these forums or how can I contact them? It would be good if they can verify what is going on.

0 Kudos

559 Views
lltsu
Contributor II

I compared the binary of a small test application and the flashed data from the controller.

this is the hexdump output from the actual binary and this is first 0x2000 bytes of data from the LPC1549 after flashing.

It looks like that the data is not copied correctly as first there are couple of bit errors and after 0x300 the data starts to get really messy. This time I'm using Ubuntu 16.04 64-bit. It really wonders me how is it possible that with Windows 8.1 the USB ISP works fine but it has big problems with Linux. Does anyone have any knowledge if there is some protocol differences how Windows and Linux distros communicate over USB?

0 Kudos