LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to flashload multiple devices at the same time...Labwindows CVI/TestStand

I am working on an application that will (hopefully)enable me to flashload code into multiple devices (8-10) at the same time through rs-232 comm ports. (Using Teststand) I would like to be able to start flashloading one device while another device is currently being flashloaded. This way, when one device is finished flashloading, I will be able to hook up another device and start the flashloading process while other devices are currently being flashloaded. So multiple devices will be flashloading, each at different points in the flashload sequence. I was wondering what would be the best way to accomplish this. My first thought was to use the multithreading capabilities of TestStand and have
each thread use the same dll. But I have run into resource sharing problems (i.e. two threads are trying to access the same dynamically created array(s)). Is there any relatively easy way to have 10 "tests" running simultaneously using the same dll that will eliminate resource sharing problems such as this??? I'm sure there has to be a better way to do this.

Thanks,

Jerry
0 Kudos
Message 1 of 3
(3,257 Views)
Just make sure your app is multithreaded safe (remove the conflists that
you mention of resource sharing) and that's it.


vishi

Dont Know wrote:
> I am working on an application that will (hopefully)enable me to
> flashload code into multiple devices (8-10) at the same time through
> rs-232 comm ports. (Using Teststand) I would like to be able to start
> flashloading one device while another device is currently being
> flashloaded. This way, when one device is finished flashloading, I
> will be able to hook up another device and start the flashloading
> process while other devices are currently being flashloaded. So
> multiple devices will be flashloading, each at different points in the
> flashload sequence. I was wondering what would be the best way to
> ac
complish this. My first thought was to use the multithreading
> capabilities of TestStand and have each thread use the same dll. But
> I have run into resource sharing problems (i.e. two threads are trying
> to access the same dynamically created array(s)). Is there any
> relatively easy way to have 10 "tests" running simultaneously using
> the same dll that will eliminate resource sharing problems such as
> this??? I'm sure there has to be a better way to do this.
>
> Thanks,
>
> Jerry
0 Kudos
Message 2 of 3
(3,257 Views)
Jerry,

Another idea here is to implement the multiple threads in the CVI dll and let TestStand make just 1 call to this dll.

In CVI you can use a bunch of tools to keep your data thread safe and be able to load all your devices at the same time, there is a good application note that is shiped with CVI that covers this. you can find it Help>>LabWindows/CVI, it is called Bookshelf Building Multithreading Applications with
LabWindows/CVI


I hope this helps.

Regards,

Juan Carlos
N.I.
0 Kudos
Message 3 of 3
(3,257 Views)