0
\$\begingroup\$

I never worked with one of the above methods but for my next project I have to. I already read a bit about it but would like to have some user experience data.( I ordered them already to test it myself as well)

I am using an Esp32 as a mqtt client. It resolves the data and controls actuators (mosfets). Right now it simply uses the io pins but we need more pins/want to add features like Ethernetcontroll over SPI or external PHY Module (LAN8720)

For that we thought about adding either some kind of io expander via SPI or I2C. Another idea would be just to control them over single-wire. Everything is fairly easy to program in arduino so I doubt there will be a problem.

What I would like to know is, if I would notice speed/delay from getting a signal to switching the mosfet depending on the used data transfer method. The wires are all pretty short and we have about 16 actuators so I would use 2x8 expanders(MCP 23S08-E/P /MCP 23S09-E/P or 2 OneWire 8 channels(DS2408)

Will I notice a difference in speed if I switch actors depending on the method? Will I notice a difference in speed if I used Ethernet over SPI-Lan Module vs external PHY How easy are they to programm ? What is the best,easiest for the ESP32 ? What is the fastest ?

Thanks and Greetings !

\$\endgroup\$
1
  • \$\begingroup\$ Too many broad questions. Would you notice a delay? What delay can you tolerate? There are too many variables and you've not given us any hard criteria to be able to give a useful answer. For your own education I'd suggest you give it a try and you'll answer your own questions. At a guess, I2C should be adequate - it's your code that actions an update, so it's in your hands. \$\endgroup\$
    – Kartman
    Apr 11, 2021 at 7:47

1 Answer 1

2
\$\begingroup\$

The overhead from I2C or SPI or 1wire would be minimal and likely undetectable to a human. 16 or 32 bits at 400 kHz or higher is fractions of a second.

Any noticeable delay would be from sharing the bus with an Ethernet device and your coding, interrupt handling, etc. Over all you need to test.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.