Changes between Version 18 and Version 19 of Tutorials/g0WmLTE/Tutorial2


Ignore:
Timestamp:
Jul 5, 2012, 3:55:09 PM (12 years ago)
Author:
jeffrabi
Comment:

No More Cheating :P

Legend:

Unmodified
Added
Removed
Modified
  • Tutorials/g0WmLTE/Tutorial2

    v18 v19  
    7070defGroup('first_node', 'node1-1.sb4.orbit-lab.org') do |node|
    7171  node.net.x0.profile = '51'
     72  node.net.x0.ip = '10.41.14.1'
     73  node.net.x0.netmask = '255.255.0.0'
     74  node.net.x0.up
    7275  node.addApplication("test:app:wimaxcu_app") do |app|
    7376    app.measure('status_link')
     
    7982 * As those familiar with ''Ruby'' will note, this method receives additional instructions from a block. Here, ''node'' is a dummy variable referring to the group itself, although the exact behavior of ''Ruby'' blocks is outside the scope (pun intended) of this discussion.
    8083
    81 Here, ''net.x0.profile'' configures the WiMAX network profile default as 51.
     84 * Here, ''net.x0.profile'' configures the WiMAX network profile default as 51. The node will prefer this network when searching for available connections.
     85
     86 * ''net.x0.ip'', ''net.x0.netmask',, and ''net.x0.up'' all perform the eponymous ''ifconfig'' operations.
    8287
    8388''addApplication'' gives a group instructions to use the defined application in the specified manner. The principle parameter is the URI of the predefined application.
     
    105110
    106111Here, ''app.measure'' is interesting because it is only one of the possible measurements that can be taken by the iperf app. For the others, see the ''iperf.rb'' code.
    107 
    108 {{{
    109 #!ruby
    110   node.exec('ifconfig', ['wmx0 10.41.14.1 netmask 255.255.0.0 up'])
    111 }}}
    112 
    113 ''node.exec'' launches a program from the terminal. Specifically, this execution launches ifconfig and configure the WiMAX card manually. This is a useful demonstration of how to 'force' certain behavior from the nodes.
    114112----
    115113== Launch Experiment ==