summaryrefslogtreecommitdiff
path: root/macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci
diff options
context:
space:
mode:
authorimushir2016-02-09 16:38:27 +0530
committerimushir2016-02-09 16:38:27 +0530
commitee5bf4d90f78673d1e4d5a9dd304ee53c503c085 (patch)
tree696221a8f8a3dffeb50d12ea287dfbdfab919fc6 /macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci
parent8ee41aca4183a0239b9cb220de3f159b1f0910fb (diff)
downloadScilab2C_fossee_old-ee5bf4d90f78673d1e4d5a9dd304ee53c503c085.tar.gz
Scilab2C_fossee_old-ee5bf4d90f78673d1e4d5a9dd304ee53c503c085.tar.bz2
Scilab2C_fossee_old-ee5bf4d90f78673d1e4d5a9dd304ee53c503c085.zip
Support for Servo motor for Arduino. Support for'diag' in c
Diffstat (limited to 'macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci')
-rw-r--r--macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci28
1 files changed, 28 insertions, 0 deletions
diff --git a/macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci b/macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci
new file mode 100644
index 0000000..df129f9
--- /dev/null
+++ b/macros/FunctionAnnotation/FA_SZ_COLUMN_DIAG.sci
@@ -0,0 +1,28 @@
+function outsize = FA_SZ_COLUMN_DIAG(insize)
+ // function outsize = FA_SZ_1(insize)
+ // -----------------------------------------------------------------
+ // Returns the first element of the size array.
+ //
+ // Input data:
+ // insize: size of input argument. It is an array of 2 strings.
+ // The first string specifies the number of rows.
+ // The second string specifies the number of columns.
+ //
+ // Output data:
+ // outsize: first element of the insize array.
+ //
+ // Status:
+ // 08-Dec-2007 -- Raffaele Nutricato: Author.
+ // 08-Dec-2007 -- Alberto Morea: Test Ok.
+ // -----------------------------------------------------------------
+
+ if(insize(2)=='1') then
+ outsize = insize(1);
+
+ elseif(insize(1) == insize(2))
+ outsize = '1';
+ else
+ outsize = insize(2);
+
+ end
+endfunction