summaryrefslogtreecommitdiff
path: root/2.3-1/src/c/scilab-arduino/cmd_i2c_write
diff options
context:
space:
mode:
authorBrijeshcr2017-07-06 15:48:47 +0530
committerGitHub2017-07-06 15:48:47 +0530
commitc600ebcb67961fe6007ba41fd5ad987da3af7f6e (patch)
tree26fc9679644561759e8a2c4080059d30b70a3105 /2.3-1/src/c/scilab-arduino/cmd_i2c_write
parenta7eeecce4c7c39ea52a2d434815c574a2c42730d (diff)
downloadScilab2C-c600ebcb67961fe6007ba41fd5ad987da3af7f6e.tar.gz
Scilab2C-c600ebcb67961fe6007ba41fd5ad987da3af7f6e.tar.bz2
Scilab2C-c600ebcb67961fe6007ba41fd5ad987da3af7f6e.zip
Revert "LinearAlgebra Function Added"
Diffstat (limited to '2.3-1/src/c/scilab-arduino/cmd_i2c_write')
-rw-r--r--2.3-1/src/c/scilab-arduino/cmd_i2c_write/u8cmd_i2c_writes.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/2.3-1/src/c/scilab-arduino/cmd_i2c_write/u8cmd_i2c_writes.cpp b/2.3-1/src/c/scilab-arduino/cmd_i2c_write/u8cmd_i2c_writes.cpp
new file mode 100644
index 00000000..0239097a
--- /dev/null
+++ b/2.3-1/src/c/scilab-arduino/cmd_i2c_write/u8cmd_i2c_writes.cpp
@@ -0,0 +1,13 @@
+#include "cmd_i2c_write.h"
+#include "Arduino.h"
+#include "Wire.h"
+
+void u8cmd_i2c_writes(uint8 address, uint8 data)
+{
+
+ Wire.beginTransmission(address); //Begins transmission to the device connected to given address
+ Wire.write(data); //sends data to slave device
+ Wire.endTransmission(); //Transmission ends
+
+}
+