Sapphire SoC DS Sapphire SoC UG Sapphire HP SoC DS Sapphire HP SoC UG RISC-V Embedded IDE UG Board Support Package
Loading...
Searching...
No Matches

Overview

Automatic hardware selection logic.

Automatic Driver Selection

Resolves the low-level driver implementation based on ACTIVE_TEMP_SENSOR_TYPE. This allows the user to switch Temperature Sensor devices by changing a single configuration value in userDef.h.

Note
  • User can switch between supported Temperature Sensor devices by changing the ACTIVE_TEMP_SENSOR_TYPE macro.
    • Add #define ACTIVE_TEMP_SENSOR_TYPE SENSOR_TYPE_EMC1413 in userDef.h to use EMC1413 Temperature Sensor.
  • For custom Temperature Sensor devices, include the custom driver header and define TEMP_SENSOR_CTRL and TEMP_SENSOR_DRIVER macros accordingly.
    • Refer to userDef.h in tempSensorDemo of including a custom Temperature Sensor driver.
#define TEMP_SENSOR_CTRL   TEMP_EMC1413_ADDR
 I2C Address for the currently selected RTC (PCF8523).
#define TEMP_SENSOR_DRIVER   emc1413_driver

Macro Definition Documentation

◆ TEMP_SENSOR_CTRL

#define TEMP_SENSOR_CTRL   TEMP_EMC1413_ADDR

#include <temp_sensor_config.h>

I2C Address for the currently selected RTC (PCF8523).

Note
User can switch to different RTC device by changing ACTIVE_RTC_TYPE macro in userDef.h.

Definition at line 50 of file temp_sensor_config.h.

◆ TEMP_SENSOR_DRIVER

#define TEMP_SENSOR_DRIVER   emc1413_driver

#include <temp_sensor_config.h>

Definition at line 51 of file temp_sensor_config.h.