![](templates/subSilver/images/CCSLogo.jpg) |
![CCS C Software and Maintenance Offers](templates/subSilver/images/forumAd6.jpg) |
View previous topic :: View next topic |
Author |
Message |
MarkP Guest
|
18F252, char[20][16], char[20][80] |
Posted: Thu Mar 27, 2003 11:35 am |
|
|
I'd like to have some arrays of strings - ie a 2D char array. I get impression this can't be done, anybody know a nice way to get around this?
Cheers,
Mark
___________________________
This message was ported from CCS's old forum
Original Post ID: 13151 |
|
![](templates/subSilver/images/spacer.gif) |
Tomi Guest
|
Re: 18F252, char[20][16], char[20][80] |
Posted: Thu Mar 27, 2003 12:25 pm |
|
|
What version?
3.148 does it fine, e.g.:
char mystrings[20][16];
......
mystrings[MainMenu][SubMenu] = lastKey;
:=I'd like to have some arrays of strings - ie a 2D char array. I get impression this can't be done, anybody know a nice way to get around this?
:=
:=Cheers,
:=Mark
___________________________
This message was ported from CCS's old forum
Original Post ID: 13153 |
|
![](templates/subSilver/images/spacer.gif) |
MarkP Guest
|
Re: 18F252, char[20][16], char[20][80] |
Posted: Mon Apr 07, 2003 12:48 pm |
|
|
<font face="Courier New" size=-1>:=What version?
I ran ccsc.exe +V and it gave me a file not found error :-S I transplanted the install from another machine that had died, so I guess there's an install problem there or a conflict with the PCM that was prevoiusly installed on it - though it works fine otheriwse!
:=3.148 does it fine, e.g.:
:=char mystrings[20][16];
:=......
:=mystrings[MainMenu][SubMenu] = lastKey;
:=
That's annoying, I do:
char units_array[20][17];
char data_array[20][80];
and I get a subscript out of range error.
Thanks for your help</font>
___________________________
This message was ported from CCS's old forum
Original Post ID: 13469 |
|
![](templates/subSilver/images/spacer.gif) |
Tomi Guest
|
Re: 18F252, char[20][16], char[20][80] |
Posted: Wed Apr 09, 2003 4:58 am |
|
|
:=char units_array[20][17];
:=char data_array[20][80];
:=
:=and I get a subscript out of range error.
20 * 80 = 1600 bytes. Check 18F252 datasheet for RAM size
___________________________
This message was ported from CCS's old forum
Original Post ID: 13530 |
|
![](templates/subSilver/images/spacer.gif) |
MarkP Guest
|
Re: 18F252, char[20][16], char[20][80] |
Posted: Mon Apr 14, 2003 8:00 am |
|
|
:=:=char units_array[20][17];
:=:=char data_array[20][80];
:=:=
:=:=and I get a subscript out of range error.
:=
:=20 * 80 = 1600 bytes. Check 18F252 datasheet for RAM size <img src="http://www.ccsinfo.com/pix/forum/smile.gif" border="0">
Damn, 1536. So close ;) That'll teach me to get complacent.
Thanks anyway.
___________________________
This message was ported from CCS's old forum
Original Post ID: 13655 |
|
![](templates/subSilver/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|