
14 changed files with 105139 additions and 0 deletions
@ -0,0 +1 @@ |
|||
builld/ |
@ -0,0 +1,6 @@ |
|||
[submodule "libs/libDaisy"] |
|||
path = libs/libDaisy |
|||
url = https://github.com/electro-smith/libDaisy |
|||
[submodule "libs/DaisySP"] |
|||
path = libs/DaisySP |
|||
url = https://github.com/electro-smith/DaisySP |
File diff suppressed because it is too large
@ -0,0 +1,42 @@ |
|||
{ |
|||
"configurations": [ |
|||
{ |
|||
"name": "Win32", |
|||
// Edit to match your development environment if necessary |
|||
"compilerPath": "C:/Program Files/DaisyToolchain/bin/arm-none-eabi-gcc.exe", |
|||
"includePath": [ |
|||
"${workspaceFolder}/Blink/**", |
|||
"${workspaceFolder}/NewProject/**", |
|||
"${workspaceFolder}/libs/libDaisy//**", |
|||
"${workspaceFolder}/libs/DaisySP//**" |
|||
], |
|||
"intelliSenseMode": "gcc-x64", |
|||
"cStandard": "c11", |
|||
"cppStandard": "c++17", |
|||
"defines": [ |
|||
"DEBUG=1", |
|||
"STM32H750xx" |
|||
], |
|||
"windowsSdkVersion": "10.0.17763.0" |
|||
}, |
|||
{ |
|||
"name": "Mac", |
|||
// Edit to match your development environment if necessary |
|||
"compilerPath": "/usr/bin/arm-none-eabi-gcc", |
|||
"includePath": [ |
|||
"${workspaceFolder}/Blink/**", |
|||
"${workspaceFolder}/NewProject/**", |
|||
"${workspaceFolder}/libs/libDaisy//**", |
|||
"${workspaceFolder}/libs/DaisySP//**" |
|||
], |
|||
"intelliSenseMode": "gcc-x64", |
|||
"cStandard": "c11", |
|||
"cppStandard": "c++17", |
|||
"defines": [ |
|||
"DEBUG=1", |
|||
"STM32H750xx" |
|||
] |
|||
} |
|||
], |
|||
"version": 4 |
|||
} |
@ -0,0 +1,69 @@ |
|||
{ |
|||
"configurations": [ |
|||
{ |
|||
"configFiles": [ |
|||
"interface/stlink.cfg", |
|||
"target/stm32h7x.cfg" |
|||
], |
|||
"cwd": "${workspaceFolder}", |
|||
"debuggerArgs": [ |
|||
"-d", |
|||
"${workspaceRoot}" |
|||
], |
|||
// Here's where you can put the path to the program you want to debug: |
|||
"executable": "${workspaceRoot}/Blink/build/Blink.elf", |
|||
"interface": "swd", |
|||
"name": "Debug Blink", |
|||
"openOCDLaunchCommands": [ |
|||
"init", |
|||
"reset init", |
|||
"gdb_breakpoint_override hard" |
|||
], |
|||
"preLaunchTask": "Build Blink", |
|||
"preRestartCommands": [ |
|||
"load", |
|||
"enable breakpoint", |
|||
"monitor reset" |
|||
], |
|||
"request": "launch", |
|||
"runToMain": true, |
|||
"servertype": "openocd", |
|||
"showDevDebugOutput": true, |
|||
"svdFile": "${workspaceRoot}/.vscode/STM32H750x.svd", |
|||
"type": "cortex-debug" |
|||
}, |
|||
{ |
|||
"configFiles": [ |
|||
"interface/stlink.cfg", |
|||
"target/stm32h7x.cfg" |
|||
], |
|||
"cwd": "${workspaceFolder}", |
|||
"debuggerArgs": [ |
|||
"-d", |
|||
"${workspaceRoot}" |
|||
], |
|||
// Here's where you can put the path to the program you want to debug: |
|||
"executable": "${workspaceRoot}/NewProject/build/NewProject.elf", |
|||
"interface": "swd", |
|||
"name": "Debug NewProject", |
|||
"openOCDLaunchCommands": [ |
|||
"init", |
|||
"reset init", |
|||
"gdb_breakpoint_override hard" |
|||
], |
|||
"preLaunchTask": "Build Blink", |
|||
"preRestartCommands": [ |
|||
"load", |
|||
"enable breakpoint", |
|||
"monitor reset" |
|||
], |
|||
"request": "launch", |
|||
"runToMain": true, |
|||
"servertype": "openocd", |
|||
"showDevDebugOutput": true, |
|||
"svdFile": "${workspaceRoot}/.vscode/STM32H750x.svd", |
|||
"type": "cortex-debug" |
|||
} |
|||
], |
|||
"version": "0.2.0" |
|||
} |
@ -0,0 +1,70 @@ |
|||
{ |
|||
"tasks": [ |
|||
{ |
|||
"label": "Build Libraries", |
|||
"command": "./ci/build_libs.sh", |
|||
"options": { |
|||
"cwd": "${workspaceFolder}" |
|||
}, |
|||
"problemMatcher": [], |
|||
"type": "shell" |
|||
}, |
|||
{ |
|||
"label": "Build Blink", |
|||
"command": "make", |
|||
"options": { |
|||
"cwd": "${workspaceFolder}/Blink" |
|||
}, |
|||
"problemMatcher": [], |
|||
"type": "shell" |
|||
}, |
|||
{ |
|||
"label": "Build NewProject", |
|||
"command": "make", |
|||
"options": { |
|||
"cwd": "${workspaceFolder}/NewProject" |
|||
}, |
|||
"problemMatcher": [], |
|||
"type": "shell" |
|||
}, |
|||
{ |
|||
"label": "Build", |
|||
"dependsOn": [ |
|||
"Build Blink", |
|||
"Build NewProject" |
|||
], |
|||
"problemMatcher": [], |
|||
"group": { |
|||
"kind": "build", |
|||
"isDefault": true |
|||
} |
|||
}, |
|||
{ |
|||
"label": "Clean Blink", |
|||
"command": "make clean", |
|||
"options": { |
|||
"cwd": "${workspaceFolder}/Blink" |
|||
}, |
|||
"problemMatcher": [], |
|||
"type": "shell" |
|||
}, |
|||
{ |
|||
"label": "Clean NewProject", |
|||
"command": "make clean", |
|||
"options": { |
|||
"cwd": "${workspaceFolder}/NewProject" |
|||
}, |
|||
"problemMatcher": [], |
|||
"type": "shell" |
|||
}, |
|||
{ |
|||
"label": "Clean", |
|||
"dependsOn": [ |
|||
"Clean Blink", |
|||
"Clean NewProject" |
|||
], |
|||
"problemMatcher": [], |
|||
} |
|||
], |
|||
"version": "2.0.0" |
|||
} |
@ -0,0 +1,22 @@ |
|||
# Project Name
|
|||
TARGET = Blink |
|||
|
|||
# Configure for debugging
|
|||
# common configurations:
|
|||
# use DEBUG = 1 and OPT = -Og for debugging
|
|||
# or DEBUG = 0 and OPT = -O3 for performance
|
|||
DEBUG = 0 |
|||
OPT = -O3 |
|||
|
|||
# Sources
|
|||
CPP_SOURCES = main.cpp |
|||
|
|||
LIBDAISY_DIR = ../libs/libDaisy |
|||
DAISYSP_DIR = ../libs/DaisySP |
|||
|
|||
# (optional) Includes FatFS source files within project.
|
|||
#USE_FATFS = 1
|
|||
|
|||
# Core location, and generic Makefile.
|
|||
SYSTEM_FILES_DIR = $(LIBDAISY_DIR)/core |
|||
include $(SYSTEM_FILES_DIR)/Makefile |
@ -0,0 +1,22 @@ |
|||
/** Basic Daisy Blink Example
|
|||
* |
|||
* This example blinks toggles the state of an LED every half a second. |
|||
*/ |
|||
#include "daisy_seed.h" |
|||
|
|||
using namespace daisy; |
|||
|
|||
DaisySeed hw; |
|||
|
|||
int main() { |
|||
hw.Init(); |
|||
bool led_state = false; |
|||
while (1) { |
|||
/** Set the USR LED to the current state */ |
|||
hw.SetLed(led_state); |
|||
/** Toggle the state from true/false, or vice versa */ |
|||
led_state = !led_state; |
|||
/** Delay for the specified number of milliseconds */ |
|||
System::Delay(500); |
|||
} |
|||
} |
@ -0,0 +1,22 @@ |
|||
# Project Name
|
|||
TARGET = Blink |
|||
|
|||
# Configure for debugging
|
|||
# common configurations:
|
|||
# use DEBUG = 1 and OPT = -Og for debugging
|
|||
# or DEBUG = 0 and OPT = -O3 for performance
|
|||
DEBUG = 0 |
|||
OPT = -O3 |
|||
|
|||
# Sources
|
|||
CPP_SOURCES = main.cpp |
|||
|
|||
LIBDAISY_DIR = ../libs/libDaisy |
|||
DAISYSP_DIR = ../libs/DaisySP |
|||
|
|||
# (optional) Includes FatFS source files within project.
|
|||
#USE_FATFS = 1
|
|||
|
|||
# Core location, and generic Makefile.
|
|||
SYSTEM_FILES_DIR = $(LIBDAISY_DIR)/core |
|||
include $(SYSTEM_FILES_DIR)/Makefile |
@ -0,0 +1,15 @@ |
|||
/** Basic Daisy Program
|
|||
* |
|||
* This file is a blank starting point for a new project. |
|||
*/ |
|||
#include "daisy_seed.h" |
|||
|
|||
using namespace daisy; |
|||
|
|||
DaisySeed hw; |
|||
|
|||
int main() { |
|||
hw.Init(); |
|||
while (1) { |
|||
} |
|||
} |
@ -1,2 +1,10 @@ |
|||
# DaisyBlinkProject |
|||
|
|||
Basic Blink Project with all required libraries, etc. |
|||
|
|||
Includes: |
|||
|
|||
* libDaisy - hardware library for Daisy |
|||
* DaisySP - DSP library |
|||
* Blink - Basic example demonstrating a blink |
|||
* NewProject - an empty project, perfect for following along with the Guided Tutorial. |
|||
|
@ -0,0 +1,24 @@ |
|||
#!/bin/bash |
|||
|
|||
START_DIR=$PWD |
|||
LIBDAISY_DIR=$PWD/libs/libDaisy |
|||
DAISYSP_DIR=$PWD/libs/DaisySP |
|||
|
|||
echo "building libDaisy . . ." |
|||
cd "$LIBDAISY_DIR" ; make -s clean ; make -j -s |
|||
if [ $? -ne 0 ] |
|||
then |
|||
echo "Failed to compile libDaisy" |
|||
exit 1 |
|||
fi |
|||
echo "done." |
|||
|
|||
echo "building DaisySP . . ." |
|||
cd "$DAISYSP_DIR" ; make -s clean ; make -j -s |
|||
if [ $? -ne 0 ] |
|||
then |
|||
echo "Failed to compile DaisySP" |
|||
exit 1 |
|||
fi |
|||
echo "done." |
|||
|
Loading…
Reference in new issue