There are literally thousands of different types of connectors when I'm searching on a distributor such as element14, and I'm not sure what are the "standard" ways of connecting boards together.
Currently, when I need to connect two different boards together, I will use a 2.54mm spaced pin header, and some ribbon jumper wires. While this is fine for prototyping, I want a more standard solution to connecting modules together (such as USB, D-Sub, HDMI connectors, etc).
The protocols I normally use a I2C and SPI, so Vcc, GND, and the bus wires (SDA, SCL, MOSI, etc). For these protocols, are there any standard physical connectors which I should use when I want to connect boards together? e.g. RJ45 or something? I've always associated RJ45 with telephone comms, so not sure if there are more appropriate standard connectors.
For example, if I want to drive a motor or fan, what type of socket should I use on my board? On computer fans, hard drivers, toys, etc. I have seen them use Molex or some tiny white connector. Is this a standard way of connecting analogue input/outputs? AFAIK Molex is a brand of connectors, but nowadays is it just a name for the type/shape of connector?
Protocol-less digital communications
For example, push button switches, and LED lights, etc. How should I connect these between boards?
Finally, in my latest project I need to connect my around 20 different connections (these include both vcc/gnd lines, analogue inputs, switch inputs, as well as an I2C line, and some multiplexer line select lines,) between two boards. Should I have different connectors for each of these, or is there one standard connector I can use for all the pins?
The distance of communication I'm talking about is 1 - 2 meters at most, however any information regarding longer range communication is also appreciated.