07-07-2021, 09:09 PM
Can someone help clear up my understanding of bluetooth services and attributes on Infinitime? I figured out how to set date and time using gatttool, but am confused as to why there are three different characteristics associated with the CurrentTime service, and how I could have found that out from the source code instead of trial and error with gatttool until I found something that looked like a time and date code.
In Infinitime/src/components/ble/CurrentTimeService.h, I can see that ctsId sets the UUID of the CurrentTime service to 0x1805. gatttool tells me this has three characteristics with handles 17, 18, and 19. Handle 19 has the date and time, and gatttool can set time on the watch with char-write-cmd. But what are handles 17 and 18 doing? And where in the source code are these characteristics defined?
Thanks,
In Infinitime/src/components/ble/CurrentTimeService.h, I can see that ctsId sets the UUID of the CurrentTime service to 0x1805. gatttool tells me this has three characteristics with handles 17, 18, and 19. Handle 19 has the date and time, and gatttool can set time on the watch with char-write-cmd. But what are handles 17 and 18 doing? And where in the source code are these characteristics defined?
Thanks,