Compare commits
8 Commits
sample-del
...
91307f1985
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
91307f1985 | ||
|
|
b343e74a12 | ||
|
|
011bfe2450 | ||
|
|
e52c86ea1a | ||
|
|
f1ae60c69f | ||
|
|
c906e8ac66 | ||
|
|
dff8489c36 | ||
|
|
030479a962 |
BIN
ad_solver.6dgoloo5nyv74ie878md8rtxa.rcgu.o
Normal file
BIN
ad_solver.6dgoloo5nyv74ie878md8rtxa.rcgu.o
Normal file
Binary file not shown.
BIN
ad_solver.ad_solver.cdfee8e00be01766-cgu.0.rcgu.o
Normal file
BIN
ad_solver.ad_solver.cdfee8e00be01766-cgu.0.rcgu.o
Normal file
Binary file not shown.
BIN
ad_solver.exe
Normal file
BIN
ad_solver.exe
Normal file
Binary file not shown.
BIN
ad_solver.pdb
Normal file
BIN
ad_solver.pdb
Normal file
Binary file not shown.
BIN
devkit/__pycache__/sensor_server.cpython-314.pyc
Normal file
BIN
devkit/__pycache__/sensor_server.cpython-314.pyc
Normal file
Binary file not shown.
BIN
devkit/__pycache__/sensor_stream_pb2.cpython-314.pyc
Normal file
BIN
devkit/__pycache__/sensor_stream_pb2.cpython-314.pyc
Normal file
Binary file not shown.
BIN
devkit/__pycache__/sensor_stream_pb2_grpc.cpython-314.pyc
Normal file
BIN
devkit/__pycache__/sensor_stream_pb2_grpc.cpython-314.pyc
Normal file
Binary file not shown.
2188
devkit/build/je-skin-devkit-server/Analysis-00.toc
Normal file
2188
devkit/build/je-skin-devkit-server/Analysis-00.toc
Normal file
File diff suppressed because it is too large
Load Diff
359
devkit/build/je-skin-devkit-server/EXE-00.toc
Normal file
359
devkit/build/je-skin-devkit-server/EXE-00.toc
Normal file
@@ -0,0 +1,359 @@
|
||||
('d:\\JE-Skin-main\\devkit\\dist\\je-skin-devkit-server.exe',
|
||||
True,
|
||||
False,
|
||||
False,
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\bootloader\\images\\icon-console.ico',
|
||||
None,
|
||||
False,
|
||||
False,
|
||||
b'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<assembly xmlns='
|
||||
b'"urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">\n <trustInfo x'
|
||||
b'mlns="urn:schemas-microsoft-com:asm.v3">\n <security>\n <requested'
|
||||
b'Privileges>\n <requestedExecutionLevel level="asInvoker" uiAccess='
|
||||
b'"false"/>\n </requestedPrivileges>\n </security>\n </trustInfo>\n '
|
||||
b'<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">\n <'
|
||||
b'application>\n <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f'
|
||||
b'0}"/>\n <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>\n '
|
||||
b' <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>\n <s'
|
||||
b'upportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>\n <supporte'
|
||||
b'dOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>\n </application>\n <'
|
||||
b'/compatibility>\n <application xmlns="urn:schemas-microsoft-com:asm.v3">'
|
||||
b'\n <windowsSettings>\n <longPathAware xmlns="http://schemas.micros'
|
||||
b'oft.com/SMI/2016/WindowsSettings">true</longPathAware>\n </windowsSett'
|
||||
b'ings>\n </application>\n <dependency>\n <dependentAssembly>\n <ass'
|
||||
b'emblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version='
|
||||
b'"6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" langua'
|
||||
b'ge="*"/>\n </dependentAssembly>\n </dependency>\n</assembly>',
|
||||
True,
|
||||
False,
|
||||
None,
|
||||
None,
|
||||
None,
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\je-skin-devkit-server.pkg',
|
||||
[('pyi-contents-directory _internal', '', 'OPTION'),
|
||||
('PYZ-00.pyz',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\PYZ-00.pyz',
|
||||
'PYZ'),
|
||||
('struct',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\struct.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod01_archive',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod01_archive.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod02_importers',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod02_importers.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod03_ctypes',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod03_ctypes.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod04_pywin32',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod04_pywin32.pyc',
|
||||
'PYMODULE'),
|
||||
('pyiboot01_bootstrap',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\loader\\pyiboot01_bootstrap.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_inspect',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_inspect.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_pkgutil',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_pkgutil.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_multiprocessing',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_multiprocessing.py',
|
||||
'PYSOURCE'),
|
||||
('sensor_server', 'D:\\JE-Skin-main\\devkit\\sensor_server.py', 'PYSOURCE'),
|
||||
('python314.dll', 'C:\\Python314\\python314.dll', 'BINARY'),
|
||||
('numpy.libs\\msvcp140-a4c2229bdc2a2a630acdc095b4d86008.dll',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy.libs\\msvcp140-a4c2229bdc2a2a630acdc095b4d86008.dll',
|
||||
'BINARY'),
|
||||
('numpy.libs\\libscipy_openblas64_-63c857e738469261263c764a36be9436.dll',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy.libs\\libscipy_openblas64_-63c857e738469261263c764a36be9436.dll',
|
||||
'BINARY'),
|
||||
('select.pyd', 'C:\\Python314\\DLLs\\select.pyd', 'EXTENSION'),
|
||||
('_multiprocessing.pyd',
|
||||
'C:\\Python314\\DLLs\\_multiprocessing.pyd',
|
||||
'EXTENSION'),
|
||||
('_zstd.pyd', 'C:\\Python314\\DLLs\\_zstd.pyd', 'EXTENSION'),
|
||||
('pyexpat.pyd', 'C:\\Python314\\DLLs\\pyexpat.pyd', 'EXTENSION'),
|
||||
('_lzma.pyd', 'C:\\Python314\\DLLs\\_lzma.pyd', 'EXTENSION'),
|
||||
('_bz2.pyd', 'C:\\Python314\\DLLs\\_bz2.pyd', 'EXTENSION'),
|
||||
('_ssl.pyd', 'C:\\Python314\\DLLs\\_ssl.pyd', 'EXTENSION'),
|
||||
('_hashlib.pyd', 'C:\\Python314\\DLLs\\_hashlib.pyd', 'EXTENSION'),
|
||||
('unicodedata.pyd', 'C:\\Python314\\DLLs\\unicodedata.pyd', 'EXTENSION'),
|
||||
('_decimal.pyd', 'C:\\Python314\\DLLs\\_decimal.pyd', 'EXTENSION'),
|
||||
('_socket.pyd', 'C:\\Python314\\DLLs\\_socket.pyd', 'EXTENSION'),
|
||||
('_ctypes.pyd', 'C:\\Python314\\DLLs\\_ctypes.pyd', 'EXTENSION'),
|
||||
('_queue.pyd', 'C:\\Python314\\DLLs\\_queue.pyd', 'EXTENSION'),
|
||||
('numpy\\_core\\_multiarray_tests.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\_core\\_multiarray_tests.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\_core\\_multiarray_umath.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\_core\\_multiarray_umath.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('_wmi.pyd', 'C:\\Python314\\DLLs\\_wmi.pyd', 'EXTENSION'),
|
||||
('_overlapped.pyd', 'C:\\Python314\\DLLs\\_overlapped.pyd', 'EXTENSION'),
|
||||
('_asyncio.pyd', 'C:\\Python314\\DLLs\\_asyncio.pyd', 'EXTENSION'),
|
||||
('numpy\\linalg\\_umath_linalg.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\linalg\\_umath_linalg.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\mtrand.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\mtrand.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\bit_generator.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\bit_generator.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_sfc64.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_sfc64.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_philox.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_philox.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_pcg64.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_pcg64.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_mt19937.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_mt19937.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_generator.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_generator.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_common.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_common.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_bounded_integers.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_bounded_integers.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\fft\\_pocketfft_umath.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\fft\\_pocketfft_umath.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('_elementtree.pyd', 'C:\\Python314\\DLLs\\_elementtree.pyd', 'EXTENSION'),
|
||||
('grpc\\_cython\\cygrpc.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\cygrpc.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('google\\_upb\\_message.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\google\\_upb\\_message.pyd',
|
||||
'EXTENSION'),
|
||||
('grpc_tools\\_protoc_compiler.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc_tools\\_protoc_compiler.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-time-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-time-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-string-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-process-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-process-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-math-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-math-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140.dll', 'C:\\Python314\\VCRUNTIME140.dll', 'BINARY'),
|
||||
('VCRUNTIME140_1.dll', 'C:\\Python314\\VCRUNTIME140_1.dll', 'BINARY'),
|
||||
('api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-private-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-private-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libcrypto-3.dll', 'C:\\Python314\\DLLs\\libcrypto-3.dll', 'BINARY'),
|
||||
('libssl-3.dll', 'C:\\Python314\\DLLs\\libssl-3.dll', 'BINARY'),
|
||||
('libffi-8.dll', 'C:\\Python314\\DLLs\\libffi-8.dll', 'BINARY'),
|
||||
('python3.dll', 'C:\\Python314\\python3.dll', 'BINARY'),
|
||||
('ucrtbase.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\ucrtbase.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-profile-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-profile-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-memory-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-memory-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l2-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-file-l2-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-debug-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-debug-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-2-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-file-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-string-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-localization-l1-2-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-localization-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-util-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-util-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-console-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-console-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-2-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-synch-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-handle-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-handle-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-fibers-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-fibers-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-heap-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-file-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-synch-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('grpc\\_cython\\_credentials\\roots.pem',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\_credentials\\roots.pem',
|
||||
'DATA'),
|
||||
('grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.h',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.h',
|
||||
'DATA'),
|
||||
('grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.cc',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.cc',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\common\\pythoncapi-compat\\COPYING',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\common\\pythoncapi-compat\\COPYING',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\INSTALLER',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\INSTALLER',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\REQUESTED',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\REQUESTED',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\fft\\pocketfft\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\fft\\pocketfft\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\splitmix64\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\splitmix64\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\linalg\\lapack_lite\\LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\linalg\\lapack_lite\\LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\include\\numpy\\libdivide\\LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\include\\numpy\\libdivide\\LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\RECORD',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\RECORD',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\WHEEL',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\WHEEL',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\sfc64\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\sfc64\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\philox\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\philox\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\pcg64\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\pcg64\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\ma\\LICENSE',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\ma\\LICENSE',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\umath\\svml\\LICENSE',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\umath\\svml\\LICENSE',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\entry_points.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\entry_points.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\mt19937\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\mt19937\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\multiarray\\dragon4_LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\multiarray\\dragon4_LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\METADATA',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\METADATA',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\DELVEWHEEL',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\DELVEWHEEL',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\highway\\LICENSE',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\highway\\LICENSE',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\distributions\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\distributions\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\npysort\\x86-simd-sort\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\npysort\\x86-simd-sort\\LICENSE.md',
|
||||
'DATA'),
|
||||
('base_library.zip',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\base_library.zip',
|
||||
'DATA')],
|
||||
[],
|
||||
False,
|
||||
False,
|
||||
1779678963,
|
||||
[('run.exe',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\bootloader\\Windows-64bit-intel\\run.exe',
|
||||
'EXECUTABLE')],
|
||||
'C:\\Python314\\python314.dll')
|
||||
337
devkit/build/je-skin-devkit-server/PKG-00.toc
Normal file
337
devkit/build/je-skin-devkit-server/PKG-00.toc
Normal file
@@ -0,0 +1,337 @@
|
||||
('d:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\je-skin-devkit-server.pkg',
|
||||
{'BINARY': True,
|
||||
'DATA': True,
|
||||
'EXECUTABLE': True,
|
||||
'EXTENSION': True,
|
||||
'PYMODULE': True,
|
||||
'PYSOURCE': True,
|
||||
'PYZ': False,
|
||||
'SPLASH': True,
|
||||
'SYMLINK': False},
|
||||
[('pyi-contents-directory _internal', '', 'OPTION'),
|
||||
('PYZ-00.pyz',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\PYZ-00.pyz',
|
||||
'PYZ'),
|
||||
('struct',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\struct.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod01_archive',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod01_archive.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod02_importers',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod02_importers.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod03_ctypes',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod03_ctypes.pyc',
|
||||
'PYMODULE'),
|
||||
('pyimod04_pywin32',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\localpycs\\pyimod04_pywin32.pyc',
|
||||
'PYMODULE'),
|
||||
('pyiboot01_bootstrap',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\loader\\pyiboot01_bootstrap.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_inspect',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_inspect.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_pkgutil',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_pkgutil.py',
|
||||
'PYSOURCE'),
|
||||
('pyi_rth_multiprocessing',
|
||||
'C:\\Python314\\Lib\\site-packages\\PyInstaller\\hooks\\rthooks\\pyi_rth_multiprocessing.py',
|
||||
'PYSOURCE'),
|
||||
('sensor_server', 'D:\\JE-Skin-main\\devkit\\sensor_server.py', 'PYSOURCE'),
|
||||
('python314.dll', 'C:\\Python314\\python314.dll', 'BINARY'),
|
||||
('numpy.libs\\msvcp140-a4c2229bdc2a2a630acdc095b4d86008.dll',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy.libs\\msvcp140-a4c2229bdc2a2a630acdc095b4d86008.dll',
|
||||
'BINARY'),
|
||||
('numpy.libs\\libscipy_openblas64_-63c857e738469261263c764a36be9436.dll',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy.libs\\libscipy_openblas64_-63c857e738469261263c764a36be9436.dll',
|
||||
'BINARY'),
|
||||
('select.pyd', 'C:\\Python314\\DLLs\\select.pyd', 'EXTENSION'),
|
||||
('_multiprocessing.pyd',
|
||||
'C:\\Python314\\DLLs\\_multiprocessing.pyd',
|
||||
'EXTENSION'),
|
||||
('_zstd.pyd', 'C:\\Python314\\DLLs\\_zstd.pyd', 'EXTENSION'),
|
||||
('pyexpat.pyd', 'C:\\Python314\\DLLs\\pyexpat.pyd', 'EXTENSION'),
|
||||
('_lzma.pyd', 'C:\\Python314\\DLLs\\_lzma.pyd', 'EXTENSION'),
|
||||
('_bz2.pyd', 'C:\\Python314\\DLLs\\_bz2.pyd', 'EXTENSION'),
|
||||
('_ssl.pyd', 'C:\\Python314\\DLLs\\_ssl.pyd', 'EXTENSION'),
|
||||
('_hashlib.pyd', 'C:\\Python314\\DLLs\\_hashlib.pyd', 'EXTENSION'),
|
||||
('unicodedata.pyd', 'C:\\Python314\\DLLs\\unicodedata.pyd', 'EXTENSION'),
|
||||
('_decimal.pyd', 'C:\\Python314\\DLLs\\_decimal.pyd', 'EXTENSION'),
|
||||
('_socket.pyd', 'C:\\Python314\\DLLs\\_socket.pyd', 'EXTENSION'),
|
||||
('_ctypes.pyd', 'C:\\Python314\\DLLs\\_ctypes.pyd', 'EXTENSION'),
|
||||
('_queue.pyd', 'C:\\Python314\\DLLs\\_queue.pyd', 'EXTENSION'),
|
||||
('numpy\\_core\\_multiarray_tests.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\_core\\_multiarray_tests.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\_core\\_multiarray_umath.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\_core\\_multiarray_umath.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('_wmi.pyd', 'C:\\Python314\\DLLs\\_wmi.pyd', 'EXTENSION'),
|
||||
('_overlapped.pyd', 'C:\\Python314\\DLLs\\_overlapped.pyd', 'EXTENSION'),
|
||||
('_asyncio.pyd', 'C:\\Python314\\DLLs\\_asyncio.pyd', 'EXTENSION'),
|
||||
('numpy\\linalg\\_umath_linalg.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\linalg\\_umath_linalg.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\mtrand.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\mtrand.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\bit_generator.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\bit_generator.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_sfc64.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_sfc64.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_philox.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_philox.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_pcg64.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_pcg64.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_mt19937.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_mt19937.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_generator.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_generator.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_common.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_common.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\random\\_bounded_integers.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\random\\_bounded_integers.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('numpy\\fft\\_pocketfft_umath.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy\\fft\\_pocketfft_umath.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('_elementtree.pyd', 'C:\\Python314\\DLLs\\_elementtree.pyd', 'EXTENSION'),
|
||||
('grpc\\_cython\\cygrpc.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\cygrpc.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('google\\_upb\\_message.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\google\\_upb\\_message.pyd',
|
||||
'EXTENSION'),
|
||||
('grpc_tools\\_protoc_compiler.cp314-win_amd64.pyd',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc_tools\\_protoc_compiler.cp314-win_amd64.pyd',
|
||||
'EXTENSION'),
|
||||
('api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-filesystem-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-locale-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-time-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-time-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-environment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-runtime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-convert-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-string-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-process-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-process-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-math-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-math-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-stdio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-conio-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('VCRUNTIME140.dll', 'C:\\Python314\\VCRUNTIME140.dll', 'BINARY'),
|
||||
('VCRUNTIME140_1.dll', 'C:\\Python314\\VCRUNTIME140_1.dll', 'BINARY'),
|
||||
('api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-utility-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-crt-private-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-crt-private-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('libcrypto-3.dll', 'C:\\Python314\\DLLs\\libcrypto-3.dll', 'BINARY'),
|
||||
('libssl-3.dll', 'C:\\Python314\\DLLs\\libssl-3.dll', 'BINARY'),
|
||||
('libffi-8.dll', 'C:\\Python314\\DLLs\\libffi-8.dll', 'BINARY'),
|
||||
('python3.dll', 'C:\\Python314\\python3.dll', 'BINARY'),
|
||||
('ucrtbase.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\ucrtbase.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-profile-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-profile-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-processthreads-l1-1-1.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-errorhandling-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-memory-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-memory-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l2-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-file-l2-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-processthreads-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-debug-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-debug-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-2-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-file-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-string-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-string-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-namedpipe-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-timezone-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-rtlsupport-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-localization-l1-2-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-localization-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-datetime-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-util-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-util-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-console-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-console-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-2-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-synch-l1-2-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-interlocked-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-handle-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-handle-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-libraryloader-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-fibers-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-fibers-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-heap-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-heap-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-file-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-file-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-sysinfo-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-processenvironment-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('api-ms-win-core-synch-l1-1-0.dll',
|
||||
'C:\\Users\\Administrator\\miniconda3\\api-ms-win-core-synch-l1-1-0.dll',
|
||||
'BINARY'),
|
||||
('grpc\\_cython\\_credentials\\roots.pem',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\_credentials\\roots.pem',
|
||||
'DATA'),
|
||||
('grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.h',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.h',
|
||||
'DATA'),
|
||||
('grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.cc',
|
||||
'C:\\Python314\\Lib\\site-packages\\grpc\\_cython\\_cygrpc\\private_key_signing\\private_key_signer_py_wrapper.cc',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\common\\pythoncapi-compat\\COPYING',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\common\\pythoncapi-compat\\COPYING',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\INSTALLER',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\INSTALLER',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\REQUESTED',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\REQUESTED',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\fft\\pocketfft\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\fft\\pocketfft\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\splitmix64\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\splitmix64\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\linalg\\lapack_lite\\LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\linalg\\lapack_lite\\LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\include\\numpy\\libdivide\\LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\include\\numpy\\libdivide\\LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\RECORD',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\RECORD',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\WHEEL',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\WHEEL',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\sfc64\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\sfc64\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\philox\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\philox\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\pcg64\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\pcg64\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\ma\\LICENSE',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\ma\\LICENSE',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\umath\\svml\\LICENSE',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\umath\\svml\\LICENSE',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\entry_points.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\entry_points.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\mt19937\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\mt19937\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\multiarray\\dragon4_LICENSE.txt',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\multiarray\\dragon4_LICENSE.txt',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\METADATA',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\METADATA',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\DELVEWHEEL',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\DELVEWHEEL',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\highway\\LICENSE',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\highway\\LICENSE',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\distributions\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\random\\src\\distributions\\LICENSE.md',
|
||||
'DATA'),
|
||||
('numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\npysort\\x86-simd-sort\\LICENSE.md',
|
||||
'C:\\Python314\\Lib\\site-packages\\numpy-2.4.4.dist-info\\licenses\\numpy\\_core\\src\\npysort\\x86-simd-sort\\LICENSE.md',
|
||||
'DATA'),
|
||||
('base_library.zip',
|
||||
'd:\\JE-Skin-main\\devkit\\build\\je-skin-devkit-server\\base_library.zip',
|
||||
'DATA')],
|
||||
'python314.dll',
|
||||
False,
|
||||
False,
|
||||
False,
|
||||
[],
|
||||
None,
|
||||
None,
|
||||
None)
|
||||
BIN
devkit/build/je-skin-devkit-server/PYZ-00.pyz
Normal file
BIN
devkit/build/je-skin-devkit-server/PYZ-00.pyz
Normal file
Binary file not shown.
1595
devkit/build/je-skin-devkit-server/PYZ-00.toc
Normal file
1595
devkit/build/je-skin-devkit-server/PYZ-00.toc
Normal file
File diff suppressed because it is too large
Load Diff
BIN
devkit/build/je-skin-devkit-server/base_library.zip
Normal file
BIN
devkit/build/je-skin-devkit-server/base_library.zip
Normal file
Binary file not shown.
BIN
devkit/build/je-skin-devkit-server/je-skin-devkit-server.pkg
Normal file
BIN
devkit/build/je-skin-devkit-server/je-skin-devkit-server.pkg
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
devkit/build/je-skin-devkit-server/localpycs/pyimod03_ctypes.pyc
Normal file
BIN
devkit/build/je-skin-devkit-server/localpycs/pyimod03_ctypes.pyc
Normal file
Binary file not shown.
Binary file not shown.
BIN
devkit/build/je-skin-devkit-server/localpycs/struct.pyc
Normal file
BIN
devkit/build/je-skin-devkit-server/localpycs/struct.pyc
Normal file
Binary file not shown.
@@ -0,0 +1,245 @@
|
||||
|
||||
This file lists modules PyInstaller was not able to find. This does not
|
||||
necessarily mean these modules are required for running your program. Both
|
||||
Python's standard library and 3rd-party Python packages often conditionally
|
||||
import optional modules, some of which may be available only on certain
|
||||
platforms.
|
||||
|
||||
Types of import:
|
||||
* top-level: imported at the top-level - look at these first
|
||||
* conditional: imported within an if-statement
|
||||
* delayed: imported within a function
|
||||
* optional: imported within a try-except-statement
|
||||
|
||||
IMPORTANT: Do NOT post this list to the issue-tracker. Use it as a basis for
|
||||
tracking down the missing module yourself. Thanks!
|
||||
|
||||
missing module named pwd - imported by posixpath (delayed, conditional, optional), shutil (delayed, optional), tarfile (optional), pathlib (optional), netrc (delayed, optional), subprocess (delayed, conditional, optional), http.server (delayed, optional)
|
||||
missing module named grp - imported by shutil (delayed, optional), tarfile (optional), pathlib (optional), subprocess (delayed, conditional, optional)
|
||||
missing module named 'collections.abc' - imported by _colorize (top-level), typing (top-level), traceback (top-level), logging (top-level), selectors (top-level), http.client (top-level), importlib.resources.readers (top-level), inspect (top-level), tracemalloc (top-level), multiprocessing.managers (top-level), typing_extensions (top-level), asyncio.base_events (top-level), asyncio.coroutines (top-level), grpc.aio._metadata (top-level), google.protobuf.internal.containers (top-level), google.protobuf.internal.well_known_types (top-level), numpy._typing._array_like (top-level), numpy._typing._nested_sequence (conditional), numpy._typing._shape (top-level), numpy._typing._dtype_like (top-level), numpy.lib._function_base_impl (top-level), _pyrepl.types (top-level), numpy.lib._npyio_impl (top-level), numpy.random._common (top-level), numpy.random._generator (top-level), numpy.random.bit_generator (top-level), numpy.random.mtrand (top-level), numpy.polynomial._polybase (top-level), xml.etree.ElementTree (top-level)
|
||||
missing module named _posixsubprocess - imported by subprocess (conditional), multiprocessing.util (delayed)
|
||||
missing module named fcntl - imported by pathlib._os (optional), subprocess (optional)
|
||||
missing module named _posixshmem - imported by multiprocessing.resource_tracker (conditional), multiprocessing.shared_memory (conditional)
|
||||
missing module named _scproxy - imported by urllib.request (conditional)
|
||||
missing module named posix - imported by posixpath (optional), shutil (conditional), importlib._bootstrap_external (conditional), pathlib._os (optional), os (conditional, optional), _pyrepl.trace (conditional)
|
||||
missing module named resource - imported by posix (top-level)
|
||||
missing module named _frozen_importlib_external - imported by importlib._bootstrap (delayed), importlib (optional), importlib.abc (optional), zipimport (top-level)
|
||||
excluded module named _frozen_importlib - imported by importlib (optional), importlib.abc (optional), zipimport (top-level)
|
||||
missing module named multiprocessing.BufferTooShort - imported by multiprocessing (top-level), multiprocessing.connection (top-level)
|
||||
missing module named multiprocessing.AuthenticationError - imported by multiprocessing (top-level), multiprocessing.forkserver (top-level), multiprocessing.connection (top-level)
|
||||
missing module named multiprocessing.get_context - imported by multiprocessing (top-level), multiprocessing.pool (top-level), multiprocessing.managers (top-level), multiprocessing.sharedctypes (top-level)
|
||||
missing module named multiprocessing.TimeoutError - imported by multiprocessing (top-level), multiprocessing.pool (top-level)
|
||||
missing module named multiprocessing.set_start_method - imported by multiprocessing (top-level), multiprocessing.spawn (top-level)
|
||||
missing module named multiprocessing.get_start_method - imported by multiprocessing (top-level), multiprocessing.spawn (top-level)
|
||||
missing module named pyimod02_importers - imported by C:\Python314\Lib\site-packages\PyInstaller\hooks\rthooks\pyi_rth_pkgutil.py (delayed)
|
||||
missing module named _dummy_thread - imported by numpy._core.arrayprint (optional)
|
||||
missing module named 'numpy_distutils.cpuinfo' - imported by numpy.f2py.diagnose (delayed, conditional, optional)
|
||||
missing module named 'numpy_distutils.fcompiler' - imported by numpy.f2py.diagnose (delayed, conditional, optional)
|
||||
missing module named 'numpy_distutils.command' - imported by numpy.f2py.diagnose (delayed, conditional, optional)
|
||||
missing module named numpy_distutils - imported by numpy.f2py.diagnose (delayed, optional)
|
||||
missing module named charset_normalizer - imported by numpy.f2py.crackfortran (optional)
|
||||
missing module named vms_lib - imported by platform (delayed, optional)
|
||||
missing module named 'java.lang' - imported by platform (delayed, optional)
|
||||
missing module named java - imported by platform (delayed)
|
||||
missing module named psutil - imported by numpy.testing._private.utils (delayed, optional)
|
||||
missing module named termios - imported by tty (top-level), _pyrepl.pager (delayed, optional)
|
||||
missing module named readline - imported by cmd (delayed, conditional, optional), code (delayed, conditional, optional), pdb (delayed, conditional, optional), rlcompleter (optional)
|
||||
missing module named win32pdh - imported by numpy.testing._private.utils (delayed, conditional)
|
||||
missing module named _typeshed - imported by numpy.random.bit_generator (top-level)
|
||||
missing module named numpy.random.RandomState - imported by numpy.random (top-level), numpy.random._generator (top-level)
|
||||
missing module named pyodide_js - imported by threadpoolctl (delayed, optional)
|
||||
missing module named numpy._core.zeros - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.vstack - imported by numpy._core (top-level), numpy.lib._shape_base_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.void - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.vecmat - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.vecdot - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.ushort - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.unsignedinteger - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.ulonglong - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.ulong - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.uintp - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.uintc - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.uint64 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.uint32 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.uint16 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.uint - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.ubyte - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.trunc - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.true_divide - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.transpose - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.lib._function_base_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.trace - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.timedelta64 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.tensordot - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.tanh - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.tan - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.swapaxes - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.sum - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.subtract - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.str_ - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.square - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.sqrt - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional), numpy.fft._pocketfft (top-level)
|
||||
missing module named numpy._core.spacing - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.sort - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.sinh - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.single - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.signedinteger - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.signbit - imported by numpy._core (delayed), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.sign - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.short - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.rint - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.right_shift - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.result_type - imported by numpy._core (delayed), numpy.testing._private.utils (delayed), numpy (conditional), numpy.fft._pocketfft (top-level)
|
||||
missing module named numpy._core.remainder - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.reciprocal - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional), numpy.fft._pocketfft (top-level)
|
||||
missing module named numpy._core.radians - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.rad2deg - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.prod - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.power - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.positive - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.pi - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.outer - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.ones - imported by numpy._core (top-level), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.object_ - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.number - imported by numpy._core (delayed), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.not_equal - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.nextafter - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.newaxis - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.negative - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.ndarray - imported by numpy._core (top-level), numpy.testing._private.utils (top-level), numpy.lib._utils_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.multiply - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.moveaxis - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.modf - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.mod - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.minimum - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.maximum - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.max - imported by numpy._core (delayed), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.matvec - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.matrix_transpose - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.matmul - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.longlong - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.longdouble - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.long - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.logical_xor - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.logical_or - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.logical_not - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.logical_and - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.logaddexp2 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.logaddexp - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.log10 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.log2 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.log1p - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.log - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.linspace - imported by numpy._core (top-level), numpy.lib._index_tricks_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.less_equal - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.less - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.left_shift - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.ldexp - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.lcm - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.isscalar - imported by numpy._core (delayed), numpy.testing._private.utils (delayed), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.isnat - imported by numpy._core (top-level), numpy.testing._private.utils (top-level), numpy (conditional)
|
||||
missing module named numpy._core.isnan - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.isfinite - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.intp - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (top-level), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.integer - imported by numpy._core (conditional), numpy (conditional), numpy.fft._helper (top-level)
|
||||
missing module named numpy._core.intc - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.int64 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.int32 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.int16 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.int8 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.inf - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.inexact - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.iinfo - imported by numpy._core (top-level), numpy.lib._twodim_base_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.hypot - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.hstack - imported by numpy._core (top-level), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.heaviside - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.half - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.greater_equal - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.greater - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.gcd - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.frompyfunc - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.frexp - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.fmod - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.fmin - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.fmax - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.floor_divide - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.floor - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.floating - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.float_power - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.float32 - imported by numpy._core (top-level), numpy.testing._private.utils (top-level), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.float16 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.finfo - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.fabs - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.expm1 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.exp2 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.exp - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.euler_gamma - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.errstate - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.equal - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.empty_like - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional), numpy.fft._pocketfft (top-level)
|
||||
missing module named numpy._core.empty - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (top-level), numpy (conditional), numpy.fft._helper (top-level)
|
||||
missing module named numpy._core.e - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.double - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.dot - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.divmod - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.divide - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.diagonal - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.degrees - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.deg2rad - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.datetime64 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.csingle - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.cross - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.count_nonzero - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.cosh - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.cos - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.copysign - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.conjugate - imported by numpy._core (conditional), numpy (conditional), numpy.fft._pocketfft (top-level)
|
||||
missing module named numpy._core.conj - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.complexfloating - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.complex64 - imported by numpy._core (conditional), numpy (conditional), numpy._array_api_info (top-level)
|
||||
missing module named numpy._core.clongdouble - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.character - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.ceil - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.cdouble - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.cbrt - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.bytes_ - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.byte - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.bool_ - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.bitwise_xor - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.bitwise_or - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.bitwise_count - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.bitwise_and - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.atleast_3d - imported by numpy._core (top-level), numpy.lib._shape_base_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.atleast_2d - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.atleast_1d - imported by numpy._core (top-level), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.asarray - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.lib._array_utils_impl (top-level), numpy (conditional), numpy.fft._helper (top-level), numpy.fft._pocketfft (top-level)
|
||||
missing module named numpy._core.asanyarray - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.array_repr - imported by numpy._core (top-level), numpy.testing._private.utils (top-level), numpy (conditional)
|
||||
missing module named numpy._core.array2string - imported by numpy._core (delayed), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.array - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (top-level), numpy.lib._polynomial_impl (top-level), numpy (conditional)
|
||||
missing module named numpy._core.argsort - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.arctanh - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arctan2 - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arctan - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arcsinh - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arcsin - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arccosh - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arccos - imported by numpy._core (conditional), numpy (conditional)
|
||||
missing module named numpy._core.arange - imported by numpy._core (top-level), numpy.testing._private.utils (top-level), numpy (conditional), numpy.fft._helper (top-level)
|
||||
missing module named numpy._core.amin - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.amax - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named numpy._core.all - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy.testing._private.utils (delayed), numpy (conditional)
|
||||
missing module named numpy._core.add - imported by numpy._core (top-level), numpy.linalg._linalg (top-level), numpy (conditional)
|
||||
missing module named yaml - imported by numpy.__config__ (delayed)
|
||||
missing module named numpy._distributor_init_local - imported by numpy (optional), numpy._distributor_init (optional)
|
||||
missing module named defusedxml - imported by openpyxl.xml (delayed, optional)
|
||||
missing module named lxml - imported by openpyxl.xml (delayed, optional)
|
||||
missing module named 'defusedxml.ElementTree' - imported by openpyxl.xml.functions (conditional)
|
||||
missing module named 'lxml.etree' - imported by openpyxl.xml.functions (conditional)
|
||||
missing module named PIL - imported by openpyxl.drawing.image (optional)
|
||||
missing module named openpyxl.tests - imported by openpyxl.reader.excel (optional)
|
||||
missing module named google.protobuf.pyext._message - imported by google.protobuf.pyext (conditional, optional), google.protobuf.internal.api_implementation (conditional, optional), google.protobuf.descriptor (conditional), google.protobuf.pyext.cpp_message (conditional)
|
||||
missing module named google.protobuf.enable_deterministic_proto_serialization - imported by google.protobuf (optional), google.protobuf.internal.api_implementation (optional)
|
||||
missing module named google.protobuf.internal._api_implementation - imported by google.protobuf.internal (optional), google.protobuf.internal.api_implementation (optional)
|
||||
missing module named grpc_reflection - imported by grpc (optional)
|
||||
missing module named grpc_health - imported by grpc (optional)
|
||||
missing module named pkg_resources - imported by grpc_tools.protoc (conditional)
|
||||
26741
devkit/build/je-skin-devkit-server/xref-je-skin-devkit-server.html
Normal file
26741
devkit/build/je-skin-devkit-server/xref-je-skin-devkit-server.html
Normal file
File diff suppressed because it is too large
Load Diff
BIN
devkit/dist/je-skin-devkit-server.exe
vendored
Normal file
BIN
devkit/dist/je-skin-devkit-server.exe
vendored
Normal file
Binary file not shown.
BIN
devkit/je-skin-devkit-server.exe
Normal file
BIN
devkit/je-skin-devkit-server.exe
Normal file
Binary file not shown.
@@ -5,8 +5,8 @@ a = Analysis(
|
||||
['sensor_server.py'],
|
||||
pathex=[],
|
||||
binaries=[],
|
||||
datas=[('sensor_stream_pb2.py', '.'), ('sensor_stream_pb2_grpc.py', '.')],
|
||||
hiddenimports=['grpc', 'openpyxl', 'numpy'],
|
||||
datas=[],
|
||||
hiddenimports=[],
|
||||
hookspath=[],
|
||||
hooksconfig={},
|
||||
runtime_hooks=[],
|
||||
|
||||
@@ -26,7 +26,6 @@ import sys
|
||||
import time
|
||||
from concurrent import futures
|
||||
from pathlib import Path
|
||||
|
||||
import grpc
|
||||
import sensor_stream_pb2
|
||||
import sensor_stream_pb2_grpc
|
||||
@@ -231,30 +230,56 @@ def _append_analysis_log(source_csv: str, stats: dict):
|
||||
class SensorPushServicer(sensor_stream_pb2_grpc.SensorPushServicer):
|
||||
"""接收实时传感器帧(streaming)"""
|
||||
|
||||
_csv_path = None # 类变量,记录当前 CSV 路径
|
||||
|
||||
def __init__(self):
|
||||
self.frame_count = 0
|
||||
self.last_report_time = time.time()
|
||||
self.last_angle = None
|
||||
self._csv_file = None
|
||||
self._csv_writer = None
|
||||
|
||||
def _open_csv(self):
|
||||
"""打开一个新的 CSV 文件用于持续写入"""
|
||||
ts = time.strftime("%Y%m%d_%H%M%S")
|
||||
SensorPushServicer._csv_path = os.path.join(os.getcwd(), f"sensor_log_{ts}.csv")
|
||||
self._csv_file = open(SensorPushServicer._csv_path, "w", newline="", encoding="utf-8-sig")
|
||||
self._csv_writer = csv.writer(self._csv_file)
|
||||
header = ["seq", "timestamp_ms", "dts_ms", "angle", "magnitude", "state", "cop_x", "cop_y", "base_x", "base_y", "resultant_force"] + [f"ch{i}" for i in range(SENSOR_ROWS * SENSOR_COLS)]
|
||||
self._csv_writer.writerow(header)
|
||||
self._csv_file.flush()
|
||||
print(f"[SensorPush] CSV logging to: {SensorPushServicer._csv_path}")
|
||||
|
||||
def _close_csv(self):
|
||||
"""关闭 CSV 文件"""
|
||||
if self._csv_file:
|
||||
self._csv_file.close()
|
||||
print(f"[SensorPush] CSV saved: {SensorPushServicer._csv_path}")
|
||||
self._csv_file = None
|
||||
self._csv_writer = None
|
||||
|
||||
def Upload(self, request_iterator, context):
|
||||
print("[SensorPush] Client connected, waiting for frames...")
|
||||
reset_baseline()
|
||||
self.last_angle = None
|
||||
self.frame_count = 0
|
||||
self._open_csv()
|
||||
|
||||
for frame in request_iterator:
|
||||
self.frame_count += 1
|
||||
angle = 0.0
|
||||
magnitude = 0.0
|
||||
state = 0
|
||||
ok = True
|
||||
message = "OK"
|
||||
cop_x = cop_y = base_x = base_y = 0.0
|
||||
total_press = 0.0
|
||||
threshold = 0.0
|
||||
if len(frame.matrix) == SENSOR_ROWS * SENSOR_COLS:
|
||||
try:
|
||||
angle = get_pzt_angle(frame.matrix)
|
||||
angle, magnitude, state, cop_x, cop_y, base_x, base_y, total_press, threshold = get_pzt_angle(frame.matrix)
|
||||
self.last_angle = angle
|
||||
if self.frame_count <= 10 or self.frame_count % 30 == 0:
|
||||
print(
|
||||
f"[SensorPush] PZT angle frame #{frame.seq} "
|
||||
f"dts={frame.dts_ms} angle={angle:.2f}"
|
||||
)
|
||||
print(f"devkit: angle={angle:.2f}, magnitude={magnitude:.4f}, state={state}, cop_x={cop_x:.4f}, cop_y={cop_y:.4f}, base_x={base_x:.4f}, base_y={base_y:.4f}, total_press={total_press:.2f}, thresh={threshold:.2f}")
|
||||
except Exception as e:
|
||||
ok = False
|
||||
message = str(e)
|
||||
@@ -262,6 +287,18 @@ class SensorPushServicer(sensor_stream_pb2_grpc.SensorPushServicer):
|
||||
else:
|
||||
ok = False
|
||||
message = f"Invalid matrix length: {len(frame.matrix)}"
|
||||
print(f"[Recv #{frame.seq}] INVALID len={len(frame.matrix)}")
|
||||
|
||||
# 持续写入 CSV
|
||||
if self._csv_writer:
|
||||
row = [frame.seq, frame.timestamp_ms, frame.dts_ms,
|
||||
f"{angle:.4f}", f"{magnitude:.4f}", state,
|
||||
f"{cop_x:.4f}", f"{cop_y:.4f}", f"{base_x:.4f}", f"{base_y:.4f}",
|
||||
frame.resultant_force]
|
||||
row += list(frame.matrix)
|
||||
self._csv_writer.writerow(row)
|
||||
if self.frame_count % 10 == 0:
|
||||
self._csv_file.flush()
|
||||
|
||||
yield sensor_stream_pb2.PztAngleResponse(
|
||||
seq=frame.seq,
|
||||
@@ -270,6 +307,14 @@ class SensorPushServicer(sensor_stream_pb2_grpc.SensorPushServicer):
|
||||
dts_ms=frame.dts_ms,
|
||||
ok=ok,
|
||||
message=message,
|
||||
magnitude=magnitude,
|
||||
state=state,
|
||||
cop_x=cop_x,
|
||||
cop_y=cop_y,
|
||||
base_x=base_x,
|
||||
base_y=base_y,
|
||||
total_press=total_press,
|
||||
threshold=threshold,
|
||||
)
|
||||
|
||||
if self.frame_count % 100 == 0:
|
||||
@@ -290,6 +335,7 @@ class SensorPushServicer(sensor_stream_pb2_grpc.SensorPushServicer):
|
||||
f"total={self.frame_count} | ~{fps:.1f} fps"
|
||||
)
|
||||
|
||||
self._close_csv()
|
||||
print(f"[SensorPush] Stream ended. Total: {self.frame_count}")
|
||||
|
||||
|
||||
@@ -350,67 +396,84 @@ def serve(port: int):
|
||||
|
||||
|
||||
import numpy as np
|
||||
import threading
|
||||
from collections import deque
|
||||
|
||||
# ===================== 算法参数=====================
|
||||
TOTAL_PRESSURE_LOW_THRESHOLD = 500
|
||||
COP_STABILITY_FRAMES_REQUIRED = 5
|
||||
SENSOR_ROWS = 12
|
||||
SENSOR_COLS = 7
|
||||
COP_INIT_MEDIAN_FRAMES = 1 # 初始COP取中位数的帧数
|
||||
NOISE_COLLECT_FRAMES = 10 # 动态阈值基线采集帧数
|
||||
THRESH_K = 5 # 阈值 = K * mean
|
||||
SENSOR_ROWS = 12
|
||||
SENSOR_COLS = 7
|
||||
|
||||
# ===================== 二次静置精修参数 =====================
|
||||
POST_INIT_WINDOW_CNT = 60000
|
||||
POST_INIT_STABLE_CNT = 100
|
||||
POST_INIT_STABLE_THRESH = 0.1
|
||||
|
||||
# ===================== 线程安全全局状态 =====================
|
||||
first_frame = None
|
||||
first_frame_lock = threading.Lock()
|
||||
first_contact_CoP_x = None
|
||||
first_contact_CoP_y = None
|
||||
contact_initialized = False
|
||||
|
||||
first_contact_CoP_x = None
|
||||
first_contact_CoP_y = None
|
||||
contact_initialized = False
|
||||
# 候选初始CoP缓冲
|
||||
cop_init_x_buf = deque(maxlen=COP_INIT_MEDIAN_FRAMES)
|
||||
cop_init_y_buf = deque(maxlen=COP_INIT_MEDIAN_FRAMES)
|
||||
|
||||
total_pressure_low_counter = 0
|
||||
# 动态阈值
|
||||
noise_sum_buf = deque(maxlen=NOISE_COLLECT_FRAMES)
|
||||
dynamic_thresh = None
|
||||
|
||||
# 二次静置精修状态
|
||||
post_init_frame_cnt = 0
|
||||
post_stable_cnt = 0
|
||||
post_refined_flag = False
|
||||
post_cand_x = None
|
||||
post_cand_y = None
|
||||
|
||||
# ===================== 基线减除 =====================
|
||||
def subtract_baseline(current_frame):
|
||||
global first_frame
|
||||
current_frame = np.array(current_frame, dtype=np.float32).flatten()
|
||||
|
||||
with first_frame_lock:
|
||||
if first_frame is None:
|
||||
first_frame = current_frame.copy()
|
||||
|
||||
diff = current_frame - first_frame
|
||||
return np.clip(diff, 0, None)
|
||||
|
||||
# ===================== 重置CoP状态 =====================
|
||||
def reset_cop_state():
|
||||
global first_contact_CoP_x, first_contact_CoP_y, contact_initialized
|
||||
global total_pressure_low_counter
|
||||
global post_init_frame_cnt, post_stable_cnt, post_refined_flag
|
||||
global post_cand_x, post_cand_y
|
||||
|
||||
first_contact_CoP_x = None
|
||||
first_contact_CoP_y = None
|
||||
contact_initialized = False
|
||||
total_pressure_low_counter = 0
|
||||
cop_init_x_buf.clear()
|
||||
cop_init_y_buf.clear()
|
||||
post_init_frame_cnt = 0
|
||||
post_stable_cnt = 0
|
||||
post_refined_flag = False
|
||||
post_cand_x = None
|
||||
post_cand_y = None
|
||||
|
||||
|
||||
# ===================== CoP压力中心计算 =====================
|
||||
def compute_pressure_direction(baseline_subtracted_frame):
|
||||
def compute_pressure_direction(raw_frame):
|
||||
global first_contact_CoP_x, first_contact_CoP_y, contact_initialized
|
||||
global total_pressure_low_counter
|
||||
global post_init_frame_cnt, post_stable_cnt, post_refined_flag
|
||||
global post_cand_x, post_cand_y
|
||||
global noise_sum_buf, dynamic_thresh
|
||||
|
||||
rows, cols = SENSOR_ROWS, SENSOR_COLS
|
||||
frame_flat = np.asarray(baseline_subtracted_frame, dtype=np.float32).flatten()
|
||||
frame_flat = np.asarray(raw_frame, dtype=np.float32).flatten()
|
||||
frame2d = frame_flat.reshape(rows, cols)
|
||||
|
||||
total_pressure = np.sum(frame2d)
|
||||
if total_pressure < TOTAL_PRESSURE_LOW_THRESHOLD:
|
||||
total_pressure_low_counter += 1
|
||||
else:
|
||||
total_pressure_low_counter = 0
|
||||
|
||||
if total_pressure_low_counter >= COP_STABILITY_FRAMES_REQUIRED:
|
||||
reset_cop_state()
|
||||
return 0.0, 0.0
|
||||
# 动态阈值
|
||||
if dynamic_thresh is None:
|
||||
noise_sum_buf.append(total_pressure)
|
||||
if len(noise_sum_buf) >= NOISE_COLLECT_FRAMES:
|
||||
sums = np.array(noise_sum_buf)
|
||||
dynamic_thresh = THRESH_K * float(np.mean(sums))
|
||||
|
||||
if total_pressure == 0:
|
||||
return 0.0, 0.0
|
||||
# 低压重置
|
||||
if total_pressure == 0 or (dynamic_thresh is not None and total_pressure < dynamic_thresh):
|
||||
if contact_initialized and dynamic_thresh is not None:
|
||||
reset_cop_state()
|
||||
return 0.0, 0.0, 0, rows-1, 0, cols-1, 0.0, 0.0, 0.0, 0.0, 0.0, 0, 0.0, dynamic_thresh
|
||||
|
||||
x_grid = np.tile(np.arange(cols), (rows, 1))
|
||||
y_grid = np.repeat(np.arange(rows), cols).reshape(rows, cols)
|
||||
@@ -419,44 +482,98 @@ def compute_pressure_direction(baseline_subtracted_frame):
|
||||
|
||||
delta_CoP_x = 0.0
|
||||
delta_CoP_y = 0.0
|
||||
base_x = cop_x
|
||||
base_y = cop_y
|
||||
|
||||
# ============ 初始点稳定判断(中位数判定) ============
|
||||
if not contact_initialized:
|
||||
first_contact_CoP_x = cop_x
|
||||
first_contact_CoP_y = cop_y
|
||||
contact_initialized = True
|
||||
else:
|
||||
delta_CoP_x = cop_x - first_contact_CoP_x
|
||||
delta_CoP_y = cop_y - first_contact_CoP_y
|
||||
cop_init_x_buf.append(cop_x)
|
||||
cop_init_y_buf.append(cop_y)
|
||||
|
||||
if len(cop_init_x_buf) >= COP_INIT_MEDIAN_FRAMES:
|
||||
first_contact_CoP_x = float(np.median(cop_init_x_buf))
|
||||
first_contact_CoP_y = float(np.median(cop_init_y_buf))
|
||||
contact_initialized = True
|
||||
cop_init_x_buf.clear()
|
||||
cop_init_y_buf.clear()
|
||||
|
||||
# ========== 计算偏移量 ==========
|
||||
else:
|
||||
# 二次静置精修
|
||||
post_init_frame_cnt += 1
|
||||
if not post_refined_flag and post_init_frame_cnt <= POST_INIT_WINDOW_CNT:
|
||||
if post_cand_x is not None:
|
||||
dist_val = np.hypot(cop_x - post_cand_x, cop_y - post_cand_y)
|
||||
if dist_val <= POST_INIT_STABLE_THRESH:
|
||||
post_stable_cnt += 1
|
||||
else:
|
||||
post_cand_x = cop_x
|
||||
post_cand_y = cop_y
|
||||
post_stable_cnt = 1
|
||||
else:
|
||||
post_cand_x = cop_x
|
||||
post_cand_y = cop_y
|
||||
post_stable_cnt = 1
|
||||
|
||||
if post_stable_cnt >= POST_INIT_STABLE_CNT:
|
||||
first_contact_CoP_x = post_cand_x
|
||||
first_contact_CoP_y = post_cand_y
|
||||
post_refined_flag = True
|
||||
else:
|
||||
post_refined_flag = True
|
||||
|
||||
delta_CoP_x = cop_x - first_contact_CoP_x
|
||||
delta_CoP_y = first_contact_CoP_y - cop_y
|
||||
base_x = first_contact_CoP_x
|
||||
base_y = first_contact_CoP_y
|
||||
|
||||
magnitude = np.hypot(delta_CoP_x, delta_CoP_y)
|
||||
if not contact_initialized:
|
||||
state = 0
|
||||
elif not post_refined_flag:
|
||||
state = 1
|
||||
else:
|
||||
state = 2
|
||||
|
||||
return (cop_x, cop_y,
|
||||
0, rows-1, 0, cols-1,
|
||||
delta_CoP_x, delta_CoP_y,
|
||||
base_x, base_y,
|
||||
magnitude, state,
|
||||
total_pressure, dynamic_thresh)
|
||||
|
||||
return delta_CoP_x, delta_CoP_y
|
||||
|
||||
# ===================== 角度计算核心 =====================
|
||||
def compute_vector_angle(x: float, y: float) -> tuple[float, float]:
|
||||
epsilon = 1e-8
|
||||
mag = np.hypot(x, y)
|
||||
angle = np.degrees(np.arctan2(y, x + epsilon))
|
||||
mag = np.hypot(x, y)
|
||||
angle = np.degrees(np.arctan2(y, x + epsilon))
|
||||
if angle < 0:
|
||||
angle += 360
|
||||
return angle, mag
|
||||
|
||||
def compute_PZT_angle(Px: float, Py: float) -> tuple[float, float]:
|
||||
return compute_vector_angle(Px, -Py)
|
||||
return compute_vector_angle(Px, Py)
|
||||
|
||||
|
||||
# ===================== 核心入口函数 =====================
|
||||
def get_pzt_angle(adc_data):
|
||||
if len(adc_data) != 84:
|
||||
raise ValueError("ADC数据长度必须为84")
|
||||
baseline_subtracted = subtract_baseline(adc_data)
|
||||
dx, dy = compute_pressure_direction(baseline_subtracted)
|
||||
result = compute_pressure_direction(adc_data)
|
||||
cop_x, cop_y = result[0], result[1]
|
||||
dx, dy = result[6], result[7]
|
||||
base_x, base_y = result[8], result[9]
|
||||
magnitude = result[10]
|
||||
state = int(result[11])
|
||||
total_press = result[12]
|
||||
threshold = result[13]
|
||||
pzt_angle, _ = compute_PZT_angle(dx, dy)
|
||||
|
||||
return pzt_angle
|
||||
return pzt_angle, magnitude, state, cop_x, cop_y, base_x, base_y, total_press, threshold
|
||||
|
||||
|
||||
# ===================== 重置基线(校准用) =====================
|
||||
def reset_baseline():
|
||||
global first_frame
|
||||
with first_frame_lock:
|
||||
first_frame = None
|
||||
reset_cop_state()
|
||||
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ _sym_db = _symbol_database.Default()
|
||||
|
||||
|
||||
|
||||
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x13sensor_stream.proto\x12\rsensor_stream\"\x85\x01\n\x0bSensorFrame\x12\x0b\n\x03seq\x18\x01 \x01(\x04\x12\x14\n\x0ctimestamp_ms\x18\x02 \x01(\x04\x12\x0c\n\x04rows\x18\x03 \x01(\r\x12\x0c\n\x04\x63ols\x18\x04 \x01(\r\x12\x0e\n\x06matrix\x18\x05 \x03(\r\x12\x17\n\x0fresultant_force\x18\x06 \x01(\x01\x12\x0e\n\x06\x64ts_ms\x18\x07 \x01(\r\"q\n\x10PztAngleResponse\x12\x0b\n\x03seq\x18\x01 \x01(\x04\x12\x14\n\x0ctimestamp_ms\x18\x02 \x01(\x04\x12\r\n\x05\x61ngle\x18\x03 \x01(\x02\x12\x0e\n\x06\x64ts_ms\x18\x04 \x01(\r\x12\n\n\x02ok\x18\x05 \x01(\x08\x12\x0f\n\x07message\x18\x06 \x01(\t\"8\n\x0eProcessRequest\x12\x10\n\x08\x63sv_path\x18\x01 \x01(\t\x12\x14\n\x0csave_as_xlsx\x18\x02 \x01(\x08\"\xa6\x01\n\x0fProcessResponse\x12\n\n\x02ok\x18\x01 \x01(\x08\x12\x13\n\x0boutput_path\x18\x02 \x01(\t\x12\x13\n\x0bgroups_used\x18\x03 \x01(\r\x12\x12\n\nmean_value\x18\x04 \x01(\x01\x12\x11\n\tthreshold\x18\x05 \x01(\x01\x12\x12\n\nrows_total\x18\x06 \x01(\r\x12\x11\n\trows_kept\x18\x07 \x01(\r\x12\x0f\n\x07message\x18\x08 \x01(\t2W\n\nSensorPush\x12I\n\x06Upload\x12\x1a.sensor_stream.SensorFrame\x1a\x1f.sensor_stream.PztAngleResponse(\x01\x30\x01\x32_\n\x0f\x45xportProcessor\x12L\n\x0bProcessFile\x12\x1d.sensor_stream.ProcessRequest\x1a\x1e.sensor_stream.ProcessResponseb\x06proto3')
|
||||
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x13sensor_stream.proto\x12\rsensor_stream\"\x85\x01\n\x0bSensorFrame\x12\x0b\n\x03seq\x18\x01 \x01(\x04\x12\x14\n\x0ctimestamp_ms\x18\x02 \x01(\x04\x12\x0c\n\x04rows\x18\x03 \x01(\r\x12\x0c\n\x04\x63ols\x18\x04 \x01(\r\x12\x0e\n\x06matrix\x18\x05 \x03(\r\x12\x17\n\x0fresultant_force\x18\x06 \x01(\x01\x12\x0e\n\x06\x64ts_ms\x18\x07 \x01(\r\"\xd1\x01\n\x10PztAngleResponse\x12\x0b\n\x03seq\x18\x01 \x01(\x04\x12\x14\n\x0ctimestamp_ms\x18\x02 \x01(\x04\x12\r\n\x05\x61ngle\x18\x03 \x01(\x02\x12\x0e\n\x06\x64ts_ms\x18\x04 \x01(\r\x12\n\n\x02ok\x18\x05 \x01(\x08\x12\x0f\n\x07message\x18\x06 \x01(\t\x12\x11\n\tmagnitude\x18\x07 \x01(\x02\x12\r\n\x05state\x18\x08 \x01(\r\x12\r\n\x05\x63op_x\x18\t \x01(\x02\x12\r\n\x05\x63op_y\x18\n \x01(\x02\x12\x0e\n\x06\x62\x61se_x\x18\x0b \x01(\x02\x12\x0e\n\x06\x62\x61se_y\x18\x0c \x01(\x02\"8\n\x0eProcessRequest\x12\x10\n\x08\x63sv_path\x18\x01 \x01(\t\x12\x14\n\x0csave_as_xlsx\x18\x02 \x01(\x08\"\xa6\x01\n\x0fProcessResponse\x12\n\n\x02ok\x18\x01 \x01(\x08\x12\x13\n\x0boutput_path\x18\x02 \x01(\t\x12\x13\n\x0bgroups_used\x18\x03 \x01(\r\x12\x12\n\nmean_value\x18\x04 \x01(\x01\x12\x11\n\tthreshold\x18\x05 \x01(\x01\x12\x12\n\nrows_total\x18\x06 \x01(\r\x12\x11\n\trows_kept\x18\x07 \x01(\r\x12\x0f\n\x07message\x18\x08 \x01(\t2W\n\nSensorPush\x12I\n\x06Upload\x12\x1a.sensor_stream.SensorFrame\x1a\x1f.sensor_stream.PztAngleResponse(\x01\x30\x01\x32_\n\x0f\x45xportProcessor\x12L\n\x0bProcessFile\x12\x1d.sensor_stream.ProcessRequest\x1a\x1e.sensor_stream.ProcessResponseb\x06proto3')
|
||||
|
||||
_globals = globals()
|
||||
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
||||
@@ -33,14 +33,14 @@ if not _descriptor._USE_C_DESCRIPTORS:
|
||||
DESCRIPTOR._loaded_options = None
|
||||
_globals['_SENSORFRAME']._serialized_start=39
|
||||
_globals['_SENSORFRAME']._serialized_end=172
|
||||
_globals['_PZTANGLERESPONSE']._serialized_start=174
|
||||
_globals['_PZTANGLERESPONSE']._serialized_end=287
|
||||
_globals['_PROCESSREQUEST']._serialized_start=289
|
||||
_globals['_PROCESSREQUEST']._serialized_end=345
|
||||
_globals['_PROCESSRESPONSE']._serialized_start=348
|
||||
_globals['_PROCESSRESPONSE']._serialized_end=514
|
||||
_globals['_SENSORPUSH']._serialized_start=516
|
||||
_globals['_SENSORPUSH']._serialized_end=603
|
||||
_globals['_EXPORTPROCESSOR']._serialized_start=605
|
||||
_globals['_EXPORTPROCESSOR']._serialized_end=700
|
||||
_globals['_PZTANGLERESPONSE']._serialized_start=175
|
||||
_globals['_PZTANGLERESPONSE']._serialized_end=384
|
||||
_globals['_PROCESSREQUEST']._serialized_start=386
|
||||
_globals['_PROCESSREQUEST']._serialized_end=442
|
||||
_globals['_PROCESSRESPONSE']._serialized_start=445
|
||||
_globals['_PROCESSRESPONSE']._serialized_end=611
|
||||
_globals['_SENSORPUSH']._serialized_start=613
|
||||
_globals['_SENSORPUSH']._serialized_end=700
|
||||
_globals['_EXPORTPROCESSOR']._serialized_start=702
|
||||
_globals['_EXPORTPROCESSOR']._serialized_end=797
|
||||
# @@protoc_insertion_point(module_scope)
|
||||
|
||||
127
devkit/test_pzt.py
Normal file
127
devkit/test_pzt.py
Normal file
@@ -0,0 +1,127 @@
|
||||
"""
|
||||
独立测试脚本:读取84个原始ADC数据,传入CoP算法计算角度,终端打印结果。
|
||||
|
||||
用法:
|
||||
python test_pzt.py # 从 stdin 逐行读取(每行84个逗号分隔数值)
|
||||
python test_pzt.py data.csv # 从 CSV 文件逐行读取
|
||||
python test_pzt.py --random # 生成随机测试数据(调试用)
|
||||
"""
|
||||
|
||||
import sys
|
||||
import csv
|
||||
import numpy as np
|
||||
|
||||
# ── 从 sensor_server.py 导入算法 ──
|
||||
sys.path.insert(0, ".")
|
||||
from sensor_server import (
|
||||
get_pzt_angle,
|
||||
reset_baseline,
|
||||
subtract_baseline,
|
||||
compute_pressure_direction,
|
||||
compute_PZT_angle,
|
||||
)
|
||||
|
||||
|
||||
def print_result(data_label: str, pzt_angle: float, magnitude: float, state: int, cop_x: float, cop_y: float, base_x: float, base_y: float):
|
||||
dx = cop_x - base_x
|
||||
dy = base_y - cop_y
|
||||
print(
|
||||
f"devkit: angle={pzt_angle:.2f}, magnitude={magnitude:.4f}, state={state}, "
|
||||
f"cop_x={cop_x:.4f}, cop_y={cop_y:.4f}, dx={dx:.4f}, dy={dy:.4f}"
|
||||
)
|
||||
|
||||
|
||||
def process_values(values: list[int | float]):
|
||||
"""处理一帧84个值并打印结果"""
|
||||
if len(values) != 84:
|
||||
print(f"[ERROR] 期望84个值,实际收到 {len(values)} 个", file=sys.stderr)
|
||||
return
|
||||
|
||||
try:
|
||||
pzt_angle, magnitude, state, cop_x, cop_y, base_x, base_y = get_pzt_angle(values)
|
||||
print_result("", pzt_angle, magnitude, state, cop_x, cop_y, base_x, base_y)
|
||||
except Exception as e:
|
||||
print(f"[ERROR] 计算失败: {e}", file=sys.stderr)
|
||||
|
||||
|
||||
def run_random_test():
|
||||
"""生成随机数据测试算法"""
|
||||
reset_baseline()
|
||||
print("[TEST] 使用随机数据测试 CoP 算法")
|
||||
print("[TEST] 先用全零帧建立基线...")
|
||||
process_values([0] * 84)
|
||||
print("[TEST] 模拟右侧偏移按压...")
|
||||
# 模拟:row 5-7, col 4-6 区域有压力
|
||||
data = [0.0] * 84
|
||||
for r in range(5, 8):
|
||||
for c in range(4, 7):
|
||||
idx = r * 7 + c
|
||||
data[idx] = 100.0 + (c - 4) * 50 # 右侧更强
|
||||
process_values(data)
|
||||
print("[TEST] 模拟下方偏移按压...")
|
||||
data2 = [0.0] * 84
|
||||
for r in range(8, 11):
|
||||
for c in range(2, 5):
|
||||
idx = r * 7 + c
|
||||
data2[idx] = 150.0 + (r - 8) * 30
|
||||
process_values(data2)
|
||||
print("[TEST] 完成")
|
||||
|
||||
|
||||
def run_csv_mode(filepath: str):
|
||||
"""从 CSV 文件逐行读取并处理"""
|
||||
reset_baseline()
|
||||
print(f"[CSV] 读取文件: {filepath}")
|
||||
with open(filepath, "r", encoding="utf-8-sig", newline="") as f:
|
||||
reader = csv.reader(f)
|
||||
for i, row in enumerate(reader):
|
||||
if not row:
|
||||
continue
|
||||
# 跳过 header
|
||||
if row[0].strip() in ("seq", "timestamp_ms"):
|
||||
print(f"[CSV] 跳过 header: {row[:5]}...")
|
||||
continue
|
||||
try:
|
||||
values = [float(v) for v in row]
|
||||
if len(values) == 84:
|
||||
process_values(values)
|
||||
elif len(values) > 84:
|
||||
process_values(values[:84])
|
||||
except ValueError:
|
||||
continue
|
||||
|
||||
|
||||
def run_stdin_mode():
|
||||
"""从 stdin 逐行读取"""
|
||||
reset_baseline()
|
||||
print("[STDIN] 等待输入(每行84个逗号分隔数值,Ctrl+C 退出)...")
|
||||
try:
|
||||
for line in sys.stdin:
|
||||
line = line.strip()
|
||||
if not line:
|
||||
continue
|
||||
try:
|
||||
values = [float(v) for v in line.split(",")]
|
||||
if len(values) >= 84:
|
||||
process_values(values[:84])
|
||||
except ValueError:
|
||||
continue
|
||||
except KeyboardInterrupt:
|
||||
print("\n[STDIN] 已退出")
|
||||
|
||||
|
||||
def main():
|
||||
if len(sys.argv) > 1:
|
||||
arg = sys.argv[1]
|
||||
if arg == "--random":
|
||||
run_random_test()
|
||||
elif arg == "--help" or arg == "-h":
|
||||
print(__doc__)
|
||||
else:
|
||||
run_csv_mode(arg)
|
||||
else:
|
||||
run_stdin_mode()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
2
package-lock.json
generated
2
package-lock.json
generated
@@ -6,7 +6,7 @@
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "JE-Skin",
|
||||
"version": "0.3.0",
|
||||
"version": "0.4.0",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@tauri-apps/api": "^2",
|
||||
|
||||
@@ -27,6 +27,14 @@ message PztAngleResponse {
|
||||
uint32 dts_ms = 4;
|
||||
bool ok = 5;
|
||||
string message = 6;
|
||||
float magnitude = 7;
|
||||
uint32 state = 8;
|
||||
float cop_x = 9;
|
||||
float cop_y = 10;
|
||||
float base_x = 11;
|
||||
float base_y = 12;
|
||||
float total_press = 13;
|
||||
float threshold = 14;
|
||||
}
|
||||
|
||||
message ProcessRequest {
|
||||
|
||||
Binary file not shown.
162
src-tauri/src/ad_solver.rs
Normal file
162
src-tauri/src/ad_solver.rs
Normal file
@@ -0,0 +1,162 @@
|
||||
/// AD值反解x计算器
|
||||
/// AD = -5.732*x^3 - 131.5*x^2 + 31980*x + 13490 (x <= 6.57)
|
||||
/// AD = -377.8*x^2 + 26040*x + 51120 (x > 6.57)
|
||||
|
||||
const X_BOUNDARY: f64 = 6.57;
|
||||
|
||||
/// 二次方程在边界处的AD值
|
||||
/// 当 x = 6.57 时,AD = -377.8*6.57^2 + 26040*6.57 + 51120
|
||||
const AD_BOUNDARY: f64 = 205895.10;
|
||||
|
||||
/// 二次方程求解器
|
||||
/// -377.8*x^2 + 26040*x + 51120 = ad
|
||||
/// 返回 x > 6.57 的那个解
|
||||
fn solve_quadratic(ad: f64) -> Option<f64> {
|
||||
let a = -377.8;
|
||||
let b = 26040.0;
|
||||
let c = 51120.0 - ad;
|
||||
|
||||
let discriminant = b * b - 4.0 * a * c;
|
||||
if discriminant < 0.0 {
|
||||
return None;
|
||||
}
|
||||
|
||||
let sqrt_d = discriminant.sqrt();
|
||||
let x1 = (-b + sqrt_d) / (2.0 * a);
|
||||
let x2 = (-b - sqrt_d) / (2.0 * a);
|
||||
|
||||
// 选择 x > 6.57 的解(只可能有一个解满足这个条件)
|
||||
if x1 > X_BOUNDARY && x1 > 0.0 {
|
||||
Some(x1)
|
||||
} else if x2 > X_BOUNDARY && x2 > 0.0 {
|
||||
Some(x2)
|
||||
} else {
|
||||
None
|
||||
}
|
||||
}
|
||||
|
||||
/// 计算三次多项式的值
|
||||
/// f(x) = -5.732*x^3 - 131.5*x^2 + 31980*x + 13490
|
||||
fn cubic_value(x: f64) -> f64 {
|
||||
-5.732 * x.powi(3) - 131.5 * x.powi(2) + 31980.0 * x + 13490.0
|
||||
}
|
||||
|
||||
/// 使用二分法求解三次方程 (x <= 6.57)
|
||||
/// 三次方程在 [0, 6.57] 范围内是单调递增的
|
||||
fn solve_cubic_bisection(ad: f64) -> Option<f64> {
|
||||
let mut low = 0.0;
|
||||
let mut high = X_BOUNDARY;
|
||||
|
||||
let target = ad;
|
||||
|
||||
// 检查目标是否在范围内
|
||||
let low_ad = cubic_value(low);
|
||||
let high_ad = cubic_value(high);
|
||||
|
||||
if target < low_ad.min(high_ad) || target > low_ad.max(high_ad) {
|
||||
return None;
|
||||
}
|
||||
|
||||
for _i in 0..100 {
|
||||
let mid = (low + high) / 2.0;
|
||||
let mid_ad = cubic_value(mid);
|
||||
|
||||
if (high - low).abs() < 1e-10 {
|
||||
return Some((low + high) / 2.0);
|
||||
}
|
||||
|
||||
if mid_ad > target {
|
||||
high = mid;
|
||||
} else {
|
||||
low = mid;
|
||||
}
|
||||
}
|
||||
|
||||
Some((low + high) / 2.0)
|
||||
}
|
||||
|
||||
/// 主求解函数:根据AD值反解x
|
||||
pub fn solve_for_x(ad: f64) -> Option<f64> {
|
||||
// 如果 AD <= 边界值,使用三次方程 (x <= 6.57)
|
||||
// 如果 AD > 边界值,使用二次方程 (x > 6.57)
|
||||
if ad <= AD_BOUNDARY {
|
||||
return solve_cubic_bisection(ad);
|
||||
}
|
||||
|
||||
// AD > 边界值,使用二次方程
|
||||
solve_quadratic(ad)
|
||||
}
|
||||
|
||||
/// 批量求解,用于验证所有解
|
||||
pub fn solve_for_x_all(ad: f64) -> Vec<f64> {
|
||||
let mut results = Vec::new();
|
||||
|
||||
// 三次方程解
|
||||
if let Some(x) = solve_cubic_bisection(ad) {
|
||||
results.push(x);
|
||||
}
|
||||
|
||||
// 二次方程解
|
||||
if let Some(x) = solve_quadratic(ad) {
|
||||
results.push(x);
|
||||
}
|
||||
|
||||
results
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_cubic_forward() {
|
||||
// 测试 x <= 6.57 的正向计算
|
||||
let x = 5.0;
|
||||
let ad = cubic_value(x);
|
||||
println!("x={}, ad={}", x, ad);
|
||||
let solved = solve_for_x(ad).unwrap();
|
||||
println!("solved={}", solved);
|
||||
assert!((solved - x).abs() < 0.01, "x={}, solved={}", x, solved);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_quadratic_forward() {
|
||||
// 测试 x > 6.57 的正向计算
|
||||
let x = 10.0;
|
||||
let ad = -377.8 * x * x + 26040.0 * x + 51120.0;
|
||||
let solved = solve_for_x(ad).unwrap();
|
||||
assert!((solved - x).abs() < 0.01, "x={}, solved={}", x, solved);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_boundary() {
|
||||
// 测试边界值
|
||||
let x = 6.57;
|
||||
let ad_cubic = cubic_value(x);
|
||||
let ad_quad = -377.8 * x * x + 26040.0 * x + 51120.0;
|
||||
|
||||
println!("x=6.57 时三次方程 AD = {:.2}", ad_cubic);
|
||||
println!("x=6.57 时二次方程 AD = {:.2}", ad_quad);
|
||||
println!("边界值 AD_BOUNDARY = {:.2}", AD_BOUNDARY);
|
||||
|
||||
// 边界处两个公式应该有显著差异
|
||||
assert!((ad_cubic - ad_quad).abs() > 100.0);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_known_values() {
|
||||
// 测试一些已知值
|
||||
let test_cases = [
|
||||
(0.0, cubic_value(0.0)),
|
||||
(3.0, cubic_value(3.0)),
|
||||
(6.0, cubic_value(6.0)),
|
||||
(8.0, -377.8 * 8.0 * 8.0 + 26040.0 * 8.0 + 51120.0),
|
||||
(15.0, -377.8 * 15.0 * 15.0 + 26040.0 * 15.0 + 51120.0),
|
||||
];
|
||||
|
||||
for (x, ad) in test_cases {
|
||||
let solved = solve_for_x(ad).unwrap();
|
||||
assert!((solved - x).abs() < 0.01, "x={}, ad={}, solved={}", x, ad, solved);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,3 +1,4 @@
|
||||
use crate::serial_core::codecs::hand_gateway::HandGatewayCodec;
|
||||
use crate::serial_core::codecs::tactile_a::{
|
||||
export_recording_csv, TactileACodec, TactileACsvImporter, TactileAHandler,
|
||||
};
|
||||
@@ -6,7 +7,7 @@ use crate::serial_core::record::CsvImporter;
|
||||
use crate::serial_core::serial::{PollMode, TactileAPollRequester};
|
||||
use crate::serial_core::{serial, TactileARecording};
|
||||
use log::info;
|
||||
use serde::Serialize;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::fs::File;
|
||||
use std::io::Cursor;
|
||||
use std::path::{Path, PathBuf};
|
||||
@@ -21,6 +22,10 @@ const DEFAULT_TACTILE_ROWS: usize = 12;
|
||||
const DEFAULT_TACTILE_POLL_INTERVAL_MS: u64 = 10;
|
||||
const DEFAULT_TACTILE_REPLY_TIMEOUT_MS: u64 = 140;
|
||||
|
||||
// MCU currently uses a fixed node layout. Update this list to match the firmware:
|
||||
// one entry per Config bit, containing that node's number of u16 samples.
|
||||
const DEFAULT_HAND_GATEWAY_NODE_SAMPLE_COUNTS: &[u16] = &[84];
|
||||
|
||||
type SharedTactileRecording = Arc<Mutex<TactileARecording>>;
|
||||
|
||||
#[derive(Serialize)]
|
||||
@@ -31,6 +36,13 @@ pub struct SerialConnectResponse {
|
||||
pub message: String,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Copy, Deserialize)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub enum SerialProtocol {
|
||||
TactileA,
|
||||
HandGateway,
|
||||
}
|
||||
|
||||
#[derive(Serialize)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub struct SerialExportResponse {
|
||||
@@ -67,7 +79,7 @@ struct SerialSession {
|
||||
port: String,
|
||||
cancel: CancellationToken,
|
||||
task: JoinHandle<()>,
|
||||
current_record: SharedTactileRecording,
|
||||
current_record: Option<SharedTactileRecording>,
|
||||
}
|
||||
|
||||
#[derive(Default)]
|
||||
@@ -78,7 +90,7 @@ pub struct SerialConnectionState {
|
||||
|
||||
pub async fn shutdown_active_session(
|
||||
state: &SerialConnectionState,
|
||||
) -> Result<Option<(String, SharedTactileRecording)>, SerialError> {
|
||||
) -> Result<Option<(String, Option<SharedTactileRecording>)>, SerialError> {
|
||||
let session = {
|
||||
let mut guard = state.session.lock().map_err(|_| SerialError::StateError)?;
|
||||
guard.take()
|
||||
@@ -98,13 +110,15 @@ pub async fn shutdown_active_session(
|
||||
let _ = task.await;
|
||||
|
||||
let frame_count = current_record
|
||||
.lock()
|
||||
.map(|record| record.frames.len())
|
||||
.as_ref()
|
||||
.and_then(|record| record.lock().ok().map(|record| record.frames.len()))
|
||||
.unwrap_or(0);
|
||||
|
||||
info!("last_record has {} frames", frame_count);
|
||||
|
||||
if let Ok(mut last_record) = state.last_record.lock() {
|
||||
if let (Some(current_record), Ok(mut last_record)) =
|
||||
(current_record.as_ref(), state.last_record.lock())
|
||||
{
|
||||
*last_record = Some(current_record.clone());
|
||||
}
|
||||
|
||||
@@ -133,6 +147,7 @@ pub fn serial_enum() -> Result<Vec<String>, SerialError> {
|
||||
pub async fn serial_connect(
|
||||
app: AppHandle,
|
||||
port: String,
|
||||
protocol: SerialProtocol,
|
||||
state: State<'_, SerialConnectionState>,
|
||||
) -> Result<SerialConnectResponse, SerialError> {
|
||||
let port_name = port.trim().to_string();
|
||||
@@ -148,7 +163,10 @@ pub async fn serial_connect(
|
||||
}
|
||||
|
||||
let cancel = CancellationToken::new();
|
||||
let current_record = Arc::new(Mutex::new(TactileARecording::new()));
|
||||
let current_record = match protocol {
|
||||
SerialProtocol::TactileA => Some(Arc::new(Mutex::new(TactileARecording::new()))),
|
||||
SerialProtocol::HandGateway => None,
|
||||
};
|
||||
let task_record = current_record.clone();
|
||||
let task_cancel = cancel.clone();
|
||||
let task_app = app.clone();
|
||||
@@ -160,32 +178,51 @@ pub async fn serial_connect(
|
||||
let session_started_at = Instant::now();
|
||||
|
||||
let task = tauri::async_runtime::spawn(async move {
|
||||
let codec = TactileACodec::new(DEFAULT_TACTILE_COLS, DEFAULT_TACTILE_ROWS);
|
||||
let handler = TactileAHandler;
|
||||
let poll_mode = PollMode::Enabled(Box::new(TactileAPollRequester::new(
|
||||
Duration::from_millis(DEFAULT_TACTILE_POLL_INTERVAL_MS),
|
||||
DEFAULT_TACTILE_COLS,
|
||||
DEFAULT_TACTILE_ROWS,
|
||||
Duration::from_millis(DEFAULT_TACTILE_REPLY_TIMEOUT_MS),
|
||||
)));
|
||||
let run_result = match protocol {
|
||||
SerialProtocol::TactileA => {
|
||||
let codec = TactileACodec::new(DEFAULT_TACTILE_COLS, DEFAULT_TACTILE_ROWS);
|
||||
let handler = TactileAHandler;
|
||||
let poll_mode = PollMode::Enabled(Box::new(TactileAPollRequester::new(
|
||||
Duration::from_millis(DEFAULT_TACTILE_POLL_INTERVAL_MS),
|
||||
DEFAULT_TACTILE_COLS,
|
||||
DEFAULT_TACTILE_ROWS,
|
||||
Duration::from_millis(DEFAULT_TACTILE_REPLY_TIMEOUT_MS),
|
||||
)));
|
||||
|
||||
if let Err(error) = serial::run_serial_with_poll(
|
||||
task_app.clone(),
|
||||
port,
|
||||
codec,
|
||||
handler,
|
||||
session_started_at,
|
||||
task_record.clone(),
|
||||
task_cancel,
|
||||
poll_mode,
|
||||
)
|
||||
.await
|
||||
{
|
||||
serial::run_serial_with_poll(
|
||||
task_app.clone(),
|
||||
port,
|
||||
codec,
|
||||
handler,
|
||||
session_started_at,
|
||||
task_record
|
||||
.clone()
|
||||
.expect("tactile protocol must have a recording"),
|
||||
task_cancel,
|
||||
poll_mode,
|
||||
)
|
||||
.await
|
||||
}
|
||||
SerialProtocol::HandGateway => {
|
||||
let codec = HandGatewayCodec::new(DEFAULT_HAND_GATEWAY_NODE_SAMPLE_COUNTS);
|
||||
serial::run_hand_gateway_serial(
|
||||
task_app.clone(),
|
||||
port,
|
||||
codec,
|
||||
session_started_at,
|
||||
task_cancel,
|
||||
)
|
||||
.await
|
||||
}
|
||||
};
|
||||
|
||||
if let Err(error) = run_result {
|
||||
eprintln!("serial task exited with error: {error}");
|
||||
}
|
||||
|
||||
let manager = task_app.state::<SerialConnectionState>();
|
||||
if let Ok(mut last_record) = manager.last_record.lock() {
|
||||
if let (Some(task_record), Ok(mut last_record)) = (task_record, manager.last_record.lock())
|
||||
{
|
||||
*last_record = Some(task_record);
|
||||
}
|
||||
|
||||
@@ -360,7 +397,7 @@ fn resolve_record_for_export(
|
||||
let session = state.session.lock().map_err(|_| SerialError::StateError)?;
|
||||
session
|
||||
.as_ref()
|
||||
.map(|current_session| current_session.current_record.clone())
|
||||
.and_then(|current_session| current_session.current_record.clone())
|
||||
};
|
||||
|
||||
if let Some(recording) = current_record {
|
||||
@@ -381,7 +418,7 @@ fn snapshot_record_frame_count(
|
||||
let session = state.session.lock().map_err(|_| SerialError::StateError)?;
|
||||
session
|
||||
.as_ref()
|
||||
.map(|current_session| current_session.current_record.clone())
|
||||
.and_then(|current_session| current_session.current_record.clone())
|
||||
};
|
||||
|
||||
if let Some(record) = current_record {
|
||||
|
||||
@@ -278,10 +278,16 @@ async fn run_grpc_upload(
|
||||
angle: message.angle,
|
||||
};
|
||||
::log::debug!(
|
||||
"python pzt angle: seq={} dts_ms={} angle={:.2}",
|
||||
message.seq,
|
||||
message.dts_ms,
|
||||
message.angle
|
||||
"devkit: angle={:.2}, magnitude={:.4}, state={}, cop_x={:.4}, cop_y={:.4}, base_x={:.4}, base_y={:.4}, total_press={:.2}, thresh={:.2}",
|
||||
message.angle,
|
||||
message.magnitude,
|
||||
message.state,
|
||||
message.cop_x,
|
||||
message.cop_y,
|
||||
message.base_x,
|
||||
message.base_y,
|
||||
message.total_press,
|
||||
message.threshold
|
||||
);
|
||||
app.emit("devkit_pzt_angle", payload)?;
|
||||
} else {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
pub mod ad_solver;
|
||||
mod commands;
|
||||
mod lan_game;
|
||||
pub mod log;
|
||||
|
||||
390
src-tauri/src/serial_core/codecs/hand_gateway.rs
Normal file
390
src-tauri/src/serial_core/codecs/hand_gateway.rs
Normal file
@@ -0,0 +1,390 @@
|
||||
use crate::serial_core::codec::Codec;
|
||||
use crate::serial_core::error::CodecError;
|
||||
use crate::serial_core::frame::{
|
||||
HandGatewayDataRepFrame, HandGatewayFrame, HandGatewayFrameMetaData, HandGatewayFrameNode,
|
||||
};
|
||||
use crate::serial_core::utils::{calc_crc8_itu, elapsed_millis};
|
||||
use log::debug;
|
||||
use std::time::Instant;
|
||||
|
||||
const FRAME_HEADER: [u8; 2] = [0x55, 0xAA];
|
||||
const RESPONSE_DATA_CMD: u8 = 0x81;
|
||||
const RESPONSE_DATA_FIXED_LENGTH: usize = 16;
|
||||
const RESPONSE_DATA_PREFIX_LENGTH: usize = 19;
|
||||
const MIN_FRAME_LENGTH: usize = 7;
|
||||
const DEFAULT_MAX_FRAME_LENGTH: usize = 64 * 1024;
|
||||
|
||||
/// Describes one fixed MCU data block.
|
||||
///
|
||||
/// `config_mask` identifies the bit associated with this block in the protocol's
|
||||
/// Config/ValidConfig fields. `sample_count` is the number of little-endian u16
|
||||
/// samples in the block.
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct HandGatewayNodeConfig {
|
||||
pub config_mask: u32,
|
||||
pub sample_count: usize,
|
||||
}
|
||||
|
||||
impl HandGatewayNodeConfig {
|
||||
pub const fn new(config_mask: u32, sample_count: usize) -> Self {
|
||||
Self {
|
||||
config_mask,
|
||||
sample_count,
|
||||
}
|
||||
}
|
||||
|
||||
fn payload_len(&self, bytes_per_sample: usize) -> Option<usize> {
|
||||
self.sample_count.checked_mul(bytes_per_sample)
|
||||
}
|
||||
}
|
||||
|
||||
/// Host-side description of the configuration currently hard-coded in the MCU.
|
||||
///
|
||||
/// Keep the node order identical to the MCU Config bit order. When the MCU gains
|
||||
/// GET_CONFIG support, construct this value from that response instead of changing
|
||||
/// the decoder.
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct HandGatewayConfig {
|
||||
pub protocol_version: u8,
|
||||
pub bytes_per_sample: usize,
|
||||
pub max_frame_length: usize,
|
||||
pub nodes: Vec<HandGatewayNodeConfig>,
|
||||
}
|
||||
|
||||
impl HandGatewayConfig {
|
||||
pub fn new(nodes: Vec<HandGatewayNodeConfig>) -> Self {
|
||||
Self {
|
||||
protocol_version: 0x01,
|
||||
bytes_per_sample: 2,
|
||||
max_frame_length: DEFAULT_MAX_FRAME_LENGTH,
|
||||
nodes,
|
||||
}
|
||||
}
|
||||
|
||||
fn validate(&self) -> Result<(), CodecError> {
|
||||
if self.bytes_per_sample == 0 || self.max_frame_length < MIN_FRAME_LENGTH {
|
||||
return Err(CodecError::InvalidLength);
|
||||
}
|
||||
|
||||
let mut used_masks = 0u32;
|
||||
for node in &self.nodes {
|
||||
if node.config_mask == 0
|
||||
|| node.config_mask.count_ones() != 1
|
||||
|| used_masks & node.config_mask != 0
|
||||
|| node.payload_len(self.bytes_per_sample).is_none()
|
||||
{
|
||||
return Err(CodecError::InvalidLength);
|
||||
}
|
||||
used_masks |= node.config_mask;
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
pub struct HandGatewayCodec {
|
||||
buffer: Vec<u8>,
|
||||
config: HandGatewayConfig,
|
||||
}
|
||||
|
||||
impl HandGatewayCodec {
|
||||
/// Convenience constructor for sequential Config bits (bit 0, bit 1, ...).
|
||||
/// Each entry is the u16 sample count of one MCU node.
|
||||
pub fn new(node_sample_counts: &[u16]) -> Self {
|
||||
let nodes = node_sample_counts
|
||||
.iter()
|
||||
.enumerate()
|
||||
.map(|(index, &sample_count)| {
|
||||
let config_mask = 1u32.checked_shl(index as u32).unwrap_or(0);
|
||||
HandGatewayNodeConfig::new(config_mask, usize::from(sample_count))
|
||||
})
|
||||
.collect();
|
||||
|
||||
Self {
|
||||
buffer: Vec::new(),
|
||||
config: HandGatewayConfig::new(nodes),
|
||||
}
|
||||
}
|
||||
|
||||
pub fn with_config(config: HandGatewayConfig) -> Result<Self, CodecError> {
|
||||
config.validate()?;
|
||||
Ok(Self {
|
||||
buffer: Vec::new(),
|
||||
config,
|
||||
})
|
||||
}
|
||||
|
||||
pub fn config(&self) -> &HandGatewayConfig {
|
||||
&self.config
|
||||
}
|
||||
|
||||
pub fn parse_node_payload(data: &[u8]) -> Result<Vec<u16>, CodecError> {
|
||||
if data.len() % 2 != 0 {
|
||||
return Err(CodecError::InvalidLength);
|
||||
}
|
||||
|
||||
Ok(data
|
||||
.chunks_exact(2)
|
||||
.map(|chunk| u16::from_le_bytes([chunk[0], chunk[1]]))
|
||||
.collect())
|
||||
}
|
||||
|
||||
fn retain_possible_header_prefix(&mut self) {
|
||||
if self.buffer.last() == Some(&FRAME_HEADER[0]) {
|
||||
self.buffer.drain(..self.buffer.len() - 1);
|
||||
} else {
|
||||
self.buffer.clear();
|
||||
}
|
||||
}
|
||||
|
||||
fn parse_data_response(
|
||||
&self,
|
||||
frame: &[u8],
|
||||
length: u16,
|
||||
session_started_at: Instant,
|
||||
) -> Result<HandGatewayFrame, CodecError> {
|
||||
let payload_len = usize::from(length)
|
||||
.checked_sub(RESPONSE_DATA_FIXED_LENGTH)
|
||||
.ok_or(CodecError::InvalidLength)?;
|
||||
let payload_end = RESPONSE_DATA_PREFIX_LENGTH
|
||||
.checked_add(payload_len)
|
||||
.ok_or(CodecError::PayloadTooLarge)?;
|
||||
|
||||
if payload_end + 1 != frame.len() {
|
||||
return Err(CodecError::InvalidLength);
|
||||
}
|
||||
|
||||
let version = frame[5];
|
||||
if version != self.config.protocol_version {
|
||||
return Err(CodecError::InvalidFrameType);
|
||||
}
|
||||
|
||||
let timestamp = u32::from_le_bytes(frame[6..10].try_into().unwrap());
|
||||
let config = u32::from_le_bytes(frame[10..14].try_into().unwrap());
|
||||
let valid_config = u32::from_le_bytes(frame[14..18].try_into().unwrap());
|
||||
let block_count = frame[18];
|
||||
|
||||
let active_nodes: Vec<&HandGatewayNodeConfig> = self
|
||||
.config
|
||||
.nodes
|
||||
.iter()
|
||||
.filter(|node| config & node.config_mask != 0)
|
||||
.collect();
|
||||
|
||||
if active_nodes.len() != usize::from(block_count) {
|
||||
return Err(CodecError::InvalidLength);
|
||||
}
|
||||
|
||||
let expected_payload_len = active_nodes.iter().try_fold(0usize, |total, node| {
|
||||
let node_len = node
|
||||
.payload_len(self.config.bytes_per_sample)
|
||||
.ok_or(CodecError::PayloadTooLarge)?;
|
||||
total
|
||||
.checked_add(node_len)
|
||||
.ok_or(CodecError::PayloadTooLarge)
|
||||
})?;
|
||||
|
||||
if expected_payload_len != payload_len {
|
||||
return Err(CodecError::InvalidLength);
|
||||
}
|
||||
|
||||
let mut cursor = RESPONSE_DATA_PREFIX_LENGTH;
|
||||
let mut nodes = Vec::with_capacity(active_nodes.len());
|
||||
for node in active_nodes {
|
||||
let node_len = node
|
||||
.payload_len(self.config.bytes_per_sample)
|
||||
.ok_or(CodecError::PayloadTooLarge)?;
|
||||
let next = cursor + node_len;
|
||||
nodes.push(HandGatewayFrameNode {
|
||||
config_mask: node.config_mask,
|
||||
valid: valid_config & node.config_mask != 0,
|
||||
payload: frame[cursor..next].to_vec(),
|
||||
});
|
||||
cursor = next;
|
||||
}
|
||||
|
||||
Ok(HandGatewayFrame::DataRep(HandGatewayDataRepFrame {
|
||||
meta: HandGatewayFrameMetaData {
|
||||
header: FRAME_HEADER,
|
||||
length,
|
||||
cmd: RESPONSE_DATA_CMD,
|
||||
version,
|
||||
checksum: frame[frame.len() - 1],
|
||||
},
|
||||
timestamp,
|
||||
config,
|
||||
valid_config,
|
||||
block_count,
|
||||
nodes,
|
||||
dts_ms: elapsed_millis(session_started_at),
|
||||
}))
|
||||
}
|
||||
}
|
||||
|
||||
impl Codec<HandGatewayFrame> for HandGatewayCodec {
|
||||
fn decode(
|
||||
&mut self,
|
||||
input: &[u8],
|
||||
session_started_at: Instant,
|
||||
) -> Result<Vec<HandGatewayFrame>, CodecError> {
|
||||
self.config.validate()?;
|
||||
self.buffer.extend_from_slice(input);
|
||||
let mut frames = Vec::new();
|
||||
|
||||
loop {
|
||||
let Some(header_pos) = self
|
||||
.buffer
|
||||
.windows(FRAME_HEADER.len())
|
||||
.position(|window| window == FRAME_HEADER)
|
||||
else {
|
||||
self.retain_possible_header_prefix();
|
||||
break;
|
||||
};
|
||||
|
||||
if header_pos > 0 {
|
||||
self.buffer.drain(..header_pos);
|
||||
}
|
||||
|
||||
if self.buffer.len() < 4 {
|
||||
break;
|
||||
}
|
||||
|
||||
let length = u16::from_le_bytes([self.buffer[2], self.buffer[3]]);
|
||||
let frame_len = usize::from(length)
|
||||
.checked_add(4)
|
||||
.ok_or(CodecError::PayloadTooLarge)?;
|
||||
|
||||
if frame_len < MIN_FRAME_LENGTH || frame_len > self.config.max_frame_length {
|
||||
debug!("invalid hand gateway frame length: {frame_len}");
|
||||
self.buffer.drain(..1);
|
||||
continue;
|
||||
}
|
||||
|
||||
if self.buffer.len() < frame_len {
|
||||
break;
|
||||
}
|
||||
|
||||
let expected_checksum = calc_crc8_itu(&self.buffer[..frame_len - 1]);
|
||||
let received_checksum = self.buffer[frame_len - 1];
|
||||
if expected_checksum != received_checksum {
|
||||
debug!(
|
||||
"hand gateway checksum mismatch: expected {expected_checksum:02X}, got {received_checksum:02X}"
|
||||
);
|
||||
self.buffer.drain(..1);
|
||||
continue;
|
||||
}
|
||||
|
||||
if self.buffer[4] == RESPONSE_DATA_CMD {
|
||||
match self.parse_data_response(
|
||||
&self.buffer[..frame_len],
|
||||
length,
|
||||
session_started_at,
|
||||
) {
|
||||
Ok(frame) => frames.push(frame),
|
||||
Err(error) => debug!("invalid hand gateway data response: {error}"),
|
||||
}
|
||||
}
|
||||
|
||||
self.buffer.drain(..frame_len);
|
||||
}
|
||||
|
||||
Ok(frames)
|
||||
}
|
||||
|
||||
fn encode(&self, _frame: &HandGatewayFrame) -> Result<Vec<u8>, CodecError> {
|
||||
Err(CodecError::InvalidFrameType)
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
fn test_codec() -> HandGatewayCodec {
|
||||
HandGatewayCodec::with_config(HandGatewayConfig::new(vec![
|
||||
HandGatewayNodeConfig::new(1 << 0, 2),
|
||||
HandGatewayNodeConfig::new(1 << 1, 1),
|
||||
]))
|
||||
.unwrap()
|
||||
}
|
||||
|
||||
fn data_response(config: u32, valid_config: u32, payload: &[u8]) -> Vec<u8> {
|
||||
let block_count = config.count_ones() as u8;
|
||||
let length = (RESPONSE_DATA_FIXED_LENGTH + payload.len()) as u16;
|
||||
let mut frame = Vec::new();
|
||||
frame.extend_from_slice(&FRAME_HEADER);
|
||||
frame.extend_from_slice(&length.to_le_bytes());
|
||||
frame.push(RESPONSE_DATA_CMD);
|
||||
frame.push(0x01);
|
||||
frame.extend_from_slice(&123_456u32.to_le_bytes());
|
||||
frame.extend_from_slice(&config.to_le_bytes());
|
||||
frame.extend_from_slice(&valid_config.to_le_bytes());
|
||||
frame.push(block_count);
|
||||
frame.extend_from_slice(payload);
|
||||
frame.push(calc_crc8_itu(&frame));
|
||||
frame
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn decodes_configured_nodes() {
|
||||
let mut codec = test_codec();
|
||||
let bytes = data_response(0b11, 0b01, &[1, 0, 2, 0, 3, 0]);
|
||||
let frames = codec.decode(&bytes, Instant::now()).unwrap();
|
||||
|
||||
let HandGatewayFrame::DataRep(frame) = &frames[0];
|
||||
assert_eq!(frame.timestamp, 123_456);
|
||||
assert_eq!(frame.block_count, 2);
|
||||
assert_eq!(frame.nodes.len(), 2);
|
||||
assert_eq!(frame.nodes[0].config_mask, 1);
|
||||
assert!(frame.nodes[0].valid);
|
||||
assert_eq!(
|
||||
HandGatewayCodec::parse_node_payload(&frame.nodes[0].payload).unwrap(),
|
||||
[1, 2]
|
||||
);
|
||||
assert!(!frame.nodes[1].valid);
|
||||
assert_eq!(
|
||||
HandGatewayCodec::parse_node_payload(&frame.nodes[1].payload).unwrap(),
|
||||
[3]
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn supports_split_and_sticky_packets() {
|
||||
let mut codec = test_codec();
|
||||
let frame = data_response(0b01, 0b01, &[1, 0, 2, 0]);
|
||||
let split = frame.len() / 2;
|
||||
|
||||
assert!(codec
|
||||
.decode(&frame[..split], Instant::now())
|
||||
.unwrap()
|
||||
.is_empty());
|
||||
|
||||
let mut remainder_and_next = frame[split..].to_vec();
|
||||
remainder_and_next.extend_from_slice(&frame);
|
||||
let frames = codec.decode(&remainder_and_next, Instant::now()).unwrap();
|
||||
assert_eq!(frames.len(), 2);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn resynchronizes_after_noise_and_bad_crc() {
|
||||
let mut codec = test_codec();
|
||||
let valid = data_response(0b10, 0b10, &[9, 0]);
|
||||
let mut bad = valid.clone();
|
||||
let last = bad.len() - 1;
|
||||
bad[last] ^= 0xFF;
|
||||
|
||||
let mut bytes = vec![0x13, 0x55, 0x12];
|
||||
bytes.extend_from_slice(&bad);
|
||||
bytes.extend_from_slice(&valid);
|
||||
|
||||
let frames = codec.decode(&bytes, Instant::now()).unwrap();
|
||||
assert_eq!(frames.len(), 1);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn rejects_payload_that_does_not_match_fixed_config() {
|
||||
let mut codec = test_codec();
|
||||
let bytes = data_response(0b01, 0b01, &[1, 0]);
|
||||
assert!(codec.decode(&bytes, Instant::now()).unwrap().is_empty());
|
||||
}
|
||||
}
|
||||
@@ -2,4 +2,5 @@ use crate::serial_core::{frame::TestFrame, record::Recording};
|
||||
|
||||
pub mod test;
|
||||
pub mod tactile_a;
|
||||
pub type TestRecording = Recording<TestFrame>;
|
||||
pub mod hand_gateway;
|
||||
pub type TestRecording = Recording<TestFrame>;
|
||||
|
||||
@@ -14,7 +14,7 @@ use anyhow::anyhow;
|
||||
use std::io::Read;
|
||||
use log::debug;
|
||||
|
||||
const FRAME_BUFFER_MIN_LENGTH: usize = 15;
|
||||
const FINGER_FRAME_BUFFER_MIN_LENGTH: usize = 15;
|
||||
|
||||
pub struct TactileACodec {
|
||||
buffer: Vec<u8>,
|
||||
@@ -77,11 +77,12 @@ impl TactileACodec {
|
||||
.chunks_exact(2)
|
||||
.map(|chunk| {
|
||||
let raw = u16::from_le_bytes([chunk[0], chunk[1]]) as i32;
|
||||
if raw < 15 {
|
||||
0
|
||||
} else {
|
||||
raw
|
||||
}
|
||||
raw
|
||||
// if raw < 15 {
|
||||
// 0
|
||||
// } else {
|
||||
// raw
|
||||
// }
|
||||
})
|
||||
.collect::<Vec<i32>>();
|
||||
|
||||
@@ -122,7 +123,7 @@ impl Codec<TactileAFrame> for TactileACodec {
|
||||
let mut frames: Vec<TactileAFrame> = Vec::new();
|
||||
|
||||
loop {
|
||||
if self.buffer.len() < FRAME_BUFFER_MIN_LENGTH {
|
||||
if self.buffer.len() < FINGER_FRAME_BUFFER_MIN_LENGTH {
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -136,7 +137,7 @@ impl Codec<TactileAFrame> for TactileACodec {
|
||||
self.buffer.drain(0..pos);
|
||||
}
|
||||
|
||||
if self.buffer.len() < FRAME_BUFFER_MIN_LENGTH {
|
||||
if self.buffer.len() < FINGER_FRAME_BUFFER_MIN_LENGTH {
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -164,7 +165,7 @@ impl Codec<TactileAFrame> for TactileACodec {
|
||||
continue;
|
||||
}
|
||||
|
||||
let frame_length = except_data_len + FRAME_BUFFER_MIN_LENGTH;
|
||||
let frame_length = except_data_len + FINGER_FRAME_BUFFER_MIN_LENGTH;
|
||||
if self.buffer.len() < frame_length {
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ pub struct TestFrame {
|
||||
pub length: usize,
|
||||
pub payload: Vec<u8>,
|
||||
pub checksum: u8,
|
||||
pub dts_ms: u64
|
||||
pub dts_ms: u64,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
@@ -30,28 +30,59 @@ pub struct TactileAReqFrame {
|
||||
pub meta: TactileAFrameMetaData,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct TactileARepFrame {
|
||||
pub meta: TactileAFrameMetaData,
|
||||
pub status: TactileAFrameStatusCode,
|
||||
pub payload: Vec<u8>,
|
||||
pub dts_ms: u64
|
||||
pub dts_ms: u64,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub enum TactileAFrameStatusCode {
|
||||
Success,
|
||||
Failure
|
||||
Failure,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub enum TactileAFrame {
|
||||
Req(TactileAReqFrame),
|
||||
Rep(TactileARepFrame)
|
||||
Rep(TactileARepFrame),
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct HandGatewayFrameMetaData {
|
||||
pub header: [u8; 2],
|
||||
pub length: u16,
|
||||
pub cmd: u8,
|
||||
pub version: u8,
|
||||
pub checksum: u8,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct HandGatewayFrameNode {
|
||||
pub config_mask: u32,
|
||||
pub valid: bool,
|
||||
pub payload: Vec<u8>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct HandGatewayDataRepFrame {
|
||||
pub meta: HandGatewayFrameMetaData,
|
||||
pub timestamp: u32,
|
||||
pub config: u32,
|
||||
pub valid_config: u32,
|
||||
pub block_count: u8,
|
||||
pub nodes: Vec<HandGatewayFrameNode>,
|
||||
pub dts_ms: u64,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub enum HandGatewayFrame {
|
||||
DataRep(HandGatewayDataRepFrame),
|
||||
}
|
||||
|
||||
#[async_trait]
|
||||
pub trait FrameHandler<F, T>: Send {
|
||||
async fn on_frame(&mut self, frame: &F) -> Result<Option<Vec<T>>>;
|
||||
}
|
||||
|
||||
|
||||
@@ -17,7 +17,6 @@ const ACTIVE_CELL_MIN_VALUE: f32 = 18.0;
|
||||
const ACTIVE_CELL_PEAK_RATIO: f32 = 0.14;
|
||||
const MIN_ACTIVE_CELLS: usize = 3;
|
||||
|
||||
const ANCHOR_LERP_ALPHA: f32 = 0.018;
|
||||
const VECTOR_SMOOTHING_ALPHA: f32 = 0.16;
|
||||
|
||||
const REPORT_MAGNITUDE_ENTER: f32 = 0.12;
|
||||
@@ -29,6 +28,12 @@ const REPORT_HOLD_FRAMES: usize = 10;
|
||||
const ASYMMETRY_WEIGHT: f32 = 1.1;
|
||||
const DRIFT_WEIGHT: f32 = 0.65;
|
||||
const MOTION_WEIGHT: f32 = 0.25;
|
||||
const EDGE_ASYMMETRY_DAMPING: f32 = 0.35;
|
||||
const EDGE_INWARD_ROLLING_BIAS: f32 = 0.55;
|
||||
const EDGE_START_COP_THRESHOLD: f32 = 0.45;
|
||||
const EDGE_START_BIAS_WEIGHT: f32 = 1.1;
|
||||
const ROLLING_FRICTION_ALPHA: f32 = 0.68;
|
||||
const ROLLING_FRICTION_MIN_MAGNITUDE: f32 = 0.05;
|
||||
|
||||
#[derive(Debug, Clone, Copy)]
|
||||
pub struct PztSpatialAnalysis {
|
||||
@@ -50,6 +55,8 @@ pub struct PztProcessor {
|
||||
anchor_cop_y: Option<f32>,
|
||||
last_cop_x: Option<f32>,
|
||||
last_cop_y: Option<f32>,
|
||||
edge_start_bias_x: f32,
|
||||
edge_start_bias_y: f32,
|
||||
smoothed_x: f32,
|
||||
smoothed_y: f32,
|
||||
report_active: bool,
|
||||
@@ -84,6 +91,8 @@ impl PztProcessor {
|
||||
anchor_cop_y: None,
|
||||
last_cop_x: None,
|
||||
last_cop_y: None,
|
||||
edge_start_bias_x: 0.0,
|
||||
edge_start_bias_y: 0.0,
|
||||
smoothed_x: 0.0,
|
||||
smoothed_y: 0.0,
|
||||
report_active: false,
|
||||
@@ -100,6 +109,8 @@ impl PztProcessor {
|
||||
self.anchor_cop_y = None;
|
||||
self.last_cop_x = None;
|
||||
self.last_cop_y = None;
|
||||
self.edge_start_bias_x = 0.0;
|
||||
self.edge_start_bias_y = 0.0;
|
||||
self.smoothed_x = 0.0;
|
||||
self.smoothed_y = 0.0;
|
||||
}
|
||||
@@ -273,6 +284,112 @@ impl PztProcessor {
|
||||
(angle, magnitude)
|
||||
}
|
||||
|
||||
fn contact_touches_edge(stats: &ContactStats) -> bool {
|
||||
stats.min_row == 0
|
||||
|| stats.max_row == SENSOR_ROWS - 1
|
||||
|| stats.min_col == 0
|
||||
|| stats.max_col == SENSOR_COLS - 1
|
||||
}
|
||||
|
||||
fn damp_edge_asymmetry(
|
||||
stats: &ContactStats,
|
||||
kinematic_x: f32,
|
||||
kinematic_y: f32,
|
||||
) -> (f32, f32) {
|
||||
let mut asymmetry_x = stats.asymmetry_x * ASYMMETRY_WEIGHT;
|
||||
let mut asymmetry_y = stats.asymmetry_y * ASYMMETRY_WEIGHT;
|
||||
|
||||
if stats.min_col == 0 && asymmetry_x < 0.0 {
|
||||
asymmetry_x = -asymmetry_x * EDGE_INWARD_ROLLING_BIAS;
|
||||
}
|
||||
if stats.max_col == SENSOR_COLS - 1 && asymmetry_x > 0.0 {
|
||||
asymmetry_x = -asymmetry_x * EDGE_INWARD_ROLLING_BIAS;
|
||||
}
|
||||
if stats.min_row == 0 && asymmetry_y < 0.0 {
|
||||
asymmetry_y = -asymmetry_y * EDGE_INWARD_ROLLING_BIAS;
|
||||
}
|
||||
if stats.max_row == SENSOR_ROWS - 1 && asymmetry_y > 0.0 {
|
||||
asymmetry_y = -asymmetry_y * EDGE_INWARD_ROLLING_BIAS;
|
||||
}
|
||||
|
||||
if Self::contact_touches_edge(stats) {
|
||||
let opposing_dot = asymmetry_x * kinematic_x + asymmetry_y * kinematic_y;
|
||||
let kinematic_mag = (kinematic_x * kinematic_x + kinematic_y * kinematic_y).sqrt();
|
||||
if opposing_dot < 0.0 && kinematic_mag >= ROLLING_FRICTION_MIN_MAGNITUDE {
|
||||
asymmetry_x *= EDGE_ASYMMETRY_DAMPING;
|
||||
asymmetry_y *= EDGE_ASYMMETRY_DAMPING;
|
||||
}
|
||||
}
|
||||
|
||||
(asymmetry_x, asymmetry_y)
|
||||
}
|
||||
|
||||
fn edge_start_bias(stats: &ContactStats) -> (f32, f32) {
|
||||
let center_x = (SENSOR_COLS - 1) as f32 * 0.5;
|
||||
let center_y = (SENSOR_ROWS - 1) as f32 * 0.5;
|
||||
let normalized_x = ((stats.cop_x - center_x) / center_x.max(1.0)).clamp(-1.0, 1.0);
|
||||
let normalized_y = ((stats.cop_y - center_y) / center_y.max(1.0)).clamp(-1.0, 1.0);
|
||||
|
||||
let mut bias_x = 0.0;
|
||||
let mut bias_y = 0.0;
|
||||
|
||||
if stats.min_col == 0 || stats.max_col == SENSOR_COLS - 1 {
|
||||
bias_x = Self::edge_start_axis_bias(normalized_x);
|
||||
}
|
||||
if stats.min_row == 0 || stats.max_row == SENSOR_ROWS - 1 {
|
||||
bias_y = Self::edge_start_axis_bias(normalized_y);
|
||||
}
|
||||
|
||||
(bias_x, bias_y)
|
||||
}
|
||||
|
||||
fn edge_start_axis_bias(normalized_axis: f32) -> f32 {
|
||||
let distance = normalized_axis.abs();
|
||||
if distance <= EDGE_START_COP_THRESHOLD {
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
let strength = ((distance - EDGE_START_COP_THRESHOLD) / (1.0 - EDGE_START_COP_THRESHOLD))
|
||||
.clamp(0.0, 1.0);
|
||||
-normalized_axis.signum() * strength * EDGE_START_BIAS_WEIGHT
|
||||
}
|
||||
|
||||
fn apply_rolling_friction(
|
||||
previous_x: f32,
|
||||
previous_y: f32,
|
||||
current_x: f32,
|
||||
current_y: f32,
|
||||
) -> (f32, f32) {
|
||||
let previous_mag = (previous_x * previous_x + previous_y * previous_y).sqrt();
|
||||
let current_mag = (current_x * current_x + current_y * current_y).sqrt();
|
||||
|
||||
if previous_mag < ROLLING_FRICTION_MIN_MAGNITUDE
|
||||
|| current_mag < ROLLING_FRICTION_MIN_MAGNITUDE
|
||||
{
|
||||
return (current_x, current_y);
|
||||
}
|
||||
|
||||
let dot = previous_x * current_x + previous_y * current_y;
|
||||
if dot >= 0.0 {
|
||||
return (current_x, current_y);
|
||||
}
|
||||
|
||||
let mixed_x = current_x * (1.0 - ROLLING_FRICTION_ALPHA)
|
||||
+ previous_x * ROLLING_FRICTION_ALPHA;
|
||||
let mixed_y = current_y * (1.0 - ROLLING_FRICTION_ALPHA)
|
||||
+ previous_y * ROLLING_FRICTION_ALPHA;
|
||||
|
||||
if mixed_x * previous_x + mixed_y * previous_y >= 0.0 {
|
||||
return (mixed_x, mixed_y);
|
||||
}
|
||||
|
||||
let keep_mag = previous_mag.min(current_mag) * 0.5;
|
||||
(
|
||||
previous_x / previous_mag * keep_mag,
|
||||
previous_y / previous_mag * keep_mag,
|
||||
)
|
||||
}
|
||||
|
||||
fn update_contact_state(&mut self, raw_frame: &[f32], frame: &[f32]) -> bool {
|
||||
if self.contact_active {
|
||||
if Self::is_contact_exit_frame(frame) {
|
||||
@@ -376,6 +493,9 @@ impl PztProcessor {
|
||||
self.anchor_cop_y = Some(stats.cop_y);
|
||||
self.last_cop_x = Some(stats.cop_x);
|
||||
self.last_cop_y = Some(stats.cop_y);
|
||||
let (edge_start_bias_x, edge_start_bias_y) = Self::edge_start_bias(&stats);
|
||||
self.edge_start_bias_x = edge_start_bias_x;
|
||||
self.edge_start_bias_y = edge_start_bias_y;
|
||||
|
||||
return Ok(self.stabilize_report(Self::weak_contact_analysis()));
|
||||
};
|
||||
@@ -388,18 +508,25 @@ impl PztProcessor {
|
||||
let motion_x = stats.cop_x - last_x;
|
||||
let motion_y = stats.cop_y - last_y;
|
||||
|
||||
let combined_x = stats.asymmetry_x * ASYMMETRY_WEIGHT
|
||||
+ drift_x * DRIFT_WEIGHT
|
||||
+ motion_x * MOTION_WEIGHT;
|
||||
let combined_y = stats.asymmetry_y * ASYMMETRY_WEIGHT
|
||||
+ drift_y * DRIFT_WEIGHT
|
||||
+ motion_y * MOTION_WEIGHT;
|
||||
let kinematic_x = drift_x * DRIFT_WEIGHT + motion_x * MOTION_WEIGHT;
|
||||
let kinematic_y = drift_y * DRIFT_WEIGHT + motion_y * MOTION_WEIGHT;
|
||||
let edge_bias_x = self.edge_start_bias_x;
|
||||
let edge_bias_y = self.edge_start_bias_y;
|
||||
let (asymmetry_x, asymmetry_y) =
|
||||
Self::damp_edge_asymmetry(&stats, kinematic_x + edge_bias_x, kinematic_y + edge_bias_y);
|
||||
|
||||
let combined_x = asymmetry_x + kinematic_x + edge_bias_x;
|
||||
let combined_y = asymmetry_y + kinematic_y + edge_bias_y;
|
||||
let (combined_x, combined_y) = Self::apply_rolling_friction(
|
||||
self.smoothed_x,
|
||||
self.smoothed_y,
|
||||
combined_x,
|
||||
combined_y,
|
||||
);
|
||||
|
||||
self.smoothed_x += (combined_x - self.smoothed_x) * VECTOR_SMOOTHING_ALPHA;
|
||||
self.smoothed_y += (combined_y - self.smoothed_y) * VECTOR_SMOOTHING_ALPHA;
|
||||
|
||||
self.anchor_cop_x = Some(anchor_x + drift_x * ANCHOR_LERP_ALPHA);
|
||||
self.anchor_cop_y = Some(anchor_y + drift_y * ANCHOR_LERP_ALPHA);
|
||||
self.last_cop_x = Some(stats.cop_x);
|
||||
self.last_cop_y = Some(stats.cop_y);
|
||||
|
||||
@@ -446,7 +573,7 @@ impl PztProcessor {
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::{PztProcessor, SENSOR_COLS, SENSOR_ROWS};
|
||||
use super::{ContactStats, PztProcessor, SENSOR_COLS, SENSOR_ROWS};
|
||||
|
||||
fn index(row: usize, col: usize) -> usize {
|
||||
row * SENSOR_COLS + col
|
||||
@@ -460,6 +587,23 @@ mod tests {
|
||||
frame
|
||||
}
|
||||
|
||||
fn stats_touching_bottom_edge() -> ContactStats {
|
||||
ContactStats {
|
||||
total: 1000.0,
|
||||
peak: 300.0,
|
||||
active_total: 900.0,
|
||||
active_cells: 6,
|
||||
min_row: SENSOR_ROWS - 2,
|
||||
max_row: SENSOR_ROWS - 1,
|
||||
min_col: 2,
|
||||
max_col: 4,
|
||||
cop_x: 3.0,
|
||||
cop_y: 10.5,
|
||||
asymmetry_x: 0.0,
|
||||
asymmetry_y: 1.0,
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn idle_frame_does_not_report_contact() {
|
||||
let mut processor = PztProcessor::new();
|
||||
@@ -524,4 +668,29 @@ mod tests {
|
||||
let analysis = processor.get_pzt_analysis(&weak).unwrap();
|
||||
assert!(analysis.reportable);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn bottom_edge_outward_gradient_is_turned_inward() {
|
||||
let stats = stats_touching_bottom_edge();
|
||||
let (_asymmetry_x, asymmetry_y) = PztProcessor::damp_edge_asymmetry(&stats, 0.0, -0.2);
|
||||
|
||||
assert!(asymmetry_y < 0.0);
|
||||
assert!(asymmetry_y > -1.1);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn bottom_edge_start_adds_fixed_upward_bias() {
|
||||
let stats = stats_touching_bottom_edge();
|
||||
let (_bias_x, bias_y) = PztProcessor::edge_start_bias(&stats);
|
||||
|
||||
assert!(bias_y < 0.0);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn rolling_friction_resists_one_frame_reversal() {
|
||||
let (x, y) = PztProcessor::apply_rolling_friction(0.4, 0.0, -0.6, 0.0);
|
||||
|
||||
assert!(x > 0.0);
|
||||
assert_eq!(y, 0.0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
use crate::ad_solver::solve_for_x;
|
||||
#[cfg(feature = "devkit")]
|
||||
use crate::devkit::{proto::SensorFrame, DevKitState};
|
||||
use crate::serial_core::codec::Codec;
|
||||
use crate::serial_core::codecs::hand_gateway::HandGatewayCodec;
|
||||
use crate::serial_core::codecs::tactile_a::TactileACodec;
|
||||
use crate::serial_core::frame::{FrameHandler, TactileAFrame, TestFrame};
|
||||
use crate::serial_core::model::{HudChartState, HudPacket, HudSpatialForce};
|
||||
@@ -10,6 +12,7 @@ use crate::serial_core::record::Recording;
|
||||
use crate::serial_core::record::{FrameTiming, RecordedFrame};
|
||||
use anyhow::Result;
|
||||
use log::debug;
|
||||
use log::info;
|
||||
use std::future::pending;
|
||||
#[cfg(feature = "devkit")]
|
||||
use std::sync::atomic::Ordering;
|
||||
@@ -22,7 +25,6 @@ use tokio::io::{AsyncReadExt, AsyncWriteExt};
|
||||
use tokio::time::{self, Duration, MissedTickBehavior};
|
||||
use tokio_serial::SerialStream;
|
||||
use tokio_util::sync::CancellationToken;
|
||||
|
||||
const AUTO_SUB_INTERVAL: Duration = Duration::from_nanos(16_666_667);
|
||||
|
||||
pub enum PollMode<F> {
|
||||
@@ -200,6 +202,61 @@ where
|
||||
.await
|
||||
}
|
||||
|
||||
/// Runs the hand gateway in passive mode. The MCU continuously uploads data, so
|
||||
/// this loop never writes request frames to the serial port.
|
||||
pub async fn run_hand_gateway_serial(
|
||||
app: AppHandle,
|
||||
mut port: SerialStream,
|
||||
mut codec: HandGatewayCodec,
|
||||
session_started_at: Instant,
|
||||
cancel: CancellationToken,
|
||||
) -> Result<()> {
|
||||
let mut buffer = [0u8; 4096];
|
||||
|
||||
loop {
|
||||
tokio::select! {
|
||||
_ = cancel.cancelled() => break,
|
||||
read_result = port.read(&mut buffer) => {
|
||||
let n = read_result?;
|
||||
if n == 0 {
|
||||
tokio::task::yield_now().await;
|
||||
continue;
|
||||
}
|
||||
|
||||
let raw = &buffer[..n];
|
||||
app.emit("hand_gateway_raw", raw.to_vec())?;
|
||||
let raw_hex = raw
|
||||
.iter()
|
||||
.map(|byte| format!("{byte:02X}"))
|
||||
.collect::<Vec<_>>()
|
||||
.join(" ");
|
||||
info!("[hand_gateway][raw] {raw_hex}");
|
||||
|
||||
for frame in codec.decode(raw, session_started_at)? {
|
||||
let crate::serial_core::frame::HandGatewayFrame::DataRep(frame) = frame;
|
||||
info!(
|
||||
"[hand_gateway][frame] timestamp_us={} config=0x{:08X} valid_config=0x{:08X} block_count={}",
|
||||
frame.timestamp,
|
||||
frame.config,
|
||||
frame.valid_config,
|
||||
frame.block_count,
|
||||
);
|
||||
for node in frame.nodes {
|
||||
info!(
|
||||
"[hand_gateway][node] mask=0x{:08X} valid={} payload={:02X?}",
|
||||
node.config_mask,
|
||||
node.valid,
|
||||
node.payload,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub async fn run_serial_with_poll<C, H, T, F>(
|
||||
app: AppHandle,
|
||||
mut port: SerialStream,
|
||||
@@ -316,10 +373,10 @@ where
|
||||
{
|
||||
let pzt_values = vals.iter().map(|value| *value as f32).collect::<Vec<f32>>();
|
||||
if let Ok(analysis) = pzt_processor.get_pzt_analysis(&pzt_values) {
|
||||
debug!(
|
||||
"spatial force: angle={:.2}°, magnitude={:.2}, dx={:.2}, dy={:.2}",
|
||||
analysis.angle_deg, analysis.magnitude, analysis.planar_x, analysis.planar_y
|
||||
);
|
||||
// debug!(
|
||||
// "spatial force: angle={:.2}°, magnitude={:.2}, dx={:.2}, dy={:.2}",
|
||||
// analysis.angle_deg, analysis.magnitude, analysis.planar_x, analysis.planar_y
|
||||
// );
|
||||
if PztProcessor::should_report(&analysis) {
|
||||
spatial_force = Some(HudSpatialForce {
|
||||
angle_deg: analysis.angle_deg,
|
||||
@@ -333,6 +390,7 @@ where
|
||||
{
|
||||
let summary = vals.iter().copied().sum::<i32>();
|
||||
let force = raw_to_g1(summary as u32);
|
||||
|
||||
push_devkit_frame(&app, vals.as_slice(), frame.dts_ms(), force);
|
||||
}
|
||||
|
||||
@@ -358,6 +416,8 @@ fn build_display_values(
|
||||
) -> Option<Vec<i32>> {
|
||||
let summary = values.iter().copied().sum::<i32>();
|
||||
let force = raw_to_g1(summary as u32);
|
||||
// let force_solve = solve_for_x(summary as f64)?;
|
||||
// println!("force_solve: {force_solve}");
|
||||
chart_state.record_summary(force as f32);
|
||||
chart_state.record_pressure_matrix(values);
|
||||
chart_state.record_spatial_force(spatial_force);
|
||||
@@ -417,12 +477,13 @@ fn infer_matrix_shape(len: usize) -> (u32, u32) {
|
||||
}
|
||||
|
||||
fn raw_to_g1(raw: u32) -> f64 {
|
||||
const X: [u32; 12] = [
|
||||
0, 84402, 117218, 140176, 159126, 175812, 191484, 208758, 224703, 252448, 302361, 352703,
|
||||
const X: [u32; 13] = [
|
||||
0, 16811, 41350, 79241, 94615, 127446, 149559, 175900, 195056, 237852, 267810, 322472,
|
||||
378511,
|
||||
];
|
||||
|
||||
const Y: [f64; 12] = [
|
||||
0.0, 160.0, 260.0, 360.0, 460.0, 560.0, 660.0, 760.0, 860.0, 1060.0, 1560.0, 2060.0,
|
||||
const Y: [f64; 13] = [
|
||||
0.0, 57.0, 97.0, 197.0, 257.0, 357.0, 457.0, 557.0, 657.0, 857.0, 1057.0, 1557.0, 2057.0,
|
||||
];
|
||||
|
||||
let n = X.len();
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
export let colorMapPreset: PressureColorMapPreset = "emerald";
|
||||
export let matrixDisplayMode: MatrixDisplayMode = "dots";
|
||||
export let stageViewMode: StageViewMode = "webgl";
|
||||
export let modelUrl = "/models/je-skin-model.glb";
|
||||
export let modelUrl = "/models/je-skin-model.gltf";
|
||||
export let replaySectionLabel = "";
|
||||
export let replayPlayLabel = "";
|
||||
export let replayPauseLabel = "";
|
||||
|
||||
@@ -19,43 +19,15 @@
|
||||
|
||||
const FLOOR_Y = -1.15;
|
||||
const MODEL_FLOOR_CLEARANCE = 0.035;
|
||||
const MODEL_TARGET_HEIGHT = 8.4;
|
||||
const MODEL_TARGET_HEIGHT = 6.55;
|
||||
const MODEL_MIN_SCALE = 0.02;
|
||||
const MODEL_MAX_SCALE = 80;
|
||||
const CAMERA_DISTANCE_FACTOR = 1.35;
|
||||
const CAMERA_DISTANCE_MIN = 7.5;
|
||||
const CAMERA_DISTANCE_MAX = 24;
|
||||
const FIXED_CAMERA_POSITION = new THREE.Vector3(-0.113, -0.149, 10.911);
|
||||
const FIXED_CAMERA_TARGET = new THREE.Vector3(0, 2.35, 0);
|
||||
const MODEL_FRONT_ROTATION_Y = -Math.PI / 2;
|
||||
const MODEL_UPRIGHT_ROTATION_Z = Math.PI * 1.5 - THREE.MathUtils.degToRad(2.2);
|
||||
|
||||
$: copy =
|
||||
locale === "zh-CN"
|
||||
? {
|
||||
title: "3D 模型舱",
|
||||
subtitle: "Dark Grid / Future Lab",
|
||||
loading: "正在加载模型",
|
||||
ready: "模型已载入",
|
||||
missing: "等待模型文件",
|
||||
error: "模型加载失败",
|
||||
modelPath: "模型路径",
|
||||
hint: "请使用 glTF 2.0 的 .glb/.gltf;旧版 glTF 1.0 需要先转换"
|
||||
}
|
||||
: {
|
||||
title: "3D Model Bay",
|
||||
subtitle: "Dark Grid / Future Lab",
|
||||
loading: "Loading model",
|
||||
ready: "Model loaded",
|
||||
missing: "Waiting for model file",
|
||||
error: "Model load failed",
|
||||
modelPath: "Model path",
|
||||
hint: "Use glTF 2.0 .glb/.gltf assets; older glTF 1.0 files need conversion first"
|
||||
};
|
||||
$: statusText =
|
||||
loadState === "ready"
|
||||
? copy.ready
|
||||
: loadState === "missing"
|
||||
? copy.missing
|
||||
: loadState === "error"
|
||||
? copy.error
|
||||
: `${copy.loading} ${Math.round(loadProgress)}%`;
|
||||
$: canvasLabel = locale === "zh-CN" ? "3D 模型" : "3D Model";
|
||||
|
||||
function disposeObject3D(object: THREE.Object3D): void {
|
||||
object.traverse((child) => {
|
||||
@@ -128,7 +100,41 @@
|
||||
return Math.min(max, Math.max(min, value));
|
||||
}
|
||||
|
||||
function materialToUnlit(material: THREE.Material): THREE.Material {
|
||||
const source = material as THREE.MeshStandardMaterial & THREE.MeshPhysicalMaterial;
|
||||
const unlit = new THREE.MeshBasicMaterial({
|
||||
color: source.color?.clone() ?? new THREE.Color(0xffffff),
|
||||
map: source.map ?? null,
|
||||
transparent: source.transparent,
|
||||
opacity: source.opacity,
|
||||
alphaMap: source.alphaMap ?? null,
|
||||
side: source.side,
|
||||
depthWrite: source.depthWrite,
|
||||
depthTest: source.depthTest,
|
||||
vertexColors: source.vertexColors,
|
||||
toneMapped: false
|
||||
});
|
||||
|
||||
return unlit;
|
||||
}
|
||||
|
||||
function applyUnlitMaterials(object: THREE.Object3D): void {
|
||||
object.traverse((child) => {
|
||||
const mesh = child as THREE.Mesh;
|
||||
if (!mesh.isMesh || !mesh.material) {
|
||||
return;
|
||||
}
|
||||
|
||||
mesh.castShadow = false;
|
||||
mesh.receiveShadow = false;
|
||||
mesh.material = Array.isArray(mesh.material)
|
||||
? mesh.material.map(materialToUnlit)
|
||||
: materialToUnlit(mesh.material);
|
||||
});
|
||||
}
|
||||
|
||||
function normalizeObjectToStage(object: THREE.Object3D): THREE.Box3 {
|
||||
object.rotation.set(0, MODEL_FRONT_ROTATION_Y, MODEL_UPRIGHT_ROTATION_Z);
|
||||
object.updateMatrixWorld(true);
|
||||
let bounds = new THREE.Box3().setFromObject(object);
|
||||
const size = bounds.getSize(new THREE.Vector3());
|
||||
@@ -149,19 +155,14 @@
|
||||
}
|
||||
|
||||
function frameObject(object: THREE.Object3D, camera: THREE.PerspectiveCamera, controls: OrbitControls): void {
|
||||
const bounds = normalizeObjectToStage(object);
|
||||
const size = bounds.getSize(new THREE.Vector3());
|
||||
const maxAxis = Math.max(size.x, size.y, size.z, 1);
|
||||
const distance = clamp(maxAxis * CAMERA_DISTANCE_FACTOR, CAMERA_DISTANCE_MIN, CAMERA_DISTANCE_MAX);
|
||||
const targetY = FLOOR_Y + Math.max(size.y * 0.46, 1.4);
|
||||
|
||||
camera.position.set(distance * 0.48, targetY + distance * 0.24, distance * 0.68);
|
||||
camera.near = Math.max(distance / 80, 0.01);
|
||||
camera.far = distance * 24;
|
||||
normalizeObjectToStage(object);
|
||||
camera.position.copy(FIXED_CAMERA_POSITION);
|
||||
camera.near = 0.05;
|
||||
camera.far = 600;
|
||||
camera.updateProjectionMatrix();
|
||||
controls.target.set(0, targetY, 0);
|
||||
controls.minDistance = Math.max(distance * 0.32, 2);
|
||||
controls.maxDistance = Math.max(distance * 2.5, 12);
|
||||
controls.target.copy(FIXED_CAMERA_TARGET);
|
||||
controls.minDistance = 2.4;
|
||||
controls.maxDistance = 32;
|
||||
controls.update();
|
||||
}
|
||||
|
||||
@@ -186,14 +187,15 @@
|
||||
scene.fog = new THREE.FogExp2(0x03070d, 0.028);
|
||||
|
||||
const camera = new THREE.PerspectiveCamera(38, 1, 0.05, 600);
|
||||
camera.position.set(8, 6, 9);
|
||||
camera.position.copy(FIXED_CAMERA_POSITION);
|
||||
camera.lookAt(FIXED_CAMERA_TARGET);
|
||||
|
||||
const controls = new OrbitControls(camera, canvasEl);
|
||||
controls.enableDamping = true;
|
||||
controls.dampingFactor = 0.08;
|
||||
controls.minDistance = 2.4;
|
||||
controls.maxDistance = 32;
|
||||
controls.target.set(0, FLOOR_Y + 3.2, 0);
|
||||
controls.target.copy(FIXED_CAMERA_TARGET);
|
||||
|
||||
const labGroup = new THREE.Group();
|
||||
scene.add(labGroup);
|
||||
@@ -241,16 +243,8 @@
|
||||
floor.position.y = FLOOR_Y - 0.018;
|
||||
labGroup.add(floor);
|
||||
|
||||
const ambient = new THREE.AmbientLight(0x9fb8d0, 0.22);
|
||||
const keyLight = new THREE.DirectionalLight(0x7be7ff, 1.5);
|
||||
keyLight.position.set(8, 12, 8);
|
||||
const rimLight = new THREE.PointLight(0xa6ff7a, 26, 24, 2.1);
|
||||
rimLight.position.set(-4.5, 4.8, -3.6);
|
||||
const sideLight = new THREE.PointLight(0x5c8cff, 15, 28, 1.7);
|
||||
sideLight.position.set(5.8, 3.2, -5.4);
|
||||
scene.add(ambient, keyLight, rimLight, sideLight);
|
||||
|
||||
let activeModel: THREE.Object3D = buildPlaceholderModel();
|
||||
applyUnlitMaterials(activeModel);
|
||||
scene.add(activeModel);
|
||||
frameObject(activeModel, camera, controls);
|
||||
|
||||
@@ -261,13 +255,7 @@
|
||||
scene.remove(activeModel);
|
||||
disposeObject3D(activeModel);
|
||||
activeModel = gltf.scene;
|
||||
activeModel.traverse((child) => {
|
||||
const mesh = child as THREE.Mesh;
|
||||
if (mesh.isMesh) {
|
||||
mesh.castShadow = true;
|
||||
mesh.receiveShadow = true;
|
||||
}
|
||||
});
|
||||
applyUnlitMaterials(activeModel);
|
||||
scene.add(activeModel);
|
||||
frameObject(activeModel, camera, controls);
|
||||
loadState = "ready";
|
||||
@@ -330,20 +318,9 @@
|
||||
</script>
|
||||
|
||||
<div class="model-stage" bind:this={rootEl}>
|
||||
<canvas class="model-canvas" bind:this={canvasEl} aria-label={copy.title}></canvas>
|
||||
<canvas class="model-canvas" bind:this={canvasEl} aria-label={canvasLabel}></canvas>
|
||||
<div class="model-vignette" aria-hidden="true"></div>
|
||||
<div class="model-scanlines" aria-hidden="true"></div>
|
||||
|
||||
<section class="model-hud" aria-label={copy.title}>
|
||||
<p class="model-kicker">{copy.subtitle}</p>
|
||||
<h2>{copy.title}</h2>
|
||||
<div class="model-status-row">
|
||||
<span class="status-light" class:is-ready={loadState === "ready"}></span>
|
||||
<span>{statusText}</span>
|
||||
</div>
|
||||
<p class="model-path">{copy.modelPath}: {modelUrl}</p>
|
||||
<p class="model-hint">{loadError || copy.hint}</p>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<style>
|
||||
@@ -388,82 +365,4 @@
|
||||
mix-blend-mode: screen;
|
||||
}
|
||||
|
||||
.model-hud {
|
||||
position: absolute;
|
||||
top: clamp(1.2rem, 2.8vw, 2.2rem);
|
||||
left: clamp(1.2rem, 2.8vw, 2.4rem);
|
||||
z-index: 2;
|
||||
display: grid;
|
||||
gap: 0.42rem;
|
||||
max-inline-size: min(22rem, 42vw);
|
||||
padding: 0.9rem 1rem 1rem;
|
||||
border: 1px solid rgb(94 231 255 / 0.24);
|
||||
border-radius: 0.7rem;
|
||||
background:
|
||||
linear-gradient(180deg, rgb(8 18 28 / 0.82), rgb(3 9 15 / 0.72)),
|
||||
radial-gradient(circle at 0 0, rgb(94 231 255 / 0.1), transparent 44%);
|
||||
box-shadow:
|
||||
inset 0 1px 0 rgb(255 255 255 / 0.06),
|
||||
0 0 28px rgb(94 231 255 / 0.08);
|
||||
backdrop-filter: blur(10px);
|
||||
}
|
||||
|
||||
.model-kicker,
|
||||
.model-path,
|
||||
.model-hint {
|
||||
margin: 0;
|
||||
color: rgb(198 226 239 / 0.72);
|
||||
font-size: 0.6rem;
|
||||
letter-spacing: 0.1em;
|
||||
text-transform: uppercase;
|
||||
line-height: 1.35;
|
||||
}
|
||||
|
||||
h2 {
|
||||
margin: 0;
|
||||
color: rgb(241 251 255 / 0.96);
|
||||
font-size: clamp(1.15rem, 1.1vw + 0.88rem, 1.72rem);
|
||||
line-height: 1.05;
|
||||
font-weight: 650;
|
||||
}
|
||||
|
||||
.model-status-row {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 0.44rem;
|
||||
color: rgb(229 249 255 / 0.94);
|
||||
font-size: 0.78rem;
|
||||
letter-spacing: 0.04em;
|
||||
}
|
||||
|
||||
.status-light {
|
||||
inline-size: 0.58rem;
|
||||
block-size: 0.58rem;
|
||||
border-radius: 50%;
|
||||
background: rgb(255 188 92 / 0.95);
|
||||
box-shadow: 0 0 0 2px rgb(255 188 92 / 0.16), 0 0 12px rgb(255 188 92 / 0.18);
|
||||
}
|
||||
|
||||
.status-light.is-ready {
|
||||
background: rgb(166 255 122 / 0.95);
|
||||
box-shadow: 0 0 0 2px rgb(166 255 122 / 0.16), 0 0 14px rgb(166 255 122 / 0.22);
|
||||
}
|
||||
|
||||
.model-path {
|
||||
color: rgb(94 231 255 / 0.78);
|
||||
text-transform: none;
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.model-hint {
|
||||
color: rgb(198 226 239 / 0.66);
|
||||
text-transform: none;
|
||||
letter-spacing: 0.04em;
|
||||
}
|
||||
|
||||
@media (max-width: 960px) {
|
||||
.model-hud {
|
||||
max-inline-size: min(20rem, calc(100% - 2.4rem));
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -306,6 +306,10 @@
|
||||
return typeof window !== "undefined" && "__TAURI_INTERNALS__" in window;
|
||||
}
|
||||
|
||||
function serialProtocolForStage(mode: StageViewMode = stageViewMode): "tactileA" | "handGateway" {
|
||||
return mode === "model3d" ? "handGateway" : "tactileA";
|
||||
}
|
||||
|
||||
function clearDevkitSpatialForce(): void {
|
||||
devkitSpatialForce = null;
|
||||
if (devkitSpatialForceClearTimer != null && typeof window !== "undefined") {
|
||||
@@ -1445,7 +1449,10 @@
|
||||
connectionNotice = "";
|
||||
|
||||
try {
|
||||
const result = await invoke<SerialConnectResult>("serial_connect", { port: event.detail });
|
||||
const result = await invoke<SerialConnectResult>("serial_connect", {
|
||||
port: event.detail,
|
||||
protocol: serialProtocolForStage()
|
||||
});
|
||||
connectionState = result.connected ? "online" : "offline";
|
||||
serialPortValue = result.port;
|
||||
connectionNotice = "";
|
||||
@@ -1800,17 +1807,48 @@
|
||||
matrixDisplayMode = event.detail ? "dots" : "numeric";
|
||||
}
|
||||
|
||||
function handleStageModeChange(event: CustomEvent<StageViewMode>): void {
|
||||
async function handleStageModeChange(event: CustomEvent<StageViewMode>): Promise<void> {
|
||||
const previousMode = stageViewMode;
|
||||
stageViewMode = event.detail;
|
||||
if (stageViewMode === "model3d") {
|
||||
isPrecisionTestOpen = false;
|
||||
isConfigPanelOpen = false;
|
||||
}
|
||||
|
||||
if (
|
||||
previousMode === stageViewMode ||
|
||||
connectionState !== "online" ||
|
||||
!serialPortValue ||
|
||||
!isTauriRuntime()
|
||||
) {
|
||||
return;
|
||||
}
|
||||
|
||||
connectionState = "connecting";
|
||||
connectionNotice = "";
|
||||
try {
|
||||
await invoke<SerialConnectResult>("serial_disconnect");
|
||||
const result = await invoke<SerialConnectResult>("serial_connect", {
|
||||
port: serialPortValue,
|
||||
protocol: serialProtocolForStage(stageViewMode)
|
||||
});
|
||||
connectionState = result.connected ? "online" : "offline";
|
||||
serialPortValue = result.port;
|
||||
clearHudPanels();
|
||||
console.info(`[serial] switched protocol to ${serialProtocolForStage(stageViewMode)}`);
|
||||
} catch (error) {
|
||||
connectionState = "offline";
|
||||
connectionNotice = resolveSerialNotice(error, "connect");
|
||||
connectionNoticeTone = "warn";
|
||||
clearHudPanels();
|
||||
console.error("Serial protocol switch failed:", error);
|
||||
}
|
||||
}
|
||||
|
||||
onMount(() => {
|
||||
let disposed = false;
|
||||
let unlistenHudStream: UnlistenFn | null = null;
|
||||
let unlistenHandGatewayRaw: UnlistenFn | null = null;
|
||||
let unlistenDevkitPztAngle: UnlistenFn | null = null;
|
||||
let stopMockFeed: (() => void) | null = null;
|
||||
|
||||
@@ -1835,6 +1873,23 @@
|
||||
.catch((error) => {
|
||||
console.error("Failed to listen for hud_stream:", error);
|
||||
});
|
||||
void listen<number[]>("hand_gateway_raw", (event) => {
|
||||
const rawHex = event.payload
|
||||
.map((byte) => byte.toString(16).padStart(2, "0").toUpperCase())
|
||||
.join(" ");
|
||||
console.info(`[hand_gateway][raw] ${rawHex}`);
|
||||
})
|
||||
.then((unlisten) => {
|
||||
if (disposed) {
|
||||
unlisten();
|
||||
return;
|
||||
}
|
||||
|
||||
unlistenHandGatewayRaw = unlisten;
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error("Failed to listen for hand_gateway_raw:", error);
|
||||
});
|
||||
void listen<DevKitPztAngleEvent>("devkit_pzt_angle", (event) => {
|
||||
const angleDeg = Number(event.payload.angle);
|
||||
if (!Number.isFinite(angleDeg)) {
|
||||
@@ -1875,6 +1930,7 @@
|
||||
clearDevkitSpatialForce();
|
||||
stopMockFeed?.();
|
||||
unlistenHudStream?.();
|
||||
unlistenHandGatewayRaw?.();
|
||||
unlistenDevkitPztAngle?.();
|
||||
if (devkitStatusTimer != null) {
|
||||
window.clearInterval(devkitStatusTimer);
|
||||
|
||||
BIN
static/models/je-skin-model.bin
Normal file
BIN
static/models/je-skin-model.bin
Normal file
Binary file not shown.
Binary file not shown.
1
static/models/je-skin-model.gltf
Normal file
1
static/models/je-skin-model.gltf
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user