Skip to content

Commit

Permalink
pyscript: Adjust demo script for slight API modification
Browse files Browse the repository at this point in the history
  • Loading branch information
ximion committed Aug 15, 2024
1 parent 1345baa commit b002a29
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion content/docs/modules/pyscript.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ oport_frame = syl.get_output_port('frame-out')
oport_tab = syl.get_output_port('tablerow-out')


def prepare():
def prepare() -> bool:
"""This function is called before a run is started.
You can use it for (slow) initializations.
NOTE: You are *not* able to send output to ports here, or access
Expand All @@ -60,6 +60,8 @@ def prepare():
oport_tab.set_metadata_value('table_header', ['Time Received', 'Frame Time'])
oport_tab.set_metadata_value('data_name_proposal', 'events/table')

return True


def start():
"""This function is called immediately when a run is started.
Expand Down

0 comments on commit b002a29

Please sign in to comment.