1/*
2 * roamingMngr_autoSM.h
3 *
4 * Copyright(c) 1998 - 2009 Texas Instruments. All rights reserved.
5 * All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions
9 * are met:
10 *
11 *  * Redistributions of source code must retain the above copyright
12 *    notice, this list of conditions and the following disclaimer.
13 *  * Redistributions in binary form must reproduce the above copyright
14 *    notice, this list of conditions and the following disclaimer in
15 *    the documentation and/or other materials provided with the
16 *    distribution.
17 *  * Neither the name Texas Instruments nor the names of its
18 *    contributors may be used to endorse or promote products derived
19 *    from this software without specific prior written permission.
20 *
21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 */
33
34/** \file roamingMngr_autoSM.h
35 *  \brief Internal Roaming Manager API
36 *
37 *  \see roamingMngr.c
38 */
39
40/****************************************************************************
41 *                                                                          *
42 *   MODULE:  Roaming Manager	    		                                *
43 *   PURPOSE: Roaming Manager Module API                              		*
44 *                                                                          *
45 ****************************************************************************/
46
47#ifndef _ROAMING_MNGR_AUTO_SM_H_
48#define _ROAMING_MNGR_AUTO_SM_H_
49
50#include "osApi.h"
51#include "paramOut.h"
52#include "scanMngrApi.h"
53#include "bssTypes.h"
54#include "DrvMainModules.h"
55
56
57/*-----------*/
58/* Constants */
59/*-----------*/
60
61/** state machine states */
62typedef enum
63{
64/*	0	*/	ROAMING_STATE_IDLE,
65/*	1	*/	ROAMING_STATE_WAIT_4_TRIGGER,
66/*	2	*/  ROAMING_STATE_WAIT_4_CMD,
67/*	3	*/  ROAMING_STATE_SCANNING,
68/*	4	*/  ROAMING_STATE_SELECTING,
69/*	5	*/  ROAMING_STATE_CONNECTING,
70/*	6	*/  ROAMING_STATE_LAST
71
72} roamingMngr_smStates;
73
74/** State machine events */
75typedef enum
76{
77/*	0	*/	ROAMING_EVENT_START = 0, 			/* CONNECTED */
78/*	1	*/	ROAMING_EVENT_STOP, 			/* NOT CONNECTED */
79/*	2	*/	ROAMING_EVENT_ROAM_TRIGGER,
80/*	3	*/	ROAMING_EVENT_SCAN,
81/*	4	*/	ROAMING_EVENT_SELECT,
82/*	5	*/	ROAMING_EVENT_REQ_HANDOVER,
83/*	6	*/	ROAMING_EVENT_ROAM_SUCCESS,
84/*	7	*/	ROAMING_EVENT_FAILURE,
85/*	8	*/	ROAMING_EVENT_LAST
86
87} roamingMngr_smEvents;
88
89#define ROAMING_MNGR_NUM_STATES     	ROAMING_STATE_LAST
90#define ROAMING_MNGR_NUM_EVENTS     	ROAMING_EVENT_LAST
91
92#define INVALID_CANDIDATE_INDEX     	0xFF
93#define CURRENT_AP_INDEX            	0xFE
94
95
96extern TGenSM_actionCell roamingMngrAuto_matrix[ROAMING_MNGR_NUM_STATES][ROAMING_MNGR_NUM_EVENTS];
97extern TI_INT8*  AutoRoamStateDescription[];
98extern TI_INT8*  AutoRoamEventDescription[];
99
100/*--------------*/
101/* Enumerations */
102/*--------------*/
103
104/*----------*/
105/* Typedefs */
106/*----------*/
107
108/*------------*/
109/* Structures */
110/*------------*/
111
112/*---------------------------*/
113/* External data definitions */
114/*---------------------------*/
115
116/*--------------------------------*/
117/* External functions definitions */
118/*--------------------------------*/
119
120/*----------------------------*/
121/* Global Function prototypes */
122/*----------------------------*/
123
124
125#endif /* _ROAMING_MNGR_AUTO_SM_H_ */
126
127