Unified the default configuration/setting values and parameters into one header file.

This commit is contained in:
GeminiServer
2020-03-15 14:45:52 +01:00
parent fddf24b7ff
commit 0461fd0a26
6 changed files with 1819 additions and 1734 deletions

View File

@@ -8,6 +8,7 @@
#include "TipThermoModel.h"
#include "Settings.h"
#include "hardware.h"
#include "../../configuration.h"
/*
* The hardware is laid out as a non-inverting op-amp
@@ -26,18 +27,6 @@
* This was bought to my attention by <Kuba Sztandera>
*/
// TIP_GAIN = TIP_GAIN/1000 == uV per deg C constant of the tip
#ifdef MODEL_TS100
#define OP_AMP_Rf 750*1000 /*750 Kilo-ohms -> From schematic, R1*/
#define OP_AMP_Rin 2370 /*2.37 Kilo-ohms -> From schematic, R2*/
#define TIP_GAIN 405
#else
#define OP_AMP_Rf 180*1000 /*180 Kilo-ohms -> From schematic, R6*/
#define OP_AMP_Rin 2000 /*2.0 Kilo-ohms -> From schematic, R3*/
#define TIP_GAIN 115
#endif
#define op_amp_gain_stage (1+(OP_AMP_Rf/OP_AMP_Rin))
uint32_t TipThermoModel::convertTipRawADCTouV(uint16_t rawADC) {
// This takes the raw ADC samples, converts these to uV