Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 8,332
» Latest member: Denzongeisure
» Forum threads: 3,636
» Forum posts: 18,784

Full Statistics

Online Users
There are currently 26 online users.
» 0 Member(s) | 15 Guest(s)
AhrefsBot, Amazonbot, Google, PetalBot, bot

Latest Threads
N20 Problem with Home Ass...
Forum: N20
Last Post: Luismical1
41 minutes ago
» Replies: 6
» Views: 32
OUTPUT DO1
Forum: KC868-AIO
Last Post: Lupi84
4 hours ago
» Replies: 8
» Views: 61
sample code to receive ht...
Forum: F16
Last Post: admin
7 hours ago
» Replies: 10
» Views: 42
Goes Offline
Forum: KC868-E16S/E16P
Last Post: admin
Yesterday, 06:45 PM
» Replies: 1
» Views: 14
Loxone RS485
Forum: KinCony integrate with Loxone home automation
Last Post: admin
Yesterday, 01:36 PM
» Replies: 11
» Views: 1,165
adaptor V2 and KC868 h32b...
Forum: KC868-ATC / Tuya adapter V2
Last Post: admin
Yesterday, 08:25 AM
» Replies: 3
» Views: 52
Problems and general Feed...
Forum: N30
Last Post: admin
12-28-2025, 11:58 PM
» Replies: 1
» Views: 18
Voltage for KC868-16
Forum: KC868-A16
Last Post: admin
12-28-2025, 11:54 PM
» Replies: 1
» Views: 11
16-Channel Lighting Contr...
Forum: News
Last Post: admin
12-28-2025, 10:52 AM
» Replies: 1
» Views: 16
N30 Energy entry not work...
Forum: N30
Last Post: Vega
12-27-2025, 01:15 PM
» Replies: 13
» Views: 138

  KC868 H32B in home assistant
Posted by: ahmedwizza - 05-17-2022, 12:49 AM - Forum: KC868-HxB series Smart Controller - Replies (4)

hello engineer could you please help my in home assistant

when i add KC868 H32B to home assistant .needed to make one switch control all On and Off like attached photos.



Attached Files Thumbnail(s)
       
Print this item

Thumbs Up [Arduino IDE of KC868-E16S]--#00-KC868-E16S-configure for ESPhome
Posted by: admin - 05-17-2022, 12:45 AM - Forum: KC868-E16S/E16P - Replies (13)

esphome:
  name: kc868-e16s
  platform: ESP32
  board: esp32dev
 
 
# Example configuration entry for ESP32
i2c:
  sda: 16
  scl: 15
  scan: true
  id: bus_a


# Example configuration entry
ethernet:
  type: LAN8720
  mdc_pin: GPIO23
  mdio_pin: GPIO18
  clk_mode: GPIO17_OUT
  phy_addr: 0

  # Optional manual IP
#  manual_ip:
#    static_ip: 192.168.1.199
#    gateway: 192.168.1.1
#    subnet: 255.255.255.0 


# Example configuration entry
pcf8574:
  - id: 'pcf8574_hub_out_1'  # for output channel 1-8
    address: 0x21

  - id: 'pcf8574_hub_out_2'  # for output channel 9-16
    address: 0x25

  - id: 'pcf8574_hub_in_1'  # for input channel 1-8
    address: 0x22

  - id: 'pcf8574_hub_in_2'  # for input channel 9-16
    address: 0x24

# Individual outputs
switch:
  - platform: gpio
    name: "e16s-output1"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 0
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "e16s-output2"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 1
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output3"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 2
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output4"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 3
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output5"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 4
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output6"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 5
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "e16s-output7"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 6
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output8"
    pin:
      pcf8574: pcf8574_hub_out_1
      number: 7
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output9"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 0
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "e16s-output10"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 1
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "e16s-output11"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 2
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output12"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 3
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output13"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 4
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output14"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 5
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output15"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 6
      mode: OUTPUT
      inverted: true
     
  - platform: gpio
    name: "e16s-output16"
    pin:
      pcf8574: pcf8574_hub_out_2
      number: 7
      mode: OUTPUT
      inverted: true
     
binary_sensor:
  - platform: gpio
    name: "e16s-input1"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 0
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input2"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 1
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input3"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 2
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input4"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 3
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input5"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 4
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input6"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 5
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input7"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 6
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input8"
    pin:
      pcf8574: pcf8574_hub_in_1
      number: 7
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input9"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 0
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input10"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 1
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input11"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 2
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input12"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 3
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input13"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 4
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input14"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 5
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input15"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 6
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "e16s-input16"
    pin:
      pcf8574: pcf8574_hub_in_2
      number: 7
      mode: INPUT
      inverted: true

# Enable logging
logger:

# Enable Home Assistant API
api:

   

Print this item

  KC868-E16S ESP32 I/O pin define
Posted by: admin - 05-17-2022, 12:44 AM - Forum: KC868-E16S/E16P - Replies (4)

ANALOG_A1  GPIO36
ANALOG_A2  GPIO35
ANALOG_A3  GPIO34
ANALOG_A4  GPIO39

IIC SDA:GPIO16
IIC SCL:GPIO15

PCF8574:U27 (relay1-8): 100 001 = 0x21
PCF8574:U28 (relay9-16): 100 101 = 0x25

PCF8574:U23 (DI1-8): 100 010 = 0x22
PCF8574:U24 (DI9-16): 100 100 = 0x24

RF433MHz wireless receiver: GPIO4

BEEP:GPIO2

Ethernet (LAN8720) I/O define:

#define ETH_ADDR        0
#define ETH_POWER_PIN  -1
#define ETH_MDC_PIN    23
#define ETH_MDIO_PIN  18
#define ETH_TYPE      ETH_PHY_LAN8720
#define ETH_CLK_MODE  ETH_CLOCK_GPIO17_OUT

--------------------
RS485:
RXD:GPIO13
TXD:GPIO32

Extend serial port (3.3v TTL level):
RXD:GPIO14
TXD:GPIO33

Print this item

  inputs and outputs
Posted by: Amaral989 - 05-16-2022, 12:43 AM - Forum: KC868-Server Raspberry Pi4 local server - Replies (5)

Hello, 
Finally received my KC868 server and so far its has been great setting it up. 
I am planning on putting this in my RV (camper van) .  i do have a question concerning inputs and outputs. In the camper van there are a few on/off switches for lights. There is some other switches that are momentary switches. Is there a way to change the programming to latch the relay . For example, if i press the momentary button, it should close the relay. Press the button again, release the relay. 

Thank you, 
John

Print this item

  KC868-UAIR screws for case
Posted by: dmshimself - 05-15-2022, 11:39 AM - Forum: KC868-Uair - Replies (10)

I will be swapping the board in a KC868-UAIR case over at some point because the original board didn't work.  I see there are 2 small screws securing the board into the bottom of the case but I'm not able to see what size and head the screws are because they are in quite a deep well.  I've zoomed in with my iphone and got good lighting in place, but the screws are so tiny, I'm not able to make out what type of screw driver to use.  I don't want to strip the heads taking them out, so does anyone know what screws these are?  There is a video of someone assembling the case, but it doesn't explain this.

Print this item

  KC868-UAIR inside case - how does IR receiver see signals?
Posted by: dmshimself - 05-13-2022, 11:07 PM - Forum: KC868-Uair - Replies (2)

I'm hoping my KC868-UAIR works with all its devices and in preparation for that I've looked at the tower case the board goes into.  The IR receiver is to the left of the 2 USB sockets on the board, but the case has no clear window for IR signals to go through and reach the board itself.  Also I've noticed that the 4 IR transmitters on the board are placed close to the clearish plastic ring that runs round the outside of the case, but if the LED lights on the KC868-UAIR are on, will signals being able to get out of the tower case to reach my devices?

Has anyone used this device and is prepared to comment on the way the case works to let IR light in and allow IR light out when the lights of the KC868-UAIR are on?

Print this item

Bug [Arduino IDE demo source code for KC868-A64]--#05-PCF8575_Input_code
Posted by: KinCony Support - 05-13-2022, 05:51 AM - Forum: KC868-A64 - Replies (9)

[Arduino IDE demo source code for KC868-A64]--#05-PCF8575_Input_code
   

Code:
/*www.kinocny.com */
/*KC868-A64 CODE OF PCF8575 READ INPUT*/

#include "Arduino.h"
#include "PCF8575.h"

// Set i2c address
PCF8575 pcf8575_IN1(0x24,15,4);
PCF8575 pcf8575_IN2(0x25,15,4);
PCF8575 pcf8575_IN3(0x21,15,4);
PCF8575 pcf8575_IN4(0x22,15,4);

void setup()
{
    Serial.begin(115200);
  pcf8575_IN1.begin();
  pcf8575_IN2.begin();
  pcf8575_IN3.begin();
  pcf8575_IN4.begin();
for(int i=0;i<16;i++)
{
  pcf8575_IN1.pinMode(i,INPUT);
  pcf8575_IN2.pinMode(i,INPUT);
  pcf8575_IN3.pinMode(i,INPUT);
  pcf8575_IN4.pinMode(i,INPUT);
}

  Serial.println("KC868-A64 64 channel input state 0:ON  1:OFF");
}

void loop()
{
  uint16_t var_1 = 0;
  uint16_t var_2 = 0;
  uint16_t var_3 = 0;
  uint16_t var_4 = 0;
  var_1 = pcf8575_IN1.digitalReadAll();
  var_2 = pcf8575_IN2.digitalReadAll();
  var_3 = pcf8575_IN3.digitalReadAll();
  var_4 = pcf8575_IN4.digitalReadAll();
/* Detect IN1-IN16  If triggered print "KEY i PRESSED"  */
  for(int i=0;i<16;i++)
  {
    if((var_1>>i&1)==0)
    {
     Serial.print("KEY ");
     Serial.print(i+1);
     Serial.println(" PRESSED");
    }
  }
/* Detect IN17-IN32  If triggered print "KEY i PRESSED"  */
  for(int i=0;i<16;i++)
  {

    if((var_2>>i&1)==0)
    {
     Serial.print("KEY ");
     Serial.print(i+17);
     Serial.println(" PRESSED");
   }
  }
/* Detect IN33-IN48  If triggered print "KEY i PRESSED"  */
for(int i=0;i<16;i++)
  {
    if((var_3>>i&1)==0)
    {
     Serial.print("KEY ");
     Serial.print(i+33);
     Serial.println(" PRESSED");
   }
  }
/* Detect IN49-IN64  If triggered print "KEY i PRESSED"  */
   for(int i=0;i<16;i++)
  {

    if((var_4>>i&1)==0)
    {
     Serial.print("KEY ");
     Serial.print(i+49);
     Serial.println(" PRESSED");
    }
  }
delay(100);
}

   
you should install the library PCF8575 library
   
Before Upload the code ,you should find the PCF8575.h  in PCF8575 Library file,and enable the the code in below picture
   



Attached Files
.zip   KC868-A64-PCF8575-DI.zip (Size: 1.13 KB / Downloads: 686)
Print this item

  KC868-A32 with Tasmota
Posted by: petez69 - 05-12-2022, 12:46 PM - Forum: KC868-A32/A32 Pro - Replies (3)

Hi Kincony

I would like to use the board with tasmota as the board can operate standalone (via web interface) or via MQTT.....

I've searched high and low but I cant find the full config, could you please help with:

1) Information we need to add to üser_config_override.h to add the expanders and ethernet
2) Config changes needed in Tasmota web configuration to enable the expanders.

ESPHome is very well documented however dont want to use it for now with Homeassistant.

Many thanks, have ordered A16 and A32, waiting for delivery :-)

Peter

Print this item

Bug [Arduino IDE demo source code for KC868-A64]--ALL code
Posted by: KinCony Support - 05-12-2022, 07:45 AM - Forum: KC868-A64 - No Replies

   



Attached Files
.zip   KC868-A64-ADC_INOUT.zip (Size: 686 bytes / Downloads: 620)
.zip   KC868-A64-LAN8720.zip (Size: 1.29 KB / Downloads: 573)
.zip   KC868-A64-PCF8575-DO.zip (Size: 1.48 KB / Downloads: 610)
.zip   KC868-A64-RS485.zip (Size: 697 bytes / Downloads: 596)
.zip   KC868-A64-PCF8575-DI.zip (Size: 1.13 KB / Downloads: 600)
Print this item

Bug [Arduino IDE demo source code for KC868-A64]--#04-PCF8575_Output_code
Posted by: KinCony Support - 05-12-2022, 07:35 AM - Forum: KC868-A64 - No Replies

[Arduino IDE demo source code for KC868-A64]--#04-PCF8575_Output_code
   

Code:
/*www.kincony.com */
/*KC868-A64 Code of PCF8575 output*/

#include "Arduino.h"
#include "PCF8575.h"

// Set i2c address
PCF8575 pcf8575_R1(0x24,5,16);  //SDA IO5  , SCL IO16
PCF8575 pcf8575_R2(0x25,5,16);
PCF8575 pcf8575_R3(0x21,5,16);
PCF8575 pcf8575_R4(0x22,5,16);

unsigned long timeElapsed;
void setup()
{
  Serial.begin(115200);

for(int i=0;i<16;i++)
{
  pcf8575_R1.pinMode(i,OUTPUT);
  pcf8575_R2.pinMode(i,OUTPUT);
  pcf8575_R3.pinMode(i,OUTPUT);
  pcf8575_R4.pinMode(i,OUTPUT);
}
  pcf8575_R1.begin();
  pcf8575_R2.begin();
  pcf8575_R3.begin();
  pcf8575_R4.begin();


/*
pcf8575_R1.pinMode(P0,OUTPUT);
pcf8575_R1.pinMode(P1,OUTPUT);
pcf8575_R1.pinMode(P2,OUTPUT);
pcf8575_R1.pinMode(P3,OUTPUT);
pcf8575_R1.pinMode(P4,OUTPUT);
pcf8575_R1.pinMode(P5,OUTPUT);
pcf8575_R1.pinMode(P6,OUTPUT);
pcf8575_R1.pinMode(P7,OUTPUT);
pcf8575_R1.pinMode(P8,OUTPUT);
pcf8575_R1.pinMode(P9,OUTPUT);
pcf8575_R1.pinMode(P10,OUTPUT);
pcf8575_R1.pinMode(P11,OUTPUT);
pcf8575_R1.pinMode(P12,OUTPUT);
pcf8575_R1.pinMode(P13,OUTPUT);
pcf8575_R1.pinMode(P14,OUTPUT);
pcf8575_R1.pinMode(P15,OUTPUT);

pcf8575_R2.pinMode(P0,OUTPUT);
pcf8575_R2.pinMode(P1,OUTPUT);
pcf8575_R2.pinMode(P2,OUTPUT);
pcf8575_R2.pinMode(P3,OUTPUT);
pcf8575_R2.pinMode(P4,OUTPUT);
pcf8575_R2.pinMode(P5,OUTPUT);
pcf8575_R2.pinMode(P6,OUTPUT);
pcf8575_R2.pinMode(P7,OUTPUT);
pcf8575_R2.pinMode(P8,OUTPUT);
pcf8575_R2.pinMode(P9,OUTPUT);
pcf8575_R2.pinMode(P10,OUTPUT);
pcf8575_R2.pinMode(P11,OUTPUT);
pcf8575_R2.pinMode(P12,OUTPUT);
pcf8575_R2.pinMode(P13,OUTPUT);
pcf8575_R2.pinMode(P14,OUTPUT);
pcf8575_R2.pinMode(P15,OUTPUT);

pcf8575_R3.pinMode(P0,OUTPUT);
pcf8575_R3.pinMode(P1,OUTPUT);
pcf8575_R3.pinMode(P2,OUTPUT);
pcf8575_R3.pinMode(P3,OUTPUT);
pcf8575_R3.pinMode(P4,OUTPUT);
pcf8575_R3.pinMode(P5,OUTPUT);
pcf8575_R3.pinMode(P6,OUTPUT);
pcf8575_R3.pinMode(P7,OUTPUT);
pcf8575_R3.pinMode(P8,OUTPUT);
pcf8575_R3.pinMode(P9,OUTPUT);
pcf8575_R3.pinMode(P10,OUTPUT);
pcf8575_R3.pinMode(P11,OUTPUT);
pcf8575_R3.pinMode(P12,OUTPUT);
pcf8575_R3.pinMode(P13,OUTPUT);
pcf8575_R3.pinMode(P14,OUTPUT);
pcf8575_R3.pinMode(P15,OUTPUT);
pcf8575_R4.pinMode(P0,OUTPUT);
pcf8575_R4.pinMode(P1,OUTPUT);
pcf8575_R4.pinMode(P2,OUTPUT);
pcf8575_R4.pinMode(P3,OUTPUT);
pcf8575_R4.pinMode(P4,OUTPUT);
pcf8575_R4.pinMode(P5,OUTPUT);
pcf8575_R4.pinMode(P6,OUTPUT);
pcf8575_R4.pinMode(P7,OUTPUT);
pcf8575_R4.pinMode(P8,OUTPUT);
pcf8575_R4.pinMode(P9,OUTPUT);
pcf8575_R4.pinMode(P10,OUTPUT);
pcf8575_R4.pinMode(P11,OUTPUT);
pcf8575_R4.pinMode(P12,OUTPUT);
pcf8575_R4.pinMode(P13,OUTPUT);
pcf8575_R4.pinMode(P14,OUTPUT);
pcf8575_R4.pinMode(P15,OUTPUT);   */

}

void loop()
{

for(int j=0;j<16;j++)
{
  pcf8575_R1.digitalWrite(j,LOW); delay(50);
}
for(int j=0;j<16;j++)
{
  pcf8575_R2.digitalWrite(j,LOW); delay(50);
}

for(int j=0;j<16;j++)
{
  pcf8575_R3.digitalWrite(j,LOW); delay(50);
}

for(int j=0;j<16;j++)
{
  pcf8575_R4.digitalWrite(j,LOW); delay(50);
}

for(int j=0;j<16;j++)
{
  pcf8575_R1.digitalWrite(j,HIGH); delay(50);
}

for(int j=0;j<16;j++)
{
  pcf8575_R2.digitalWrite(j,HIGH); delay(50);
}

for(int j=0;j<16;j++)
{
  pcf8575_R3.digitalWrite(j,HIGH); delay(50);
}

for(int j=0;j<16;j++)
{
  pcf8575_R4.digitalWrite(j,HIGH); delay(50);
}
/*
//R1 LOW----------------------
pcf8575_R1.digitalWrite(P0,LOW);
delay(50);
pcf8575_R1.digitalWrite(P1,LOW);
delay(50);
pcf8575_R1.digitalWrite(P2,LOW);
delay(50);
pcf8575_R1.digitalWrite(P3,LOW);
delay(50);
pcf8575_R1.digitalWrite(P4,LOW);
delay(50);
pcf8575_R1.digitalWrite(P5,LOW);
delay(50);
pcf8575_R1.digitalWrite(P6,LOW);
delay(50);
pcf8575_R1.digitalWrite(P7,LOW);
delay(50);
pcf8575_R1.digitalWrite(P8,LOW);
delay(50);
pcf8575_R1.digitalWrite(P9,LOW);
delay(50);
pcf8575_R1.digitalWrite(P10,LOW);
delay(50);
pcf8575_R1.digitalWrite(P11,LOW);
delay(50);
pcf8575_R1.digitalWrite(P12,LOW);
delay(50);
pcf8575_R1.digitalWrite(P13,LOW);
delay(50);
pcf8575_R1.digitalWrite(P14,LOW);
delay(50);
pcf8575_R1.digitalWrite(P15,LOW);
delay(50);

//R2 LOW------------------------
pcf8575_R2.digitalWrite(P0,LOW);
delay(50);
pcf8575_R2.digitalWrite(P1,LOW);
delay(50);
pcf8575_R2.digitalWrite(P2,LOW);
delay(50);
pcf8575_R2.digitalWrite(P3,LOW);
delay(50);
pcf8575_R2.digitalWrite(P4,LOW);
delay(50);
pcf8575_R2.digitalWrite(P5,LOW);
delay(50);
pcf8575_R2.digitalWrite(P6,LOW);
delay(50);
pcf8575_R2.digitalWrite(P7,LOW);
delay(50);
pcf8575_R2.digitalWrite(P8,LOW);
delay(50);
pcf8575_R2.digitalWrite(P9,LOW);
delay(50);
pcf8575_R2.digitalWrite(P10,LOW);
delay(50);
pcf8575_R2.digitalWrite(P11,LOW);
delay(50);
pcf8575_R2.digitalWrite(P12,LOW);
delay(50);
pcf8575_R2.digitalWrite(P13,LOW);
delay(50);
pcf8575_R2.digitalWrite(P14,LOW);
delay(50);
pcf8575_R2.digitalWrite(P15,LOW);
delay(50);

//R3 LOW------------------------
pcf8575_R3.digitalWrite(P0,LOW);
delay(50);
pcf8575_R3.digitalWrite(P1,LOW);
delay(50);
pcf8575_R3.digitalWrite(P2,LOW);
delay(50);
pcf8575_R3.digitalWrite(P3,LOW);
delay(50);
pcf8575_R3.digitalWrite(P4,LOW);
delay(50);
pcf8575_R3.digitalWrite(P5,LOW);
delay(50);
pcf8575_R3.digitalWrite(P6,LOW);
delay(50);
pcf8575_R3.digitalWrite(P7,LOW);
delay(50);
pcf8575_R3.digitalWrite(P8,LOW);
delay(50);
pcf8575_R3.digitalWrite(P9,LOW);
delay(50);
pcf8575_R3.digitalWrite(P10,LOW);
delay(50);
pcf8575_R3.digitalWrite(P11,LOW);
delay(50);
pcf8575_R3.digitalWrite(P12,LOW);
delay(50);
pcf8575_R3.digitalWrite(P13,LOW);
delay(50);
pcf8575_R3.digitalWrite(P14,LOW);
delay(50);
pcf8575_R3.digitalWrite(P15,LOW);
delay(50);

//R4 LOW------------------------
pcf8575_R4.digitalWrite(P0,LOW);
delay(50);
pcf8575_R4.digitalWrite(P1,LOW);
delay(50);
pcf8575_R4.digitalWrite(P2,LOW);
delay(50);
pcf8575_R4.digitalWrite(P3,LOW);
delay(50);
pcf8575_R4.digitalWrite(P4,LOW);
delay(50);
pcf8575_R4.digitalWrite(P5,LOW);
delay(50);
pcf8575_R4.digitalWrite(P6,LOW);
delay(50);
pcf8575_R4.digitalWrite(P7,LOW);
delay(50);
pcf8575_R4.digitalWrite(P8,LOW);
delay(50);
pcf8575_R4.digitalWrite(P9,LOW);
delay(50);
pcf8575_R4.digitalWrite(P10,LOW);
delay(50);
pcf8575_R4.digitalWrite(P11,LOW);
delay(50);
pcf8575_R4.digitalWrite(P12,LOW);
delay(50);
pcf8575_R4.digitalWrite(P13,LOW);
delay(50);
pcf8575_R4.digitalWrite(P14,LOW);
delay(50);
pcf8575_R4.digitalWrite(P15,LOW);
delay(50);
//R1 HIGH-----------------------
pcf8575_R1.digitalWrite(P0,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P1,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P2,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P3,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P4,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P5,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P6,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P7,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P8,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P9,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P10,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P11,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P12,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P13,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P14,HIGH);
delay(50);
pcf8575_R1.digitalWrite(P15,HIGH);
delay(50);

//R3 HIGH------------------------
pcf8575_R2.digitalWrite(P0,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P1,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P2,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P3,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P4,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P5,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P6,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P7,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P8,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P9,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P10,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P11,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P12,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P13,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P14,HIGH);
delay(50);
pcf8575_R2.digitalWrite(P15,HIGH);
delay(50);

//R3 HIGH-----------------------
pcf8575_R3.digitalWrite(P0,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P1,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P2,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P3,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P4,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P5,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P6,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P7,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P8,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P9,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P10,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P11,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P12,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P13,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P14,HIGH);
delay(50);
pcf8575_R3.digitalWrite(P15,HIGH);
delay(50);

//R4 HIGH------------------------
pcf8575_R4.digitalWrite(P0,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P1,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P2,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P3,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P4,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P5,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P6,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P7,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P8,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P9,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P10,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P11,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P12,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P13,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P14,HIGH);
delay(50);
pcf8575_R4.digitalWrite(P15,HIGH);
delay(50);

*/
}
   



Attached Files
.zip   KC868-A64-PCF8575-DO.zip (Size: 1.48 KB / Downloads: 562)
Print this item