cancel
Showing results for 
Search instead for 
Did you mean: 

Where are Bluetooth LE library sources?

Posted on January 25, 2018 at 11:46

Hi,

I would like to use BlueNRG-2 in my project. 

I downloaded BlueNRG-1.2 DK software package.

There is a lot of examples of applications. They use an archive library libbluenrg1_stack.a containing compiled Bluetooth LE stack.

Where can I find the sources of this library, and how can I build it with Atollic TrueStudio?

Regards,

Piotr

#stack #bluetooth-le #bluenrg-2
1 ACCEPTED SOLUTION

Accepted Solutions
Antonio Vilei
Senior III
Posted on January 26, 2018 at 10:51

Dear Piotr,

that binary file is the low level implementation of the BLE stack and its source code is not available for publication.

If users had access to the source, somebody could alter the behavior of the BLE stack in a way that is not compatible with the standard and possibly violate the FCC requirements.

In order to build your own applications, you just need to link that binary library.

Out of curiosity, why would you like to rebuild it?

Best regards,

Antonio

View solution in original post

6 REPLIES 6
Antonio Vilei
Senior III
Posted on January 26, 2018 at 10:51

Dear Piotr,

that binary file is the low level implementation of the BLE stack and its source code is not available for publication.

If users had access to the source, somebody could alter the behavior of the BLE stack in a way that is not compatible with the standard and possibly violate the FCC requirements.

In order to build your own applications, you just need to link that binary library.

Out of curiosity, why would you like to rebuild it?

Best regards,

Antonio

Posted on January 26, 2018 at 12:37

Hi Antonio,

Thank you for your response.

I designed own pcb containing BlueNRG-2 and STM32L462 chips. 

I am trying to identify what parts of software are available and what I need to develop myself for my application.

So far I understand that I need:

a) firmware for BlueNRG-2

b) bluetooth stack for STM32 (the library)

c) application on STM32

If I am correct the library that I asked is (b), It isn't?

I am little confused by Development Kit, I rather expected 3 projects that reflect parts that I mentioned above. I cannot identify them.

> Out of curiosity, why would you like to rebuild it?

I would like to rebuild it because:

1. I made my own pin assignment in STM32 and I would like to adapt the stack for it.

2. I would like to know what is going on in the stack, be able to debug it

3. I probably will need to modify it for low power requirements

4. closed code cannot be controlled, just works as it is

I would like also to modify BlueNRG-2 firmware. In my PCB I tried to copy BlueNRG connections from STEVAL board but I noticed that bootloader-init shares the pin with irq from BlueNRG (DIO7). This could be a problem if I consider putting into standby mode two chips. 

I will also consider moving the application into BlueNRG-2.

Regards,

Piotr  

Posted on January 26, 2018 at 18:33

Hi Piotr,

BlueNRG-1/2 is an application processor and you can run bothyour own application and the BLE stack on it without the need to use another MCU. The library you asked for is not meant to run on an STM32 but directly on BlueNRG-1/2.

if you're going to use another STM32 (STM32L462 in your case) along with your BlueNRG-1/2 chip, you may be interested in the scenario described in this thread, i.e.

https://community.st.com/0D50X00009XkeEaSAJ

.

Please let me know if I misunderstood your question.

Best regards,

Antonio

Posted on January 26, 2018 at 20:19

Hi Antonio,

Thank you for explanation. Now I am sure that the binary library is only for BlueNRG chip.

I will use DTM firmware on BlueNRG in my device. Maybe I would like to change SPI_IRQ pin (DIO7), just to separate it from Bootloader-activate that is now shared on the pin. This is not critical on current stage of my project.

Thank you for pointing me the thread. There are information that I looked for. I repeat the links below just to other people searching it, there are requirements hot to connect external micro and BlueNRG via spi, and what is the protocol between them:

1) BlueNRG-1_2 DK 2.6.0/Docs/STM32_SPI_protocol_example_html/STM32_SPI_protocol_example.html

2) 

BlueNRG-1_2 DK 2.6.0/

Docs/SPI_protocol_specification/SPI_protocol_specification.html

In BlueNRG-DevKit I saw a few examples that should run on external micro, i.e. BLE Beacon, BLE Chat Master&Slave, Sensor Demo, DTM.

Unfortunately they are only for EWARM environment. May I obtain project files for TrueSTUDIO for these demo applications?

Please confirm if I understand correctly software parts:

1. DTM firmware for BlueNRG can be built from:

     a. sources Project/BLE_Examples/DTM 

     b. binary library libbluenrg1_stack.a

2. demonstration application of sensor for external STM32 can be built completely from sources:

    a. STM32L/BLE_SensorDemo

so, I can adapt it to my pin assignment and my chip version.

Am I correct?

Regards,

Piotr

PS

What does DTM acronym stand for?
Antonio Vilei
Senior III
Posted on January 30, 2018 at 10:14

Hi Piotr,

Please confirm if I understand correctly software parts:

1. DTM firmware for BlueNRG can be built from:

     a. sources Project/BLE_Examples/DTM 

     b. binary library libbluenrg1_stack.a

2. demonstration application of sensor for external STM32 can be built completely from sources:

    a. STM32L/BLE_SensorDemo

so, I can adapt it to my pin assignment and my chip version.

Correct.

TrueStudio examples are available only for native BlueNRG-1/2 projects and you can use TrueStudio to change the SPI_IRQ pin (DIO7) on your DTM firmware.

As for the example running on STM32, instead, as you correctly pointed out, there's no TrueStudio support yet and for the time being you need to use IAR EWARM. You can use either the size-limited or the time-limited version if you don't want to pay for it.

Best regards,

Antonio

P.S.

DTM stands for Device Test Mode.

Posted on January 30, 2018 at 15:43

Thank you, Antonio.

Regars,

Piotr