27 lines
599 B
C
27 lines
599 B
C
/*
|
|
* MTG RFID Companion - Shared SPI bus manager
|
|
*
|
|
* Phase 2 Step 2.3: Initializes the single SPI2_HOST (VSPI) bus shared by
|
|
* the ST7789 display and the MFRC522 RFID reader.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "esp_err.h"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/**
|
|
* @brief Initialize the shared SPI2_HOST bus.
|
|
*
|
|
* Must be called exactly once before the display and RFID driver attach
|
|
* their SPI devices. MFRC522 is passed a NULL bus_config so that it adds
|
|
* its device to this pre-existing bus instead of trying to own it.
|
|
*/
|
|
esp_err_t spi_bus_manager_init(void);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif |