-
Notifications
You must be signed in to change notification settings - Fork 52
WIP: Add initial music api stubs and test #116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
❤️ This is great! +1 me. One API suggestion might be to implement a music_onchange callback so that users don't have to poll (callback fires for everything but time ticks), though that could go in a second commit. |
|
Oh, yeah, one PR meta-nitpick: for WIP PRs, please include a checkbox list in the description of what's left before you think it would be ready to merge. (If a design review / code review is all that remains, and you'd be happy with something being merged as is otherwise, no need to put "WIP" in the subject.) Thanks! |
|
Yeah, thought about a callback (see https://github.com/ginge/FreeRTOS-Pebble/pull/116/files#diff-9b012897d7876f3a3a7756e12ba612cfR38), might check out how to implement one. 👍 Thanks for the meta-nitpick, will update~ |
|
Oh yeah, this is just lovely... I'm happy with this, good job. I'll spend a bit more time poking, and I do agree a callback will be required at some point. We use callbacks quite a lot, buttons are a callback, so should be plenty of examples to work from |
Includes on_music_change, on_music_play_pause and on_music_skip
|
Ok, I implemented callbacks for on_music_change, on_music_play_pause and on_music_skip. Also it's using app_calloc and app_free for the music info struct, thus adding the need for it to be passed around and making me think that all the track info related setting and getting are a bit wonky at the moment, I'll have to think about that a bit more (not a 100% sure in my mind how those interact with the actual pebble protocol calls yet). As for the testing I am thinking about implementing a stepped through test, where the tester presses play and then reports if the music started playing successfully by answering yes or no. |
|
so general musings here... How many music_track_info do we expect to have in existence at any one time? I can't think of a use case where there would be multiple music tracks required. in terms of how pebble would then interact with this, i'll basically have it fill in that music_track_info struct when some data arrives. |
|
Would that single opaque music track info be in memory all the time or should I keep the init and deinit calls? |
|
Ok, kept the init and deinit calls, removed the passing of the struct. @ginge Should I extend the music test to include more manual interaction or is the current simple one ok? |
* Better applifecycle management Move app quit away from app look to manager loop apps get terminated if non-responsive app loading failures/non-responsive start/download failures fallback to system app * Overlays dismiss. Connsvc fix. Some bugfixes * Quieten some build warnings
Feedback welcome ❤️