* avr uses a reduced buffer and file name length in textrecs and filerecs

* fixed file and text sizes for avr

git-svn-id: trunk@22147 -
This commit is contained in:
florian 2012-08-20 20:11:13 +00:00
parent 74d3c8cc57
commit 04034b6771
3 changed files with 13 additions and 4 deletions

View File

@ -2466,15 +2466,15 @@ implementation
savesize:=332; savesize:=332;
end; end;
{$endif cpu32bitaddr} {$endif cpu32bitaddr}
{$ifdef cpu8bitaddr} {$ifdef cpu16bitaddr}
case filetyp of case filetyp of
ft_text : ft_text :
savesize:=127; savesize:=96;
ft_typed, ft_typed,
ft_untyped : ft_untyped :
savesize:=127; savesize:=76;
end; end;
{$endif cpu8bitaddr} {$endif cpu16bitaddr}
end; end;

View File

@ -21,7 +21,11 @@
} }
const const
{$ifdef CPUAVR}
filerecnamelength = 15;
{$else CPUAVR}
filerecnamelength = 255; filerecnamelength = 255;
{$endif CPUAVR}
type type
{ using packed makes the compiler to generate ugly code on some CPUs, further { using packed makes the compiler to generate ugly code on some CPUs, further
using packed causes the compiler to handle arrays of text wrongly, see see tw0754 e.g. on arm } using packed causes the compiler to handle arrays of text wrongly, see see tw0754 e.g. on arm }

View File

@ -20,8 +20,13 @@
} }
const const
{$ifdef CPUAVR}
TextRecNameLength = 16;
TextRecBufSize = 16;
{$else CPUAVR}
TextRecNameLength = 256; TextRecNameLength = 256;
TextRecBufSize = 256; TextRecBufSize = 256;
{$endif CPUAVR}
type type
TLineEndStr = string [3]; TLineEndStr = string [3];
TextBuf = array[0..TextRecBufSize-1] of char; TextBuf = array[0..TextRecBufSize-1] of char;