07-28-2021, 03:54 AM
(07-22-2021, 06:09 PM)renze Wrote: This might be usefull information: https://github.com/libc0607/Realtek_switch_hacking
(Translated: https://github-com.translate.goog/libc06...=ajax,elem)
I've seen that GitHub repository quite a while ago, and the information available there is very useful. I've also stumbled upon the source code of a Realtek "unmanaged switch" SDK (as Realtek called it), but that SDK unfortunately didn't contain the source code and the "magic blob" that's apparently required to turn RTL8370N into a managed switch, by enabling the built-in 8051 CPU, etc.
(07-23-2021, 05:34 PM)renze Wrote: I've dumped the contents of the EEPROM chip attached to the RTL8370N on the Clusterboard (using a SoPine on the Clusterboard itself).
The EEPROM appears to contain a series of register writes which the chip executes directly after starting from reset state. I've parsed the register writes that are executed into a table and I've documented what I did here: https://github.com/renzenicolai/uboot-pi...t%20switch
I suspect that configuring VLANs could be as easy as adding extra register writes to the EEPROM and resetting the ethernet switch chip.
This is very interesting! However, please keep in mind that my original idea wasn't to create a "hacky" solution that configures VLANs through external register writes and "hacky" stuff like that. Please, don't get me wrong, that's perfectly fine for some use cases, but my original idea was to create a feature-complete open-source firmware for RTL8370N, which would run on the built-in 8051 and be capable of accepting SSH connections and presenting a command-line interface that would allow all features of RTL8370N to be managed, port statistics to be collected, etc.