BB.Error.State.OutsideJointHistory exception (bb v0.33.2)

Copy Markdown View Source

A joint configuration was asked for at a time the history can't answer.

Returned by BB.Robot.State.get_all_configurations_at/2 in two cases, distinguished by direction:

  • :past - the time is older than joint's oldest retained sample, either because it has aged out of the history or because it predates the robot starting. boundary_time is that oldest sample's time.
  • :future - the time is later than now. Nothing can be known about it yet, and the history refuses to extrapolate. joint is nil, since it applies to every joint, and boundary_time is the current monotonic time.

All times are System.monotonic_time(:nanosecond) values.

Summary

Types

t()

@type t() :: %BB.Error.State.OutsideJointHistory{
  __exception__: term(),
  boundary_time: integer(),
  bread_crumbs: term(),
  class: term(),
  direction: :past | :future,
  joint: atom() | nil,
  path: term(),
  requested_time: integer(),
  splode: term(),
  stacktrace: term(),
  vars: term()
}

Functions

exception(args)

@spec exception(opts :: Keyword.t()) :: %BB.Error.State.OutsideJointHistory{
  __exception__: term(),
  boundary_time: term(),
  bread_crumbs: term(),
  class: term(),
  direction: term(),
  joint: term(),
  path: term(),
  requested_time: term(),
  splode: term(),
  stacktrace: term(),
  vars: term()
}

Create an Elixir.BB.Error.State.OutsideJointHistory without raising it.

Keys

  • :direction
  • :joint
  • :requested_time
  • :boundary_time