|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Urgent help needed... Structs and compiling issues
okay so i make a simple structure like this:
Code:
struct constants
{
int KP;
int KI;
int KD;
int div;
};
struct constants pid[2]={{0,0,0,0},{0,0,0,0}}; this works fine and dandy but when i do this it gives me a linker error: struct constants pid[4]={{0,0,0,0},{0,0,0,0},{0,0,0,0},{0,0,0,0}}; What is going on I CANNOT figure it out! the linker says something like this: idata_pid.o cannot fit the section. Section "idata_pid.o" length = 0x0000010a please help...! i can't figure it out ... this is so simple yet frustrating |
|
#2
|
|||
|
|||
|
Re: Urgent help needed... Structs and compiling issues
It sounds like you are using too much memory.
Try making the variables smaller like a short int or an unsigned char |
|
#3
|
|||
|
|||
|
Re: Urgent help needed... Structs and compiling issues
thats what i thought of as well... but doesn't a char take just as memory as an int ? i will try it though... i don't see why though... i mean watsons struct has 6-7 ints... maybe i have too many we'll see ... thanks
|
|
#4
|
||||
|
||||
|
Re: Urgent help needed... Structs and compiling issues
Quote:
|
|
#5
|
|||||
|
|||||
|
Re: Urgent help needed... Structs and compiling issues
Quote:
[edit]Woah! post #2048! Sweeeet! [/edit]Last edited by Greg Ross : 18-02-2006 at 14:31. |
|
#6
|
|||
|
|||
|
Re: Urgent help needed... Structs and compiling issues
[edit]Woah! post #2048! Sweeeet! [/edit]
anyone that jubilates over having a post count equal to a power of two is a true nerd. 161 posts until i can celebrate ! |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|