TOP Contributors

  1. MIKROE (2653 codes)
  2. Alcides Ramos (351 codes)
  3. Shawon Shahryiar (307 codes)
  4. jm_palomino (112 codes)
  5. Chisanga Mumba (90 codes)
  6. S P (73 codes)
  7. dany (71 codes)
  8. MikroBUS.NET Team (35 codes)
  9. NART SCHINACKOW (34 codes)
  10. Armstrong Subero (27 codes)

Most Downloaded

  1. Timer Calculator (136652 times)
  2. FAT32 Library (69875 times)
  3. Network Ethernet Library (55904 times)
  4. USB Device Library (46245 times)
  5. Network WiFi Library (41880 times)
  6. FT800 Library (41115 times)
  7. GSM click (28968 times)
  8. PID Library (26404 times)
  9. mikroSDK (26333 times)
  10. microSD click (25345 times)
Libstock prefers package manager

Package Manager

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]

< Back
mikroSDK Library

BLE 4 click

Rating:

5

Author: MIKROE

Last Updated: 2019-10-02

Package Version: 1.0.0.0

mikroSDK Library: 1.0.0.0

Category: BT/BLE

Downloaded: 3360 times

Not followed.

License: MIT license  

BLE 4 Click is fully embedded stand-alone Bluetooth 5.0 low energy connectivity module, equipped with the NINA-B312, an ultra-small, high-performing, standalone Bluetooth low energy module for easy integration of Bluetooth low energy connectivity (BLE) into various electronic devices.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "BLE 4 click" changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "BLE 4 click" changes.

Do you want to report abuse regarding "BLE 4 click".

  • mikroSDK Library 2.0.0.0
  • Comments (0)
DOWNLOAD LINK RELATED COMPILER CONTAINS
mikroBasic PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc

mikroSDK Library Blog

BLE 4 click

BLE 4 click

Native view of the BLE 4 click board.

View full image
BLE 4 click

BLE 4 click

Front and back view of the BLE 4 click board.

View full image

Library Description

The library covers all the necessary functions to control BLE 4 Click board. A library performs the communication with the NINA-B312-00B series Bluetooth® 5 low energy module via UART interface.

Key functions:

  • void ble4_uartWrite( uint8_t *txData ) - UART write function.
  • void ble4_setDeviceName( uint8_t *deviceName ) - Set device name setting function.
  • uint8_t ble4_readByte() - Read Single Byte.

Examples description

The application is composed of three sections :

  • System Initialization - Initializes UART, sets AN and INT pin as input and RST, CS and PWM pin as output and start to write log.
  • Application Initialization - Initialization driver enables - UART, hardware reset BLE module, restores factory settings of the module, set device name, select data mode and start to send data.
  • Application Task - (code snippet) - This is an example which demonstrates the use of BLE 4 Click board. If 'READ' - repeatedly sends string "mikroE". If 'WRITE' - receives messages from NINA-B3 series Bluetooth® 5 low energy module and LOGs received message. Results are being sent to the Usart Terminal where you can track their changes.
void applicationTask()
{
    char tmp;
    uint8_t rdyFlag;

    if ( moduleMode == _BLE4_READ_MODE )
    {
        rdyFlag = ble4_byteReady();

        if ( 1 == rdyFlag )
        {
            tmp = ble4_readByte();
            mikrobus_logWrite( &tmp, _LOG_BYTE );
        }
    }
    else if ( moduleMode == _BLE4_WRITE_MODE )
    {
        for ( cnt = 0; cnt < 9; cnt++ )
        {
            ble4_writeByte( MESSAGE_DATA[ cnt ] );
            Delay_1sec();
        }

        Delay_1sec();
    }
}

Other mikroE Libraries used in the example:

  • UART

Additional notes and informations

Depending on the development board you are using, you may need USB UART clickUSB 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.

ALSO FROM THIS AUTHOR

AD SWIO 2 click

0

AD-SWIO 2 Click is a quad-channel software configurable input/output solution based on AD74413R, for building and process control application. The AD74413R is a quad-channel software configurable input/output solution for building and process control applications. The device provides a fully integrated single chip solution for input and output operation. The AD-SWIO 2 Click contains four 13-bit DACs, one per chanal, and 16-bit Σ-∆ ADC.

[Learn More]

Hall Current 6 click

0

Hall Current 6 Click is a very accurate current measurement Click board™, based on the ACS723 IC. This IC is a galvanically isolated current sensor, which utilizes the Hall-effect principle.

[Learn More]

Expand 8 click

5

Expand 8 Click is a compact add-on board that contains a multi-port I/O expander with bi-directional input/outputs. This board features the MAX7317, 10-Port SPI-interfaced I/O expander with overvoltage and hot-insertion protection from Maxim Integrated. The MAX7317 provides microprocessors with 10 I/O ports rated to 7V. Each port can be individually configured as either an open-drain output or an overvoltage-protected Schmitt input that supports hot insertion. All port pins remain high impedance in Power-Down mode with up to 8V asserted on them.

[Learn More]