Go to Post In my opinion, the right mix of student, mentor, and engineer involvement is when everyone gives it 100%. - Jack Jones [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

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Spotlight this post!  
Unread 12-02-2006, 01:33
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,861
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Problem with idata_user_routines.o?

There are two of these particular kinds of limits that can be at fault in this case.

1) We are restricted to declaring a maximum of 256 bytes of global and static variables within any single .c file. So an array of 256 bytes by itself will actually fit, but the same array plus one byte more, e.g.,
char myarray[256];
char onetoomany;
will cause it to bomb. Easy work arounds include using smaller arrays of course, moving the array to the Program memory if it will never change and th values can all be preset, a la
rom const char myarrary[256]={0,1,2,3,4,...255};
or moving the 256 byte array to a dummy .c file and referencing it locally as an "extern".

2) Each of our routines within a .c file is limited to no more than 120 bytes of local variables, so char myarray[120]; would be it.

e.g., these represent the maximums and not one byte more:
Code:
/************
*  my_routines.c
************/

char myglobal[256];

void myroutine()
{
  char mylocal[120];
...
}
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 12-02-2006 at 09:37.
 


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
The best thing you can do when reporting a problem .. Brandon Martus CD Forum Support 1 08-02-2006 07:46
Need a realistic Statics Problem sanddrag Technical Discussion 10 05-12-2005 15:07
Programming Problem: Extremely Frustrating chantilly_team Programming 19 12-02-2005 23:00
The problem with scouting... archiver 2001 10 23-06-2002 23:49
Major problem with chipphua motors aka Scott White Motors 18 19-03-2002 19:44


All times are GMT -5. The time now is 19:08.

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