cputemp

package
v0.0.0-...-c936f35 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 18, 2024 License: Apache-2.0 Imports: 1 Imported by: 19

Documentation

Overview

Package cputemp implements an i3bar module that shows the CPU temperature.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Module

type Module = temperature.Module

Module represents a cputemp bar module. It supports setting the output format, click handler, update frequency, and urgency/colour functions.

func New

func New() *Module

New constructs an instance of the cputemp module for zone type "x86_pkg_temp". Returns nil of the x86_pkg_temp thermal zone is unavailable.

func OfType

func OfType(typ string) *Module

OfType constructs an instance of the cputemp module for the *first* available sensor of the given type. "x86_pkg_temp" usually represents the temperature of the actual CPU package, while others may be available depending on the system, e.g. "iwlwifi" for wifi, or "acpitz" for the motherboard.

func Zone

func Zone(thermalZone string) *Module

Zone constructs an instance of the cputemp module for the specified zone. The file /sys/class/thermal/<zone>/temp should return cpu temp in 1/1000 deg C.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL