Hi, I have an app that receives a string via Bluetooth I need organized into an app based data table dynamically. The closest I’ve gotten is doing it like (notice GETSCHEDULES string is the command to send the data from device to the app):
This doesn’t really work as it only writes the first line item, and then when the button is pushed again it writes the the first line item on the 3rd row id. That makes sense since I assume ‘newline’ =/= next letter so letter 21+ is just returning a blank. I can fix that by just making the data a string with no new lines, and just a space or something else but its not worth it since this method requires me to manually code every piece of data to be organized. The max ‘Data Points’ my device is allowed to save/send is 99, and recoding this 99 times manually really seems like the wrong way to do this.
Here how a demo string is transmitted:
00,19:26,11.00,4.00,7.00
01,19:45,11.00,4.00,7.00
02,19:40,0.00,0.00,0.00
03,19:40,6.00,4.00,0.00
04,19:59,5.00,23.00,41.00
The idea for formatting is the first two numbers (00, 01, 02, etc.) is the event ID, and the rest of the number on the line are parameters for that event. The event is something handled on the device. The apps job is to be able to get this data from the device for the user to view, and then the user needs to be able to select it, and send a string with a command and the event ID back to the device to interact with it.
I’ve been playing with different blocks, watching youtube videos, and reading thunkable docs for the better part of 10 hours now, and I need some help figuring out how to format this data because my brain just isn’t coming up with the right answer. I can change the formatting of the data on the device side as well, I just cant figure out what to change it to to make it dynamic, and avoid having to manually code everything like is shown in my screenshot.