Test PCF8574 chips with leds

Dependencies:   mbed PCF8574

Revision:
0:759957225002
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Mon Jul 22 01:29:04 2019 +0000
@@ -0,0 +1,24 @@
+#include "mbed.h"
+#include "pcf8574.h"
+
+
+
+I2C _i2c(D14, D15);// (sda,scl)
+
+
+int main()
+{
+ //Inicializamos 
+ PCF8574 pcf(&_i2c,0x00,PCF8574_TYPE);
+ unsigned char dato;
+ dato = 0x01;
+ while(1)
+ {
+    pcf.WriteByte(dato);
+    wait(0.5);
+    if (dato == 0x80) dato = 0x01;
+    dato = (dato << 1);
+       
+ }   
+    
+}    
\ No newline at end of file