This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Multiple Services or 1 service with multiple characteristics

This may just be a preference or architecturing question but I thought I'd ask in case there was anything I'm not thinking of, or benefit of one or the other.

I have 2 notification characteristics sending data from a sensor. The first is a 'live stream' and will be enabled when the phone app is open. The second is a burst of notifications (~600 bytes of data) once every half an hour or so to a background process on the phone.

I had intended to write them as 2 different services, but then got to thinking maybe they should just be 2 characteristics within a single service?

I will also have another characteristic for writing configuration values to the device. Previous version followed the lbs example code and I had that in its own service previously as well.

Is it better to do it all in a single Service or have multiple services?

Related