view src/cs/services/audio/audio_ffs_i.h @ 303:f76436d19a7a default tip

!GPRS config: fix long-standing AT+COPS chance hanging bug There has been a long-standing bug in FreeCalypso going back years: sometimes in the AT command bring-up sequence of an ACI-only MS, the AT+COPS command would produce only a power scan followed by cessation of protocol stack activity (only L1 ADC traces), instead of the expected network search sequence. This behaviour was seen in different FC firmware versions going back to Citrine, and seemed to follow some law of chance, not reliably repeatable. This bug has been tracked down and found to be specific to !GPRS configuration, stemming from our TCS2/TCS3 hybrid and reconstruction of !GPRS support that was bitrotten in TCS3.2/LoCosto version. ACI module psa_mms.c, needed only for !GPRS, was missing in the TCS3 version and had to be pulled from TCS2 - but as it turns out, there is a new field in the MMR_REG_REQ primitive that needs to be set correctly, and that psa_mms.c module is the place where this initialization needed to be added.
author Mychaela Falconia <falcon@freecalypso.org>
date Thu, 08 Jun 2023 08:23:37 +0000
parents 4e78acac3d88
children
line wrap: on
line source

/********************************************************************************/
/*                                                                              */
/*    File Name:   audio_ffs_i.h                                                */
/*                                                                              */
/*    Purpose:     This header contains the audio ffs constants related to      */
/*                 the ffs behavior.                                            */
/*                                                                              */
/*    Note:                                                                     */
/*        None.                                                                 */
/*                                                                              */
/*    Revision History:                                                         */
/*       11 May 01     Francois Mazard - Stephanie Gerthoux        Create       */
/*                                                                              */
/* (C) Copyright 2001 by Texas Instruments Incorporated, All Rights Reserved.   */
/*                                                                              */
/********************************************************************************/
  #ifndef _AUDIO_FFS_I_H_
    #define _AUDIO_FFS_I_H_

    #ifdef __cplusplus
      extern "C"
      {
    #endif

      #define AUDIO_MEM_MAX_CHANNEL            (1)
      #define AUDIO_VM_AMR_PLAY_SIZE           (500)// 16 bit unit
      #define AUDIO_VM_AMR_PLAY_NB_BUFFER      (2)
      #define AUDIO_VM_AMR_RECORD_SIZE         (500)// 16 bit unit
      #define AUDIO_VM_AMR_RECORD_NB_BUFFER    (2)      
      #define AUDIO_MIDI_SIZE                  (500) // 16 bit unit
      #define AUDIO_MIDI_NB_BUFFER             (2)

      #if (MELODY_E1) || (MELODY_E2) || (VOICE_MEMO)
        /* maximum number of FFS channel */
        #define AUDIO_FFS_MAX_CHANNEL             (2)

        /* list of the session_id depending on the audio features */
        /* session id of the melody E1 number 0 */
        #define AUDIO_FFS_SESSION_MELODY_E1_0     (0)
        /* session id of the melody E1 number 1 */
        #define AUDIO_FFS_SESSION_MELODY_E1_1     (1)
        /* session id of the melody E2 number 0 */
        #define AUDIO_FFS_SESSION_MELODY_E2_0     (2)
        /* session id of the melody E2 number 1 */
        #define AUDIO_FFS_SESSION_MELODY_E2_1     (3)

        /* session id of the voice memo play */
        #define AUDIO_FFS_SESSION_VM_PLAY         (4)
        /* session id ofthe voice memo record */
        #define AUDIO_FFS_SESSION_VM_RECORD       (5)
        /* size of the data to download to the RAM for each features */
        /* using the FLASH to RAM session*/
        #define AUDIO_MELODY_E1_SIZE              (512)
        #define AUDIO_MELODY_E2_SIZE              (512)
        #define AUDIO_VM_PLAY_SIZE                (1024)
        /* size to allocate in RAM for each features */
        /* using the RAM to FLASH session */
        #define AUDIO_VM_RECORD_INITIAL_SIZE      (1024)

        /* maximum number of buffer per session */
        #define AUDIO_MAX_FFS_BUFFER_PER_SESSION  (2)

        /* The audio FFS is activated: the audio task run with a time out */
        #ifndef _WINDOWS
          #define AUDIO_FFS_TIME_OUT                (RVF_MS_TO_TICKS(500))
        #else
          #define AUDIO_FFS_TIME_OUT                (RVF_MS_TO_TICKS(10))
        #endif


        /* The audio FFS manager need to be activate asap */
        #define AUDIO_FFS_ACTIVE_NOW              (0)

        /* The audio FFS timer is in one shot mode */
        #define AUDIO_FFS_ONE_SHOT_TIMER          (FALSE)

        /* The audio FFS timer is in continuous mode */
        #define AUDIO_FFS_CONTINUOUS_TIMER        (TRUE)

        /* state of the cust_get_pointer state machine */
        #define  AUDIO_CUST_GET_POINTER_INIT      (0)
        #define  AUDIO_CUST_GET_POINTER_NORMAL    (1)
        #define  AUDIO_CUST_GET_POINTER_LOOP      (2)
      #endif /* MELODY_E1 || MELODY_E2 || VOICE_MEMO */

    #ifdef __cplusplus
      }
    #endif
  #endif /* _AUDIO_FFS_I_ */