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

C-band earth station , Normal 0 false false false EN-US...

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Task of changing the ip address, 1. Bob has been given the task of changing...

1. Bob has been given the task of changing the IP address and enabling telnet access on a CISCO 2950 enterprise switch. The current IP address is 10.10.10.2/8 the new IP address

Network design by detailing infrastructure, i have an assigment due and wan...

i have an assigment due and want some one to do my assognment

Define metropolitan area network, Q. Define Metropolitan Area Network? ...

Q. Define Metropolitan Area Network? Metropolitan Area Network (MAN) Cable Network Architecture: Overview Protocols and Standards - Set of regulations that go

Determine the term- web server and webmaster, Determine the term- Web Serve...

Determine the term- Web Server and Webmaster Web Server: A host computer that stores Web pages and responds to requests for viewing. Web servers communicate with Web browse

Explain priority and reservation of token passing, Priority and Reservation...

Priority and Reservation Higher priority stations may possibly access the token sooner Each station has a priority code Since token passes by station waiting to t

Different types of subnet classfull networks are present, How many dissimil...

How many dissimilar types of subnet classful networks are present?

Verify vlans and trunking - ccna, Verify VLANs and trunking. Use the sh...

Verify VLANs and trunking. Use the show ip interface trunk command on S1 and the show vlan command on S2 to determine that the switches are trunking correctly and the proper VL

Routing algorithms, compare routing algorithms with non adaptive algorithms...

compare routing algorithms with non adaptive algorithms

Explain the cost of a path between two nodes, Explain the cost of a path be...

Explain the cost of a path between two nodes Given a network of nodes linked by bidirectional links, where every link has a cost associated with it in each direction, explain t

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