This commit is contained in:
Jozef Šimko 2022-05-20 15:38:52 +02:00
parent e9e8a5cc1e
commit 3fc37a23b7

View File

@ -20,21 +20,36 @@ Implemented and tested on:
| Windows | Windows 10.0.19043 | gcc version 11.2.0 (MinGW-W64 x86_64-posix-seh) | | Windows | Windows 10.0.19043 | gcc version 11.2.0 (MinGW-W64 x86_64-posix-seh) |
| Raspberry Pi | Linux raspberrypi 5.10.17 | gcc version 8.3.0 (Raspbian 8.3.0-6+rpi1) | | Raspberry Pi | Linux raspberrypi 5.10.17 | gcc version 8.3.0 (Raspbian 8.3.0-6+rpi1) |
### LINUX #### LINUX
* CLIENT - `gcc client.c -Wall -Werror -Wextra -o client`
* SERVER - `gcc server.c rs232.c -Wall -Werroe -Wextra -o client`
### WINDOWS #### WINDOWS
* CLIENT - `gcc client.c -Wall -Wextra -lwsock32 -o client`
* SERVER - `gcc server.c rs232.c -lwsock32 -Wall -Werror -Wextra -o client`
## Launch ## Launch
### Server #### Server
Program *serveru* je po kompilácii možné spustiť v 2 režimoch: Server can be launched with 1 or 2 input parameters. The number of parameters determines what mode will be used - manual or automatic mode.
* manuálny režim (./server port)
* automatický režim (./server port config_file)
### Client **port** -
### Demo
**config_file** -
* Manual mode - server waits for input commands from client, sends them to laser sensor and returns results back to client
`./server <port>`
* Automatic mode - server loads variables from configuration file *config.txt*, starts measuring and sends results to client continuously.
`./server <port> [config_file]`
#### Client
Client has to be lauched with 2 input parameters.
**IP address** -
**port** -
#### Demo
## References ## References
[WinLibs GCC](https://winlibs.com) [WinLibs GCC](https://winlibs.com)
[RS-232 library](https://www.teuniz.net/RS-232/)