UpdateIMU module

Houses the UpdateIMU task Class.

class UpdateIMU.UpdateIMU(s_field_heading: Share, i2c)

Bases: object

Task to update a IMU euler angle heading relative to game field.

The IMU must be a BNO055 IMU from BOSCH.

Parameters:
  • s_field_heading (task_share.Share) – Used to convey the romi chassis heading in field-space accorning to the IMU.

  • i2c (machine.I2C) – Preinitialized I2C object to designate the correct communication bus.

run()

Implementation as a generator function.

Raises:

ValueError – invalid state.

Yields:

int – Machine state.