{#
Common Header Template for TCL Scripts

This template generates standardized headers for all TCL scripts.

Context variables expected:
- title: Header title
- device: Device information (optional)
- board: Board information (optional)
- meta: Metadata (generated_time, etc.)
#}
#==============================================================================
# {{ title }}
#==============================================================================
{% if device %}
# Device: {{ device.vendor_id }}:{{ device.device_id }}{% if device.class_code %} (Class: {{ device.class_code }}){% endif %}
{% endif %}
{% from "_helpers.j2" import board_name, board_fpga_part, safe_board_name, safe_board_fpga_part %}
{% if board is string %}
# Board: {{ safe_board_name(board) }}
# FPGA Part: {{ safe_board_fpga_part(board) }}
{% elif board %}
# Board: {{ board_name(board) }}
# FPGA Part: {{ board_fpga_part(board) }}
{% endif %}
{% if meta and meta.generated_time %}
# Generated: {{ meta.generated_time }}
{% endif %}
#==============================================================================