view src/condat/com/include/cl_user_spver.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 4bb5772a05a3
children
line wrap: on
line source

/*
 * This header file is a FreeCalypso addition; it is part of the mechanism
 * for setting a user-defined list of accepted speech versions in the Bearer
 * Capability IE for speech calls, with a user-defined order of preference,
 * overriding the standard SV list based on hw+fw platform capabilities
 * and the standard order of preference.
 */

#ifndef CL_USER_SPVER_H
#define CL_USER_SPVER_H

/*
 * This function sets (establishes for use) a user-defined SV list.
 * The input is an array of 5 bytes, giving the list of speech versions
 * in the user-preferred order; if fewer than all 5 possible SVs are listed,
 * the remaining array elements shall be filled with 0xFF.  At least FRv1
 * (GSM full rate speech version 1) must always be included in the list;
 * a corollary of this requirement is that an empty list is not a valid input.
 */
extern UBYTE cl_user_spver_set(const UBYTE *spver_list);

/* cl_user_spver_set() return codes */
#define	CL_USER_SPVER_SET_OK		0
#define	CL_USER_SPVER_SET_ERROR		1

/*
 * This function resets (clears) the user-defined SV list, returning to
 * standard operation of accepting all speech versions supported by the
 * platform with the standard order of preference.
 */
extern void cl_user_spver_reset(void);

/*
 * This function checks to see if a user-defined speech version list is set.
 * If no such list is set, the function returns CL_USER_SPVER_IS_NOT_SET
 * and leaves *spver_list and *rad_chan_req untouched.  If a user-defined
 * SV list is set, the function returns CL_USER_SPVER_IS_SET, writes the list
 * into the *spver_list output array (all 5 bytes are always written,
 * with 0xFF padding as needed), and writes the corresponding radio channel
 * requirement code into *rad_chan_req.
 */
extern UBYTE cl_user_spver_get(UBYTE *spver_list, UBYTE *rad_chan_req);

/* cl_user_spver_get() return codes */
#define	CL_USER_SPVER_IS_NOT_SET	0
#define	CL_USER_SPVER_IS_SET		1

#endif	/* include guard */