pibootctl.info¶
The pibootctl.info
module contains some simple routines for determining
information about the Pi that the application is running on.
- pibootctl.info.get_board_revision()[source]¶
Return the Pi’s board revision as an unsigned 32-bit integer number. This is the same number as reported under “Revision” in
/proc/cpuinfo
.
- pibootctl.info.get_board_serial()[source]¶
Return the Pi’s serial number as an unsigned 64-bit integer number. This can also be queried as “Serial” under
/proc/cpuinfo
.
- pibootctl.info.get_board_type()[source]¶
Return a string indicating the overall model of the Pi, e.g. “pi0w”, “pi2”, or “pi3+”. This is derived from the result of
get_board_revision()
according to the Pi’s revision codes table.
- pibootctl.info.get_board_types()[source]¶
Return a set of strings used for matching the model of Pi against configuration sections according to the conditional filters table.
- pibootctl.info.get_board_mem()[source]¶
Return the amount of memory (in megabytes) present on the Pi, according to the model returned by
get_board_revision()
.