BLE GATT profile options

say i wanted to rapid prototype a design that utilizes ble gatt profile, is there anything available that would get me going in short order?

now i did a search and have come to the understanding that Bluetooth is considered well supported due to the fact that there many modules available which integrate via serial, but as i mention i am after the gatt profile and don’t intend to roll my own support for it.
i mean i know the ble gatt profile pretty well, but figure implementing it over serial would be quite a bit of work.
So are there any complete libraries available for any hardware for tinyclr, v1 or 2?

Nothing out of the box but this is a good question and we will investigate.

please do! for better off worse I’ve ‘bound’ myself to the esp32 for anything ble due to the implementation support available, would be great to have it here.

Not sure if this helps, but I have use this Adafruit Bluefruit LE UART Friend in the past which is very easy to use with TinyCLR. I used it mainly with v1 and it works without any issues. Sample code

var bluefruitLe = UartController.FromName(STM32F4.UartPort.Usart3);
bluefruitLe.SetActiveSettings(9600, 8, UartParity.None, UartStopBitCount.One, UartHandshake.None);
bluefruitLe.Enable();

I then send data to the remote (Android app)

 while (true)
            {
                var data = $"Date = { DateTime.Now.ToString("hh:mm:ss tt")} {Environment.NewLine}" +
                    $"Battery Voltage = {mainBattery} {Environment.NewLine}" +
                    $"M1 Current = {m1Current}{Environment.NewLine}" +
                    $"M2 Current = {m2Current} {Environment.NewLine}";
                bluefruitLe.Write(Encoding.UTF8.GetBytes($"{data}|"));
                bluefruitLe.Flush();

                Thread.Sleep(100);
                sb.Clear();
            }
3 Likes

this appears to be straight ‘raw’ serial data transfer… the default, i suppose this is what all the previous posts i read suggest is the current level of Bluetooth support.

ble gatt is a generic protocol built over ble that has sort of ‘built in’ functionally as many devices, tokens, fobs, also have it built in support it.

in my opinion it’s just one of those things that provide inherent functionality and potential for rapid development

Based on my limited understanding of Bluetooth LE, the chip on a BLE device is vastly different than that of a classic Bluetooth device and the profile can be different per device based on the device function. Meaning, the profile for a heart rate monitor may be different than that of a pedometer.

So question, are looking to have TinyCLR running a particular profile? This may required a Bluetooth LE chip and TinyCLR running some kind of a Gatt server. Or, you just want to communication with TinyCLR via a device with profile already in place?

well whatever the particular hardware required, im aware ble want introduced until version 4 so arguably v1-3 hardware wouldn’t suffice, when working with the GATT profile, whatever predefined characteristics your speaking of, be it heart rate or other, are just that, predefined… but it could use it for custom data transfer, it just seems to organize the data on the protocol for you.

anyway in Android for example there is an abstraction for working with BLE GATT, curious if anything was available likewise

but I’m not sure what the hardware support required actually is