Skip to content

Commit

Permalink
Enable force platform minnowboard turbot
Browse files Browse the repository at this point in the history
Compile error would result if force minnowboard max. This is
because mraa_intel_minnowboard_byt_compatible signature requires
bool option for max or turbot board variations. This patch allows
user to force platform for either max or turbot without compile
error.

Signed-off-by: Kevron Rees <[email protected]>
  • Loading branch information
tripzero committed Sep 29, 2017
1 parent 1a4ba6a commit 7d47370
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions api/mraa/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ typedef enum {
MRAA_PHYBOARD_WEGA = 14, /**< The phyBOARD-Wega */
MRAA_DE_NANO_SOC = 15, /**< Terasic DE-Nano-SoC Board */
MRAA_UP2 = 16, /**< The UP^2 Board */
MRAA_INTEL_MINNOWBOARD_TURBOT = 17, /**< The Intel Minnow Board Max */

// USB platform extenders start at 256
MRAA_FTDI_FT4222 = 256, /**< FTDI FT4222 USB to i2c bridge */
Expand Down
2 changes: 2 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ if (NOT ${MRAAPLATFORMFORCE} STREQUAL "ALL")
set (mraa_LIB_X86_SRCS_NOAUTO ${PROJECT_SOURCE_DIR}/src/x86/x86.c ${PROJECT_SOURCE_DIR}/src/x86/intel_edison_fab_c.c)
elseif (${MRAAPLATFORMFORCE} STREQUAL "MRAA_INTEL_MINNOWBOARD_MAX")
set (mraa_LIB_X86_SRCS_NOAUTO ${PROJECT_SOURCE_DIR}/src/x86/x86.c ${PROJECT_SOURCE_DIR}/src/x86/intel_minnow_byt_compatible.c)
elseif (${MRAAPLATFORMFORCE} STREQUAL "MRAA_INTEL_MINNOWBOARD_TURBOT")
set (mraa_LIB_X86_SRCS_NOAUTO ${PROJECT_SOURCE_DIR}/src/x86/x86.c ${PROJECT_SOURCE_DIR}/src/x86/intel_minnow_byt_compatible.c)
elseif (${MRAAPLATFORMFORCE} STREQUAL "MRAA_INTEL_NUC5")
set (mraa_LIB_X86_SRCS_NOAUTO ${PROJECT_SOURCE_DIR}/src/x86/x86.c ${PROJECT_SOURCE_DIR}/src/x86/intel_nuc5.c)
elseif (${MRAAPLATFORMFORCE} STREQUAL "MRAA_INTEL_SOFIA_3GR")
Expand Down
4 changes: 3 additions & 1 deletion src/x86/x86.c
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,9 @@ mraa_x86_platform()
#elif defined(xMRAA_INTEL_DE3815)
plat = mraa_intel_de3815();
#elif defined(xMRAA_INTEL_MINNOWBOARD_MAX)
plat = mraa_intel_minnowboard_byt_compatible();
plat = mraa_intel_minnowboard_byt_compatible(0);
#elif defined(xMRAA_INTEL_MINNOWBOARD_TURBOT)
plat = mraa_intel_minnowboard_byt_compatible(1);
#elif defined(xMRAA_INTEL_GALILEO_GEN1)
plat = mraa_intel_galileo_rev_d();
#elif defined(xMRAA_INTEL_NUC5)
Expand Down

0 comments on commit 7d47370

Please sign in to comment.