Go to Post I got something totally different from my FIRST experience. to me the spirit of FIRST is all about sharing. during the 6 week build period, you share yourself with the other people on your team. at the competition, you share your creation with everyone who watches your 'bot play the game. - George1902 [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 27-10-2010, 18:47
The Zevling's Avatar
The Zevling The Zevling is offline
Modern Major General
AKA: Jonathan Zev
FRC #0599 (Robodox)
Team Role: Scout
 
Join Date: May 2009
Rookie Year: 2008
Location: Granada Hills, CA
Posts: 42
The Zevling is an unknown quantity at this point
Arrays in RobotC

I'm working in robotC for our VEX robots, and I cannot figure out how to pass an array into a function.

When I try to declare the function as:
Code:
int Foo(int array[]);
I get several errors that sum up to mean that the code doesn't like square brackets inside function declarations.

Is there a way to pass arrays into functions, or will I have to find an alternate solution?
__________________
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would've appeared to them to be otherwise." - Alice in Wonderland

"Outside a dog, a book is man's best friend. Inside a dog, it's too dark to read." - Groucho Marx

"A man should live forever, or die trying." - Callahan's Crosstime Saloon

"[a] good bookshop is just a genteel blackhole that knows how to read." - Terry Pratchet
  #2   Spotlight this post!  
Unread 27-10-2010, 21:49
RoboDesigners's Avatar
RoboDesigners RoboDesigners is offline
Registered User
VRC #2190 (RoboDesigners)
Team Role: Leadership
 
Join Date: Jun 2010
Rookie Year: 2006
Location: Virginia
Posts: 361
RoboDesigners will become famous soon enoughRoboDesigners will become famous soon enough
Re: Arrays in RobotC

You might want to look at this thread on the RobotC forums. It seems that you can't pass arrays to functions, but that might have changed...
__________________
Visit my website! www.RoboDesigners.com

VRC Team #2190

Twitter: @RoboDesigners
Closed Thread


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
Sorting 2-D Arrays [Labview] Kahn! NI LabVIEW 4 12-01-2009 21:58
Arrays in Vex Programming Kit EasyC? gblake FIRST Tech Challenge 9 12-09-2006 17:05
Using multidimension arrays? Aalfabob Programming 1 11-01-2005 15:15
Arrays on the PIC? scitobor 617 Programming 8 06-12-2004 09:10
EduCAD and Arrays!!!!! Sachiel7 Programming 14 03-11-2003 03:21


All times are GMT -5. The time now is 23:13.

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