Pantherinae
Posts: 2
Joined: Mon May 25, 2020 8:25 pm

RPI to arduino(MKR 1010) Master-Slave Ethernet Protocol.

Mon May 25, 2020 8:43 pm

Hello everyone,

so I got my RPI 4B with ethernet capabilities, my Arduino Mkr comes, with wifi which I believe I can turn to ethernet using this https://store.arduino.cc/usa/mkr-eth-shield. so I was hoping someone could point me to an article where I'm able to set my RPI as the master.

deepo
Posts: 583
Joined: Sun Dec 30, 2018 8:36 pm
Location: Denmark

Re: RPI to arduino(MKR 1010) Master-Slave Ethernet Protocol.

Tue May 26, 2020 5:47 pm

Wired and WiFi components can communicate with each other through a wifi router, so no need to convert wifi to cabled ethernet with another component. Or am I reading your post wrong?
Look into sockets in python to create a socket server on the Pi.

/Mogens

Pantherinae
Posts: 2
Joined: Mon May 25, 2020 8:25 pm

Re: RPI to arduino(MKR 1010) Master-Slave Ethernet Protocol.

Tue May 26, 2020 11:22 pm

yeah but I don't want them to communicate over wifi, I prefer Ethernet , as this is a mobile device that needs to operate independent of public wifi. I know the arduino can connect to a network. Can my RPI be a creator of that network, so that all the microcontrollers can be .connected to a LAN Switch, that my RPI is connected to.

markkuk
Posts: 204
Joined: Thu Mar 22, 2018 1:02 pm
Location: Finland

Re: RPI to arduino(MKR 1010) Master-Slave Ethernet Protocol.

Wed May 27, 2020 5:03 am

TCP/IP Ethernet networks are peer-to-peer, not master-slave. There is no "creator of the network". Assign a different IPv4 address for each device, and use standard socket communications between the devices.

hippy
Posts: 7762
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: RPI to arduino(MKR 1010) Master-Slave Ethernet Protocol.

Wed May 27, 2020 12:33 pm

Pantherinae wrote:
Tue May 26, 2020 11:22 pm
yeah but I don't want them to communicate over wifi, I prefer Ethernet , as this is a mobile device that needs to operate independent of public wifi.
You don't need to use public WiFi to connect to a Pi.

WiFi would usually allow greater mobility than wired ethernet, so it's odd to see you wanting to use wired ethernet over WiFi.

You can connect the wired ethernet Pi to a home router then WiFi connect your Arduino to that same router, or set up the Pi as a WiFi Access Point and WiFi connect your Arduino direct to the Pi. No need to buy an Ethernet Shield.

Or you can use the Ethernet Shield with your Arduino and cable connect both to a router, or switch, or directly.

There will be some configuration needed no matter which you do but it should be minimal in all cases.

Return to “Advanced users”