Skip to content

Commit

Permalink
Adds fix to omit header file unless needed
Browse files Browse the repository at this point in the history
  • Loading branch information
rosahay-silabs committed Feb 17, 2023
1 parent 33b00f3 commit c2aa2e6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 4 additions & 1 deletion examples/platform/silabs/efr32/spi_multiplex.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@
* limitations under the License.
*/

#include "spi_multiplex.h"
#if (defined(EFR32MG24) && defined(WF200_WIFI))
#include "sl_wfx.h"
#endif /* EFR32MG24 && WF200_WIFI */

#include "spi_multiplex.h"
#include "dmadrv.h"
#include "em_bus.h"
#include "em_cmu.h"
Expand Down
4 changes: 3 additions & 1 deletion examples/platform/silabs/efr32/uart.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ extern "C" {
#include "sl_uartdrv_instances.h"
#ifdef SL_CATALOG_UARTDRV_EUSART_PRESENT
#include "sl_uartdrv_eusart_vcom_config.h"
#if (defined(EFR32MG24) && defined(WF200_WIFI))
#include "spi_multiplex.h"
#endif /* EFR32MG24 && WF200_WIFI */
#endif
#ifdef SL_CATALOG_UARTDRV_USART_PRESENT
#include "sl_uartdrv_usart_vcom_config.h"
Expand Down Expand Up @@ -308,7 +310,7 @@ int16_t uartConsoleWrite(const char * Buf, uint16_t BufLength)
#endif /* EFR32MG24 && WF200_WIFI */

#if defined(SL_CATALOG_POWER_MANAGER_PRESENT)
sl_power_manager_remove_em_requirement(SL_POWER_MANAGER_EM1);
sl_power_manager_remove_em_requirement(SL_POWER_MANAGER_EM1);
#endif

if (ECODE_EMDRV_UARTDRV_OK == ecode_status)
Expand Down

0 comments on commit c2aa2e6

Please sign in to comment.