![]() |
|
Troubles using I2C/IIC bus - Printable Version +- Smart Home Automation Forum (https://www.kincony.com/forum) +-- Forum: Technical Support (https://www.kincony.com/forum/forumdisplay.php?fid=20) +--- Forum: KC868-A6 (https://www.kincony.com/forum/forumdisplay.php?fid=22) +--- Thread: Troubles using I2C/IIC bus (/showthread.php?tid=8204) |
RE: Troubles using I2C/IIC bus - admin - 06-25-2025 you just need to install PCF8574 library.
PCF8574_library.zip (Size: 23.8 MB / Downloads: 269)
RE: Troubles using I2C/IIC bus - ksarz - 06-26-2025 Hi. There are of the my IDE code: include <PCF8574.h> #include <Wire.h> #define SDA_PIN 4 // GPIO номер SDA #define SCL_PIN 15 // GPIO номер SCL void setup() { Wire.begin(SDA_PIN, SCL_PIN); // Задали новые контакты для I²C // Инициализируем I²C Serial.begin(115200); // Инициализируем последовательный порт while (!Serial); // Ждем открытия порта Serial.println("\n\n--- I²C Scanner ---"); } void loop() { byte error, address; int nDevicesFound = 0; Serial.println("Scaning..."); for (address = 1; address < 127; address++ ) { Wire.beginTransmission(address); error = Wire.endTransmission(); if (error == 0) { Serial.print("Device found at address: 0x"); if (address < 16) { Serial.print("0"); } Serial.println(address, HEX); nDevicesFound++; } else if (error == 4) { Serial.print("Unknown error at address: 0x"); if (address < 16) { Serial.print("0"); } Serial.println(address, HEX); } } if (nDevicesFound == 0) { Serial.println("No I²C devices found.\n"); } else { Serial.println("Scan complete.\n"); } delay(5000); // Повторяем проверку каждые 5 секунд } Where it any mistake? RE: Troubles using I2C/IIC bus - ksarz - 06-30-2025 What does the problem at yours demo Relays code? May be the KC-868-A6 Board is defective? RE: Troubles using I2C/IIC bus - admin - 06-30-2025 please download KCS v2 firmware to test your board firstly. if KCS v2 firmware work well, that means hardware is well, you need to check your software system. RE: Troubles using I2C/IIC bus - ksarz - 07-02-2025 (06-30-2025, 11:20 PM)admin Wrote: please download KCS v2 firmware to test your board firstly. Dear Admin! I have already installed the KSV firmware on my board several times.The version of the my Firmware is KC868_A6-v2.2.14.bin. See you the attachment. After installation this firmware I2C and relays does not wort on my Board too! RE: Troubles using I2C/IIC bus - admin - 07-02-2025 after you downloaded KCS v2 firmware, login by web browser, click "monitor" webpage, turn on/off relay button ico, relay can't work , right? RE: Troubles using I2C/IIC bus - ksarz - 07-02-2025 Dear,Admin! This is incredible!! The KC 868 Board worked. But in the Monitor Menu there is NO RELAY, Please see screenshot RE: Troubles using I2C/IIC bus - admin - 07-02-2025 take a photo of your PCB board. RE: Troubles using I2C/IIC bus - ksarz - 07-03-2025 (07-02-2025, 10:44 AM)admin Wrote: take a photo of your PCB board. There is of Photo my Board RE: Troubles using I2C/IIC bus - admin - 07-03-2025 what power supply you are using? suggest use DC12V 2A. suggest you change a new power supply for a testing. |