This example code: https://www.b4x.com/android/forum/threads/ble-2-bluetooth-low-energy.59937/#content
successfully scans for BLE devices and finds my DSD relay board, then successfully connects to it.
That code then fails when writing to the DSD board via BLE.
Understanding that sample program is taking some effort. An Index is being passed to some routines wherein a .get function is used, but it isn't intuitively obvious why copying that code to a new subroutine generates compile errors for an object not being initiated, but that's not really my question.
What I'd love to know is how to make a Button_click write a hex byte to my DSD relay board via BLE. Something extraordinarily simple, one would hope.
I did extensive forum searches and they all came back to that BLE2 sample code or bluetooth chat code (obviously I need BLE).
What I was hoping to find was a simple program that wrote hex bytes via BLE so that I could just tweak that code. Oy vey. Search after search.
successfully scans for BLE devices and finds my DSD relay board, then successfully connects to it.
That code then fails when writing to the DSD board via BLE.
Understanding that sample program is taking some effort. An Index is being passed to some routines wherein a .get function is used, but it isn't intuitively obvious why copying that code to a new subroutine generates compile errors for an object not being initiated, but that's not really my question.
What I'd love to know is how to make a Button_click write a hex byte to my DSD relay board via BLE. Something extraordinarily simple, one would hope.
I did extensive forum searches and they all came back to that BLE2 sample code or bluetooth chat code (obviously I need BLE).
What I was hoping to find was a simple program that wrote hex bytes via BLE so that I could just tweak that code. Oy vey. Search after search.