Driver for CC3000 Wi-Fi module

Dependencies:   NVIC_set_all_priorities

Dependents:   CC3000_Simple_Socket Wi-Go_IOT_Demo

Embed: (wiki syntax)

« Back to documentation index

Cc3000_common

Cc3000_common

Functions

void Init_HostDriver (void)
 Set basic controls and parameters for the HostDriver.
char * sendDriverPatch (unsigned long *Length)
 Return a pointer to the driver patch.
char * sendBootLoaderPatch (unsigned long *Length)
 Return a pointer to the bootloader patch.
char * sendWLFWPatch (unsigned long *Length)
 Return a pointer to the firmware patch.
long ReadWlanInterruptPin (void)
 Read Wlan Interrupt pin.
void WlanInterruptEnable (void)
 Enable waln IrQ pin.
void WlanInterruptDisable (void)
 Disable waln IrQ pin.
void WriteWlanPin (unsigned char val)
 WriteWlanPin.
void SimpleLinkWaitEvent (unsigned short usOpcode, void *pRetParams)
 Wait for event, pass it to the hci_event_handler and update the event opcode in a global variable.
void SimpleLinkWaitData (unsigned char *pBuf, unsigned char *from, unsigned char *fromlen)
 Wait for data, pass it to the hci_event_handler and update in a global variable that there is data to read.
unsigned char * UINT32_TO_STREAM_f (unsigned char *p, unsigned long u32)
 Copy 32 bit to stream while converting to little endian format.
unsigned char * UINT16_TO_STREAM_f (unsigned char *p, unsigned short u16)
 Copy 16 bit to stream while converting to little endian format.
unsigned short STREAM_TO_UINT16_f (char *p, unsigned short offset)
 Copy received stream to 16 bit in little endian format.
unsigned long STREAM_TO_UINT32_f (char *p, unsigned short offset)
 Copy received stream to 32 bit in little endian format.

Function Documentation

void Init_HostDriver ( void   )

Set basic controls and parameters for the HostDriver.

Parameters:
none
Returns:
none

Definition at line 50 of file cc3000_common.cpp.

long ReadWlanInterruptPin ( void   )

Read Wlan Interrupt pin.

Parameters:
none
Returns:
wlan interrup pin level

Definition at line 101 of file cc3000_common.cpp.

char* sendBootLoaderPatch ( unsigned long *  Length )

Return a pointer to the bootloader patch.

Since there is no patch, 0 is returned
(the patches are taken from the EEPROM and not from the host)

Parameters:
pointerto the length
Returns:
NULL

Definition at line 87 of file cc3000_common.cpp.

char* sendDriverPatch ( unsigned long *  Length )

Return a pointer to the driver patch.

Since there is no patch, 0 is returned
(the patches are taken from the EEPROM and not from the host)

Parameters:
pointerto the length
Returns:
NULL

Definition at line 80 of file cc3000_common.cpp.

char* sendWLFWPatch ( unsigned long *  Length )

Return a pointer to the firmware patch.

Since there is no patch, 0 is returned
(the patches are taken from the EEPROM and not from the host)

Parameters:
pointerto the length
Returns:
NULL

Definition at line 94 of file cc3000_common.cpp.

void SimpleLinkWaitData ( unsigned char *  pBuf,
unsigned char *  from,
unsigned char *  fromlen 
)

Wait for data, pass it to the hci_event_handler and update in a global variable that there is data to read.

Parameters:
pBufdata buffer
fromfrom information
fromlenfrom information length
Returns:
none

Definition at line 580 of file evnt_handler.cpp.

void SimpleLinkWaitEvent ( unsigned short  usOpcode,
void *  pRetParams 
)

Wait for event, pass it to the hci_event_handler and update the event opcode in a global variable.

Parameters:
usOpcodecommand operation code
pRetParamscommand return parameters
Returns:
none

Definition at line 571 of file evnt_handler.cpp.

unsigned short STREAM_TO_UINT16_f ( char *  p,
unsigned short  offset 
)

Copy received stream to 16 bit in little endian format.

Parameters:
ppointer to the stream
offsetoffset in the stream
Returns:
pointer to the new 16 bit

Definition at line 167 of file cc3000_common.cpp.

unsigned long STREAM_TO_UINT32_f ( char *  p,
unsigned short  offset 
)

Copy received stream to 32 bit in little endian format.

Parameters:
ppointer to the stream
offsetoffset in the stream
Returns:
pointer to the new 32 bit

Definition at line 174 of file cc3000_common.cpp.

unsigned char* UINT16_TO_STREAM_f ( unsigned char *  p,
unsigned short  u16 
)

Copy 16 bit to stream while converting to little endian format.

Parameters:
ppointer to the new stream
u32pointer to the 16 bit
Returns:
pointer to the new stream

Definition at line 159 of file cc3000_common.cpp.

unsigned char* UINT32_TO_STREAM_f ( unsigned char *  p,
unsigned long  u32 
)

Copy 32 bit to stream while converting to little endian format.

Parameters:
ppointer to the new stream
u32pointer to the 32 bit
Returns:
pointer to the new stream

Definition at line 149 of file cc3000_common.cpp.

void WlanInterruptDisable ( void   )

Disable waln IrQ pin.

Parameters:
none
Returns:
none

Definition at line 114 of file cc3000_common.cpp.

void WlanInterruptEnable ( void   )

Enable waln IrQ pin.

Parameters:
none
Returns:
none

Definition at line 106 of file cc3000_common.cpp.

void WriteWlanPin ( unsigned char  val )

WriteWlanPin.

Parameters:
val(1: enable - 0: disable)
Returns:
none

Definition at line 120 of file cc3000_common.cpp.