summaryrefslogtreecommitdiff
path: root/2.3-1
diff options
context:
space:
mode:
Diffstat (limited to '2.3-1')
-rw-r--r--2.3-1/loader.sce18
-rw-r--r--2.3-1/macros/ASTManagement/%ifthenelse_string.sci27
-rw-r--r--2.3-1/macros/ASTManagement/%operation_string.sci13
-rw-r--r--2.3-1/macros/ASTManagement/AST_HandleEOL.sci8
-rw-r--r--2.3-1/macros/ASTManagement/_ifthenelse_string.sci27
-rw-r--r--2.3-1/macros/ASTManagement/_operation_string.sci13
-rw-r--r--2.3-1/macros/ASTManagement/libbin1780 -> 4861 bytes
-rw-r--r--2.3-1/macros/ASTManagement/names4
-rw-r--r--2.3-1/macros/CCodeGeneration/libbin1020 -> 2449 bytes
-rw-r--r--2.3-1/macros/ErrorMessages/libbin532 -> 379 bytes
-rw-r--r--2.3-1/macros/FunctionAnnotation/libbin2256 -> 7053 bytes
-rw-r--r--2.3-1/macros/FunctionList/libbin600 -> 741 bytes
-rw-r--r--2.3-1/macros/GeneralFunctions/filenamefprintf.sci2
-rw-r--r--2.3-1/macros/GeneralFunctions/libbin1144 -> 2809 bytes
-rw-r--r--2.3-1/macros/Hardware/AVR/libbin984 -> 2265 bytes
-rw-r--r--2.3-1/macros/Hardware/RasberryPi/libbin988 -> 2037 bytes
-rw-r--r--2.3-1/macros/ImageProcessing/core/libbin536 -> 293 bytes
-rw-r--r--2.3-1/macros/ImageProcessing/highgui/libbin596 -> 471 bytes
-rw-r--r--2.3-1/macros/ImageProcessing/imgproc/libbin764 -> 1145 bytes
-rw-r--r--2.3-1/macros/Scilab-Arduino/libbin608 -> 759 bytes
-rw-r--r--2.3-1/macros/SymbolTable/libbin740 -> 1199 bytes
-rw-r--r--2.3-1/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci2
-rw-r--r--2.3-1/macros/ToolInitialization/libbin816 -> 1543 bytes
-rw-r--r--2.3-1/macros/findDeps/libbin608 -> 679 bytes
-rw-r--r--2.3-1/macros/libbin548 -> 649 bytes
-rw-r--r--2.3-1/src/c/CACSD/obscont/dobsconta.c2
-rw-r--r--2.3-1/unloader.sce31
27 files changed, 130 insertions, 17 deletions
diff --git a/2.3-1/loader.sce b/2.3-1/loader.sce
index ddfe6370..061021cb 100644
--- a/2.3-1/loader.sce
+++ b/2.3-1/loader.sce
@@ -1,10 +1,20 @@
// This file is released under the 3-clause BSD license. See COPYING-BSD.
// Generated by builder.sce: Please, do not edit this file
+oldmode = mode(); mode(-1);
+oldlines = lines()(2); lines(0);
try
- getversion("scilab");
+ exec(get_absolute_file_path("loader.sce")+"etc/"+"scilab2c.start");
catch
- error("Scilab 5.0 or more is required.");
-end;
+ [errmsg, tmp, nline, func] = lasterror()
+ msg = "%s: error on line #%d: ""%s""\n"
+ msg = msprintf(msg, func, nline, errmsg)
+ lines(oldlines)
+ mode(oldmode);
+ clear oldlines oldmode tmp nline func
+ error(msg);
+end
+lines(oldlines);
+mode(oldmode);
+clear oldlines oldmode;
-exec(get_absolute_file_path("loader.sce")+"etc\"+"scilab2c.start");
diff --git a/2.3-1/macros/ASTManagement/%ifthenelse_string.sci b/2.3-1/macros/ASTManagement/%ifthenelse_string.sci
new file mode 100644
index 00000000..ef588c56
--- /dev/null
+++ b/2.3-1/macros/ASTManagement/%ifthenelse_string.sci
@@ -0,0 +1,27 @@
+function txt=%ifthenelse_string(I)
+//overloading function for "ifthenel" type tlist string function
+//this is a node of the AST
+//fields:
+// expression : "expression" type tlist (the if expression)
+// then : list of "equal" type tlist and list('EOL') (the
+// then instructions list)
+// elseifs : a list of tlists
+// else : list of "equal" type tlist and list('EOL') (the
+// else instructions list)
+ txt=['If '
+ ' Expression:'
+ ' '+string(I.expression)
+ ' If Statements'
+ ' '+objectlist2string(I.then)]
+ for e=I.elseifs
+ txt=[txt;
+ ' Else If Expression'
+ ' '+string(e.expression)
+ ' Else If Statements'
+ ' '+objectlist2string(e.then)]
+ end
+ txt=[txt;
+ ' Else Statements'
+ ' '+objectlist2string(I.else)
+ 'EndIf']
+endfunction
diff --git a/2.3-1/macros/ASTManagement/%operation_string.sci b/2.3-1/macros/ASTManagement/%operation_string.sci
new file mode 100644
index 00000000..84f5ce3c
--- /dev/null
+++ b/2.3-1/macros/ASTManagement/%operation_string.sci
@@ -0,0 +1,13 @@
+function txt=%operation_string(O)
+//overloading function for "operation" type tlist string function
+//this is a node of the AST
+//fields:
+// operands: a list
+// operator: a string
+ txt=['Operation'
+ ' Operands:'
+ ' '+objectlist2string(O.operands)
+ ' Operator: '+O.operator
+ 'EndOperation'
+ ]
+endfunction \ No newline at end of file
diff --git a/2.3-1/macros/ASTManagement/AST_HandleEOL.sci b/2.3-1/macros/ASTManagement/AST_HandleEOL.sci
index 0f55457e..4b287283 100644
--- a/2.3-1/macros/ASTManagement/AST_HandleEOL.sci
+++ b/2.3-1/macros/ASTManagement/AST_HandleEOL.sci
@@ -46,15 +46,17 @@ sciline = mgetl(SciFileFid,1);
PrintStringInfo(' ',ReportFileName,'file','y','n');
PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
-PrintStringInfo('### Scilab code: '+sciline+' ###',ReportFileName,'file','y','n');
+//PrintStringInfo('### Scilab code: '+sciline+' ###',ReportFileName,'file','y','n');
PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
PrintStringInfo('##################'+'################'+'##################'+'##################'+'##################',ReportFileName,'file','y','n');
// #RNU_RES_E
PrintStringInfo(' ',CPass1FileName,'file','y');
// RNU BRUNO modeprintstringinfo MUST BE AN EXTERNAL PARAMETER!
-modeprintstringinfo = 'both';
+//modeprintstringinfo = 'both';
if (SharedInfo.CopySciCodeIntoCCode == 1)
- modeprintstringinfo = 'both';
+ modeprintstringinfo = 'file';
+else
+ modeprintstringinfo = 'stdout';
end
PrintStringInfo(C_IndentBlanks(IndentLevel)+'/*SCI2C: #############'+'############'+'##############'+'###############'+'############',CPass1FileName,modeprintstringinfo,'y','n');
PrintStringInfo(C_IndentBlanks(IndentLevel)+' SCI2C: '+sciline,CPass1FileName,modeprintstringinfo,'y','n');
diff --git a/2.3-1/macros/ASTManagement/_ifthenelse_string.sci b/2.3-1/macros/ASTManagement/_ifthenelse_string.sci
new file mode 100644
index 00000000..ef588c56
--- /dev/null
+++ b/2.3-1/macros/ASTManagement/_ifthenelse_string.sci
@@ -0,0 +1,27 @@
+function txt=%ifthenelse_string(I)
+//overloading function for "ifthenel" type tlist string function
+//this is a node of the AST
+//fields:
+// expression : "expression" type tlist (the if expression)
+// then : list of "equal" type tlist and list('EOL') (the
+// then instructions list)
+// elseifs : a list of tlists
+// else : list of "equal" type tlist and list('EOL') (the
+// else instructions list)
+ txt=['If '
+ ' Expression:'
+ ' '+string(I.expression)
+ ' If Statements'
+ ' '+objectlist2string(I.then)]
+ for e=I.elseifs
+ txt=[txt;
+ ' Else If Expression'
+ ' '+string(e.expression)
+ ' Else If Statements'
+ ' '+objectlist2string(e.then)]
+ end
+ txt=[txt;
+ ' Else Statements'
+ ' '+objectlist2string(I.else)
+ 'EndIf']
+endfunction
diff --git a/2.3-1/macros/ASTManagement/_operation_string.sci b/2.3-1/macros/ASTManagement/_operation_string.sci
new file mode 100644
index 00000000..84f5ce3c
--- /dev/null
+++ b/2.3-1/macros/ASTManagement/_operation_string.sci
@@ -0,0 +1,13 @@
+function txt=%operation_string(O)
+//overloading function for "operation" type tlist string function
+//this is a node of the AST
+//fields:
+// operands: a list
+// operator: a string
+ txt=['Operation'
+ ' Operands:'
+ ' '+objectlist2string(O.operands)
+ ' Operator: '+O.operator
+ 'EndOperation'
+ ]
+endfunction \ No newline at end of file
diff --git a/2.3-1/macros/ASTManagement/lib b/2.3-1/macros/ASTManagement/lib
index ae21cfc5..67ea09be 100644
--- a/2.3-1/macros/ASTManagement/lib
+++ b/2.3-1/macros/ASTManagement/lib
Binary files differ
diff --git a/2.3-1/macros/ASTManagement/names b/2.3-1/macros/ASTManagement/names
index 43522229..a1aafbc1 100644
--- a/2.3-1/macros/ASTManagement/names
+++ b/2.3-1/macros/ASTManagement/names
@@ -4,7 +4,9 @@
%for_string
%funcall_string
%ifthenel_string
+%ifthenelse_string
%operatio_string
+%operation_string
%program_p
%program_string
%variable_string
@@ -47,7 +49,9 @@ _equal_string
_for_string
_funcall_string
_ifthenel_string
+_ifthenelse_string
_operatio_string
+_operation_string
_program_p
_program_string
_variable_string
diff --git a/2.3-1/macros/CCodeGeneration/lib b/2.3-1/macros/CCodeGeneration/lib
index ef0ea492..2db4b8c8 100644
--- a/2.3-1/macros/CCodeGeneration/lib
+++ b/2.3-1/macros/CCodeGeneration/lib
Binary files differ
diff --git a/2.3-1/macros/ErrorMessages/lib b/2.3-1/macros/ErrorMessages/lib
index 5b1667c2..0a9f8913 100644
--- a/2.3-1/macros/ErrorMessages/lib
+++ b/2.3-1/macros/ErrorMessages/lib
Binary files differ
diff --git a/2.3-1/macros/FunctionAnnotation/lib b/2.3-1/macros/FunctionAnnotation/lib
index d9cc4762..f02997b0 100644
--- a/2.3-1/macros/FunctionAnnotation/lib
+++ b/2.3-1/macros/FunctionAnnotation/lib
Binary files differ
diff --git a/2.3-1/macros/FunctionList/lib b/2.3-1/macros/FunctionList/lib
index fc8038c9..2bbf0cbe 100644
--- a/2.3-1/macros/FunctionList/lib
+++ b/2.3-1/macros/FunctionList/lib
Binary files differ
diff --git a/2.3-1/macros/GeneralFunctions/filenamefprintf.sci b/2.3-1/macros/GeneralFunctions/filenamefprintf.sci
index 99ddcea4..f25e603e 100644
--- a/2.3-1/macros/GeneralFunctions/filenamefprintf.sci
+++ b/2.3-1/macros/GeneralFunctions/filenamefprintf.sci
@@ -23,7 +23,7 @@ function filenamefprintf(filename,ennewline,str,formattedstring)
// Copyright 2006 Raffaele Nutricato.
// Contact: raffaele.nutricato@tiscali.it
// -----------------------------------------------------------------
-
+
// ------------------------------
// --- Check input arguments. ---
// ------------------------------
diff --git a/2.3-1/macros/GeneralFunctions/lib b/2.3-1/macros/GeneralFunctions/lib
index 1c78f72c..e1d6f0fb 100644
--- a/2.3-1/macros/GeneralFunctions/lib
+++ b/2.3-1/macros/GeneralFunctions/lib
Binary files differ
diff --git a/2.3-1/macros/Hardware/AVR/lib b/2.3-1/macros/Hardware/AVR/lib
index 16d9e3ea..5c8f0da2 100644
--- a/2.3-1/macros/Hardware/AVR/lib
+++ b/2.3-1/macros/Hardware/AVR/lib
Binary files differ
diff --git a/2.3-1/macros/Hardware/RasberryPi/lib b/2.3-1/macros/Hardware/RasberryPi/lib
index b92a6ea7..9afd77da 100644
--- a/2.3-1/macros/Hardware/RasberryPi/lib
+++ b/2.3-1/macros/Hardware/RasberryPi/lib
Binary files differ
diff --git a/2.3-1/macros/ImageProcessing/core/lib b/2.3-1/macros/ImageProcessing/core/lib
index 87c0f305..56053510 100644
--- a/2.3-1/macros/ImageProcessing/core/lib
+++ b/2.3-1/macros/ImageProcessing/core/lib
Binary files differ
diff --git a/2.3-1/macros/ImageProcessing/highgui/lib b/2.3-1/macros/ImageProcessing/highgui/lib
index 8f5561e0..a46d5d87 100644
--- a/2.3-1/macros/ImageProcessing/highgui/lib
+++ b/2.3-1/macros/ImageProcessing/highgui/lib
Binary files differ
diff --git a/2.3-1/macros/ImageProcessing/imgproc/lib b/2.3-1/macros/ImageProcessing/imgproc/lib
index c8b45d34..4863059b 100644
--- a/2.3-1/macros/ImageProcessing/imgproc/lib
+++ b/2.3-1/macros/ImageProcessing/imgproc/lib
Binary files differ
diff --git a/2.3-1/macros/Scilab-Arduino/lib b/2.3-1/macros/Scilab-Arduino/lib
index da395a36..0304cade 100644
--- a/2.3-1/macros/Scilab-Arduino/lib
+++ b/2.3-1/macros/Scilab-Arduino/lib
Binary files differ
diff --git a/2.3-1/macros/SymbolTable/lib b/2.3-1/macros/SymbolTable/lib
index f10d8ee9..dbc603e2 100644
--- a/2.3-1/macros/SymbolTable/lib
+++ b/2.3-1/macros/SymbolTable/lib
Binary files differ
diff --git a/2.3-1/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci b/2.3-1/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci
index 8c5aee70..f0a83604 100644
--- a/2.3-1/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci
+++ b/2.3-1/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci
@@ -5189,7 +5189,7 @@ ClassName = 'RPI_DigitalSetup';
PrintStringInfo(' Adding Class: '+ClassName+'.',GeneralReport,'file','y');
ClassFileName = fullfile(SCI2CLibCAnnClsDir,ClassName+ExtensionCAnnCls);
PrintStringInfo('NIN= 2',ClassFileName,'file','y');
-PrintStringInfo('NOUT= 1 ',ClassFileName,'file','y');
+PrintStringInfo('NOUT= 0 ',ClassFileName,'file','y');
PrintStringInfo('OUT(1).TP= ''u8''',ClassFileName,'file','y');
PrintStringInfo('OUT(1).SZ(1)= ''1''',ClassFileName,'file','y');
PrintStringInfo('OUT(1).SZ(2)= ''1''',ClassFileName,'file','y');
diff --git a/2.3-1/macros/ToolInitialization/lib b/2.3-1/macros/ToolInitialization/lib
index 439f3abf..4d03bdc5 100644
--- a/2.3-1/macros/ToolInitialization/lib
+++ b/2.3-1/macros/ToolInitialization/lib
Binary files differ
diff --git a/2.3-1/macros/findDeps/lib b/2.3-1/macros/findDeps/lib
index 25edeed7..a49dc793 100644
--- a/2.3-1/macros/findDeps/lib
+++ b/2.3-1/macros/findDeps/lib
Binary files differ
diff --git a/2.3-1/macros/lib b/2.3-1/macros/lib
index fcbd1b8d..d818e184 100644
--- a/2.3-1/macros/lib
+++ b/2.3-1/macros/lib
Binary files differ
diff --git a/2.3-1/src/c/CACSD/obscont/dobsconta.c b/2.3-1/src/c/CACSD/obscont/dobsconta.c
index 88837692..c67b70e2 100644
--- a/2.3-1/src/c/CACSD/obscont/dobsconta.c
+++ b/2.3-1/src/c/CACSD/obscont/dobsconta.c
@@ -85,7 +85,7 @@ void dobsconta(double* sys, int sys_rows, int sys_cols, double* Kc, double* Kf,
}
}
- (int)dom = sys[(sys_rows*(sys_cols-2)) + no_of_states];
+ dom = (int)sys[(sys_rows*(sys_cols-2)) + no_of_states];
dmulma(B,no_of_states,no_of_inputs,Kc,no_of_inputs,no_of_states,BKc);
dmulma(Kf,no_of_states,no_of_outputs,C,no_of_outputs,no_of_states,KfC);
diff --git a/2.3-1/unloader.sce b/2.3-1/unloader.sce
index e0e3d5bc..e4ec09c7 100644
--- a/2.3-1/unloader.sce
+++ b/2.3-1/unloader.sce
@@ -1,14 +1,31 @@
// This file is released under the 3-clause BSD license. See COPYING-BSD.
// Generated by builder.sce: Please, do not edit this file
+oldmode = mode(); mode(-1);
+oldlines = lines()(2); lines(0);
try
- getversion("scilab");
+ // Unregister the library of macros. This does not unregister its macros
+ clear scilab2clib
+ // Del help chapter
+ if or(getscilabmode() == ["NW";"STD"]) then
+ mprintf("\tRemove help chapter\n");
+ del_help_chapter("scilab2c", %F);
+ end
+ // Remove Preferences GUI
+ if getscilabmode() == "STD" then
+ removeModulePreferences(get_absolute_file_path("unloader.sce"))
+ end
+ // TODO: detect and unlink related gateways
catch
- error("Scilab 5.4 or more is required.");
-end;
-
-fileQuit = get_absolute_file_path("unloader.sce") + "etc\" + "scilab2c.quit";
-if isfile(fileQuit) then
- exec(fileQuit);
+ [errmsg, tmp, nline, func] = lasterror()
+ msg = "%s: error on line #%d: ""%s""\n"
+ msg = msprintf(msg, func, nline, errmsg)
+ lines(oldlines)
+ mode(oldmode);
+ clear oldlines oldmode tmp nline func
+ error(msg);
end
+lines(oldlines);
+mode(oldmode);
+clear oldlines oldmode;