summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsiddhu89902015-09-15 14:47:02 +0530
committersiddhu89902015-09-15 14:47:02 +0530
commite929ae3e4254caac2d29a832ee75d4ed8ae4a380 (patch)
treebc09b45e76c3b62b8249caf8cf7981f38d4da47e
parentfa48de77a489b8b6e7c5cb335b8dc55721cf2a28 (diff)
downloadScilab2C_fossee_old-e929ae3e4254caac2d29a832ee75d4ed8ae4a380.tar.gz
Scilab2C_fossee_old-e929ae3e4254caac2d29a832ee75d4ed8ae4a380.tar.bz2
Scilab2C_fossee_old-e929ae3e4254caac2d29a832ee75d4ed8ae4a380.zip
Working arduino digital input and output
-rw-r--r--includes/sci2clib.h4
-rw-r--r--macros/CCodeGeneration/.fuse_hidden00001d2200000003bin0 -> 13696 bytes
-rw-r--r--macros/CCodeGeneration/C_FinalizeCode.binbin13696 -> 13696 bytes
-rw-r--r--macros/CCodeGeneration/C_GenerateMakefile.binbin17792 -> 17792 bytes
-rw-r--r--macros/CCodeGeneration/C_InitHeader.binbin13696 -> 13696 bytes
-rw-r--r--macros/CCodeGeneration/C_Type.binbin9600 -> 9600 bytes
-rw-r--r--macros/ToolInitialization/.fuse_hidden00002d5800000006bin407504 -> 0 bytes
-rw-r--r--macros/ToolInitialization/INIT_CreateDirs.binbin9600 -> 9600 bytes
-rw-r--r--macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci10
-rw-r--r--macros/ToolInitialization/INIT_GenAnnFLFunctions.binbin9600 -> 9600 bytes
-rw-r--r--macros/ToolInitialization/INIT_GenFileInfo.binbin13696 -> 13696 bytes
-rw-r--r--macros/ToolInitialization/INIT_GenLibraries.binbin9600 -> 9600 bytes
-rw-r--r--macros/ToolInitialization/INIT_GenSharedInfo.binbin13696 -> 13696 bytes
-rw-r--r--macros/ToolInitialization/INIT_LoadLibraries.binbin9600 -> 9600 bytes
-rw-r--r--macros/ToolInitialization/INIT_RemoveDirs.binbin13696 -> 13696 bytes
-rw-r--r--macros/ToolInitialization/INIT_SCI2C.binbin21152 -> 21152 bytes
-rw-r--r--macros/ToolInitialization/INIT_SharedInfoEqual.binbin9600 -> 9600 bytes
-rw-r--r--macros/ToolInitialization/ManageNextConversion.binbin13696 -> 13696 bytes
-rw-r--r--macros/ToolInitialization/UpdateSCI2CInfo.binbin30256 -> 30256 bytes
-rw-r--r--macros/findDeps/getAllHeaders.binbin13696 -> 13696 bytes
-rw-r--r--macros/findDeps/getAllInterfaces.binbin13696 -> 13696 bytes
-rw-r--r--macros/findDeps/getAllSources.binbin89136 -> 89136 bytes
-rw-r--r--macros/findDeps/getArduinoFiles.binbin0 -> 9600 bytes
-rw-r--r--src/c/operations/interfaces/int_OpLogEq.h9
-rw-r--r--src/c/scilab-arduino/default_files/Makefile4
-rw-r--r--src/c/scilab-arduino/interfaces/int_cmd_digital_out.h5
26 files changed, 30 insertions, 2 deletions
diff --git a/includes/sci2clib.h b/includes/sci2clib.h
index b887ebb..aa6a9cc 100644
--- a/includes/sci2clib.h
+++ b/includes/sci2clib.h
@@ -332,8 +332,12 @@
/*Scilab-arduino toolbox*/
#include "int_cmd_digital_out.h"
#include "cmd_digital_out.h"
+#include "int_cmd_digital_in.h"
+#include "cmd_digital_in.h"
#include "int_cmd_analog_out.h"
#include "cmd_analog_out.h"
+#include "int_cmd_analog_in.h"
+#include "cmd_analog_in.h"
#include "int_sleep.h"
#include "sleep.h"
diff --git a/macros/CCodeGeneration/.fuse_hidden00001d2200000003 b/macros/CCodeGeneration/.fuse_hidden00001d2200000003
new file mode 100644
index 0000000..02f578e
--- /dev/null
+++ b/macros/CCodeGeneration/.fuse_hidden00001d2200000003
Binary files differ
diff --git a/macros/CCodeGeneration/C_FinalizeCode.bin b/macros/CCodeGeneration/C_FinalizeCode.bin
index a2e3e12..133956e 100644
--- a/macros/CCodeGeneration/C_FinalizeCode.bin
+++ b/macros/CCodeGeneration/C_FinalizeCode.bin
Binary files differ
diff --git a/macros/CCodeGeneration/C_GenerateMakefile.bin b/macros/CCodeGeneration/C_GenerateMakefile.bin
index bbb2cea..d4164e6 100644
--- a/macros/CCodeGeneration/C_GenerateMakefile.bin
+++ b/macros/CCodeGeneration/C_GenerateMakefile.bin
Binary files differ
diff --git a/macros/CCodeGeneration/C_InitHeader.bin b/macros/CCodeGeneration/C_InitHeader.bin
index 0147576..0673399 100644
--- a/macros/CCodeGeneration/C_InitHeader.bin
+++ b/macros/CCodeGeneration/C_InitHeader.bin
Binary files differ
diff --git a/macros/CCodeGeneration/C_Type.bin b/macros/CCodeGeneration/C_Type.bin
index 36a9458..424c615 100644
--- a/macros/CCodeGeneration/C_Type.bin
+++ b/macros/CCodeGeneration/C_Type.bin
Binary files differ
diff --git a/macros/ToolInitialization/.fuse_hidden00002d5800000006 b/macros/ToolInitialization/.fuse_hidden00002d5800000006
deleted file mode 100644
index 406f6f5..0000000
--- a/macros/ToolInitialization/.fuse_hidden00002d5800000006
+++ /dev/null
Binary files differ
diff --git a/macros/ToolInitialization/INIT_CreateDirs.bin b/macros/ToolInitialization/INIT_CreateDirs.bin
index 2925a70..e180f6e 100644
--- a/macros/ToolInitialization/INIT_CreateDirs.bin
+++ b/macros/ToolInitialization/INIT_CreateDirs.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci b/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci
index eafc416..792ef65 100644
--- a/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci
+++ b/macros/ToolInitialization/INIT_FillSCI2LibCDirs.sci
@@ -1375,6 +1375,15 @@ PrintStringInfo('z2d2'+ArgSeparator+'d2',ClassFileName,'file','y');
PrintStringInfo('d2z2'+ArgSeparator+'d2',ClassFileName,'file','y');
PrintStringInfo('s2c2'+ArgSeparator+'s2',ClassFileName,'file','y');
+PrintStringInfo('u80d0'+ArgSeparator+'u80',ClassFileName,'file','y');
+PrintStringInfo('i80d0'+ArgSeparator+'i80',ClassFileName,'file','y');
+PrintStringInfo('u160d0'+ArgSeparator+'u160',ClassFileName,'file','y');
+PrintStringInfo('i160d0'+ArgSeparator+'i160',ClassFileName,'file','y');
+
+PrintStringInfo('d0u80'+ArgSeparator+'u80',ClassFileName,'file','y');
+PrintStringInfo('d0i80'+ArgSeparator+'i80',ClassFileName,'file','y');
+PrintStringInfo('d0u160'+ArgSeparator+'u160',ClassFileName,'file','y');
+PrintStringInfo('d0i160'+ArgSeparator+'i160',ClassFileName,'file','y');
// --- Annotation Function And Function List Function. ---
FunctionName = 'OpLogEq'; // BJ : Done AS : Float_Done
@@ -3769,6 +3778,7 @@ PrintStringInfo('OUT(1).SZ(2)= ''1''',ClassFileName,'file','y');
// --- Function List Class. ---
ClassFileName = fullfile(SCI2CLibCFLClsDir,ClassName+ExtensionCFuncListCls);
PrintStringInfo('d0d0d0'+ArgSeparator+'u80',ClassFileName,'file','y');
+PrintStringInfo('d0d0u80'+ArgSeparator+'u80',ClassFileName,'file','y');
// --- Annotation Function And Function List Function. ---
FunctionName = 'cmd_digital_out';
diff --git a/macros/ToolInitialization/INIT_GenAnnFLFunctions.bin b/macros/ToolInitialization/INIT_GenAnnFLFunctions.bin
index 3f8981a..b0cff95 100644
--- a/macros/ToolInitialization/INIT_GenAnnFLFunctions.bin
+++ b/macros/ToolInitialization/INIT_GenAnnFLFunctions.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_GenFileInfo.bin b/macros/ToolInitialization/INIT_GenFileInfo.bin
index 733ab51..e5a9ae2 100644
--- a/macros/ToolInitialization/INIT_GenFileInfo.bin
+++ b/macros/ToolInitialization/INIT_GenFileInfo.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_GenLibraries.bin b/macros/ToolInitialization/INIT_GenLibraries.bin
index a1bf6f5..de7d66e 100644
--- a/macros/ToolInitialization/INIT_GenLibraries.bin
+++ b/macros/ToolInitialization/INIT_GenLibraries.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_GenSharedInfo.bin b/macros/ToolInitialization/INIT_GenSharedInfo.bin
index 9c82bde..28e3e32 100644
--- a/macros/ToolInitialization/INIT_GenSharedInfo.bin
+++ b/macros/ToolInitialization/INIT_GenSharedInfo.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_LoadLibraries.bin b/macros/ToolInitialization/INIT_LoadLibraries.bin
index 35bc6a1..65cd4c0 100644
--- a/macros/ToolInitialization/INIT_LoadLibraries.bin
+++ b/macros/ToolInitialization/INIT_LoadLibraries.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_RemoveDirs.bin b/macros/ToolInitialization/INIT_RemoveDirs.bin
index 5a3cc93..4982a1e 100644
--- a/macros/ToolInitialization/INIT_RemoveDirs.bin
+++ b/macros/ToolInitialization/INIT_RemoveDirs.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_SCI2C.bin b/macros/ToolInitialization/INIT_SCI2C.bin
index 1c2b2d3..b3a3aaa 100644
--- a/macros/ToolInitialization/INIT_SCI2C.bin
+++ b/macros/ToolInitialization/INIT_SCI2C.bin
Binary files differ
diff --git a/macros/ToolInitialization/INIT_SharedInfoEqual.bin b/macros/ToolInitialization/INIT_SharedInfoEqual.bin
index 6737e64..b0f6e77 100644
--- a/macros/ToolInitialization/INIT_SharedInfoEqual.bin
+++ b/macros/ToolInitialization/INIT_SharedInfoEqual.bin
Binary files differ
diff --git a/macros/ToolInitialization/ManageNextConversion.bin b/macros/ToolInitialization/ManageNextConversion.bin
index 03565bd..93114c6 100644
--- a/macros/ToolInitialization/ManageNextConversion.bin
+++ b/macros/ToolInitialization/ManageNextConversion.bin
Binary files differ
diff --git a/macros/ToolInitialization/UpdateSCI2CInfo.bin b/macros/ToolInitialization/UpdateSCI2CInfo.bin
index 2ee6b8d..142bfd7 100644
--- a/macros/ToolInitialization/UpdateSCI2CInfo.bin
+++ b/macros/ToolInitialization/UpdateSCI2CInfo.bin
Binary files differ
diff --git a/macros/findDeps/getAllHeaders.bin b/macros/findDeps/getAllHeaders.bin
index b0355de..3cbeb65 100644
--- a/macros/findDeps/getAllHeaders.bin
+++ b/macros/findDeps/getAllHeaders.bin
Binary files differ
diff --git a/macros/findDeps/getAllInterfaces.bin b/macros/findDeps/getAllInterfaces.bin
index 1a0fedc..c01712f 100644
--- a/macros/findDeps/getAllInterfaces.bin
+++ b/macros/findDeps/getAllInterfaces.bin
Binary files differ
diff --git a/macros/findDeps/getAllSources.bin b/macros/findDeps/getAllSources.bin
index a689472..bf26b3b 100644
--- a/macros/findDeps/getAllSources.bin
+++ b/macros/findDeps/getAllSources.bin
Binary files differ
diff --git a/macros/findDeps/getArduinoFiles.bin b/macros/findDeps/getArduinoFiles.bin
new file mode 100644
index 0000000..f63160e
--- /dev/null
+++ b/macros/findDeps/getArduinoFiles.bin
Binary files differ
diff --git a/src/c/operations/interfaces/int_OpLogEq.h b/src/c/operations/interfaces/int_OpLogEq.h
index 446b11c..b693db6 100644
--- a/src/c/operations/interfaces/int_OpLogEq.h
+++ b/src/c/operations/interfaces/int_OpLogEq.h
@@ -31,6 +31,15 @@
#define c0s0OpLogEqs0(in1,in2) s0c0OpLogEqs0(in2,in1)
#define z0d0OpLogEqd0(in1,in2) d0z0OpLogEqd0(in2,in1)
+#define u80d0OpLogEqu80(in1,in2) (uint8) (in1 == (uint8)in2)
+#define i80d0OpLogEqi80(in1,in2) (int8) (in1 == (int8)in2)
+#define u160d0OpLogEqu160(in1,in2) (uint16) (in1 == (uint16)in2)
+#define i160d0OpLogEqi160(in1,in2) (int16) (in1 == (int16)in2)
+
+#define d0u80OpLogEqu80(in1,in2) (uint8) ((uint8)in1 == in2)
+#define d0i80OpLogEqi80(in1,in2) (int8) ((int8)in1 == in2)
+#define d0u160OpLogEqu160(in1,in2) (uint16) ((uint16)in1 == in2)
+#define d0i160OpLogEqi160(in1,in2) (int16) ((int16)in1 == in2)
#define s2s0OpLogEqs2(in1,size,in2,out) {int i;\
diff --git a/src/c/scilab-arduino/default_files/Makefile b/src/c/scilab-arduino/default_files/Makefile
index 7d74195..2b888f0 100644
--- a/src/c/scilab-arduino/default_files/Makefile
+++ b/src/c/scilab-arduino/default_files/Makefile
@@ -3,8 +3,8 @@
ARDUINO_DIR = /usr/share/arduino
ARDMK_DIR = /usr/share/arduino
AVR_TOOLS_DIR = /usr
-BOARD_TAG = atmega328
+BOARD_TAG = uno
USER_LIB_PATH = ../../
ARDUINO_LIBS = src/c includes interfaces ../Temp
-ARDUINO_PORT = /dev/ttyUSB0
+ARDUINO_PORT = /dev/ttyACM0
include /usr/share/arduino/Arduino.mk
diff --git a/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h b/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h
index a3d1eab..fdc1728 100644
--- a/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h
+++ b/src/c/scilab-arduino/interfaces/int_cmd_digital_out.h
@@ -23,6 +23,11 @@ extern "C" {
#define d0d0d0cmd_digital_outu80(in1,in2,in3) u8cmd_digital_outs((uint8)in1,\
(uint8)in2,(uint8)in3)
+//Required when input from one pin is directed to other output pin.
+#define d0d0u80cmd_digital_outu80(in1,in2,in3) u8cmd_digital_outs((uint8)in1,\
+ (uint8)in2, in3)
+
+
#ifdef __cplusplus
} /* extern "C" */
#endif