Questions tagged [udp]
User Datagram Protocol is one of the messaging protocols of the IP protocol stack. With UDP, computer applications can send messages to other hosts on an Internet Protocol (IP) network without requiring prior communications to set up special transmission channels or data paths.
38 questions
3
votes
1
answer
99
views
UDP and TCP sockets in the browser
I'm using a Web extension to communicate with an Isolated Web App over externally_connectable for the capability to use Direct Sockets UDP and TCP sockets from ...
7
votes
3
answers
1k
views
Rotary Encoder Controller C++
I built a controller with 3 rotary encoders to control various parameters of a program i wrote to control a motor. The controller delivers data via usb through serial (Arduino).
Originally I used OSC ...
2
votes
1
answer
209
views
ESP32-12: Sample analog audio and send it via udp
I want to sample audio as a learning process.
In the future i want to make my dorbell "smart" and stream the audio via VoIP. But as beginning i want to sample a simple audio signal from my ...
8
votes
3
answers
738
views
Send arbitrary number of arbitrary length buffers in packets of fixed arbitrary size
Background:
I am in earlier stages of implementing a standard on top of an existing 'backend'
This standard requires that I send data in UDP packets of a size specified at runtime
All packets must be ...
2
votes
1
answer
272
views
to capture packets with options like -i interface, -o open file, etc using pyshark and python
review my code if possible. I am making network packet capture using pyshark and python. if possible give me some feedback about the code and help to make it better.
...
1
vote
1
answer
305
views
NTP client displaying reference, originate, receive and transmit timestamps periodically with graceful shutdown in C#
based on this stackoverflow topic: https://stackoverflow.com/a/12150289/15270760 I have decided to create a simple NTP client displaying difference between NTP server response and DateTime.Now called ...
2
votes
1
answer
386
views
UDP image livestream from Android device to C# desktop application
After searching a lot, on how to do it and not finding any good solutions, I implemented my own UDP livestream from an Android device to a C#/WPF desktop application. It works, however, since I get ...
1
vote
1
answer
354
views
Java UDP port knocking authentication. Many clients at the same time
This is a student project of mine. I got 4/5 points but I suspect there's a lot of weird stuff in there. I never had a chance to hear my teacher's feedback about it and it bothers me so I figured ...
2
votes
0
answers
66
views
How to define UDP connection sessions more correctly?
Listening to messages from the udp socket, I would like to somehow determine where packets come from and scatter in sessions to get a more detailed report on the received data, I just did it forehead, ...
5
votes
2
answers
297
views
Network IP packet tracker
this is my code for watching IP packets. I am doing project for my self because I want to learn how this things works.
This is my IP Packet class:
...
2
votes
1
answer
830
views
Simple UDP server (java)
I write kind of UDP server. It should serves about 50 messages per second.
I would like a review about the general code 'quality' and logic. The server uses the same socket for sending and receiving ...
4
votes
0
answers
609
views
Python UDP server to relay CSV or JSON data to cloud for analysis
What am I doing?
UDP/TCP server in Python (2.7 / 3.7)
How am I doing?
Using threads
Where am I going to execute it?
In a virtual machine running linux in AWS or Google Cloud or Azure ()
What ...
7
votes
1
answer
5k
views
Non-blocking TCP and UDP in Unity3D Game Engine
I would like constructive criticism of a networking plugin I've written for Unity 3D. The use-case of the code is for people in "creative coding," where simple TCP and UDP messages are used for ...
6
votes
2
answers
2k
views
UDP Reverse Shell
I'm currently learning python / network programming altogether and I coded this simple python reverse shell; I would like to hear any remarks from you regarding code structure, any common beginner ...
2
votes
1
answer
2k
views
A send and receive UDP node in C
I am working on a (personal) light weight distributed project for the Rpi platform. Making it distributed requires P2P communication between the nodes, and I thought it would be a good time to learn ...
3
votes
1
answer
2k
views
UDP timeout detector
Camera streaming app for the pizero, hobby project.
I want the cam to be sending frames only if there is an active client on the other end.
For this purpose the cam is listening on a port for client ...
13
votes
1
answer
505
views
Game-oriented UDP protocol
As part of a small multiplayer game project I designed a generic (and not too complex) protocol (used over udp). The game is 2D, has physics-based elements (e.g. rigid body, smoke) and should be ...
6
votes
1
answer
2k
views
SFML-based chat in C++
I wanted to get some review on this code I wrote. The repo is here if you want to download the CodeBlocks project.
This program is several things: it is a console using SFML graphics; it is a console ...
8
votes
1
answer
3k
views
Real time UDP packet decoder
I have basic C++ lectures at a university and I don't really know how I can optimize this line of code for a real-time application (I call this function every 5 ms for UDP packet decoding).
I would ...
6
votes
3
answers
2k
views
Python UDP class to control drone
I'm currently building a small plane with Raspberry Pi Zero W. I wrote a small code which uses UDP to control it.
Here I'm resending packets regularly in a thread because of the joystick input (it ...
2
votes
1
answer
15k
views
Implementation of an asynchronous UDP server Listener
I have written this code in C# and have tested this code to ensure it works well. Any other suggestions for this code would be appreciated as I have a number of users who are sending data on this port....
2
votes
1
answer
855
views
Semi-Reliable Communications Using UDP
I'm writing a communications library for a class. Part of the requirements is that semi-reliable communications, which leads me to this monstrosity:
...
2
votes
1
answer
2k
views
Handling errors in a Python UDP proxy [closed]
The following (stripped) program receives UDP packets on port 5000 and forwards them to port 5001. It may throw socket errors on startup (e.g.: if the port is already in use), but I am not too worried ...
10
votes
2
answers
3k
views
Thread to send heartbeat UDP packets
This C code will run on an embedded machine with a Linux OS. It should create data packets (ASCII) to repeatedly be sent to a UDP server.
Just to give an overview about what functions should do:
<...
3
votes
0
answers
725
views
Event-driven UDP listener wrapper
I wrote this wrapper around the UdpClient,using events for new datagrams:
...
2
votes
0
answers
2k
views
UDP server for a multiplayer game using socketserver
I am making a multiplayer platforming game, and currently there are server performance issues once I have about 7+ clients connected. I was told earlier last week that I should investigate ...
6
votes
1
answer
8k
views
UDP Server Design and Performance
What I'm doing
I am writing a server to work as my games backend. The server is being written in C# using UDP as the protocol, while the game is in C++. The biggest thing I've been focusing on was ...
0
votes
1
answer
100
views
Playing audio from two data sources
I want to play some audio of two byte arrays. I was wondering whether it would be better to play them as two separate arrays both calling the method, or to put them into one array and play it from ...
9
votes
1
answer
3k
views
UDP Server class
For my current project I need a basic UDP server. The first priority is to make it as fast, but as resource friendly as possible (it will be run on Raspberry Pi-like devices).
I would like a review ...
20
votes
2
answers
418
views
Select external resource to feed data into a processing function
I wrote an application a while back to plan and manage drones races. (Well, it could be anything with identification numbers going through checkpoints.) At that time, communication between the gates (...
3
votes
3
answers
2k
views
Simple UDP server/client written in Python to report back IP address
I'd like to get some feedback/criticism on my attempt to write a simple client/server application that reports back the (client's) global IP address.
It would be nice if you could comment on the UDP ...
6
votes
2
answers
4k
views
Multithreaded Network Server
I would like the following code reviewed:
I am trying to create a local server which listens indefinitely and
provides the latest information. The server runs another while loop
which fetches ...
11
votes
4
answers
4k
views
Gossip algorithm in distributed systems
I have implemented the gossip algorithm in distributed systems for review.
Gossip class
...
40
votes
1
answer
1k
views
Utility that decodes and logs UDP packets
I have written the following utility, as my first non-tutorial program in Go.
The purpose of the utility is
to connect to a torque/force sensor (aka load-cell) via UDP;
to send an initialization ...
5
votes
2
answers
2k
views
Logging to a File vs UDP
I'm trying to understand where my ruby implementation of this fails and hoping for an expert to shed some light on this situation. I've tried to make this a very simple example with the idea that ...
6
votes
2
answers
2k
views
High udpclient CPU use
I have a bunch of different ports I want to listen on and the iterate over the available data to send to a Dataflow pipeline. In total I'm listening on 14 ports. I'm looking for any advice on how to ...
6
votes
1
answer
664
views
Good usage of MailboxProcessor/Agent in class rather than mutable field?
I've written a simple Simple Service Discovery Protocol (SSDP) module. This module contains a class, Session that you create and then use to issue commands and ...
6
votes
1
answer
781
views
Blocking and async UDP communication with an IR camera
I'm writing a Java application to control a custom IR research camera that will be installed on an aircraft. The camera connects to the the computer using UDP sockets via a direct LAN cable. The ...