RBP Filter README
November 6, 2006

The code in this directory constitutes the first release of the RBP
Filter. The RBP filter provides greatly improved reliability for
flooding. It does so by keeping track of how well neighbors propagate
a broadcast. If not enough neighbors propagate a broadcast, RBP will
do up to three retries. The neighbor thresholds and number of retries
are dependent on local density. The less dense a neighborhood is,
the harder RBP tries to propagate the broadcast. Nodes which have only
one upstream neighbor will inform that neighbor that an "important
link" exists between the two nodes. When a broadcast does not 
propagate across an important link, up to three retries will
be made.

The implementation of RBP represented by this code resides between the
MAC and routing layers.  Although RBP could be ported into a number of
protocol stacks, it has only been tested in one specific stack that is
put together with the EmStar framework (http://cvs.cens.ucla.edu/emstar).
Here are the elements that make up the stack:

Application Layer
RRD filter
One Phase Pull Diffusion filter
Diffusion Filter Core
EmStar blacklist module
EmStar neighbors module
EmStar linkstats module
EmStar motenic
EmStar hostmote
BMAC

Major Caveats:

If you do not run the RBP filter with the neighbors and blacklist modules,
then you will need to provide your own neighbor service. RBP only works
when it knows who its neighbors are. Nodes with marginal or asymmetric
connectivity should not be included in a neighbor set.

The default error model in EmSim (the EmStar simulator) did not support the
modelling of transmit errors at the time RBP was developed. We therefore added
transmit errors to the EmSim error model. UCLA has since added transmit errors
to the released version of EmSim. Please consult <emstar-design@cens.ucla.edu>
for information. Without transmit errors you will not get coherence between
simulation and testbed environments.

Sample emruntab file:

#
#  rrddefaulttab
#     emruntab for RBP over one_phase_pull creates the stack:
#     rrd<->one_phase_pull<->filter_core<->
#     blacklistd<->neighbord<->linkstats<->motenic<->hostmote
#     Application code (source or sink) is not included in this example.
#     The include files are part of the emstar release

include link/link.run
include mote/mote.run

&mote_hostmote(/dev/ttyS0,mica2,0);
&mote_motenic(mote0,0,show="leds");
&link_linkstats(mote0,ls0,show="leds:core");
&link_neighbors(ls0);
&link_blacklist(ls0,bl0,ls0,args="-b 70 -g 80");

process filter_core {
  waitfor = bl0;
  type = once;
  noclean;
  cmd = "link/diffusion/filter_core";
}

process one_phase_pull {
  type = once;
  noclean;
  cmd = "link/diffusion/one_phase_pull";
}

process rrd {
  type = once;
  noclean;
  cmd = "link/diffusion/rrd";
}

#     Application code would be started here.

Thanks,
Fred Stann
