+ ====================================================================== +
MINITALK
+ ====================================================================== +
Minitalk is a project from the 42 Network focused on creating a simple communication system between two programs using Unix signals. The challenge involves implementing a message transfer protocol and demonstrating the usage of signals to send and receive data, which enhances understanding of process control and inter-process communication.
π Features
- Allows communication between two programs using Unix signals.
- The client sends a string message, and the server prints it.
- Focuses on understanding signals, processes, and message encoding.
- Provides an introduction to low-level inter-process communication in C.
π οΈ Getting Started
Prerequisites
To get started, ensure you have the following installed:
- A C compiler like
gcc makefor building the project- A UNIX-like operating system (Linux/macOS/WSL)
git clone https://github.com/your-username/minitalk.git cd minitalkAfter cloning the repository, run the following command to compile the project:
makeTo start the server, use the following command:
./serverTo send a message from the client to the server, use the following command:
./client <server_pid> <message><server_pid>: The PID of the running server.<message>: The message you want to send.
To remove the compiled files:
make cleanπ‘ Concepts Covered
- Unix signals (SIGUSR1, SIGUSR2)
- Process management and PID handling
- Encoding and decoding messages via binary representation
π Useful Links