Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4026276
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T10:57:00+00:00 2026-05-20T10:57:00+00:00

Hello i have made a program for my old windows mobile phone to send

  • 0

Hello i have made a program for my old windows mobile phone to send gps data ,temperature etc every 5 seconds just for experimental reasons to create a fleet management system.

I noticed that within one hour 350kb were consumed although i sent only 20kb of data…

As i dont have deep knowledge in networks ,how much does a tcp connection cost in bytes?

Maybe i should keep the socket alive because i close and open it every 5 seconds.Would that save bytes?

Also does MTU matter here?
Any other idea to reduce the overhead?
thank you

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T10:57:01+00:00Added an answer on May 20, 2026 at 10:57 am

    Let’s do some math here.

    Every 5 seconds is 720 connections per hour plus data. 20K / 720 is about 28 bytes of payload (your GPS data) for each connection.

    IP and TCP headers along are 48 bytes in addition to whatever data is being sent.
    
    3-way handshake connection: 3 packets (2 out, 1 in) == 96 bytes out and 48 bytes in
    Outbound Data-packet: 48+28 bytes == 76 bytes (out)
    Inbound Ack: 48 bytes (in)
    Close: 48 bytes (out)
    Final Ack: 48 bytes (in)
    
    Total out per connection: 220
    Total in per connection:  144
    Total data send/received per connection: 220+144 = 364
    Total data usage in one hour = 364 * 720 = 262K
    

    So I’m in the ballpark of your data usage estimates.

    If you’re looking to reduce bandwidth usage, here’s three ideas:

    1. Scale back on your update rate.

    2. Don’t tear down the socket connection each time. Just keep it open.

    3. Given your GPS coordinates are periodically updated, you could consider using UDP instead of TCP. There’s potential for packet loss, but given you’re retransmitting fresher data every 5 seconds anyway, an update getting lost isn’t worth the bandwidth to retransmit. IP and UDP headers combined are only 28 bytes with no “connection” overhead.

    UPDATE

    When I originally posted this, I erroneously misunderstood the connection close to be a single exchange of FIN packets between client and server. In practice, the client sends a FIN as part of it initiating the CLOSE. Then server ACKs the FIN. Then the server sends its own FIN that is ACK’d by the client. In other words, an additional 96 bytes per connection. Redoing our math:

    Total data send/received per connection =
    220+48 + 144+48 = 460
    Total data usage in one hour = 460 * 720 = 331K
    

    So my revised estimate of 331KB in one hour is a bit closer to what the OP saw.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have made a program in Java which is used to collect medical data
If I have data in the following format id subid text 1 1 Hello
I have a file called hellowf.cs class MyFirstApp { static void Main() { System.Windows.Forms.MessageBox.Show(Hello,
I have been playing around with Template functions, and made a little logger program.
I started a little fun project - collecting a hello World-program for every letter
Hello I have the following error by git-fsck, which cannot be cleaned by git-gc
Hello we have an SQL server application running over a low bandwith connection. We
Hello I have a number of crystal reports in my VS2008 project. I am
I have done this: $ z() { echo 'hello world'; } How do I
Imagine I have the following: inFile = /adda/adas/sdas/hello.txt # that instruction give me hello.txt

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.