This project automates process of creating a PYNQ Z1/Z2 Overlay in Vivado, generates a custom Juypter Notebook template and uploads to a target PYNQ FPGA.
When the notebook is re-run, the entire script is reloaded and all previously defined variables are cleared. However, manually created threads continues running because they are independent of the variable scoping. This leads to a situation where the thread is still trying to access variables that no longer exist in the current execution context. This has no effect on the functionality of the notebook but causes confusing error messages to appear. Additionally, these threads may continue using resources in the background.
Changes
Add a "name" property to the created thread in the generate_io_visuals() function ("work")
One of the first steps in the .py file is to find and kill all running threads with the name "work"
Catch and handle any "NameError" thrown in the work() function
When the notebook is re-run, the entire script is reloaded and all previously defined variables are cleared. However, manually created threads continues running because they are independent of the variable scoping. This leads to a situation where the thread is still trying to access variables that no longer exist in the current execution context. This has no effect on the functionality of the notebook but causes confusing error messages to appear. Additionally, these threads may continue using resources in the background.
Changes
generate_io_visuals()
function ("work").py
file is to find and kill all running threads with the name "work"