Skip to content

PSR record not per V4.2007 spec. Packing with __repr__ through an error. #61

Description

@dmitry5999

Tasks/Steps/Elements

PSR record packing defined incorrectly.
Platform: Advantest SmarTest 8
Problem appear when there is a list of patterns in the record.
PAT_LBL is a list of patterns (long names) so record length is more than 3000.
LOCP_CNT is always 0 after unpacking.

Trying to write STDF is unsuccessful - always complains about wrong record length.
Class defining PSR record relies on correct definition of the LOCP_CNT.
OPT_FLAG in the PSR.py defined as OPT_FLG. (as per spec, but _pack() relies on OPT_FLAG.
to fix that each PSR record should be modified (or parser need to be changed):

for REC in rec_list:
if REC.id == "PSR":
locp_cnt = len(REC.get_fields('PAT_LBL')[3])
REC.set_value('LOCP_CNT', locp_cnt)
REC.set_value('TOTP_CNT', int(psr_num))
REC.set_value('FILE_UID', REC.get_fields('PAT_FILE')[3])
REC.set_value('ATPG_DSC', REC.get_fields('PAT_FILE')[3])
REC.set_value('SRC_ID', REC.get_fields('PAT_FILE')[3])

Versions checklist

  • Spyder version: >= 5
  • Python version: 3.7, 3.8
  • Qt version: all
  • PyQt version: all
  • Operating System name/version:
    • server : Ubuntu 20.04 Linux (aarch64 on RPI)
    • client : Windows/Linux/macOS

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions