File tree Expand file tree Collapse file tree 3 files changed +17
-3
lines changed
Expand file tree Collapse file tree 3 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -103,6 +103,13 @@ static obc_error_code_t handleEnterEmergencyState(void);
103103static obc_error_code_t handleEmergUplinkState (void );
104104/* COMMS STATE HANDLER FUNCTIONS END */
105105
106+ /**
107+ * @brief Reading the temperature using driver functions and adding that temperature to
108+ * the mailbox temperature queue
109+ * @return error code
110+ */
111+ static obc_error_code_t postCommsManagerTempQueue ();
112+
106113typedef obc_error_code_t (* comms_state_func_t )(void );
107114
108115static const comms_state_func_t commsStateFns [] = {
@@ -317,7 +324,7 @@ static obc_error_code_t postCommsManagerTempQueue() {
317324 if (xQueueOverwrite (cc1120TempQueueHandle , & value ) != pdPASS ) {
318325 return OBC_ERR_CODE_UNKNOWN ;
319326 }
320- return OBC_ERR_CODE_INVALID_STATE ;
327+ return OBC_ERR_CODE_SUCCESS ;
321328}
322329
323330/*
Original file line number Diff line number Diff line change @@ -83,7 +83,7 @@ obc_error_code_t sendToCommsManagerQueue(comms_event_t *event);
8383 * @param temp The memory address that stores the temperature in the mailbox queue
8484 * @return The error code
8585 */
86- obc_error_code_t readCC1120Temp (float * temp );
86+ // obc_error_code_t readCC1120Temp(float* temp);
8787
8888/**
8989 * @brief Send an event to the front of the Comms Manager queue
Original file line number Diff line number Diff line change @@ -22,6 +22,13 @@ QueueHandle_t rtcTempQueueHandle = NULL;
2222static StaticQueue_t rtcTempQueue ;
2323static uint8_t rtcTempQueueStack [RTC_TEMP_QUEUE_LENGTH * RTC_TEMP_QUEUE_ITEM_SIZE ];
2424
25+ /**
26+ * @brief Reading the temperature using driver functions and adding that temperature to
27+ * the mailbox temperature queue
28+ * @return error code
29+ */
30+ static obc_error_code_t postRtcTempQueue ();
31+
2532void obcTaskInitTimekeeper (void ) {
2633 ASSERT ((rtcTempQueueStack != NULL ) && (& rtcTempQueue != NULL ));
2734 if (rtcTempQueueHandle == NULL ) {
@@ -40,7 +47,7 @@ static obc_error_code_t postRtcTempQueue() {
4047 return OBC_ERR_CODE_SUCCESS ;
4148}
4249
43- obc_error_code_t readRTCTemp (float * data ) {
50+ obc_error_code_t readRTCTemp (float * data ) {
4451 if (xQueuePeek (rtcTempQueueHandle , data , 0 ) != pdPASS ) {
4552 return OBC_ERR_CODE_QUEUE_EMPTY ;
4653 }
You can’t perform that action at this time.
0 commit comments