 So, we now have the numbers, I have brought them here, so just take a look at this number, so what we have is suppose we are using a 802.11b system which is 11 Mbps, so that implies that approximately in 1 microsecond you are going to transfer 11 bits, and we are using a G711 voice codec which samples at the rate of 64 kbps every 20 milliseconds, so now 64 kbps every 20 milliseconds translates to 160 bytes per packet, so what this basically means is that the voice codec is going to generate a 160 byte packet every 20 milliseconds in order to establish the voice call. And now, so in 1 second how many such packets are going to be generated, 50 packets in each direction, so there are going to be 50 packets in going from the client to the other end and 50 packets coming in the reverse direction as well, so this is the total number of packets that have to be fitted in in 1 second of the 11 Mbps channel, so I have also found out the numbers for the various headers, RTP header is 12 bytes, UDP header is 8 bytes, IP header is 20 bytes, MAC header is 34 bytes, PHY header is typically not calculated in bytes, but in microseconds, so the PHY header for 11 Mbps is 96 microseconds, the act size is 14 bytes. So, now we need to calculate how many calls can be supported, so the way you want to do this is you want to find out how much how many bits does one call correspond to, so try to go back and forth between bits and microseconds because SFS time is 20 microseconds, 20 microseconds again now corresponds to certain number of bits, so if you keep going back and forth you will be able to find out. So, you have a void packet which is coming in, it is going to wait for DIFS amount of time, then there may be a back off, then the data has to go, ignoring RTSCTS overhead, if we add the RTSCTS it is going to become worse, but generally for voice you will not do RTSCTS because you are never going to do retransmission on this, so ignoring the RTSCTS, so you will have the data that it goes out again another SFS, then an act that has to come. So, then we will see how big does that packet become and how many such things can fit in a 11 Mbps system, so let us go stepwise, I have actually lost the sheet on which I had the answers, so just to be alert to see if I am making any errors here. So, first you want to see the number of bits per void packet. So, we want to find out what is the total, what is the number of bits that go for each void packet, how much is that, that will be DIFS plus back off, because you are always going to have packets in the queue. So, you cannot assume that there is no back off, like we were talking before lunch that the access point is always going to have to do some back off, DIFS plus back off plus data plus SIFS plus AC, this is what is going to be the number of bits, now DIFS is 50 microseconds plus back off you will have to now assume a certain number of slots. So, the total value that we come to depends upon what is the value of back off that we are going to assume. So, let us say we are assuming a back off value of 7, is that okay? 7 sounds reasonable, so 7 has the back off value, 7 into 20, slot time is 20 microseconds, so 7 into 20 microseconds. So, this is in microseconds, so just we have to be a bit careful since we are going back and forth between bits and seconds, so what is the data now? Data was we had 1 to 8 0 bits per packet, so we had 1 to 8 0 bits plus SIFS was 10 microseconds plus AC is 112 bits, so now if we convert this thing entirely into bits what we will get is for how much is 1 microsecond, 1 microsecond kind of corresponds to 11 bits, so this will be 550 bits plus 1, what is this 140 into 11 correct, 1 5 4 0, okay, plus 1 2 8 0 plus headers right, how much is that 1 2 8 0 plus 592 1 0 5 6 right plus 10 right 110 plus 112 correct, so this turns out to be 6 5 2 0, now how many such packets have to fit in a second? Yeah, number of wipe packets, number of wipe packets per second is 50 into 2 right, 50 into 2 packets is what we are going to be having per second which is 100 packets okay, so correct per second per call, so what does that mean? That means number of bits per wipe call 6 5 2 0 0 0, so this is 0.65 megabits right, so what is the number of calls that we can do okay, in a 11 Mbps system you have 11 megabits is what you have, each guy is going to occupy 0.65 correct, so what does this turn out to be roughly around 18 okay, so what is the key here? How can this increase? This can increase if this slots that we are assuming for the back off increases correct, if you are going to assume one slot back off then you can have higher number of calls but that is not a realistic assumption, typically you have to assume some average, we have a large number of calls in your system, you have to take some average and if you are taking a window of 0 to 15 then 7 would be about the average number of slots that you have to back off, so this is what you get for a 11 Mbps system okay, so if it is a 54 Mbps system automatically this number changes right and if it is a 822.11e system then this number changes but most of the other numbers are going to remain the same okay, if you are using a different codec then again the data number of bits that you have for the data is going to change, so basically 1208 0 bits is useful data and what we are actually being forced to spend is 6520 bits that is the real killer in your Wi-Fi system okay, so what are the things that we have not taken into account here, so if you had a way of compressing all these headers and making it very efficient then you could decrease it but if you keep on doing it then you will reach a GSM like system where you will give a identification number, you will give a connection ID, so when we talk about Ymax later on today we will find that we do away with all these headers okay, because Ymax is was invented after people learnt about 822.11e and all that okay, so Ymax is that okay let me not have all these headers, let me have a connection identifier, the moment I have a connection identifier I just use the connection identifier in my MAC header itself straight away okay, so all these RTP headers UDP headers can be gotten rid of, so that is the summary of 822.11 which is kind of the most important standard or technology to be studied since the past few years and for the next few years okay, so now let us go on to other topics okay, is everybody woken up alright, so let us go on to other topics where we talk about how does the routing happen, now that there is mobility we want to now try to figure out how to do routing okay, so the key motivation is that the traditional routing is based on IP addresses okay, but that is not useful for me because if I want to change IP address each time a mobile node moves from here to there I do not want to go through the trouble of having to change the IP address every time right, things are going to break and so on, so that is not a good solution basically that is what this slide is summarizing okay, so what other ways are there in which I could attempt, so one attempt is you know I could change entries in the routing table, in the router itself I can say that okay such and such IP address which was here as part of your subnet has now moved into another router subnet right, I could change routing table entries that again is not a good solution because it will not scale right, I have to keep going into the router and keeping on changing the number of entries okay, so our requirement now is that we want a solution which retains the same IP address as far as the host is concerned okay and it has to be able to work in a transparent manner okay, so this is, so the problem is like this, I have a source which is sending data through a router to a mobile node okay, now the mobile node is going to move to another network and I want this communication to continue okay, so that is the requirement, how do we solve this, yeah I have to redirect but let's do it step by step, if we jump ahead then we will skip some steps and our solution won't work okay, so what is the first thing that I need okay, so let me just click one more time, this is basically what we want to show happening right, we have a mobile node which moves from one network into the other network and we want to make such a thing happen okay, so what are the key things that we need in our solution, so again let's ask questions okay okay, how does mobile node right, mobile node IP, mobile IP uses MN as the terminology, how does mobile node get access in the new network, this is the first question that you want to ask okay, let's not try to answer any questions, let's list down the questions first, what is the next question you want to ask, let's say we figure this out, then so the second question that you want to ask is how does mobile node inform the old network okay, which is called its home of its new location, then third question is how do I forward the packets okay, how do the networks and the mobile node forward the packets in each direction, once you ask the correct question the answer is obvious right, so you ask the questions now, are there any more questions to ask, these are the three main ones that we need to ask okay, now let's figure out the answers, how does the mobile node get access in the new network, so basically in order to get access, so if you break this down into further steps, how does it get access to the new network is basically how does it know, what we are saying is how does mobile node know about what is called the foreign agent okay, foreign agent is the router which is going to help it to do all these things correct, how does the mobile node know about the foreign agent that guy has to do some advertisement, so the first step is any router which is mobile IP capable has to keep sending out advertisements, it's just like Beacons that we talked about in JSM right, it has to keep sending out advertisements saying that I am a mobile IP capable router, then it has to do what is called registration okay, so the next question is how does the mobile node talk to the foreign agent, I have heard about the foreign agent as through the advertisement, I have heard about the foreign agent through the advertisement and now I need to figure out how to talk to the foreign agent okay, so in that case I am going to be able to I am going to have to send some packet to the foreign agent in order to get access okay, then what happens, the next question is how does it get, how does it inform its home network about the new location correct, there has to be a link between the, so this is again called registration, so I am going to do a registration through the foreign agent with home agent through the foreign agent, so what will I inform now, I am going to say that I was such and such IP address registered in the home network, now I have moved to this foreign network and this is the new IP address which has been assigned to me correct, that's basically what I am going to say as my registration message and then how do the networks forward packets in each direction, this is a process called tunneling okay, sometimes there are two L's in it, sometimes there is one L in it depending on which system you are following right, what is tunneling basically, yeah, it's encapsulation, it's like taking a envelope, putting it into another envelope and putting it back out into the postal system okay, so you write a different address on the envelope but primarily you are using the same system, same postal mechanism you are using, you take one envelope, you received it, you took a new one, put this into that, write a new address and send it out into the same system, once it reaches the other end, you remove the first envelope to get back the original envelope okay, so the question is that why is it the reverse of what happens in boot P where the responsibility is that of the person who comes into the network to look for a somebody who is going to assign a dynamic address right, so actually mobile IP has a lot of variants, so I am just trying to do one basic variant here, there is a variant of mobile IP in which the router will not send out the advertisement but it is the responsibility of the mobile node which upon getting into a new network has to send a query okay, so it will send a query into the network saying is there a mobile IP enabled router here and then the router has to reply to that, so there are like umpteen variations of mobile IP, so what I am trying to get across here is that it's all very straightforward if you know what are the steps that we need to follow okay, so if you look at the terminology you have mobile node and you have a home agent correct, mobile node is a node that moves across networks, home agent is the host in the home network typically router it registers the location of the mobile node tunnels packets to the care of agent, care of agent is also the foreign agent okay, foreign agent is the host in the foreign network, forwards the tunnel packets to the mobile node, care of address is the current address of the mobile node okay, let us look at a figure, so this is basically what is happening okay, so CN stands for correspondent node, CN is going to send data to the mobile node, does the correspondent node need to know that this guy has moved and all? No right, the correspondent node does not need to know that he has moved, so he sends data to the original network itself, this home agent captures this packet puts it in another envelope which is this red thing that you see here okay, puts it in another envelope tunnels that packet to the foreign agent, now the foreign agent is going to remove the encapsulation and get back the original packet which is then sent on to the mobile node okay, so it's a very straightforward system if we look at it at this abstract level, we go down one more level deeper then we will start seeing some intricacies okay, so sender sends to the IP address of the mobile node, the home agent intercepts the packet, home agent tunnels the packet to the care of agent okay, in this case the care of agent is the foreign agent and then the foreign agent forwards the packet to the mobile node okay, who is doing proxy ARP? What is proxy ARP? See now if we start asking some more deeper questions here then we will find all the answers right, so what is what I what do I need to know? Suppose somebody is trying to connect to this mobile node for the first time okay, think of what happens in this network okay, now there may be a node in this network which is also trying to connect to your same mobile node okay, what happens to that guy right, so think of it like this, there is a node here, there is another node here, this guy is trying to connect to that guy right, one node is trying to connect to the other node, it doesn't know that the other node has moved away okay, so what is the first step that this node is going to take? It's going to send a R request to get the MAC ID correct, so it's going to make an R request to get the MAC ID as a result of which but that IP address is not there and this network anymore right, so the home agent has to keep track of all the fellows who have gone out and it has to give its own MAC address as the corresponding IP address that is what is called proxy ARP okay, so the home agent has to fool other people in the network as though it is the mobile node, it has to give the proxy ARP reply to the mobile node that thereby capturing the packets and then it will tunnel the packets correct okay, what else, so how does data transfer happen from the mobile node is that the mobile node can now send the packet directly to the corresponding node, so this is the basic operation first you have an agent advertisement, so I am just going to do the simple part and then I will ask a question okay, so first you have the agent advertisement where the home agent, foreign agents periodically send advertisement messages into their physical subnets right, mobile node listens to these messages and detects if it is in the home or the foreign network correct, then the mobile node reads a care of address, what is the care of address, it is a temporary IP address okay, it is a temporary IP address which you are given in the new network, so it reads the care of address from the foreign agent advertisement message okay, then the mobile node registers, it sends the care of address to the home agent, home agent does an acknowledgement okay, okay let us not worry about security at this point and then you have the home agent advertises the IP address and it does a proxy, finally the home agent tunnels the packets to the mobile node okay, so that is the question, that is the next question that you have to ask right, so suppose the firewalls are going to permit only topologically correct addresses, then what do I do okay, then I have to send it back to the home agent and let the home agent send it to the correspondent node okay, then there are other optimizations which are called triangular routing, you know informing the correspondent node and all that okay, so let us do an example like this, now suppose there are two mobile nodes okay, let us say two mobile hosts mh1 and mh2 okay and therefore home agents okay, HA1 and HA2 okay, let us say this is given, we have two networks, two mobile nodes and they are home agents okay, so now mh1 is in its home network, mh2 is in a foreign network, now suppose mh1 initiates data transfer with mh2, what is the path of the packets okay, just talk to each other, make each other up and just try to determine this answer, mh2 being in a foreign network does not necessarily mean it is in HA1, it could be in any network okay, let us see if we can get this okay, so what do you have, you have network 1 okay, this is network 1, let us say this is mobile host mh1 and then let us say there is HA1 in my network 1 okay, let us say this network is connected to okay network 2 where you have HA2 correct and let us say this guy has moved off to a third network okay and here is where the mh2 has moved correct, mh1 is in a, in its home network with HA1 right and mh2 has moved into a foreign network, so let us say this guy is called FA2 okay, let us not complicate things by making the same HA and FA okay, so this is called FA2 right, so FA2 may turn out to be the same as HA1 it does not matter okay, so we can consider them as different as far as we are concerned okay, so what is the path of the packets, so mh1 what are we doing mh1 is initiating the data transfer right, so mh1 will it go to HA1 or not, depends if HA1 is the router then it will go to HA1, if HA1 is not the router then it need not go to HA1 right, it has to go through the router for that network okay, so if HA1 is the router it will go to HA1 right and then it will go to HA2 okay, HA2 is going to tunnel it, tunnel it to FA2 right, is that making sense, FA2 will decapsulate it and send it on to mh2 okay, so this is tunnel and this is decapsulation, so HA2 will do the encapsulation and FA2 will do the decapsulation okay, is that fine fairly straightforward action that is happening okay, so question is how often should mobile node keep on updating the home network about its changing position, whenever it changes the same thing happens right, it is always a tradeoff you have to play the tradeoff, so two options are there I can update it every time I move to a new network or I can leave what is called the forwarding pointer right, I do not update the new network suppose I move from FA2 to let us say another FA3 instead of updating the home network I can just leave a forwarding pointer and let the packets come chasing behind me okay, that is a possibility but typically what will happen in a typical mobile IP implementation is that this registration has a lifetime, see when you are updating the home network that is called registration, so there is a registration lifetime associated with it, so before the expiry of the registration lifetime a new registration request has to come that is the basic principle okay, so what is the kind of information the home agent is maintaining can we try to draw okay, so let us say mobile MH1 has an IP address okay, so let us try to do this with IP address let us say this is 10, 129, 1.1 okay and let us say this guy was this guy is 10, 105.2 okay, this was MH2's original IP address okay and this network is 10 let us say 10.8 dot it is a 10.8 network okay, so what will happen now, so the MH2's original IP address is 10.100.5.2 correct, now when it arrives in a 10.8 network this foreign agent has got to do a mapping or it has to assign an IP address to the mobile host okay, so this guy will assign an IP address like of the form 10.8.13.5 something right, so this is my IP address this is what is your care of address okay, so often the foreign agent will just assign its own IP address as a care of address it does not matter because it is going to do the decapsulation okay, so what is the table the foreign agent is maintaining foreign agent has to maintain this table saying for a visitor called 10.100.5.2 I have assigned the IP address 10.8.13.5 correct, so there is a table which is to be maintained by the foreign agent, now once the MH2 is doing the registration with the home agent the home agent is also going to maintain a similar table right, with the entries reversed it is going to say that actually the same entries 10.100.5.2 is going to map it to 10.8.13.5 okay, so now what is going to happen when I am doing the encapsulation, so the packet that I am getting this is the source IP right and this is the destination IP okay in the packet that I am receiving the source IP is that of MH1 the destination IP is that of MH2 original IP address of MH2 correct, so the first thing that the home agent is going to do is it is going to look up this table it is going to see that this node has moved to this area new IP address, so it is going to create another packet, so what is going to be the IP address that goes across the tunnel it is going to be the home agent as the source and the foreign agent as the destination okay, so the home agent at the as the source and the foreign agent as the destination, so that is how the tunnel is going to happen and then at the foreign agent it is again going to look it up saying that okay I have received a packet for this guy 10.8.13.5 and that actually maps to 10.100.5.2 and it will just deliver it to the mobile host, so okay in this case I have not given it a proper router looking address okay 13.1 if we give okay it would be a routers address, the care of address could be a routers address and the router can just keep a mapping at the socket level right it can just say that you know this address on this port number I am giving it to that particular machine okay so that is possible okay let us do one more step of this exercise before we go on to the next topic, so the next question is okay what is the path taken by MH1 now moves to a foreign network okay what happens when MH1 now moves to a foreign network okay, so this is the data transfer that is going on now MH1 also moves to some other foreign network okay let us see how that works you had MH1 HA1 right this was connected through HA2 okay and this guy had moved off to FA2 and you had MH2 right now we are saying that MH2 MH1 is moving off to some other network with FA1 okay so let us say this guy has moved off to a new network here okay so what is the path that it will take to go from MH1 to FA1 to HA1 or HA2 okay so let me just leave it as HA1 or HA2 here okay that we need to figure that out and then once it reaches HA2 things are straightforward right HA2 to FA2 to MH2 correct so now the question is does it go to HA1 or does it go to HA2 why okay let us say it goes to HA1 okay in what case will it go to HA1 if it is a router then correct so if it is a router see what happens is now this guy has got a new address here right so if the so if there is a firewall let us say you know where would I draw a firewall now okay so let us say here we have a firewall after this FA1 okay this says that okay I need to send I cannot have any arbitrary looking address that comes out of here okay so this has a what was the address that we gave to that guy 10.129.1.1 okay so let us say so this has a 10.129.1.1 okay this is its original address and here under the foreign network let us say it gets some other IP address 10.5.5.5 okay so suppose this foreign network has a firewall here which says that only 10.5 packets can go out okay what is this 10.129 packet doing here and it drops the packet then you cannot go directly to HA2 okay so then what you have to do is you have to do a tunnel here you have to tunnel from FA1 to FA2 to HA1 okay and then HA1 will have to decapsulate it and forward it forward it on to HA2 is it making sense what I am saying if on the other hand you do not have a firewall here then you can just let this packet go directly to HA2 see remember the important thing is the socket is already established the socket is already established between 10.129 and 10.100.5.2 right so this is 10.100.5.2 okay so if either of these machines at the socket level see any other IP address they are going to break the connection the connection is going to break right so neither MH1 nor MH2 should really see at the IP level below IP you have to be able to do that below the socket level so below TCP or below UDP before you have the socket that is where you have to ensure that this is the IP address that the node has got right so if you send a packet with 10.129.1.1 going out of a 10.5 network sometimes the firewall will be configured to say that this is an invalid packet okay so it may drop the packet so in which case what you have to do is you have to take a 10.5.5 address as your source and send the packet so that it goes out of the firewall is that being sense now if I send it directly with a 10.5.5 address to this guy this chap is going to get confused who is this new guy who's talking to me right so that's why I may sometimes have to send the packet home and send it from the home so that the other node does not get confused as to where the packet is coming from all right any other questions on mobile IP now there are a lot of intricacies on you know how the advertisement happens how the registration happens what we do in case of security and all that so I am just going to happily skip all of it okay the internet provided using mobile IP now no okay mobile IP is used in very specific instances when you have let's say a building combined with wireless it is sometimes used no when you have a building in which wireless is deployed you know I start a download on my laptop I carry it from here I go to some other place okay so at that time the packets have to be forwarded to me so sometimes you can use it for that otherwise you know you never use it on an internet scale see whenever you are going to shut down your machine and restart it you don't need mobile IP because you can re-establish all your sockets it's only when there is any ongoing so okay communication that you need something like mobile IP okay as far as hardware configuration is concerned of a normal router versus a mobile IP router okay what is the difference the router has to be able to send out advertisements okay so a normal router also sends out router advertisements same router advertisement message if you can add something to it that becomes a mobile IP advertisement okay so very little change is required to the router okay instead of tunneling can I not change the source address so let's see what we are trying to do is we are trying to send this as a tunnel I could change the source address but then again if the home agent is not the same as the router then the router will block it the firewall will block it correct and secondly in order to change the it kind of breaks the encapsulation philosophy right I mean I am going into a packet changing it so it's it's preferred to just put it into another packet so technically yes it is possible but it's not done right okay so we'll take a break before the break let me just tell you what is left okay so what we have left to do is TCP how many of you are familiar with TCP okay few of you okay so we have to do a little bit of how TCP works how TCP works over wireless okay we'll do a little bit of how ad hoc networks work and then Ymax okay so that's kind of what I've planned for the rest of the time okay it's a bit early to take the break but then I'll still let you off okay