Go to Post I would be thankful to just participate in champs, I would be happy with just that. - Brandon_L [more]
Home
Go Back   Chief Delphi > Technical > National Instruments LabVIEW and Data Acquisition
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rating: Thread Rating: 11 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #22   Spotlight this post!  
Unread 25-01-2008, 00:29
Danny Diaz's Avatar
Danny Diaz Danny Diaz is offline
Smooth Operator
AKA: FrankenMentor
None #0418
Team Role: Alumni
 
Join Date: Apr 2005
Rookie Year: 2003
Location: Manchester, NH
Posts: 545
Danny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond reputeDanny Diaz has a reputation beyond repute
Send a message via AIM to Danny Diaz
Re: Labview Video Tutorial? Dashboard

Okay, I'm going to shoot from the hip here since I cannot test it right now - the only thing I can think is happening is that I forgot to put a wait in the while loop. The program runs fine on my dual core laptop, but I haven't checked to see if one cores is pegged out. See, when you create a while loop you're supposed to put some kind of wait or blocking call in it so that the while loop doesn't just spin and eat all the processor (that way the thread running the loop yields for other threads in the system to be able to run). Open the Dashboard Provider VI and you'll see what I mean, the while loops there have a "wait for millisecond multiple" and usually it has 10 wired into it (that means the processing within the loop will be suspended until the next 10 ms multiple). I had thought the "Dashboard Read" VI would take some time to read the datasocket variable (actually I thought it was a blocking call), but I could be incorrect - if this is the case then the thread reading the datasocket variable in your while loop is using a significant amount of the processor and it is starving the serial port read; that's why the overrun is probably happening (you can verify this by watching your CPU utilization while you're running the VI). On a dual core target if you're lucky and the serial read happens to be running on one processor and the datasocket read hogs the second processor, everything will run fine. However, if you're on a single core target then you're in for some serious trouble, which is probably what's happening to you (or you're unlucky and both threads got scheduled on the same processor).

I won't be able to get my hands on the testing platform again until Saturday, so if this is the case I'll update the video then with this new code. Until then, please accept this new VI (attached) and let me know if this solves your problem.

-Danny
Attached Files
File Type: vi SampleDashboard.vi (26.7 KB, 117 views)
__________________
Danny Diaz
Former Lead Technical Mentor, FRC 418

Last edited by Danny Diaz : 25-01-2008 at 00:32.
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Example LabVIEW Apps - Dashboard, CMUcam2 and Motors DanDon LabView and Data Acquisition 3 29-01-2009 22:13
Example LabVIEW Apps - Dashboard, CMUcam2 and Motors Russ Beavis National Instruments LabVIEW and Data Acquisition 9 21-01-2007 17:19
LabView Dashboard Problems brummer_13 LabView and Data Acquisition 11 01-02-2006 20:13
National Instruments LabVIEW and Data Acquisition Forum Danny Diaz National Instruments LabVIEW and Data Acquisition 1 16-01-2006 13:20
Custom Dashboard code for LabVIEW ready for download. archiver 2001 3 24-06-2002 00:49


All times are GMT -5. The time now is 21:57.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi