Documentation
This commit is contained in:
@@ -1,81 +1,90 @@
|
|||||||
@startuml
|
@startuml
|
||||||
interface Sensor {
|
|
||||||
+ {abstract} int Value()
|
|
||||||
}
|
|
||||||
|
|
||||||
class LMSensor {
|
package sensor {
|
||||||
|
interface Sensor {
|
||||||
|
+ {abstract} int Value()
|
||||||
|
}
|
||||||
|
|
||||||
|
class LMSensor {
|
||||||
- string Label
|
- string Label
|
||||||
|
|
||||||
+ int Value()
|
+ int Value()
|
||||||
}
|
}
|
||||||
|
|
||||||
class GPUSensor {
|
class GPUSensor {
|
||||||
+ int Value()
|
+ int Value()
|
||||||
|
}
|
||||||
|
|
||||||
|
class LMSensorsFacade
|
||||||
|
{
|
||||||
|
+ List<Sensor> RPMSensors()
|
||||||
|
+ List<Sensor> TemperatureSensors()
|
||||||
|
}
|
||||||
|
|
||||||
|
class GPUSensorsFacade
|
||||||
|
{
|
||||||
|
+ List<Sensor> TemperatureSensors()
|
||||||
|
}
|
||||||
|
|
||||||
|
class SensorManager
|
||||||
|
{
|
||||||
|
- LMSensorsFacade
|
||||||
|
- GPUSensorsFacade
|
||||||
|
|
||||||
|
+ List<Sensor> RPMSensors()
|
||||||
|
+ List<Sensor> TemperatureSensors()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class HWMONFan {
|
package fan
|
||||||
|
{
|
||||||
|
class HWMONFan {
|
||||||
- string Label
|
- string Label
|
||||||
- Sensor RPMSensor
|
- Sensor RPMSensor
|
||||||
- PWMControl PWMControl
|
- PWMControl PWMControl
|
||||||
|
|
||||||
+ int RPM()
|
+ int RPM()
|
||||||
+ void PWMPercent(int value)
|
+ void PWMPercent(int value)
|
||||||
}
|
}
|
||||||
|
|
||||||
class PWMControl {
|
class FanGenerator
|
||||||
+ void PWMPercent(int value)
|
{
|
||||||
+ int PWM()
|
|
||||||
}
|
|
||||||
|
|
||||||
class PWMControlFacade {
|
|
||||||
+ List<PWMControl> PWMControls()
|
|
||||||
}
|
|
||||||
|
|
||||||
class LMSensorsFacade
|
|
||||||
{
|
|
||||||
+ List<Sensor> RPMSensors()
|
|
||||||
+ List<Sensor> TemperatureSensors()
|
|
||||||
}
|
|
||||||
|
|
||||||
class GPUSensorsFacade
|
|
||||||
{
|
|
||||||
+ List<Sensor> TemperatureSensors()
|
|
||||||
}
|
|
||||||
|
|
||||||
class SensorManager
|
|
||||||
{
|
|
||||||
- LMSensorsFacade
|
|
||||||
- GPUSensorsFacade
|
|
||||||
|
|
||||||
+ List<Sensor> RPMSensors()
|
|
||||||
+ List<Sensor> TemperatureSensors()
|
|
||||||
}
|
|
||||||
|
|
||||||
class FanGenerator
|
|
||||||
{
|
|
||||||
+ FanList FindFans(List<RPMSensor>, List<PWMControl>)
|
+ FanList FindFans(List<RPMSensor>, List<PWMControl>)
|
||||||
}
|
}
|
||||||
|
|
||||||
struct FanStep
|
struct FanStep
|
||||||
{
|
{
|
||||||
int Temp
|
int Temp
|
||||||
int Percent
|
int Percent
|
||||||
}
|
}
|
||||||
|
|
||||||
class FanCurve
|
class FanCurve
|
||||||
{
|
{
|
||||||
- List<FanStep> Steps
|
- List<FanStep> Steps
|
||||||
- List<Sensor> TempSensor
|
- List<Sensor> TempSensor
|
||||||
- List<HWMONFan> Fan
|
- List<HWMONFan> Fan
|
||||||
|
|
||||||
+ DoFanControl()
|
+ DoFanControl()
|
||||||
}
|
}
|
||||||
|
|
||||||
class FanController
|
class FanController
|
||||||
{
|
{
|
||||||
- List<FanCurve>
|
- List<FanCurve>
|
||||||
|
|
||||||
+ void StartFanControlLoop()
|
+ void StartFanControlLoop()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
package pwm
|
||||||
|
{
|
||||||
|
class PWMControl {
|
||||||
|
+ void PWMPercent(int value)
|
||||||
|
+ int PWM()
|
||||||
|
}
|
||||||
|
|
||||||
|
class PWMControlFacade {
|
||||||
|
+ List<PWMControl> PWMControls()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class ConfigManager
|
class ConfigManager
|
||||||
@@ -85,9 +94,9 @@ class ConfigManager
|
|||||||
|
|
||||||
HWMONFan -- Sensor
|
HWMONFan -- Sensor
|
||||||
HWMONFan -- PWMControl
|
HWMONFan -- PWMControl
|
||||||
HWMONFan - FanCurve
|
HWMONFan -- FanCurve
|
||||||
|
|
||||||
PWMControl -- PWMControlFacade
|
PWMControlFacade -- PWMControl
|
||||||
|
|
||||||
Sensor <|-- LMSensor
|
Sensor <|-- LMSensor
|
||||||
Sensor <|-- GPUSensor
|
Sensor <|-- GPUSensor
|
||||||
@@ -99,13 +108,12 @@ GPUSensor -- GPUSensorsFacade
|
|||||||
LMSensorsFacade -- SensorManager
|
LMSensorsFacade -- SensorManager
|
||||||
GPUSensorsFacade -- SensorManager
|
GPUSensorsFacade -- SensorManager
|
||||||
|
|
||||||
FanGenerator - HWMONFan
|
FanGenerator -- HWMONFan
|
||||||
FanGenerator - SensorManager
|
FanGenerator -- SensorManager : uses >
|
||||||
FanGenerator - PWMControl
|
FanGenerator -- PWMControlFacade : uses >
|
||||||
|
|
||||||
Sensor - FanCurve
|
Sensor - FanCurve
|
||||||
FanCurve -- FanStep
|
FanCurve -- FanStep
|
||||||
FanCurve -- SensorAggregateFunction
|
|
||||||
|
|
||||||
FanController -- FanCurve
|
FanCurve -- FanController
|
||||||
@enduml
|
@enduml
|
||||||
|
|||||||
Reference in New Issue
Block a user