Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(Examples): Add Action Recognition Demo for MAX78000 and Known Answer Test for MAX78002 #851

Merged
merged 14 commits into from
Jan 23, 2024
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project>
<configuration id="cdt.managedbuild.toolchain.gnu.cross.base.1028364529" name="Default">
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
<provider class="org.eclipse.cdt.managedbuilder.language.settings.providers.GCCBuildCommandParser" id="org.eclipse.cdt.managedbuilder.core.GCCBuildCommandParser" keep-relative-paths="false" name="CDT GCC Build Output Parser" parameter="${PREFIX}(g?cc)|([gc]\+\+)|(clang)" prefer-non-shared="true"/>
<provider class="org.eclipse.cdt.internal.build.crossgcc.CrossGCCBuiltinSpecsDetector" console="true" env-hash="-99955491804503126" id="org.eclipse.cdt.build.crossgcc.CrossGCCBuiltinSpecsDetector" keep-relative-paths="false" name="CDT Cross GCC Built-in Compiler Settings" parameter="${GCC_PREFIX}gcc ${FLAGS} -E -P -v -dD &quot;${INPUTS}&quot; -DMXC_ASSERT_ENABLE -DARM_MATH_CM4" prefer-non-shared="true">
<language-scope id="org.eclipse.cdt.core.gcc"/>
<language-scope id="org.eclipse.cdt.core.g++"/>
</provider>
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
</extension>
</configuration>
</project>

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
eclipse.preferences.version=1
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/BOARD/delimiter=;
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/BOARD/operation=append
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/BOARD/value=FTHR_RevA
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/GCC_PREFIX/delimiter=;
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/GCC_PREFIX/operation=replace
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/GCC_PREFIX/value=arm-none-eabi-
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/PROJECT/delimiter=;
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/PROJECT/operation=append
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/PROJECT/value=KineticsFullTCN120
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/TARGET/delimiter=;
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/TARGET/operation=append
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/TARGET/value=MAX78000
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/append=true
environment/project/cdt.managedbuild.toolchain.gnu.cross.base.1028364529/appendContributed=true
548 changes: 548 additions & 0 deletions Examples/MAX78000/CNN/actionrecognition-demo/.vscode/README.md

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"configurations": [
{
"name": "Win32",
"includePath": [
"${default}"
],
"defines": [
"${default}"
],
"intelliSenseMode": "gcc-arm",
"compilerPath": "${config:ARM_GCC_path}/bin/arm-none-eabi-gcc.exe",
"browse": {
"path": [
"${default}"
]
}
},
{
"name": "Linux",
"includePath": [
"${default}"
],
"defines": [
"${default}"
],
"intelliSenseMode": "gcc-arm",
"compilerPath": "${config:ARM_GCC_path}/bin/arm-none-eabi-gcc",
"browse": {
"path": [
"${default}"
]
}
},
{
"name": "Mac",
"includePath": [
"${default}"
],
"defines": [
"${default}"
],
"intelliSenseMode": "gcc-arm",
"compilerPath": "${config:ARM_GCC_path}/bin/arm-none-eabi-gcc",
"browse": {
"path": [
"${default}"
]
}
}
],
"version": 4
}
15 changes: 15 additions & 0 deletions Examples/MAX78000/CNN/actionrecognition-demo/.vscode/flash.gdb
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
define flash_m4
set architecture armv7e-m
target remote | openocd -c "gdb_port pipe;log_output flash.log" -s $arg0/scripts -f interface/$arg1 -f target/$arg2 -c "init; reset halt"
load
compare-sections
monitor reset halt
end

define flash_m4_run
set architecture armv7e-m
target remote | openocd -c "gdb_port pipe;log_output flash.log" -s $arg0/scripts -f interface/$arg1 -f target/$arg2 -c "init; reset halt"
load
compare-sections
monitor resume
end
104 changes: 104 additions & 0 deletions Examples/MAX78000/CNN/actionrecognition-demo/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
{
"configurations": [
{
"name": "GDB (Arm M4)",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/build/${config:program_file}",
"args": [],
"stopAtEntry": true,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"linux": {
"miDebuggerPath": "${config:ARM_GCC_path}/bin/arm-none-eabi-gdb",
"debugServerPath": "${config:OCD_path}/openocd",
},
"windows": {
"miDebuggerPath": "${config:ARM_GCC_path}/bin/arm-none-eabi-gdb.exe",
"debugServerPath": "${config:OCD_path}/openocd.exe",
},
"osx": {
"miDebuggerPath": "${config:ARM_GCC_path}/bin/arm-none-eabi-gdb",
"debugServerPath": "${config:OCD_path}/bin/openocd",
},
"logging": {
"exceptions": true,
"trace": false,
"traceResponse": false,
"engineLogging": false
},
"miDebuggerServerAddress": "localhost:3333",
"debugServerArgs": "-s ${config:OCD_path}/scripts -f interface/${config:M4_OCD_interface_file} -f target/${config:M4_OCD_target_file} -c \"init; reset halt\"",
"serverStarted": "Info : Listening on port 3333 for gdb connections",
"filterStderr": true,
"targetArchitecture": "arm",
"customLaunchSetupCommands": [
{"text":"-list-features"}
],
"setupCommands": [
{ "text":"set logging overwrite on"},
{ "text":"set logging file debug-arm.log"},
{ "text":"set logging on"},
{ "text":"cd ${workspaceFolder}" },
{ "text":"exec-file build/${config:program_file}" },
{ "text":"symbol-file build/${config:symbol_file}" },
{ "text":"target remote localhost:3333" },
{ "text":"monitor reset halt" },
{ "text":"set $pc=Reset_Handler"},
{ "text":"b main" }
]
},
{
"name": "GDB (RISC-V)",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/buildrv/${config:program_file}",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"linux": {
"miDebuggerPath": "${config:xPack_GCC_path}/bin/riscv-none-embed-gdb",
"debugServerPath": "${config:OCD_path}/openocd",
},
"windows": {
"miDebuggerPath": "${config:xPack_GCC_path}/bin/riscv-none-embed-gdb.exe",
"debugServerPath": "${config:OCD_path}/openocd.exe",
},
"osx": {
"miDebuggerPath": "${config:xPack_GCC_path}/bin/riscv-none-embed-gdb",
"debugServerPath": "${config:OCD_path}/bin/openocd",
},
"logging": {
"exceptions": true,
"trace": false,
"traceResponse": false,
"engineLogging": false
},
"miDebuggerServerAddress": "localhost:3334",
"debugServerArgs": "-c \"gdb_port 3334\" -s ${config:OCD_path}/scripts -f interface/${config:RV_OCD_interface_file} -f target/${config:RV_OCD_target_file}",
"serverStarted": "Info : Listening on port 3334 for gdb connections",
"filterStderr": true,
"customLaunchSetupCommands": [
{"text":"-list-features"}
],
"targetArchitecture": "arm",
"setupCommands": [
{ "text":"set logging overwrite on"},
{ "text":"set logging file debug-riscv.log"},
{ "text":"set logging on"},
{ "text":"cd ${workspaceFolder}" },
{ "text": "set architecture riscv:rv32", "ignoreFailures": false },
{ "text":"exec-file build/${config:program_file}", "ignoreFailures": false },
{ "text":"symbol-file buildrv/${config:symbol_file}", "ignoreFailures": false },
{ "text":"target remote localhost:3334" },
{ "text":"b main" },
{ "text": "set $pc=Reset_Handler","ignoreFailures": false }
]
}
]
}
73 changes: 73 additions & 0 deletions Examples/MAX78000/CNN/actionrecognition-demo/.vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"terminal.integrated.env.windows": {
"Path":"${config:OCD_path};${config:ARM_GCC_path}/bin;${config:xPack_GCC_path}/bin;${config:Make_path};${env:PATH}",
"MAXIM_PATH":"${config:MAXIM_PATH}"
},
"terminal.integrated.defaultProfile.windows": "Command Prompt",

"terminal.integrated.env.linux": {
"PATH":"${config:OCD_path}:${config:ARM_GCC_path}/bin:${config:xPack_GCC_path}/bin:${env:PATH}",
"MAXIM_PATH":"${config:MAXIM_PATH}"
},
"terminal.integrated.env.osx": {
"PATH":"${config:OCD_path}/bin:${config:ARM_GCC_path}/bin:${config:xPack_GCC_path}/bin:${env:PATH}",
"MAXIM_PATH":"${config:MAXIM_PATH}"
},

"target":"MAX78000",
"board":"FTHR_RevA",

"project_name":"${workspaceFolderBasename}",

"program_file":"${config:project_name}.elf",
"symbol_file":"${config:program_file}",

"M4_OCD_interface_file":"cmsis-dap.cfg",
"M4_OCD_target_file":"${config:target}.cfg",
"RV_OCD_interface_file":"ftdi/olimex-arm-usb-ocd-h.cfg",
"RV_OCD_target_file":"${config:target}_riscv.cfg",

"v_Arm_GCC":"10.3",
"v_xPack_GCC":"10.2.0-1.2",

"OCD_path":"${config:MAXIM_PATH}/Tools/OpenOCD",
"ARM_GCC_path":"${config:MAXIM_PATH}/Tools/GNUTools/${config:v_Arm_GCC}",
"xPack_GCC_path":"${config:MAXIM_PATH}/Tools/xPack/riscv-none-embed-gcc/${config:v_xPack_GCC}",
"Make_path":"${config:MAXIM_PATH}/Tools/MSYS2/usr/bin",

"C_Cpp.default.includePath": [
"${workspaceFolder}",
"${workspaceFolder}/**",
"${config:MAXIM_PATH}/Libraries/Boards/${config:target}/Include",
"${config:MAXIM_PATH}/Libraries/Boards/${config:target}/${config:board}/Include",
"${config:MAXIM_PATH}/Libraries/CMSIS/Device/Maxim/${config:target}/Include",
"${config:MAXIM_PATH}/Libraries/CMSIS/Include",
"${config:ARM_GCC_path}/arm-none-eabi/include",
"${config:ARM_GCC_path}/lib/gcc/arm-none-eabi/${config:v_Arm_GCC}/include",
"${config:MAXIM_PATH}/Libraries/PeriphDrivers/Include/${config:target}",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/Camera",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/Display",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/ExtMemory",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/LED",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/PMIC",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/PushButton",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/Touchscreen"
],
"C_Cpp.default.browse.path": [
"${workspaceFolder}",
"${config:MAXIM_PATH}/Libraries/Boards/${config:target}/Source",
"${config:MAXIM_PATH}/Libraries/Boards/${config:target}/${config:board}/Source",
"${config:MAXIM_PATH}/Libraries/PeriphDrivers/Source",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/Camera",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/Display",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/LED",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/PMIC",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/PushButton",
"${config:MAXIM_PATH}/Libraries/MiscDrivers/Touchscreen",
"${config:MAXIM_PATH}/Libraries/MiscDrivers"
],
"C_Cpp.default.defines": [
"${config:board}"
]
}

106 changes: 106 additions & 0 deletions Examples/MAX78000/CNN/actionrecognition-demo/.vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "build",
"type": "shell",
"command": "make -r -j 8 TARGET=${config:target} BOARD=${config:board} MAXIM_PATH=${config:MAXIM_PATH} MAKE=make PROJECT=${config:project_name}",
"group": "build",
"problemMatcher": []
},
{
"label": "clean",
"type": "shell",
"command": "make -j 8 clean TARGET=${config:target} BOARD=${config:board} MAXIM_PATH=${config:MAXIM_PATH} MAKE=make PROJECT=${config:project_name}",
"group": "build",
"problemMatcher": []
},
{
"label": "clean-periph",
"type": "shell",
"command": "make -j 8 distclean TARGET=${config:target} BOARD=${config:board} MAXIM_PATH=${config:MAXIM_PATH} MAKE=make PROJECT=${config:project_name}",
"group": "build",
"problemMatcher": []
},
{
"label": "flash",
"type": "shell",
"command": "arm-none-eabi-gdb",
"args": [
"--cd=\"${workspaceFolder}\"",
"--se=\"build/${config:program_file}\"",
"--symbols=build/${config:symbol_file}",
"-x=\"${workspaceFolder}/.vscode/flash.gdb\"",
"--ex=\"flash_m4 ${config:OCD_path} ${config:M4_OCD_interface_file} ${config:M4_OCD_target_file}\"",
"--batch"
],
"group": "build",
"problemMatcher": [],
"dependsOn":["build"]
},
{
"label": "flash & run",
"type": "shell",
"command": "arm-none-eabi-gdb",
"args": [
"--cd=\"${workspaceFolder}\"",
"--se=\"build/${config:program_file}\"",
"--symbols=build/${config:symbol_file}",
"-x=\"${workspaceFolder}/.vscode/flash.gdb\"",
"--ex=\"flash_m4_run ${config:OCD_path} ${config:M4_OCD_interface_file} ${config:M4_OCD_target_file}\"",
"--batch"
],
"group": "build",
"problemMatcher": [],
"dependsOn":["build"]
},
{
"label": "erase flash",
"type": "shell",
"command": "openocd",
"args": [
"-s", "${config:OCD_path}/scripts",
"-f", "interface/${config:M4_OCD_interface_file}",
"-f", "target/${config:M4_OCD_target_file}",
"-c", "\"init; reset halt; max32xxx mass_erase 0;\"",
"-c", "exit"
],
"group":"build",
"problemMatcher": [],
"dependsOn":[]
},
{
"label": "openocd (m4)",
"type": "shell",
"command": "openocd",
"args": [
"-s",
"${config:OCD_path}/scripts",
"-f",
"interface/${config:M4_OCD_interface_file}",
"-f",
"target/${config:M4_OCD_target_file}",
"-c",
"\"init; reset halt\""
],
"problemMatcher": [],
"dependsOn":[]
},
{
"label": "gdb (m4)",
"type": "shell",
"command": "arm-none-eabi-gdb",
"args": [
"--ex=\"cd ${workspaceFolder}\"",
"--se=\"build/${config:program_file}\"",
"--symbols=build/${config:symbol_file}",
"--ex=\"target remote localhost:3333\"",
"--ex=\"monitor reset halt\"",
"--ex=\"b main\"",
"--ex=\"c\""
],
"problemMatcher": [],
"dependsOn":[]
},
]
}
Loading