missionpinball / mpf-monitor

Graphical utilty which connects to MPF to let you visually control, troubleshoot, and see the status of the machine
http://missionpinball.org
MIT License
11 stars 10 forks source link

Add recent events #1

Closed GabeKnuth closed 7 years ago

GabeKnuth commented 7 years ago

I know it's opening up a ton of chatter, but it would be cool to see a list of recent events to Monitor. I think it would be implemented as a text box with checkboxes for different kind of events that make it into the list.

For example, I want to see events about shots, but I'm not sure what the full event is that I want to hook (like, is it shot_group_my_group_active_hit or shot_my_shot_flashing_hit or whatever). I'd have to run with -v and check the logs now.

Not sure if Monitor is just reading logs, but I suspect not, so if it saves me from stopping my game, running -v, and then filtering the logs, that would be a huge time saver when you add up 30 secs times 1000 different events I need to find.

Thoughts? I was thinking a UI like this:

O Shot events Ø Mode events O Logic Block events O Timer events O ...


2016-10-05 22:24:04,714 : DEBUG : Events : ^^^^ Posted event 'mode_attract_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:04,716 : DEBUG : Events : ^^^^ Posted event 'mode_attract_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:11,912 : DEBUG : Events : ^^^^ Posted event 'mode_game_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:11,913 : DEBUG : Events : ^^^^ Posted event 'mode_attract_stopping'. Type: queue, Callback: <bound method Mode._stopped of >, Args: {} 2016-10-05 22:24:11,924 : DEBUG : Events : ^^^^ Posted event 'mode_attract_stopped'. Type: None, Callback: <bound method Mode._mode_stopped_callback of >, Args: {} 2016-10-05 22:24:11,925 : DEBUG : Events : ^^^^ Posted event 'mode_game_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:11,965 : DEBUG : Events : ^^^^ Posted event 'mode_wizard_advance_lit_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:11,970 : DEBUG : Events : ^^^^ Posted event 'mode_managers_choice_base_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:11,975 : DEBUG : Events : ^^^^ Posted event 'mode_skill_shot_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:12,031 : DEBUG : Events : ^^^^ Posted event 'mode_base_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:12,057 : DEBUG : Events : ^^^^ Posted event 'mode_base_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:12,060 : DEBUG : Events : ^^^^ Posted event 'mode_light_mission_select_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:12,061 : DEBUG : Events : ^^^^ Posted event 'mode_light_mission_select_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:12,065 : DEBUG : Events : ^^^^ Posted event 'mode_skill_shot_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:12,079 : DEBUG : Events : ^^^^ Posted event 'mode_managers_choice_lit_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:12,080 : DEBUG : Events : ^^^^ Posted event 'mode_managers_choice_lit_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:12,082 : DEBUG : Events : ^^^^ Posted event 'mode_managers_choice_base_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:12,083 : DEBUG : Events : ^^^^ Posted event 'mode_wizard_advance_lit_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:12,106 : DEBUG : Events : ^^^^ Posted event 'mode_mystery_lit_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:12,110 : DEBUG : Events : ^^^^ Posted event 'mode_mystery_lit_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:16,269 : DEBUG : Events : ^^^^ Posted event 'mode_base_score_score'. Type: None, Callback: None, Args: {'change': 0, 'prev_value': 10, 'value': 10} 2016-10-05 22:24:16,275 : DEBUG : Events : ^^^^ Posted event 'mode_skill_shot_stopping'. Type: queue, Callback: <bound method Mode._stopped of >, Args: {} 2016-10-05 22:24:16,291 : DEBUG : Events : ^^^^ Posted event 'mode_skill_shot_stopped'. Type: None, Callback: <bound method Mode._mode_stopped_callback of >, Args: {} 2016-10-05 22:24:16,660 : DEBUG : Events : ^^^^ Posted event 'mode_base_score_score'. Type: None, Callback: None, Args: {'change': 0, 'prev_value': 10, 'value': 10} 2016-10-05 22:24:17,325 : DEBUG : Events : ^^^^ Posted event 'mode_base_score_score'. Type: None, Callback: None, Args: {'change': 0, 'prev_value': 10, 'value': 10} 2016-10-05 22:24:17,812 : DEBUG : Events : ^^^^ Posted event 'mode_base_score_score'. Type: None, Callback: None, Args: {'change': 0, 'prev_value': 10, 'value': 10} 2016-10-05 22:24:18,741 : DEBUG : Events : ^^^^ Posted event 'mode_base_score_score'. Type: None, Callback: None, Args: {'change': 0, 'prev_value': 10, 'value': 10} 2016-10-05 22:24:20,464 : DEBUG : Events : ^^^^ Posted event 'mode_light_mission_select_stopping'. Type: queue, Callback: <bound method Mode._stopped of >, Args: {} 2016-10-05 22:24:20,489 : DEBUG : Events : ^^^^ Posted event 'mode_mission_rotator_starting'. Type: queue, Callback: <bound method Mode._started of >, Args: {} 2016-10-05 22:24:20,491 : DEBUG : Events : ^^^^ Posted event 'mode_mission_rotator_started'. Type: None, Callback: <bound method Mode._mode_started_callback of >, Args: {} 2016-10-05 22:24:20,504 : DEBUG : Events : ^^^^ Posted event 'mode_light_mission_select_stopped'. Type: None, Callback: <bound method Mode._mode_stopped_callback of >, Args: {}

toomanybrians commented 7 years ago

Adding events is on the todo list, and filtering them should be easy enough. It won't add too much overhead since BCP is already handling uncompressed DMD frames and state updates for all the LEDs 50 and all that, so this would be nothing.

toomanybrians commented 7 years ago

done in 0.1.5