Skip to content
/ um7 Public
forked from buxit/um7

Python library to interface with CH Robotics UM7 IMU

License

Notifications You must be signed in to change notification settings

philsuth/um7

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

57 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

UM7

Python library to interface with CH Robotics / Redshift Labs UM7 IMU

Provides a class UM7 with the following methods:

  • readreg(start, length=0) to read register values
  • writereg(start, length=0, data=None) to write to registers
  • readpacket() to read and parse incoming packet data from the serial port
  • catchsample() to read and parse incoming data and update the internal state accoringly
  • catchallsamples(wanted_state, timeout) wait at most timeout seconds for new data listed in wanted_state

usage example:

import um7

u = um7.UM7('um7', '/dev/ttyS0', ['health', 'pitch', 'roll', 'yaw'])
print('GET_FW_REVISION=' + u.get_fw_revision())
u.zero_gyros()

u.catchallsamples(['pitch', 'roll', 'yaw'], 0.5)
print('{0[health]:010b} {0[pitch]:8.2f} {0[roll]:8.2f} {0[yaw]:8.2f}'.format(u.state))

About

Python library to interface with CH Robotics UM7 IMU

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%