📦 版本
✨支持大/小端格式输出
🛠️ 使用
配置帧及对应测试输入帧,以实现硬件通路的简单测试,后续将芯片实际测试输出帧与预期结果进行对比即可。
⚠️ 由于配置帧/测试帧I型需要配合串口配置使用,因此目前仅采用配置/测试帧II型方案,且 CHIP_ADDR 与 CORE*_ADDR 均固定为 (0, 0)。
-
实例化
PAITest。在这个版本下,参数test_chip_coord的优先级大于direction;当仅配置dirction时通过此计算test_chip_coord,否则使用test_chip_coord参数from paitest import paitest # Set the address of chip under test and the test chip address. PAITestManager = paitest("EAST", (0, 0), test_chip_coord=(1, 0))
-
Get1GroupForNCoresWithNParams,产生1组针对N个核的配置-测试帧,每个核配置不同参数。可以指定单个需要屏蔽的核坐标groups = 10 # Generate 10 groups save_to_dir="./test" # Save frames into ./test directory # Generate configuration frames, testin & testout frames cf, ti, to = PAITestManager.Get1GroupForNCoresWithNParams(groups, save_dir=save_to_dir, verbose=True) # Mask a cord coordinate so that avoid generating the same coordinate. cf, ti, to = PAITestManager.Get1GroupForNCoresWithNParams(groups, save_dir=save_to_dir, masked_core_coord=(12, 16), gen_txt=True)
⚠️ 指定
verbose=True以开启日志显示,默认关闭 -
Get1GroupForNCoresWith1Param,产生1组针对N个核的配置-测试帧,每个核配置相同参数。可以指定单个需要屏蔽的核坐标# Same as Get1GroupForNCoresWithNParams cf, ti, to = PAITestManager.Get1GroupForNCoresWith1Param(10, save_dir="./test")
-
GetNGroupsFor1CoreWithNParams,产生N组针对1个核的配置-测试帧,每个核配置不同参数。可以指定单个需要屏蔽的核坐标# Same as Get1GroupForNCoresWithNParams cf, ti, to = PAITestManager.GetNGroupsFor1CoreWithNParams(1, save_dir="./test")
-
ReplaceCoreCoord,替换单个或一组帧中的CORE_ADDR为指定坐标# Replaced core coordinate with (9, 9) replaced = PAITestManager.ReplaceCoreCoord(original_frames, (9, 9))
⚠️ 一组指一组完整的配置帧,包含3帧。对于测试输入帧,即为单帧。
-
SaveFrames,保存帧数据至指定文件,支持.bin或.txt格式,支持指定大/小端输出# Save into binary files with big-edian format(default) PAITestManager.SaveFrames("./test/config.bin", replaced, byteorder="big") # Or text files PAITestManager.SaveFrames("./test/config.txt", replaced)
⚠️ 指定
byteorder="big"/"little"以大/小端格式储存帧数据,默认大端
🗓️ TODO
- 上板验证
- 参数检验
- 配置/测试帧III/IV型
Metadata
Release files for paitest 1.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| paitest-1.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Release files / paitest-1.1.1-py3-none-any.whl
| Download URL | paitest-1.1.1-py3-none-any.whl |
|---|---|
| Size | 15.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5c5441ae7773d7d987f4eb6ee2850b3ef3ab7b88c85f99bb808e0fac29490019
|
|
BLAKE2b-256 checksum How to use checksums |
24dc6c092afae0d1d4d57cad1f4d2c272b42b4e63d98d07f6cc679a7a77fae76
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.5.1 CPython/3.10.9 Linux/5.15.0-1042-azure
|