  This tutorial paper presents recent work of the authors that extends the
theory of Control Barrier Functions (CBFs) to address practical challenges in
the synthesis of safe controllers for autonomous systems and robots. We present
novel CBFs and methods that handle safety constraints (i) with time and input
constraints under disturbances, (ii) with high-relative degree under
disturbances and input constraints, and (iii) that are affected by adversarial
inputs and sampled-data effects. We then present novel CBFs and adaptation
methods that prevent loss of validity of the CBF, as well as methods to tune
the parameters of the CBF online to reduce conservatism in the system response.
We also address the pointwise-only optimal character of CBF-induced control
inputs by introducing a CBF formulation that accounts for future trajectories,
as well as implementation challenges such as how to preserve safety when using
output feedback control and zero-order-hold control. Finally we consider how to
synthesize non-smooth CBFs when discontinuous inputs and multiple constraints
are present.
