mirror of
https://github.com/Ralim/IronOS.git
synced 2025-02-26 07:53:55 +00:00
Temperature code updates (#1814)
* Create a typedef for temperatures * Quick parse replace temp types * Fixup for fast/slow PWM on PinecilV2 * Update PIDThread.cpp * Pinecil small tips need less smoothing * Remove incorrect comment * Remove unused function * Update PinecilV2 Tune as well
This commit is contained in:
10
source/Core/Inc/Types.h
Normal file
10
source/Core/Inc/Types.h
Normal file
@@ -0,0 +1,10 @@
|
||||
#ifndef TYPES_H_
|
||||
#define TYPES_H_
|
||||
#include <stddef.h>
|
||||
|
||||
// Used for temperature represented in C or x10C.
|
||||
//
|
||||
|
||||
typedef int32_t TemperatureType_t;
|
||||
|
||||
#endif
|
||||
@@ -2,10 +2,11 @@
|
||||
#define __MAIN_H
|
||||
#include "OLED.hpp"
|
||||
#include "Setup.h"
|
||||
#include "Types.h"
|
||||
#include <stdint.h>
|
||||
extern volatile uint32_t currentTempTargetDegC;
|
||||
extern bool settingsWereReset;
|
||||
extern bool usb_pd_available;
|
||||
extern volatile TemperatureType_t currentTempTargetDegC;
|
||||
extern bool settingsWereReset;
|
||||
extern bool usb_pd_available;
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
@@ -23,7 +23,6 @@ const uint8_t wattHistoryFilter = 24; //
|
||||
extern expMovingAverage<uint32_t, wattHistoryFilter> x10WattHistory;
|
||||
|
||||
uint32_t availableW10(uint8_t sample);
|
||||
int32_t tempToX10Watts(int32_t rawTemp);
|
||||
void setTipX10Watts(int32_t mw);
|
||||
uint8_t X10WattsToPWM(int32_t milliWatts, uint8_t sample = 0);
|
||||
#endif /* POWER_HPP_ */
|
||||
|
||||
Reference in New Issue
Block a user