We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]
Not published
Rating:
Author: MIKROE
Last Updated: 2023-04-10
Package Version: 1.0.0.0
mikroSDK Library: 1.0.0.0
Category: WiFi+BLE
Downloaded: 4010 times
Not followed.
License: MIT license
WiFi BLE click is a Click boardâ„¢ which provides Internet and BT/BLE connectivity for any embedded application. It features the ESP32-WROOM-32, an integrated wireless connectivity solution.
Library Description
Library carries generic command parser adopted for AT command based modules. Generic parser.
Key functions:
wifible_cmdSingle
- Sends provided command to the module.wifible_setHandler
- Handler assignation to the provied command.wifible_modulePower
- Turn on module.Examples description
The application is composed of the three sections :
Commands : '+' - Next command 's' - Start command 'e' - change example (WiFi example / BLE example)
Additional Functions :
Timer initialization and default handler.
Note:
void applicationTask()
{
uint8_t dataReady_;
char receivedData_;
dataReady_ = UART_Rdy_Ptr( );
wifible_process();
if (dataReady_ != 0)
{
receivedData_ = UART_Rd_Ptr( );
switch (receivedData_)
{
case '+' :
{
command_cnt++;
if(command_cnt > 5)
{
command_cnt = 0;
}
fCommand = _WIFIBLE_NEXT_COMMAND;
break;
}
case 's' :
{
fCommand = _WIFIBLE_START_COMMAND;
break;
}
case 'e' :
{
if(fExample == _WIFIBLE_BLE_EXAMPLE)
{
fExample = _WIFIBLE_WIFI_EXAMPLE;
mikrobus_logWrite("- Example: WiFi - TCP example ", _LOG_LINE);
mikrobus_logWrite("- [+] First command // [e] Next example", _LOG_LINE);
command_cnt = -1;
fCommand = _WIFIBLE_NO_COMMAND;
}
if(fExample == _WIFIBLE_WIFI_EXAMPLE)
{
fExample = _WIFIBLE_BLE_EXAMPLE;
mikrobus_logWrite("- Example: BLE - iBeacon example ", _LOG_LINE);
mikrobus_logWrite("- [+] First command // [e] Next example", _LOG_LINE);
command_cnt = -1;
fCommand = _WIFIBLE_NO_COMMAND;
}
break;
}
}
if(fExample == _WIFIBLE_WIFI_EXAMPLE)
{
_WiFi_TCPServer(command_cnt);
}
if(fExample == _WIFIBLE_BLE_EXAMPLE)
{
_BLE_iBeacon(command_cnt);
}
}
}
Alongside with the demo application timer initialization functions are provided. Note that timer is configured acording to default develoment system and MCUs, changing the system or MCU may require update of timer init and timer ISR functions.
Other mikroE Libraries used in the example:
String
Conversion
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. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
Audio Amp 2 Click is a highly efficient class D audio amplifier, using the TDA7491, a dual BTL class-D audio amplifier IC, capable of delivering up to 20W to 8Ω load.
[Learn More]Compass 6 Click is a compact add-on board perfect for implementation in applications such as an electronic compass. This board features the HSCDTD008A, a high-sensitivity geomagnetic sensor from ALPS Alpine.
[Learn More]You have unsaved changes. If you choose to leave all changes will be discarded.
Do you want to subscribe in order to receive notifications regarding "WiFi BLE click" changes.
Do you want to unsubscribe in order to stop receiving notifications regarding "WiFi BLE click" changes.
Do you want to report abuse regarding "WiFi BLE click".