Multiple USBDM programmers and ARM_Programmer command line utility

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

Multiple USBDM programmers and ARM_Programmer command line utility

612 Views
matthewharper
Contributor III

Started using the latest, okay not quite the latest,  USBDM_4_11_1_10 programmer firmware. (I see it got updated last night)

We're using four programmers based on the USBDM firmware for the FRDM-KL25 to program four devices at the same time

using arm_programmer.exe from the command line actually we are shelling out from a C# program to run the utility.

First issue.

One of the the four programmers will hang occasionally.  And we'll have to unplug it. Not sure why this is happening. 

We tried moving them two different USB bus controllers and this helps a lot.  Isn't ideal though.  Not sure why this

is happening exactly, but it's a problem.  Using just one programmer is totally reliable though.

Any guidance on how to go forward would be appreciated.

Second issue

Is when the arm_programmer.exe is run from the command line and you get a target connection

problem, the utility pops up a message box.  This probably should be disabled when running on the command line.

(On our computer is sometimes pops up behind another window and that causes confusion)

This seems like an easy enough fix.

Third question: Is it possible to recompile the dll used by the USBDM firmware and call it directly from C#/.net?

Thanks

0 Kudos
4 Replies

418 Views
pgo
Senior Contributor V

Hi Matthew,

When you say "one of the four" programmers hangs - Do you mean a particular one or just any one of the four?

I will have a look at the pop-up.  I just have failed to set the handler correctly.

The 4.11 versions have been restructured to allow the programming functions to be used independently.  So yes it should be possible to make use of the code to roll your own.  The required DLLs are now plugin-ins though I expect they have rough edges.  I'll make up an example some time soon.

bye

0 Kudos

418 Views
matthewharper
Contributor III

pgo wrote:

When you say "one of the four" programmers hangs - Do you mean a particular one or just any one of the four?

I will have a look at the pop-up.  I just have failed to set the handler correctly.

The 4.11 versions have been restructured to allow the programming functions to be used independently.  So yes it should be possible to make use of the code to roll your own.  The required DLLs are now plugin-ins though I expect they have rough edges.  I'll make up an example some time soon.

Random.  Did find that staggering the programming 'helped' but didn't eliminate the problem. If we stagger them completely then it seems to work okay.  But then programming is slow. Programming with a single programmer always works.

Might look at the DLL's at some point then.  I might also try compiling the programmer for Linux and see if the issue persists.

Thanks!

0 Kudos

418 Views
pgo
Senior Contributor V

Hi Matthew,

I have uploaded an example CPP program using the new DLLs

usbdm-eclipse-makefiles-build/USBDM_Programmer_API_Example at master · podonoghue/usbdm-eclipse-make...

bye

0 Kudos

418 Views
matthewharper
Contributor III

Thanks I will look at your example in the next few days.

Additional hints

Definitely appears that the problem occurs when we have more than one programmer on a USB bus controller.

Often both units on the same controller become unusable after the failure occurs. (Bringing up the ARM_programmer.exe GUI shows both as

unavailable.

If we reset (as in reset the K20 processor with a clip lead from reset to gnd) the unit that failed, then everything works again.

0 Kudos