Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

161
Views
how to get data from tcp server port and display in html

ı want to get data from tcp port and show data on clientside by Javascript or Angular. ı can list data in console but dont know how to list on client side.

const port = 4000;
const host = '0.0.0.0';
let buffered='';
const client = new Net.Socket();
client.connect({ port: port, host: host }), function() {
    console.log('TCP connection established with the server.');

    client.write('Hello, server.');
};
client.on('data', function(chunk) {
    console.log('rocket name :'+chunk.slice(1,11).toString(),'rocket altitude:'+chunk.slice(13,17).readFloatBE(0)
    ,'rocket speed:'+chunk.slice(17,21).readFloatBE(0)
    ,'Temprature :'+chunk.slice(29,33).readFloatBE(0));


    client.end();
});




client.on('end', function() {
    console.log('Requested an end to the TCP connection');
});


about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!