Skip to content

Commit

Permalink
Guard IO Functions to Pass Unit Tests (#1324)
Browse files Browse the repository at this point in the history
### Changelist 
<!-- Give a list of the changes covered in this PR. This will help both
you and the reviewer keep this PR within scope. -->

### Testing Done
<!-- Outline the testing that was done to demonstrate the changes are
solid. This could be unit tests, integration tests, testing on the car,
etc. Include relevant code snippets, screenshots, etc as needed. -->

### Resolved Tickets
<!-- Link any tickets that this PR resolves. -->
  • Loading branch information
Lucien950 authored Jun 24, 2024
1 parent 1118ff5 commit 61ff5cb
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions firmware/quadruna/VC/src/app/states/app_driveState.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
#include "states/app_driveState.h"
#include "states/app_inverterOnState.h"

#ifdef TARGET_EMBEDDED
#include "io_canTx.h"
#endif

#include "app_canTx.h"
#include "app_canRx.h"
Expand Down Expand Up @@ -192,14 +194,17 @@ static void driveStateRunOnExit(void)
app_canTx_VC_INVL_CommandParameterAddress_set((uint16_t)20);
app_canTx_VC_INVL_CommandReadWrite_set(true);
app_canTx_VC_INVL_CommandData_set((uint16_t)0);
io_canTx_VC_INVL_ReadWriteParamCommand_sendAperiodic();
io_canTx_VC_INVL_ReadWriteParamCommand_sendAperiodic();

app_canTx_VC_INVR_CommandParameterAddress_set((uint16_t)20);
app_canTx_VC_INVR_CommandReadWrite_set(true);
app_canTx_VC_INVR_CommandData_set((uint16_t)0);

#ifdef TARGET_EMBEDDED
io_canTx_VC_INVL_ReadWriteParamCommand_sendAperiodic();
io_canTx_VC_INVL_ReadWriteParamCommand_sendAperiodic();
io_canTx_VC_INVR_ReadWriteParamCommand_sendAperiodic();
io_canTx_VC_INVR_ReadWriteParamCommand_sendAperiodic();
#endif

// Disable buzzer on exit drive.
io_efuse_setChannel(EFUSE_CHANNEL_BUZZER, false);
Expand Down

0 comments on commit 61ff5cb

Please sign in to comment.