Brooklyn
Posts: 5
Joined: Tue May 28, 2019 11:21 pm

Raspberry PI with arduino = TCP/IP

Tue Jul 02, 2019 1:14 pm

Can I create a chat server on the Rpi and create a chat client on the Arduino and let it communicate with each other over my local network?

&

Can I create a chat server on the Rpi and create a chat client on the Arduino and let it communicate with each other over my local network. Can this work with a chatserver -> chatclient?
Over tcp/ip?
Or is udp better?

User avatar
HermannSW
Posts: 1392
Joined: Fri Jul 22, 2016 9:09 pm
Location: Eberbach, Germany
Contact: Website Twitter YouTube

Re: Raspberry PI with arduino = TCP/IP

Tue Jul 02, 2019 3:25 pm

> on the Rpi
>
You don't state which Rpi, in case of Pi0 you need to add network connectivity either by USB OTG or enc28j60 network module:
https://www.raspberrypi.org/forums/view ... 0#p1015300

You don't state which arduino, you can add network connectivity to AVR based Arduinos with enc28cj60 module as well:
https://github.com/njh/EtherCard
https://twitter.com/HermannSW/status/711237172523720704

> Or is udp better?
>
while it does not make a big difference to loose some packets when streaming video, I doub't that you would want unnoticed lost packets (messages) for a chat client. So for chat definitely TCP is needed.


Image
⇨https://stamm-wilbrandt.de/en/Raspberry_camera.html

https://github.com/Hermann-SW/Raspberry_v1_camera_global_external_shutter
https://gitlab.freedesktop.org/HermannSW/gst-template
https://github.com/Hermann-SW/fork-raspiraw
https://twitter.com/HermannSW

Brooklyn
Posts: 5
Joined: Tue May 28, 2019 11:21 pm

Re: Raspberry PI with arduino = TCP/IP

Wed Jul 03, 2019 2:27 pm

It's a Raspberry Pi Model 3B +
and
I have now a arduino mega with a esp module inbuilt but maybe i will buy a arduino uno wifi.

ankith26
Posts: 103
Joined: Mon Mar 25, 2019 11:08 am
Location: Earth
Contact: Website

Re: Raspberry PI with arduino = TCP/IP

Thu Jul 04, 2019 2:31 pm

If you plan to interface arduino and raspi, use serial protocol with usb cable connecting them... This is the easiest way to have any sort of chat or communication
I had many troubles using esp8266 module(I fried 3 modules as i did not know how to handle the thing)
My website is at https://pratt.ml
Hope it runs (which it wont)

Brooklyn
Posts: 5
Joined: Tue May 28, 2019 11:21 pm

Re: Raspberry PI with arduino = TCP/IP

Thu Jul 04, 2019 5:53 pm

ankith26 wrote:
Thu Jul 04, 2019 2:31 pm
If you plan to interface arduino and raspi, use serial protocol with usb cable connecting them... This is the easiest way to have any sort of chat or communication
I had many troubles using esp8266 module(I fried 3 modules as i did not know how to handle the thing)
Is it easier to communicatie two rpi in a network?
because my raspberry pi is a server that stands in my garage and the arduino or maybe a other rpi that stand in my bedroom.

ankith26
Posts: 103
Joined: Mon Mar 25, 2019 11:08 am
Location: Earth
Contact: Website

Re: Raspberry PI with arduino = TCP/IP

Fri Jul 05, 2019 2:56 pm

A Pi to Pi connection would be easier according to me..
On arduino-raspi connection through lan, idk much
My website is at https://pratt.ml
Hope it runs (which it wont)

Brooklyn
Posts: 5
Joined: Tue May 28, 2019 11:21 pm

Re: Raspberry PI with arduino = TCP/IP

Fri Jul 05, 2019 4:36 pm

ankith26 wrote:
Fri Jul 05, 2019 2:56 pm
A Pi to Pi connection would be easier according to me..
On arduino-raspi connection through lan, idk much
Is that also tcp/ip protocol

ankith26
Posts: 103
Joined: Mon Mar 25, 2019 11:08 am
Location: Earth
Contact: Website

Re: Raspberry PI with arduino = TCP/IP

Sat Jul 06, 2019 8:43 am

Yup.. Through sockets that is...
I found this youtube video that shall suite your purpose
https://www.youtube.com/watch?v=l0p-NvmoeUA
My website is at https://pratt.ml
Hope it runs (which it wont)

Return to “Networking and servers”