This Node.js application facilitates the construction and transmission of telegram messages over TCP/IP. It consists of two main files: app.js
and server.js
.
The server.js
file acts as a receiver for telegram messages over TCP/IP. It can decode received messages. On the other hand, the app.js
file constructs telegram messages according to a specified format. Users can choose to encrypt/decrypt these messages using XOR encryption .
Encryption and decryption are optional features that users can enable as needed.
-
Clone the repository:
git clone https://github.com/ghassenelkamel/NodeJS-Message-Sender.git
-
Navigate to the project directory:
cd NodeJS-Message-Sender
-
Install dependencies:
npm install
-
Run the server:
node server.js
The server will start listening for incoming telegram messages.
-
Send a message:
node app.js MCR 123456789012345 12345 100 25 100
Replace the arguments with the desired telegram data. The format is as follows:
node app.js
<Identifier>
: Fixed to "MCR"<Distance>
: 64-bit integer in millimeters<Magnitude>
: 32-bit unsigned integer<Phase>
: 8-bit integer<Temperature>
: 32-bit integer in Celsius
video.mp4
This project is licensed under the MIT License.