feat: add M95M02-only GAS and EEPROM profiles
Expose the existing registers through Modbus and service CAN using one GAS provider only in M95M02 builds. Include the EEPROM layout/driver, LOAD protection and calibration, firmware identity and shared CCS build workflow. Add transport/profile and SCI8 validation tests, documentation and the checked M95M02 firmware image.
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
"""Check SPI wire address widths for both production EEPROM configurations."""
|
||||
from pathlib import Path
|
||||
import subprocess
|
||||
import os
|
||||
import shutil
|
||||
import tempfile
|
||||
|
||||
root = Path(__file__).resolve().parents[2]
|
||||
protocol = root.parent / 'newProject/SETGUI/third_party/templates/c/set-protocol'
|
||||
compiler = os.environ.get('CC') or shutil.which('gcc') or 'C:/msys64/mingw64/bin/gcc.exe'
|
||||
os.environ['PATH'] = str(Path(compiler).resolve().parent) + os.pathsep + os.environ['PATH']
|
||||
with tempfile.TemporaryDirectory() as folder:
|
||||
for profile in (0, 1):
|
||||
exe = Path(folder) / f'spi{profile}.exe'
|
||||
subprocess.run([compiler, '-std=c99',
|
||||
f'-DEEPROM_M95M02={profile}', '-Itests/eeprom_profiles/stubs',
|
||||
'-ISource/Internal/Include', '-I' + str(protocol),
|
||||
'tests/eeprom_profiles/spi_test.c', '-o', str(exe)],
|
||||
cwd=root, check=True)
|
||||
subprocess.run([str(exe)], check=True, timeout=10)
|
||||
print(f'PASS SPI profile {profile}')
|
||||
Reference in New Issue
Block a user