|
|
| 64 |
* variables. During the "Off" state, no traffic is generated. |
64 |
* variables. During the "Off" state, no traffic is generated. |
| 65 |
* During the "On" state, cbr traffic is generated. This cbr traffic is |
65 |
* During the "On" state, cbr traffic is generated. This cbr traffic is |
| 66 |
* characterized by the specified "data rate" and "packet size". |
66 |
* characterized by the specified "data rate" and "packet size". |
|
|
67 |
* |
| 68 |
* Note: When an application is started, the first packet transmission |
| 69 |
* occurs _after_ a delay equal to (packet size/bit rate). Note also, |
| 70 |
* when an application transitions into an off state in between packet |
| 71 |
* transmissions, the remaining time until when the next transmission |
| 72 |
* would have occurred is cached and is used when the application starts |
| 73 |
* up again. Example: packet size = 1000 bits, bit rate = 500 bits/sec. |
| 74 |
* If the application is started at time 3 seconds, the first packet |
| 75 |
* transmission will be scheduled for time 5 seconds (3 + 1000/500) |
| 76 |
* and subsequent transmissions at 2 second intervals. If the above |
| 77 |
* application were instead stopped at time 4 seconds, and restarted at |
| 78 |
* time 5.5 seconds, then the first packet would be sent at time 6.5 seconds, |
| 79 |
* because when it was stopped at 4 seconds, there was only 1 second remaining |
| 80 |
* until the originally scheduled transmission, and this time remaining |
| 81 |
* information is cached and used to schedule the next transmission |
| 82 |
* upon restarting. |
| 67 |
*/ |
83 |
*/ |
| 68 |
class OnOffApplication : public Application |
84 |
class OnOffApplication : public Application |
| 69 |
{ |
85 |
{ |