fix mem fault

This commit is contained in:
Hendrik Schutter 2024-12-26 11:01:25 +01:00
parent 26d0761aed
commit 80e48f632f
2 changed files with 4 additions and 3 deletions

View File

@ -35,7 +35,7 @@ void initControl(void)
BaseType_t taskCreated = xTaskCreate( BaseType_t taskCreated = xTaskCreate(
taskControl, // Function to implement the task taskControl, // Function to implement the task
"taskControl", // Task name "taskControl", // Task name
4096, // Stack size (in words, not bytes) 8192, // Stack size (in words, not bytes)
NULL, // Parameters to the task function (none in this case) NULL, // Parameters to the task function (none in this case)
5, // Task priority (higher number = higher priority) 5, // Task priority (higher number = higher priority)
NULL // Task handle (optional) NULL // Task handle (optional)

View File

@ -114,9 +114,9 @@ void updateAverage(sMeasurement *pMeasurement)
pMeasurement->average60s.fValue = sum / pMeasurement->average60s.bufferCount; pMeasurement->average60s.fValue = sum / pMeasurement->average60s.bufferCount;
*/ */
} }
/*
void updatePrediction(sMeasurement *pMeasurement) void updatePrediction(sMeasurement *pMeasurement)
{ /* Prediction of the value in 10sec */ { Prediction of the value in 10sec
pMeasurement->predict10s.samples[pMeasurement->predict10s.bufferIndex] = pMeasurement->fCurrentValue; pMeasurement->predict10s.samples[pMeasurement->predict10s.bufferIndex] = pMeasurement->fCurrentValue;
pMeasurement->predict10s.bufferIndex = (pMeasurement->predict10s.bufferIndex + 1) % PRED10_SAMPLE_SIZE; pMeasurement->predict10s.bufferIndex = (pMeasurement->predict10s.bufferIndex + 1) % PRED10_SAMPLE_SIZE;
@ -138,6 +138,7 @@ void updatePrediction(sMeasurement *pMeasurement)
} }
} }
} }
*/
void taskInput(void *pvParameters) void taskInput(void *pvParameters)
{ {