esp8684  2.1.0.0
Main Page

ESP8684 click

ESP8664 Click is a compact add-on board that contains a wireless combo module. This board features the ESP8684-MINI-1, a highly integrated WiFi, and a Bluetooth 5 module from Espressif Systems. It simultaneously supports BSS in Station mode, SoftAP mode, Station + SoftAP mode, and promiscuous mode.

click Product page


Click library

  • Author : Stefan Ilic
  • Date : Jun 2023.
  • Type : UART type

Software Support

We provide a library for the ESP8684 Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.

Package can be downloaded/installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.

Library Description

This library contains API for ESP8684 Click driver.

Standard key functions :

Example key functions :

Example Description

This example connects to the desired WiFi network and then

connects to the TCP/UDP server, writes then reads data to and from it.

The demo application is composed of two sections :

Application Init

Initializes driver and wifi communication, then connects to the desired WiFi network

and sends data to the TCP/UDP server.

void application_init ( void )
{
log_cfg_t log_cfg;
esp8684_cfg_t esp8684_cfg;
LOG_MAP_USB_UART( log_cfg );
log_init( &logger, &log_cfg );
log_info( &logger, " Application Init " );
// Click initialization.
esp8684_cfg_setup( &esp8684_cfg );
ESP8684_MAP_MIKROBUS( esp8684_cfg, MIKROBUS_1 );
if ( UART_ERROR == esp8684_init( &esp8684, &esp8684_cfg ) )
{
log_error( &logger, " Communication init." );
for ( ; ; );
}
Delay_ms( 3000 );
Delay_ms( 500 );
Delay_ms( 500 );
Delay_ms( 500 );
// Communication initialization
log_info( &logger, " Application Task " );
}

Application Task

Writes and reads data from TCP/UDP server, processes all incoming data

and displays them on the USB UART.

void application_task ( void )
{
log_printf( &logger, "Sending and reading data from the TCP/UDP server \r\n" );
Delay_ms( 5000 );
}

The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on Mikroe github account.

Other Mikroe Libraries used in the example:

  • MikroSDK.Board
  • MikroSDK.Log
  • Click.ESP8684

Additional notes and informations

Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all MikroElektronika compilers.


app_error_flag
err_t app_error_flag
Definition: main.c:58
esp8684_con_device_to_network
void esp8684_con_device_to_network(void)
ESP8684 connect device to the network.
Definition: main.c:335
esp8684_init
err_t esp8684_init(esp8684_t *ctx, esp8684_cfg_t *cfg)
ESP8684 initialization function.
ESP8684_CMD_GMR
#define ESP8684_CMD_GMR
Definition: esp8684.h:71
esp8684_cfg_setup
void esp8684_cfg_setup(esp8684_cfg_t *cfg)
ESP8684 configuration object setup function.
esp8684_clear_app_buf
void esp8684_clear_app_buf(void)
ESP8684 clearing application buffer.
Definition: main.c:207
application_task
void application_task(void)
Definition: main.c:188
logger
log_t logger
Definition: main.c:53
esp8684_rsp_check
err_t esp8684_rsp_check(uint8_t *response)
ESP8684 response check function.
Definition: main.c:263
esp8684_send_query_cmd
void esp8684_send_query_cmd(esp8684_t *ctx, uint8_t *cmd)
ESP8684 send query command function.
esp8684_send_cmd
void esp8684_send_cmd(esp8684_t *ctx, uint8_t *cmd, uint8_t *args)
ESP8684 send command with arguments function.
esp8684_error_check
void esp8684_error_check(err_t error_flag)
ESP8684 error check function.
Definition: main.c:295
esp8684_default_cfg
void esp8684_default_cfg(esp8684_t *ctx)
ESP8684 default configuration function.
ESP8684_RSP_READY
#define ESP8684_RSP_READY
Definition: esp8684.h:99
esp8684_connect_to_network
void esp8684_connect_to_network(esp8684_t *ctx, uint8_t *ssid, uint8_t *password)
ESP8684 connect to network function.
esp8684_t
ESP8684 Click context object.
Definition: esp8684.h:149
application_init
void application_init(void)
Definition: main.c:132
ESP8684_CMD_AT
#define ESP8684_CMD_AT
ESP8684 control commands.
Definition: esp8684.h:69
esp8684_send_data
void esp8684_send_data(void)
ESP8684 send message to the host.
Definition: main.c:363
esp8684
esp8684_t esp8684
Definition: main.c:52
ESP8684_CMD_RST
#define ESP8684_CMD_RST
Definition: esp8684.h:70
esp8684_cfg_t
ESP8684 Click configuration object.
Definition: esp8684.h:172
ESP8684_RSP_OK
#define ESP8684_RSP_OK
Definition: esp8684.h:96
esp8684_process
err_t esp8684_process(void)
ESP8684 data reading function.
Definition: main.c:222
ESP8684_MAP_MIKROBUS
#define ESP8684_MAP_MIKROBUS(cfg, mikrobus)
MikroBUS pin mapping.
Definition: esp8684.h:133