view src/g23m-fad/tcpip/include/rv_defined_swe.h @ 600:8f50b202e81f

board preprocessor conditionals: prep for more FC hw in the future This change eliminates the CONFIG_TARGET_FCDEV3B preprocessor symbol and all preprocessor conditionals throughout the code base that tested for it, replacing them with CONFIG_TARGET_FCFAM or CONFIG_TARGET_FCMODEM. These new symbols are specified as follows: CONFIG_TARGET_FCFAM is intended to cover all hardware designs created by Mother Mychaela under the FreeCalypso trademark. This family will include modem products (repackagings of the FCDEV3B, possibly with RFFE or even RF transceiver changes), and also my desired FreeCalypso handset product. CONFIG_TARGET_FCMODEM is intended to cover all FreeCalypso modem products (which will be firmware-compatible with the FCDEV3B if they use TI Rita transceiver, or will require a different fw build if we switch to one of Silabs Aero transceivers), but not the handset product. Right now this CONFIG_TARGET_FCMODEM preprocessor symbol is used to conditionalize everything dealing with MCSI. At the present moment the future of FC hardware evolution is still unknown: it is not known whether we will ever have any beyond-FCDEV3B hardware at all (contingent on uncertain funding), and if we do produce further FC hardware designs, it is not known whether they will retain the same FIC modem core (triband), if we are going to have a quadband design that still retains the classic Rita transceiver, or if we are going to switch to Silabs Aero II or some other transceiver. If we produce a quadband modem that still uses Rita, it will run exactly the same fw as the FCDEV3B thanks to the way we define TSPACT signals for the RF_FAM=12 && CONFIG_TARGET_FCFAM combination, and the current fcdev3b build target will be renamed to fcmodem. OTOH, if that putative quadband modem will be Aero-based, then it will require a different fw build target, the fcdev3b target will stay as it is, and the two targets will both define CONFIG_TARGET_FCFAM and CONFIG_TARGET_FCMODEM, but will have different RF_FAM numbers. But no matter which way we are going to evolve, it is not right to have conditionals on CONFIG_TARGET_FCDEV3B in places like ACI, and the present change clears the way for future evolution.
author Mychaela Falconia <falcon@freecalypso.org>
date Mon, 01 Apr 2019 01:05:24 +0000
parents 90eb61ecd093
children
line wrap: on
line source

/**
 *
 * @file  rv_defined_swe.h
 *
 * Definition of the SWE that will be compiled.
 *
 * To include a SWE in the build, the System/env.mak file is used.
 * Before the build, a rv_swe.h file is generated from env.mak.
 * This file includes rv_swe.h and makes some adjustement if necessary
 * (e.g. mandatory SWE to include if some other is included, include
 * of group of SWE, etc).
 *
 * @author  Cristian Livadiotti
 * @version  0.4
 *
 */

/*
 * Revision History:
 *
 * 10/10/2000  Cristian Livadiotti    Create.
 * 10/18/2001   Christophe Favergeon  Updated for R2D.
 * 10/15/2002   Laurent Sollier      Updated for automatic definition from env.mak file.
 * 11/19/2002  Vincent Oberle      Added RivieraTool support to automatic definition.
 *
 * (C) Copyright 2000 by Texas Instruments Incorporated, All Rights Reserved
 */

#ifndef _RV_DEFINED_SWE_H_
#define _RV_DEFINED_SWE_H_

#ifndef _SIMULATION_
   #include "l1sw.cfg"
   #include "rv.cfg"
   #include "swconfig.cfg"
   #include "debug.cfg"
/*
 * rv_swe.h is generated before build from System/env.mak
 * It is used both for RivieraTool and Target.
 */
#include "rv_swe.h"
#endif


/* ------------------------------------------------------------------
 * Grouped SWEs
 * Some define in rv_swe.h might not represent one SWE, but a group
 * of SWEs, this is decoded here.
 * ------------------------------------------------------------------ */

/*
 * Bluetooth SWEs.
 * If RVM_BLUETOOTH_SWE is defined, the SWE's for the BT PS are defined,
 * each profile must be defined independently in the env.mak file.
 */
#ifdef RVM_BLUETOOTH_SWE
   #define RVM_HCI_SWE
   #define RVM_L2CAP_SWE
   #define RVM_BTCTRL_SWE
   #define RVM_RFCOMM_SWE
   #define RVM_SPP_SWE
   #define RVM_SDP_SWE
   #define RVM_OBX_SWE
#endif

/*
 * DEV SWEs.
 * (might become useless soon).
 */
#ifdef RVM_DEV_SWE
   #define RVM_DEV1_SWE
   #define RVM_DEV2_SWE
   #define RVM_DEV3_SWE
#endif

/*
 * J2ME SW entities
 * If RVM_J2ME_K_SWE is defined, the SWE's for the Java KVM are defined.
 */
#ifdef RVM_JAVA_K_SWE
   #define RVM_KGC_SWE
   #define RVM_KIL_SWE
   #define RVM_KCL_SWE
   #define RVM_KMM_SWE
   #define RVM_KNM_SWE
   #define RVM_UVM_SWE
   #define RVM_KZP_SWE
   #define RVM_KPG_SWE
   #define RVM_JTM_SWE
#endif

/*
 * AUDIO_FRAMEWORK SW entities
 * If it is defined, AUDIO SWE is defined and AUDIO BACKGROUND may be defined
 * depending on available audio features
 */

#ifdef RVM_AUDIO_SWE
  #define RVM_AUDIO_MAIN_SWE
  #if ((MELODY_E2) || (L1_GTT == 1))
    #define RVM_AUDIO_BGD_SWE
  #endif
#endif

/*
 * TCP/IP
 * The rule is simple: The Real Implementation has the priority
 * over others, so if Real Implementation is defined,
 * then Winsocket (Windows only) and Bridge (Board only) are undefined.
 * Otherwise, Winsocket and Bridge can be defined together
 */
#if (defined RVM_RNET_RT_SWE)
   #define RVM_RNET_SWE
   #ifdef RVM_RNET_WS_SWE
      #undef RVM_RNET_WS_SWE /* Undef Winsocket implemetation. */
   #endif
   #ifdef RVM_RNET_BR_SWE
      #undef RVM_RNET_BR_SWE /* Undef Bridge implemetation. */
   #endif
#elif ((defined RVM_RNET_WS_SWE) || (defined RVM_RNET_BR_SWE))
   #define RVM_RNET_SWE
#endif

/* ----------------------------------------
 * Specifics for a RivieraTool build.
 * ---------------------------------------- */
#ifdef _WINDOWS

   #ifndef RVM_ATP_UART_SWE
      #define RVM_ATP_UART_SWE
   #endif

   // Bluetooth PS SW entities: Is this Windows specific???
   #ifdef BLUETOOTH
      #define RVM_SYN_SWE
   #endif

// Pascal POMPEI - Removed (Bluetooth only).
//   /* This SWE is mandatory for Riviera Tool (UART driver) */
//   #ifndef RVM_HCI_SWE
//      #define RVM_HCI_SWE
//   #endif

   /* No bridge on Windows */
   #ifdef RVM_RNET_BR_SWE
      #undef RVM_RNET_BR_SWE
   #endif

   // TEMPORARY: THESE SWEs MUST BE FIXED FOR RIVIERATOOL
   #ifdef RVM_DAR_SWE
      #undef RVM_DAR_SWE
   #endif
   #ifdef RVM_ETM_SWE
      #undef RVM_ETM_SWE
   #endif

/* ----------------------------------------
 * Specifics for target build.
 * ---------------------------------------- */
#else
   #if (TI_PROFILER == 1) || (TI_NUC_MONITOR == 1)
      #define RVM_TI_PRF_SWE
   #endif

   #ifndef RVM_RVT_SWE
      #define RVM_RVT_SWE
   #endif

   #if ((defined RVM_TTY_SWE) && (L1_GTT == 0))
     #error "TTY entity cannot be enabled if L1_GTT is disabled (= 0)"
   #endif

   #if ((!defined RVM_TTY_SWE) && (L1_GTT == 1))
     #error "L1_GTT cannot be enabled (= 1) if TTY entity is disabled"
   #endif

   /* No Winsocket on target */
   #ifdef RVM_RNET_WS_SWE
      #undef RVM_RNET_WS_SWE
   #endif

#endif

#if (defined TEST) && (defined RVM_R2D_SWE) && (defined RVM_RGUI_SWE)
   #define RVM_RTEST_SWE
#endif

#endif /* _RV_DEFINED_SWE_H_ */