blob: f95f25227ad7832bc787f83336af05bf6b043e67 [file] [log] [blame]
rjw6c1fd8f2022-11-30 14:33:01 +08001/*****************************************************************************
2* Copyright Statement:
3* --------------------
4* This software is protected by Copyright and the information contained
5* herein is confidential. The software may not be copied and the information
6* contained herein may not be used or disclosed except with the written
7* permission of MediaTek Inc. (C) 2016
8*
9* BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES
10* THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS (""MEDIATEK SOFTWARE"")
11* RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON
12* AN ""AS-IS"" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES,
13* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
14* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.
15* NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE
16* SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR
17* SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH
18* THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO
19* NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S
20* SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM.
21*
22* BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE
23* LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE,
24* AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE,
25* OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO
26* MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE.
27*
28* THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE
29* WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF
30* LAWS PRINCIPLES. ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND
31* RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER
32* THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC).
33*
34*****************************************************************************/
35/*************************************************************************
36 *
37 * File Name: valattune.h
38 *
39 * Description: Tuning parameters
40 *
41 *
42 ************************************************************************/
43#ifndef _AT_TUNE_H
44#define _AT_TUNE_H 1
45
46#include "valatdata.h"
47/* ---------------------------------------------------------------------
48 * Name: Data Port Present
49 *
50 * Description:
51 * This switch defines whether or not AppInt supports a Data Port
52 * interface. Set this switch to KAL_FALSE for Browser-Only applications.
53 *
54 * Restrictions:
55 * KAL_FALSE, KAL_TRUE
56 *
57 * Default Value:
58 * KAL_TRUE
59 *
60 * Notes:
61 * When this switch is set to KAL_FALSE, the following files can be excluded
62 * from the build-set:
63 * - ai_ch.c
64 * - ai_cmd.c
65 * - ai_dh.c
66 * - ai_dr.c
67 * - ai_parse.c
68 * - atparse.c
69 * - atpparse.c
70 * - iqmgr.c
71 * - isolib.c
72 */
73#define AT_DPD_PRESENT 1
74
75/* ---------------------------------------------------------------------
76 * Name: V.42bis Compression Capabilities: <direction>
77 *
78 * Description:
79 * This switch defines the capabilities of the V.42bis software
80 * provisioned in the MT. AppInt uses this switch to determine the
81 * valid range for the <direction> parameter in the +CDS command.
82 *
83 * Restrictions:
84 * 0: No V.42bis provisioned.
85 * 1: V.42bis available in the reverse direction only.
86 * 2: V.42bis available in the forward direction only.
87 * 3: V.42bis available in both directions.
88 *
89 * Default Value:
90 * 0
91 */
92#define AT_CMP_DIRECTION 0
93
94/* ---------------------------------------------------------------------
95 * Name: V.42bis Compression Capabilities: <max_dict>
96 *
97 * Description:
98 * This switch defines the maximum dictionary size supported the V.42bis
99 * software provisioned in the MT. AppInt uses this switch to determine
100 * the valid range for the <max_dict> parameter in the +CDS command.
101 *
102 * Restrictions:
103 * 512 - 65535
104 *
105 * Default Value:
106 * 2048
107 */
108#define AT_CMP_MAX_DICT 2048
109
110
111/* ---------------------------------------------------------------------
112 * Name: V.42bis Compression Capabilities: <max_string>
113 *
114 * Description:
115 * This switch defines the maximum string size supported the V.42bis
116 * software provisioned in the MT. AppInt uses this switch to determine
117 * the valid range for the <max_string> parameter in the +CDS command.
118 *
119 * Restrictions:
120 * 6 - 250
121 *
122 * Default Value:
123 * 6
124 */
125#define AT_CMP_MAX_STRING 6
126
127
128/* ---------------------------------------------------------------------
129 * Name: Data Port Driver Capabilities: autobaud rates
130 *
131 * Description:
132 * This switch defines the bit rates which may be auto-detected by the
133 * Data Port Driver hardware. These rates are to be used in Command
134 * state and for Async Data calls only. AppInt uses this switch to
135 * determine the valid range for the <auto-detectable rates> parameter
136 * in the +IPR command.
137 *
138 * Restrictions:
139 * Any number of entries from the following list:
140 * BR_300
141 * BR_1200
142 * BR_2400
143 * BR_4800
144 * BR_9600
145 * BR_19200
146 * BR_38400
147 * BR_57600
148 * BR_115200
149 * or: BR_NONE.
150 *
151 * The same bit rate may not be specified in both AT_DPD_AUTOBAUD_RATES and
152 * AT_DPD_FIXED_RATES.
153 *
154 * Default Value:
155 * (BR_300 + BR_1200 + BR_2400 + BR_4800 + BR_9600 +
156 * BR_19200 + BR_38400 + BR_57600 + BR_115200)
157 */
158/*
159#define AT_DPD_AUTOBAUD_RATES (BR_300 + \
160 BR_1200 + \
161 BR_2400 + \
162 BR_4800 + \
163 BR_9600 + \
164 BR_19200 + \
165 BR_38400 + \
166 BR_57600 + \
167 BR_115200)
168
169*/
170
171#define AT_DPD_AUTOBAUD_RATES BR_NONE
172/* ---------------------------------------------------------------------
173 * Name: Data Port Driver Capabilities: fixed baud rates
174 *
175 * Description:
176 * This switch defines the bit rates supported by the Data Port Driver
177 * hardware, but which may not be auto-detected.
178 * These rates are to be used in Command state and for Async Data calls only.
179 * AppInt uses this switch to determine the valid range for the
180 * <fixed-only rates> parameter in the +IPR command.
181 *
182 * Restrictions:
183 * Any number of entries from the following list:
184 * BR_300
185 * BR_1200
186 * BR_2400
187 * BR_4800
188 * BR_9600
189 * BR_19200
190 * BR_38400
191 * BR_57600
192 * BR_115200
193 * or: BR_NONE
194 *
195 * The same bit rate may not be specified in both AT_DPD_AUTOBAUD_RATES and
196 * AT_DPD_FIXED_RATES.
197 *
198 * Default Value:
199 * BR_NONE
200 */
201#define AT_DPD_FIXED_RATES (BR_19200 + \
202 BR_115200+ \
203 BR_230400 )
204
205
206/* ---------------------------------------------------------------------
207 * Name: Local AT-Parameter Default Value: +IPR
208 *
209 * Description:
210 * This switch defines the default value to be used for the "Fixed
211 * DTE Rate" parameter.
212 * This value is used to reset the parameter value when a ATZ or AT&F
213 * command is processed and AT_DPD_AUTOBAUD_RATES is BR_NONE. Otherwise,
214 * a value of zero is used.
215 *
216 * Restrictions:
217 * Any value from the list defined for AT_DPD_FIXED_RATES.
218 *
219 * Default Value:
220 * BR_230400
221 */
222#define AT_DEFAULT_IPR BR_230400
223
224
225/* ---------------------------------------------------------------------
226 * Name: Data Port Driver Capabilities: Maximum FAX bit rate
227 *
228 * Description:
229 * This switch defines the maximum bit rate which the Data Port Driver
230 * can use during FAX calls. AppInt uses this switch to determine the
231 * valid range of values for the +FPR command.
232 *
233 * Restrictions:
234 * Any one of the following values:
235 * FR_2400
236 * FR_4800
237 * FR_9600
238 * FR_19200
239 * FR_38400
240 * FR_57600
241 * FR_115200
242 *
243 * Default Value:
244 * FR_19200
245 */
246#define AT_DPD_MAX_FPR FR_19200
247
248
249/* ---------------------------------------------------------------------
250 * Name: Data Port Driver Capabilities: Fax transmit buffer size.
251 *
252 * Description:
253 * This switch defines the size of the buffer used by the Data Port Driver
254 * to store data in the reverse direction during FAX calls. AppInt uses
255 * this switch when reporting information for the <tbs> parameter in the
256 * +FBS? command.
257 *
258 * Restrictions:
259 * 0 - 65535
260 *
261 * Default Value:
262 * 3600
263 */
264#define AT_DPD_FBS_TX 3600
265
266/* ---------------------------------------------------------------------
267 * Name: Data Port Driver capabilities: Fax receive buffer size.
268 *
269 * Description:
270 * This switch defines the size of the buffer used by the Data Port Driver
271 * to store data received in the forward direction during FAX calls.
272 * AppInt uses this switch when reporting information for the <rbs>
273 * parameter in the +FBS? command.
274 *
275 * Restrictions:
276 * 3600 - 65535
277 *
278 * Default Value:
279 * 3600
280 */
281#define AT_DPD_FBS_RX 3600
282
283/* ---------------------------------------------------------------------
284 * Name: Local AT-Parameter Default Value: +CDS.<max_dict>
285 *
286 * Description:
287 * This switch defines the default value to be used for the V.42bis
288 * data compression: <max_dict> parameter to be used on the Um interface.
289 * This value is used to reset the parameter value when a ATZ or AT&F
290 * command is processed.
291 *
292 * Restrictions:
293 * 512 - AT_CMP_MAX_DICT
294 *
295 * Default Value:
296 * AT_CMP_MAX_DICT
297 */
298#define AT_DEFAULT_CDS_MAX_DICT AT_CMP_MAX_DICT
299
300
301/* ---------------------------------------------------------------------
302 * Name: Local AT-Parameter Default Value: +CPS
303 *
304 * Description:
305 * This switch defines the default value to be used for the
306 * Packet Data Service Option parameter.
307 * This value is used to reset the parameter value when a ATZ or AT&F
308 * command is processed.
309 *
310 * Restrictions:
311 * 7, 8, 15, 16, 22, 23, 24, 25, 26, 27, 28, 29,
312 * 4103, 4104
313 *
314 * Default Value:
315 * 4103
316 */
317#define AT_DEFAULT_CPS 59
318
319/* ---------------------------------------------------------------------
320 * Name: Local AT-Parameter Default Value: +CMUX
321 *
322 * Description:
323 * This switch defines the default value to be used for the "Select
324 * Multiplex Option" parameter.
325 * This value is used to reset the parameter value when a ATZ or AT&F
326 * command is processed.
327 *
328 * Restrictions:
329 * 1 - 2
330 *
331 * Default Value:
332 * 2
333 */
334#define AT_DEFAULT_CMUX 2
335
336/* ---------------------------------------------------------------------
337 * Name: Local AT-Parameter Default Value: +FPR
338 *
339 * Description:
340 * This switch defines the default value to be used for the "Serial
341 * Port Rate Control" parameter.
342 * This value is used to reset the parameter value when a ATZ or AT&F
343 * command is processed and +FCLASS = 2.0.
344 *
345 * Restrictions:
346 * Any value from the following list up to the value specified by
347 * AT_DPD_MAX_FPR:
348 * FR_AUTOBAUD,
349 * FR_19200
350 *
351 * Default Value:
352 * FR_AUTOBAUD
353 */
354#define AT_DEFAULT_FPR FR_19200
355
356/* ---------------------------------------------------------------------
357 * Name: NSPE Capabilities: Maximum TX Request Size
358 *
359 * Description:
360 * This switch defines the maximum size (in bytes) which AppInt may
361 * specify in a nspeAiTxReq call. AppInt requires this parameter to
362 * be at least 98 bytes so that the longest EIA-617 in-band command
363 * may be transmitted in a single TxReq. The upper bound for this
364 * parameter is determined by the MBUF size and high water mark settings
365 * configured for NSPE.
366 *
367 * Restrictions:
368 * 98 - 65535
369 *
370 * Default Value:
371 * 1024
372 */
373#define AT_NSPE_MAX_TXREQ_LEN 1024
374
375
376/* ---------------------------------------------------------------------
377 * Name: Data Transfer Behavior
378 *
379 * Description:
380 * This switch defines the maximum amount of time (in msec) AppInt will
381 * allow reverse channel User Data to sit in the V.42bis compressor or
382 * the TCP layer of NSPE. When this timer expires, AppInt will flush the
383 * compressor (if compression is active and if there could be partially
384 * matched User Data strings in the compressor) and push data out of the
385 * TCP layer.
386 *
387 * Restrictions:
388 * 1 - 65535
389 *
390 * Default Value:
391 * 100
392 */
393#define AT_STALE_DATA_TMO 100
394
395
396/* ---------------------------------------------------------------------
397 * Name: AppInt Capabilities: Maximum AT-command line length
398 *
399 * Description:
400 * This switch defines the maximum size of an AT-command line in
401 * COMMAND state as well as the largest single AT-command which may be
402 * reflected by the IWF in ONLINE state.
403 *
404 * For COMMAND state, this size includes the initial "AT" and trailing
405 * <s3><s4> characters.
406 *
407 * The longest single AT-command in the IS-707 repertoire (AT+FNS=) requires
408 * 280 characters. The second longest command (AT+CFG=) requires 258
409 * characters. AppInt allows the data from repetitive AT+FNS= and AT+CFG=
410 * commands to be appended to the existing parameter data. Therefore, with
411 * a cooperating TE2, this tuning parameter may be safely reduced to the
412 * maximum length of the third longest single AT-command: AT+MA=
413 * (48 characters).
414 *
415 * Restrictions:
416 * 48 - 65535
417 *
418 * Default Value:
419 * 280
420 */
421#ifdef SYS_OPTION_ENHANCEDAT
422#define AT_MAX_AT_CMD_LEN ATC_ENHANCED_AT_CMD_LEN
423#else
424#define AT_MAX_AT_CMD_LEN 280
425#endif
426
427
428/* ---------------------------------------------------------------------
429 * Name: Compression Negotiation Timeout
430 *
431 * Description:
432 * This switch defines the amount of time (in msec) AppInt will wait for
433 * the Um data compression negotiation procedure to complete.
434 * This timer is activated only if the +CDS.<compressionNegotiation>
435 * parameter is enabled.
436 * If the timer expires and the data compression specified by the other
437 * +CDS parameters has not been obtained, AppInt will disconnect the call.
438 *
439 * Restrictions:
440 * 1 - 65535
441 *
442 * Default Value:
443 * 5000
444 */
445#define AT_CN_TMO 5000
446
447/* ---------------------------------------------------------------------
448 * Name: Allow Invalid Body Characters
449 *
450 * Description:
451 * Setting this switch to KAL_TRUE disables EIA-617 extended command body
452 * character validation. This overcomes a bug in some IWF implementations.
453 *
454 * Restrictions:
455 * KAL_FALSE, KAL_TRUE
456 *
457 * Default Value:
458 * KAL_TRUE
459 */
460#define AT_ALLOW_INVALID_BODY_CHARS KAL_TRUE
461
462/* ---------------------------------------------------------------------
463 * Name: Allow Invalid Body Characters
464 *
465 * Description:
466 * This switch determines whether or not AppInt will upload an ATM1
467 * (speaker-on-until-connect) command to the IWF.
468 * This switch should only be set to KAL_TRUE if the MT software supports
469 * the multiply connected service option configuration and service
470 * option switching functions described in IS-707-A.4, section 4.1(b)
471 *
472 * Restrictions:
473 * KAL_FALSE, KAL_TRUE
474 *
475 * Default Value:
476 * KAL_FALSE
477 */
478#define AT_UPLOAD_ATM KAL_FALSE
479
480/* ---------------------------------------------------------------------
481 * Name: Packet Data Service Options
482 *
483 * Description:
484 * These switches define the values which AppInt will accept for
485 * the +CPS AT-command.
486 *
487 * Restrictions:
488 * KAL_FALSE, KAL_TRUE
489 *
490 * Default Value:
491 * AT_CPS_SO_07: KAL_TRUE
492 * AT_CPS_SO_08: KAL_TRUE
493 * AT_CPS_SO_15: KAL_TRUE
494 * AT_CPS_SO_16: KAL_TRUE
495 *
496 * AT_CPS_SO_22: KAL_FALSE
497 * AT_CPS_SO_23: KAL_FALSE
498 * AT_CPS_SO_24: KAL_FALSE
499 * AT_CPS_SO_25: KAL_FALSE
500 * AT_CPS_SO_26: KAL_FALSE
501 * AT_CPS_SO_27: KAL_FALSE
502 * AT_CPS_SO_28: KAL_FALSE
503 * AT_CPS_SO_29: KAL_FALSE
504 *
505 * AT_CPS_SO_4103: KAL_TRUE
506 * AT_CPS_SO_4104: KAL_TRUE
507 */
508#define AT_CPS_SO_07 KAL_TRUE
509#define AT_CPS_SO_08 KAL_TRUE
510#define AT_CPS_SO_15 KAL_TRUE
511#define AT_CPS_SO_16 KAL_TRUE
512
513#define AT_CPS_SO_22 KAL_TRUE
514#define AT_CPS_SO_23 KAL_TRUE
515#define AT_CPS_SO_24 KAL_TRUE
516#define AT_CPS_SO_25 KAL_TRUE
517
518#define AT_CPS_SO_26 KAL_FALSE
519#define AT_CPS_SO_27 KAL_FALSE
520#define AT_CPS_SO_28 KAL_FALSE
521#define AT_CPS_SO_29 KAL_FALSE
522
523#define AT_CPS_SO_33 KAL_TRUE
524#define AT_CPS_SO_59 KAL_TRUE
525#define AT_CPS_SO_69 KAL_TRUE
526
527#define AT_CPS_SO_4103 KAL_TRUE
528#define AT_CPS_SO_4104 KAL_TRUE
529
530
531/* ---------------------------------------------------------------------
532 * Name: Maximum Browser Digits
533 *
534 * Description:
535 * This switch defines the maximum string length which can be returned by
536 * the cfgAiGetBrowserDigits function, excluding the NULL terminator.
537 *
538 * Restrictions:
539 * 1 - 255
540 *
541 * Default Value:
542 * 20
543 */
544#define AT_MAX_BROWSER_DIGITS 20
545
546#ifdef MTK_CBP
547/* ---------------------------------------------------------------------
548 * Name: SYS ACTIVED BAND
549 *
550 * Default Value:
551 * VAL_SYS_BAND_CLASS_INVALID_MASK 0XFFFF FFFF
552 */
553
554#define AT_DEFAULT_SYS_ACTIVED_BAND_CLASS_MASK 0XFFFFFFFF
555#endif
556
557#endif /* _AI_TUNE_H */