UDP Programming, Computer Networking

Assignment Help:
I have a larget text file of 1MB, how do i break down into chunks of packets to send over UDP?

byte b[]=new byte[1024];
FileInputStream f=new FileInputStream("input.txt");
DatagramSocket dsoc=new DatagramSocket(2000);
int i=0;
while(f.available()!=0)
{
b[i]=(byte)f.read();
i++;
}
f.close();
dsoc.send(new DatagramPacket(b,i,InetAddress.getLocalHost(),1000));

this doesnt seems to work

Related Discussions:- UDP Programming

What is the mac address, The address for a device as it is recognized at th...

The address for a device as it is recognized at the Media Access Control (MAC) layer in the network architecture. MAC address is usually stored in ROM on the network adapter card a

How is a logical network diagram, Question: a) In relation to network ...

Question: a) In relation to network design, give two reasons why the building-block approach is favoured to the traditional approach. b) Explain the following steps in rela

What are the protocol support tools, What are the Protocol Support Tools ...

What are the Protocol Support Tools The Intranet should support the tools meant for providing various services on the Internet through the protocols. In addition to the convent

Headers and frame format, HEADERS AND FRAME FORMAT:  LAN technology st...

HEADERS AND FRAME FORMAT:  LAN technology standards describe frame format for every technology. All contemporary standards use the following basic format. a) Frame header b

Show the bidirectional transmission, Q. Show the Bidirectional Transmission...

Q. Show the Bidirectional Transmission? Bidirectional Transmission Each party must maintain S and R to track frames sent and expected Piggybacking hooking ACK wit

Shared programming using library routines, Shared Programming Using Library...

Shared Programming Using Library Routines The most well-liked of them is the use of combo function called fork() and join(). Fork() function is used to make a new child proces

Ipv6 packet format - network layer and routing , IPv6 packet Format Th...

IPv6 packet Format The format  of an IPv6 header is shown  in figure. Although IPv6 addresses are four  times  the size  of IPv4 address  the basic  IPv6 header is only twice

Illustrate transport layer responsibilities, Q. Illustrate Transport Layer ...

Q. Illustrate Transport Layer Responsibilities ? - Process-to-process delivery of whole message - Port addressing - Segmentation and reassembly - Connection control co

What is the full form of FDM and TDM, What is the full form of FDM and TDM ...

What is the full form of FDM and TDM It is both. Each of the 100 channels is possess its own frequency band (FDM), and on every channel two logical streams are intermixed by th

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd