KC868-A16 - Own Arduino firmware - Printable Version +- Smart Home Automation Forum (https://www.kincony.com/forum) +-- Forum: Technical Support (https://www.kincony.com/forum/forumdisplay.php?fid=1) +--- Forum: Development (https://www.kincony.com/forum/forumdisplay.php?fid=4) +--- Thread: KC868-A16 - Own Arduino firmware (/showthread.php?tid=7057) Pages:
1
2
|
KC868-A16 - Own Arduino firmware - boe666 - 11-13-2024 I am waiting for the kc868-A16 to be delivered. My goal is to make a complete program in Arduino to support my own smart elements - the superior system is Domoticz/HomeAssistant. Are there any examples in Arduino that show how to implement access to all PCF and other in/out ports (pins, addresses) as well as the LAN module (pins, addresses) in the Arduino environment? If so, where can I find them. I know that you can do reverse engineering and laboriously check and test everything - but if someone has already figured it out - maybe they could share a few source files. RE: KC868-A16 - Own Arduino firmware - admin - 11-13-2024 if you want to use home assistant, you can use by ESPHome, we already supply yaml file. you can check at here: https://www.kincony.com/forum/showthread.php?tid=1628 if you MUST want to use arduino , here are all sample demo code for KC868-A16: https://www.kincony.com/forum/forumdisplay.php?fid=25 RE: KC868-A16 - Own Arduino firmware - boe666 - 11-14-2024 When I try to compile the example I get the messagerc/WebServer_WT32_ETH01.h:63:4: error: #error This code is designed to run on ESP32 platform! Please check your Tools->Board setting. Espressif ESP32 installed (boards). Selected board ESP32 S3 Box or WT32-ETH1. Regardless of which board variant I choose - I get the same message. Any tips? Arduino:2.3.3, ESP 3.0.7. file: HelloServer.ino RE: KC868-A16 - Own Arduino firmware - admin - 11-14-2024 if you are using KC868-A16, it use ESP32 device, NOT ESP32-S3 device. RE: KC868-A16 - Own Arduino firmware - boe666 - 11-14-2024 but which one exactly, because there are many types of ESP32 boards in Espressif. There is no regular ESP32. In the thread https://www.kincony.com/forum/showthread.php?tid=1613 it says to choose NodeMCU-32S - that's the name of the board but no changes - the same message. RE: KC868-A16 - Own Arduino firmware - admin - 11-14-2024 chose NodeMCU32 also is OK. your problem is not installed WebServer_WT32_ETH01 arduino library. just install it. RE: KC868-A16 - Own Arduino firmware - boe666 - 11-14-2024 I have the WebServer_WT32_ETH01 library installed, the problem lies in the STM32 definition in the code of this library. Just change the line #if ESP32 to #if !ESP32 and the compiler goes on. However, there is another problem with the PCF8547 library.. in the second picture. RE: KC868-A16 - Own Arduino firmware - boe666 - 11-14-2024 Probably you have to use Renzo Mischianti's PCF8574 library. Now the problem is the ETH.h library - which one to use? I have installed https://docs.arduino.cc/libraries/ethernet/ in newest version but I see that the esp32 library has its own ETH.h (so I uninstalled my) libraries. It says that constants should be defined, for example: #ifndef ETH_PHY_TYPE #define ETH_PHY_TYPE ETH_PHY_LAN8720 #define ETH_PHY_ADDR 0 #define ETH_PHY_MDC 23 #define ETH_PHY_MDIO 18 #define ETH_PHY_POWER -1 #define ETH_CLK_MODE ETH_CLOCK_GPIO0_IN #endif The compiler reports as follows: PHP Code: C:\Users\mkapski\Documents\Arduino\testy_kicony_v2_demo1\testy_kicony_v2_demo1.ino: In function 'void setup()': C:\Users\mkapski\Documents\Arduino\testy_kicony_v2_demo1\testy_kicony_v2_demo1.ino:288:12: error: no matching function for call to 'ETHClass::begin(int, int)' 288 | ETH.begin(ETH_PHY_ADDR, ETH_PHY_POWER); RE: KC868-A16 - Own Arduino firmware - admin - 11-14-2024 here is PCF8574 arduino library we are using. PCF8574_library.zip (Size: 23.8 MB / Downloads: 6) RE: KC868-A16 - Own Arduino firmware - boe666 - 11-14-2024 (11-14-2024, 12:36 PM)admin Wrote: here is PCF8574 arduino library we are using. PCF problem solved. What about ETH.h library and compiler errors? Which library should I use? Currently the one built into the esp32 library is used, which can be seen in the error logs. Interestingly, the example from the esp32 / Ethernet library called ETH_LAN8720 compiles without errors in the same Arduino environment. Request for support. Ultimately, I would like to use the MYSENSORS library, but I have to start with the network first. |