brainaccess.core.version#

Classes#

Version

A version number: major, minor and patch.

Functions#

is_version_compatible(expected, actual)

Check whether two versions are compatible.

Module Contents#

class brainaccess.core.version.Version(major, minor, patch)[source]#

Bases: ctypes.Structure

A version number: major, minor and patch.

Returned by brainaccess.core.get_version() and as the hardware and firmware versions in DeviceInfo. Printing it gives major.minor.patch.

Variables:
  • major (int) – Major version; changes when the interface changes incompatibly.

  • minor (int) – Minor version; changes when functionality is added.

  • patch (int) – Patch version; changes for bug fixes.

major[source]#
minor[source]#
patch[source]#
brainaccess.core.version.is_version_compatible(expected, actual)[source]#

Check whether two versions are compatible.

Versions are compatible if their major and minor numbers are the same; the patch number is ignored.

Parameters:
  • expected (Version) – The required version.

  • actual (Version) – The version to check.

Returns:

True if the versions are compatible.

Return type:

bool