Code Monkey home page Code Monkey logo

custom_ble_service_example's People

Contributors

bjornspock avatar bjornspockeli avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

custom_ble_service_example's Issues

Error While adding the mcuboot folder in repo.

Hi We are using the nordic sdk 1.9.1.
I have created my own project and i want whole sdk commit to my repo. I am able to build the project.I am not able to commit the mcuboot, It showing the error you are not able to commit the git repository under another git repository.

  1. If i remove .git folder in the sdk then we are able to commit but nothing got committed in the mcuboot folder .I am not able to build the project.
  2. I have tried to create the mcuboot as repository which contain the same file which mcuboot repo having and add as the submodule to my repo still am facing the build issue

can you please explain by removing the .git folder we are facing the build issue. What is the role of .git folder of mcuboot for the successfully building of the project.

Is there is any way to commit the whole nordic sdk.

sd_ble_gatts_hvx issue

Hello,

I am using 14.1.0 SDK, I implemented the custom service and characteristic, but if adding CCCD(Client Characteristic Configuration Descriptor) with the custom value characteristic, the system will be reset after pushing cccd button in app, I can't know the reason,

when checking the issue point, the issue is happened with sd_ble_gatts_hvx function,

please help me the method to solve issue,
My email is [email protected]

thankful for your support and kindness in advance

Question : Should I change memory as to ram ?
currently start is 0x20002a68 and size is 0x2000ffff, how can I change it ? please..help me...

thanks

Outdated for SDK14

Awesome tutorial, but it seems to be a bit outdated for what SDK 14 requires.

Byte-swap error in the write-up

For a newbie, this erroneous byte swap was a little confusing:

In the text, it says this is the UUID that was used:
f364adc9-b000-4042-ba50-05ca45bf8abc

But all the code and screenshots are written with this UUID (two erroneous byte swaps):
f364adc9-00b0-4240-ba50-05ca45bf8abc

It was very confusing to me, as it was kind of a pain figuring out how the byte-ordering is supposed to work. I made a python3 script for this, if anyone is interested:

https://gist.github.com/kbrafford/b517289bdbbd2102b1e23bc3c7aa841e

custom_value_char_add is not defined in the header file.

In the main README, in step 4 right at the beginning it says to declare custom_value_char_add in the header file. It won't compile (at least using GCC) if you follow this step, and this step is also not in the final ble_cus.h file.

Characteristic User Description

Hello @bjornspockeli,

thanks for this great example!
Can you please add a custom User Description to the characteristic. I had it working on SDK 14, though after migration to Version 15, I can't get it work. Please help.

Thanks
Sebastian

Error 133 When Connecting with nRF Connect

Hi: I followed your excellent tutorial and am running into this issue.
I followed through the thread posted by someone that had the same issue and apparently solved it by relocating where, in ble_cus_init() he was initializing the event struct.

This doesn't appear to be my problem. I set a breakpoint on the first line of on_connect() and when I step through, I notice that the second line (ble_cus_evt_t evt) isn't executing. Furthermore, I cannot set a breakpoint on this line as I get a "no code for breakpoint" warning.

As you probably guessed by now, I am very new to the nRF world so am just now getting familiar with everything. I encountered a similar problem while stepping through another example and I discovered that I needed to include and enable some items in sdk_config.h before the associated code would compile else that code gets ignored.

Am I missing something in the configuration for this project? The project I am modifying is ble_app_template.

Are there any examples of how to create a central that can connect to this custom service?

Are there any examples of how to create a central that can connect to this custom service? I need to make a pair of devices, one that will be the custom peripheral and one that will be a custom central to talk to each other. I have not been able to find an example for a central that connects to a custom service.

I did find some comments about modifying the UART example, but that example still seems to use some of the "built in" nRF files for the UART.

NRF_ERROR_DATA_SIZE error when increasing the length of the data

I wanted to send an array of uint8_t so I made the following changes in the ble_cus_custom_value_update() function. I changed it to :
code
I changed the function parameter of custom_value to a pointer so that I can pass the array and changed the gatts_value.len to the size of the array. The gatts_value.len is where the problem occurs. If I don't change it and keep it as sizeof(unit8_t); then it works fine but I only receive the first byte of the array on the Central. When I changed the gatts_value.len to the size of the array I get the error as "NRF_ERROR_DATA_SIZE" and the microcontroller hangs. I'm using nrf52832 dk and sdk15. I'll attach the error output below for better understanding :
image

Getting an error on step 7

Hey, so far your code has been beyond helpful getting familiar with this technology. However, I seem to be getting a problem propagating custom service events to the application. Specifically when I call p_cus->evt_handler(p_cus, &evt); within on_connect(). When I comment out that specific line of code the app is able to connect to the ble app on my android phone and I can communicate through the softdevice. Though, when I do include it, the app tries to connect but then fails. Do you have an idea as to why this might be the case? I am using a nRF52840 chip.

RAM Start & End Problem (S140)

Hello Bjorn,
Thanks for this useful tutorial.
We are working on an application with motion control based on nRF52840 (S140).
I have implemented your example / tutorial and modified the RAM start 0x20002220 and the size to 0xDDE0 however I am still getting the FATAL ERROR message related to the memory allocation.
Any thoughts about that?
Thanks,
Elias

the CCCD of custom value characteristic with nrf52832

Hello,

I am using 14.1.0 SDK, I implemented the custom service and characteristic, but if adding CCCD(Client Characteristic Configuration Descriptor) with the custom value characteristic, the system will be reset, I can't know the reason,

when checking the issue point, the issue is happened with sd_ble_gatts_hvx function,

please help me the method to solve issue,
My email is [email protected]

thankful for your support and kindness in advance

Question : Should I change memory as to ram ?
currently start is 0x20002a68 and size is 0x2000ffff, how can I change it ? please..help me...

thanks

Error in Readme.md Walkthrough Steps - nRF 15.2.0

As written, the walkthrough does not work. At the end of Step 3 you should be able to connect to the peripheral, but I wasn't able to. The missing steps appear to be the addition of QWR Queued Write Module. After adding the QWR logic to my services_init method I'm able to connect to the peripheral.

Thanks for the great walkthrough!

Thank you very much!

Hey i just wanted to say thank you for your great tutorial!
The step by step explanations are perfect for including a custom service in an existing project.
Without this repo it would take several days for me (still beginner) and now i am ready after a few hours and know exactly where to tweak things.

Great work @bjornspockeli !

How to add more than 1 custom service?

Hi, first of all, I would like to say that you have helped me a lot with your tutorial. Thank you for your excellent work.

But, how can I add more than one custom service?
I do these things:

  • Create a new Custom Service
  • Add new Characteristics
  • Add the new CUSTOM_SERV_UUID to advertising array in main.c
  • Set NRF_SDH_BLE_VS_UUID_COUNT to 2 inside the sdk_config.h
  • Initialize service.

But when I try to run, my application stops to do advertising.

I think I have two possible errors:
1 - I need to set the RAM_START and RAM_SIZE values.
2 - When I created my new service, I put this in an advertising package and this made it exceed the allowed 31-byte value of advertising.

Ps: My second custom service doesn't need to advertise. So, if I can remove from advertising and see those values when my peer is connected, I could do this, by I don't know how to do.

Could you help me to solve this issue?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.