Go to Post Who would have thought a triangular robot would fit into a triangular goal :rolleyes: - Wayne Doenges [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
  #1   Spotlight this post!  
Unread 17-02-2015, 22:58
tcjinaz tcjinaz is offline
Tim
FRC #3853
Team Role: Mentor
 
Join Date: May 2011
Rookie Year: 2011
Location: Arizona
Posts: 206
tcjinaz has a spectacular aura abouttcjinaz has a spectacular aura about
Re: Problems with VI after integrating into robot project.

Quote:
Originally Posted by Levansic View Post
Well, we fixed the problem. We made a change to our motion filter sub-vi.

I think the issue is that although we set sensible default values that should have given a sane size for the array at compilation, there was no error checking to catch insane values or sizes that may be undefined or not a number. The array initializer wants an integer input for the size, rather than an unsigned int. For all I know, the value the compiler could have been accounting for may have been a very large negative number.

We coerced the array size to between 1 and 10 elements, which is generous for all of our anticipated use cases. We can always bump up the upper limit if we need a slower ramp rate.

If you are interested, the code is at our git repository, posted above.
Did you make the VI re-entrant? You seem to instantiate it more than once, each instance needs its own, unique memory for the eight feedback nodes:

File->VI properties->Execution->Preallocated Clone Reentrant Execution

Good luck,
Tim
__________________
Software Mentor
3853 Pridetronics[

Reply With Quote
  #2   Spotlight this post!  
Unread 18-02-2015, 04:27
Levansic's Avatar
Levansic Levansic is offline
Registered User
AKA: Len Evansic
FRC #0585 (Cyber Penguins)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2008
Location: Tehachapi, CA
Posts: 185
Levansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud ofLevansic has much to be proud of
Re: Problems with VI after integrating into robot project.

Quote:
Originally Posted by tcjinaz View Post
Did you make the VI re-entrant? You seem to instantiate it more than once, each instance needs its own, unique memory for the eight feedback nodes:
Hi Tim. Yes, we made them re-entrant. That's standard practice for us for sub-vi's, as we tend to make utility functions that can be used in multiple places. The motion filter used here is such a vi, as we are using it in our autonomous to generate acceleration and deceleration for more repeatable robot placement.

This problem was hard to diagnose, because we couldn't get to a running state, except in a non-interactively deployed running of all of our robot code. I think we tried every iteration that we could find on the execution pane of VI preferences, just to try to shake out any clues.
Reply With Quote
  #3   Spotlight this post!  
Unread 18-02-2015, 21:25
tcjinaz tcjinaz is offline
Tim
FRC #3853
Team Role: Mentor
 
Join Date: May 2011
Rookie Year: 2011
Location: Arizona
Posts: 206
tcjinaz has a spectacular aura abouttcjinaz has a spectacular aura about
Re: Problems with VI after integrating into robot project.

Schooled. I didn't finish reading the thread. I had been trying to teach re-entrant lately, and had array initialization problems for a while...

After the season's over question:

Did you really need 4 state bits (well, 5, there's an integer masquerading as a state bit)? I love programming; there are so many answers to a question

Stack'm high,
Tim
__________________
Software Mentor
3853 Pridetronics[

Reply With Quote
Reply


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


All times are GMT -5. The time now is 10:25.

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