0

We're trying to make an network of connected cars in which the status of one car is continuously updated to the nearby cars (for example, speed, gear, brakes, etc.).

Can I continuously send out sensor data via ESP8266 and and any nearby ESP8266 can pick it up? Is it possible? Or if there's any other method?

Greenonline's user avatar
Greenonline
3,1527 gold badges37 silver badges49 bronze badges
askedAug 17, 2018 at 10:12
Pankaj Thakur's user avatar
1
  • yes, that's completely possible. you can go ESPNOW or mesh or a pre-setup LAN.CommentedAug 17, 2018 at 16:05

1 Answer1

1

Yes, you can - if all the "cars" are on the same WiFi network.

If that is the case, then I'd recommend using UDP as your transport layer, and eitherbroadcast ormulticast the packets.

I use UDP and Multicast to send sensor data from multiple sensors to multiple receivers on my network. All nodes subscribe to the same multicast address, and the sensors include their own ID in the packet to identify them. A sensor sends out one packet, and all the other nodes can receive it.

However, if there is no active WiFi network already established between the "cars" then no, there's not a lot you can do with an ESP8266. It communicates using IP, and that relies on there being an established layer 2 network (WiFi / Ethernet, etc) already in existence. You should instead investigate more peer-to-peer communication technologies, or communication technologies that don't rely on establishing a connection to a network of any form. Maybe the nRF24L01+ would be a better fit?

answeredAug 17, 2018 at 10:46
Majenko's user avatar
1
  • ESP-NOW fits the problem better than wifi, which has to maintain a connection. ESPNOW also allows encryption (nrf doesn't) and has a nice built-in encoder, with error detection, sender ID, etc.CommentedAug 17, 2018 at 16:05

Your Answer

Sign up orlog in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

By clicking “Post Your Answer”, you agree to ourterms of service and acknowledge you have read ourprivacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.