Commit graph

13 commits

Author SHA1 Message Date
William Wilgus
a2e5d9563f [Feature] resume TSR plugins after interruption WIP
save tsr plugin path for later

resume tsr plugin when user stops the interrupting plugin

expand return of tsr_exit function to allow
continue, suspend, terminate

tsr plugins check parameter at start to determine if
the plugin is being resumed

Change-Id: I6fc70de664c7771e7dbc9a1af7a831e7b50b1d15
2023-03-25 10:02:43 -04:00
William Wilgus
11ddc6cf1c announce_status Fix USB fall through and usb on plugin start
When running and USB plugged announce status ack'd the USB and then un intentionally fell through to EV_EXIT
this caused the thread to exit but not the TSR hook

Now: plugin keeps track of usb status and doesn't announce till usb is unplugged again
on unplug the start-up beep is played to announce its presence

announce_status on startup blocks usb since USB handling is done in the thread that hasn't started yet
Now: don't start if USB is plugged

Plugin now beeps if it couldn't play the announcement excpept for missing voice file unfortunately

Change-Id: I69cf7e687508ce02358432e7bd1adc27c78c4072
2021-11-13 03:38:28 -05:00
William Wilgus
0679faf65d lib/helper add talk_val()
talk_value_decimal() replaced talk_value()

Change-Id: Ibb7c738d6f3b399fab2e771d8ab85967e3af96d1
2021-08-18 21:30:13 -04:00
William Wilgus
24e8fa317e plugins trade talk_value for talk_value_decimal
talk_value is just talk_value_decimal with 0 decimals

lets add the extended function instead

static inline int talk_val(long n, int unit, bool enqueue)
{
    #define NODECIMALS 0
    return rb->talk_value_decimal(n, unit, NODECIMALS, enqueue);
}

Change-Id: Iaba3d2f95785f2e1855e294ccf099a977bb6cb20
2021-08-19 01:17:29 +00:00
Aidan MacDonald
48c29e3b3b Fix announce_status usage of plugin buffer
Since this is a TSR plugin, it is not safe to use the plugin buffer.
Convert to using static buffers instead.

Change-Id: Ic5b297468a99d77d56f5b75e52dafabeb80d2f78
2021-07-21 11:26:14 +00:00
William Wilgus
9cf45374e0 Announce_status plugin bugfix use artist prior to albumartist
give id3->artist higer precedence than id3->albumartist

Change-Id: I7f57ea274211673c04bf23458735796b03031a15
2021-03-05 21:12:10 -05:00
William Wilgus
0c958d2b4a announce_status trackchange bugfix
!Properly remove callback!
don't play voice prompt at startup if something is actively playing

Change-Id: I237d09c1496bc2bed8433dcdaa1469f3d0f2cb10
2021-03-05 17:37:57 +00:00
William Wilgus
03ae4e6019 Announce_status plugin make USB plug aware
Announce_status was blocking USB from working it now quits on USB plug

Change-Id: I0b7e5e9c1ef118582febd459e706c9b61cf7fe25
2021-03-04 22:55:39 -05:00
Solomon Peachy
ce7731527a announce_status: Fix incorrect function prototype definition
Change-Id: I053b4e3df194ac9dd2172249c0f4902d31a6d412
2020-12-13 19:19:33 -05:00
Moshe Piekarski
cb9280c9e1
Fix DEBUG builds
Change-Id: Ie3b4caebf448444b7400541e44d11d40961781cb
2020-10-06 15:27:56 -05:00
William Wilgus
84bfd68fb5 Battery_bench & announce_status stack fix
had stack growing the wrong way

Change-Id: I51bf14526f5239e77e15dc0ffd76ad3ed8bdcbc8
2020-08-15 09:57:10 -04:00
Solomon Peachy
e1681345cc fix the red in be04c4b
Change-Id: I569561e5199c71a814b7f8118d63063f13958831
2020-07-28 01:18:14 +00:00
William Wilgus
be04c4be0a Voice TSR Plugin Demo
allows user to run plugin in background that voices
status messages

grouping is now working it counts ; as the end of a group

sleep timer remaining is not voiced if sleep timer is not active

TODO
manual entries

Change-Id: I39e8500df6440c07d2a3347513c749d5e155d1cc
2020-07-27 20:47:03 -04:00