-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Port nuki_hub to Olimex ESP32-POE-ISO Board #38
Comments
Hi, it should be possible to port this to the Olimex board. However, there are quite a few more boards with LAN connectivity and this is a project I'm running and financing privately - I unfortunately can't buy every hardware out there. |
yeah, i understand that, no prob. Maybe i can help you with stuff? i looked into your code, looks like the network stack is "modular", maybe we can write another stack for LAN8710A ? |
Sure ... thinking about maybe it's enough to just wire a LAN8710A module the same way it's wired on the board? They are fairly cheap. |
should be. i tried flashing the firmware in hope to use the esp32 wifi, but unfortunately, the gpio pin for eth activation (gpio26) is wired to the nic chip. this leads to deactivating the wifi. which IDE do you used for developing this code? |
I'm using clion, but if your question is how to compile the code it's a cmake project. Have a look at my other project "coffeetimer", there's a howto for compiling. Not sure about the GPIO ... I had to pick one so it was 26. We could make it configurable in software, but that has the risk of someone changing to the setting to LAN and then have an ESP that isn't reachable because the hardware is missing. Maybe have two settings for LAN:
This way also issue #36 could be addressed. |
i have no pratical experience with cmake programs. i managed to install arduino sdk, cmake and toolchain, but i got error when trying to compile: CMake Error at /home/philipp/Arduino-CMake-Toolchain-master/Arduino/System/BoardBuildTargets.cmake:166 (message): CMake Error at CMakeLists.txt:111 (target_link_arduino_libraries): -- Configuring incomplete, errors occurred! any short hint? |
mkdir build Also, please use my fork of the arduino toolchain: https://github.com/technyon/Arduino-CMake-Toolchain Which version of the Arduino core for ESP32 did you install? |
EDIT: nvm. had to clear cmake cache :D yeah, the toolchain file worked for me. i used esp32 version 1.0.6, because all of the 2.0 vers does not find a suitable CXX compiler:
is not a full path to an existing compiler tool. Tell CMake where to find the compiler by setting either the environment -- Configuring incomplete, errors occurred! |
i dont get it, now it compiled, but i dont know how to flash it, the directive "upload-nuki_hub" does not work, because no bootloader is generated. another hint? |
Strange with the compiler, I didn't have that problem. Maybe just set a symbolic link? But for your purposes, 1.0.6 is fine. Pre 2.0 the WiFi problems were much more pronounced, but apart from that it's the same. You could just copy the bootloader from the official release (basically all .bin files). I'm using ninja though instead of make, maybe that would fix your problems. Are you on Debian or Ubuntu? In that case run: apt install ninja-build Then remove all files from the cmake build directory and add the option "-GNinja" to the cmake command line. |
yeah, i was dumb. got it to work. or am i missing something? |
Yes, create a new device in networkDevices, then instantiate it in network.cpp. The question is how to switch between W5500 and LAN8720. What do you think about selecting driver and GPIO in the web portal? |
yeah, i would use wifi as standard, because every esp32 does have it. after first boot, you can decide in the webinterface which driver you want to use. |
my problem is, that i have little to no experience in CMake Projects, i managed to compile it, i tried to integrate new functions for LAN87xx devices, but i dont get it. i got the lan to initialize, but it aborted with error "ethernet_event_start" event failed. i used the resources over here: https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/network/esp_eth.html the important parts for my board seems to be: with this i managed to get a short connection. i dont know how to go further, anyone comments on this? |
It's a bit hard to tell like this what's the issue. Could you fork my project and check in your code so I can have a look at it? Also which library are you using to communicate with the LAN8170? I don't think it's related to cmake ... if you have problems with cmake it's usually about getting your code to compile. |
Getting LAN8170 support would be amazing so I could replace my WiFi-based ESP32 by one of these Olimex boards with PoE built-in! Any additional progress so far @pilo1337? |
Hi, I've added support for the M5Stack Atom POE which uses the W5500 chip: https://docs.m5stack.com/en/atom/atom_poe If I find some time I'll try to add their other ESP with Ethernet: https://shop.m5stack.com/products/esp32-ethernet-unit-with-poe The latter is considerably cheaper, but lacks a USB port so you have to connect a USB-serial converter. |
@pilo1337 Can you share the full code ? |
The Olimex is finally supported ! |
Amazing @technyon 👏 ! Will the PoE port be automatically detected or will it still require a WiFi connection to enable the ethernet component? |
You have to first connect it to wifi and then select olimex hardware. I don't really have a good way to detect that it's running on an olimex board. |
A different image with these pre-defined values would be great. If you use platform.io, you'd just need to compile the image for a different environment with specific build tags. Example: https://github.com/OpenEVSE/ESP32_WiFi_V4.x/blob/master/platformio.ini |
Hi,
i was wondering porting this app to an Olimex ESP32 PoE Board?
this has several benefits:
Unfortunately, the board uses a LAN8710A Chip in RMII Mode for managing Ethernet, which is not supported by the current firmware.
the board is well documentated, maybe we can write a port for this particular board?
the shematic: https://github.com/OLIMEX/ESP32-POE-ISO/blob/master/HARDWARE/ESP32-PoE-ISO-Rev.H/ESP32-PoE-ISO_Rev_H.pdf
The text was updated successfully, but these errors were encountered: