per1234 / EtherEvent

Easy to use password authenticated Ethernet communication between Arduinos and EventGhost Network Event Sender/Receiver or TCPEvents plugins.
MIT License
0 stars 0 forks source link

ESP32??? #5

Closed kdschlosser closed 4 years ago

kdschlosser commented 4 years ago

@per1234 what would be the possibility of adding support for the ESP32? I have a user over in EventGhost land that wants to use an m5stack (ESP32 based) and have it report to EG. The firmware for the device is open source so EtherEvent can be added to it.

per1234 commented 4 years ago

I wrote this library for my own needs, which was Ethernet. I wanted to make it as easy as possible for the user to write a sketch to communicate between Arduino boards and EventGhost using the network event system.

However, I now feel that it would have been worth a bit more complexity on the sketch side of things to make the library support any network interface, as I documented here: https://github.com/per1234/EtherEvent/issues/2

Just as the initial decision to hardcode in a specific type of network interface was a bad idea, hardcoding additional network interfaces would be even worse.

I did a little bit of work on changing the library to a generic communication interface, which I believe is here: https://github.com/per1234/EtherEvent/tree/MoreInterfaces2

but this will be a breaking change, so I wanted to get the library in its current form as polished as possible and make a release before doing that. I believe the work on that is here: https://github.com/per1234/EtherEvent/tree/development

Unfortunately, all the use of the preprocessor I added to provide for your large payload application (https://github.com/per1234/EtherEvent/issues/1) ended up making continued development quite difficult. I ended up switching to a header-only format, and everything was going well for EtherEvent, but then when I updated the EtherEventQueue library to work with the new format I really ran into some confusing problems and never got past that.

kdschlosser commented 4 years ago

I see how it is. blaming it on me.. LOL...

Don't ya hate it when ya write a program in a specific way and that way bites ya in the ass later on. I hate it when I do that. That is probably the single thing that causes me to have to write things over.

No worries tho. as it turns out that device the user wants to use it able to operate with MicroPython. They have an SDK coded up for it. Writing a socket connection to talk with the Network Receiver plugin is a snap to do in Python. I am not going to write an entire UI for the user, he/she is going to have to learn python to do that. I will write the socket portion tho.

per1234 commented 4 years ago

Yeah, you can really get into trouble by establishing an API without really thinking it through in advance. Then you end up with the dilemma or whether to harm the users by changing the API, or harming progress by keeping the limiting API.

It's not really such a big deal for this project because probably nobody other than myself is using it, but I certainly will have to do some work on my own projects to adapt to the new API.