From 1b60e7bc827c5f1b03dad882f6bc431a2b6da7a6 Mon Sep 17 00:00:00 2001 From: TheSlowGrowth <9356320+TheSlowGrowth@users.noreply.github.com> Date: Tue, 19 Jul 2022 17:58:51 +0200 Subject: [PATCH 1/3] Add .editorconfig file with libDaisy settings --- .editorconfig | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000..52709647f --- /dev/null +++ b/.editorconfig @@ -0,0 +1,25 @@ +# EditorConfig auto-configures your text editor to +# use repository-enforced formatting settings. +# EditorConfig is awesome: https://EditorConfig.org + +# top-most EditorConfig file +root = true + +# Unix-style newlines with a newline ending for +# some non-code files +[{CHANGELOG.md,README.md,examples/README.md}] +charset = utf-8 +end_of_line = lf +insert_final_newline = true + +# Unix-style newlines with a newline ending +# and 4 space indentation on C / C++ files in +# - tests (non-recursively) +# - src (recursively) +# - examples (recursively) +[{tests/*,src/**,examples/**}.{c,cpp,c++,h,hpp,h++,ipp,i++}] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +indent_style = space +indent_size = 4 From 637654f7957334663661b64a5d573f10a0e989bd Mon Sep 17 00:00:00 2001 From: TheSlowGrowth <9356320+TheSlowGrowth@users.noreply.github.com> Date: Tue, 19 Jul 2022 17:59:08 +0200 Subject: [PATCH 2/3] Add VSCode editorconfig extension to recommended extensions --- .vscode/extensions.json | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 108f9380e..42d814279 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,8 +1,9 @@ { "recommendations": [ "ms-vscode.cpptools", - "xaver.clang-format", + "xaver.clang-format", "davidschuldenfrei.gtest-adapter", - "vadimcn.vscode-lldb" - ] -} \ No newline at end of file + "vadimcn.vscode-lldb", + "EditorConfig.EditorConfig" + ] +} From c5d223c2ebcc5e8bbc92e0a2a3015a138a0b720b Mon Sep 17 00:00:00 2001 From: TheSlowGrowth <9356320+TheSlowGrowth@users.noreply.github.com> Date: Tue, 19 Jul 2022 18:29:28 +0200 Subject: [PATCH 3/3] formatting: Apply .editorconfig to all files --- CHANGELOG.md | 8 +- Makefile | 14 +- README.md | 2 +- core/Makefile | 8 +- core/STM32H750IB_flash.lds | 2 +- core/STM32H750IB_qspi.lds | 2 +- core/STM32H750IB_sram.lds | 2 +- core/startup_stm32h750xx.c | 598 ++++++------- core/startup_stm32h750xx.s | 846 +++++++++--------- examples/CopyingWavs/CopyingWavs.cpp | 6 +- examples/README.md | 2 +- .../SpiBlockingTransmit.cpp | 6 +- .../SPI/SpiDmaTransmit/SpiDmaTransmit.cpp | 6 +- .../TIM_SingleCallback/TIM_SingleCallback.cpp | 10 +- .../Blocking_Transmit_Fifo_Receive.cpp | 2 +- .../Dma_Fifo_Receive/Dma_Fifo_Receive.cpp | 4 +- src/daisy_core.h | 48 +- src/daisy_field.cpp | 2 +- src/daisy_field.h | 4 +- src/daisy_legio.cpp | 2 +- src/daisy_legio.h | 6 +- src/daisy_patch.h | 4 +- src/daisy_patch_sm.cpp | 4 +- src/daisy_patch_sm.h | 74 +- src/daisy_pod.h | 2 +- src/daisy_seed.h | 16 +- src/daisy_versio.h | 4 +- src/dev/apds9960.h | 12 +- src/dev/codec_ak4556.h | 12 +- src/dev/codec_pcm3060.h | 12 +- src/dev/codec_wm8731.h | 22 +- src/dev/dps310.h | 10 +- src/dev/flash_IS25LP064A.h | 6 +- src/dev/flash_IS25LP080D.h | 6 +- src/dev/icm20948.h | 6 +- src/dev/lcd_hd44780.cpp | 2 +- src/dev/lcd_hd44780.h | 12 +- src/dev/leddriver.h | 18 +- src/dev/max11300.h | 98 +- src/dev/mcp23x17.h | 40 +- src/dev/mpr121.h | 4 +- src/dev/neopixel.h | 8 +- src/dev/neotrellis.h | 12 +- src/dev/oled_ssd130x.h | 24 +- src/dev/sdram.cpp | 4 +- src/dev/sdram.h | 6 +- src/dev/sr_4021.h | 16 +- src/dev/sr_595.h | 6 +- src/dev/tlv493d.h | 4 +- src/hid/MidiEvent.h | 6 +- src/hid/audio.h | 26 +- src/hid/ctrl.cpp | 2 +- src/hid/ctrl.h | 16 +- src/hid/disp/display.h | 34 +- src/hid/disp/graphics_common.h | 2 +- src/hid/disp/oled_display.h | 10 +- src/hid/encoder.h | 4 +- src/hid/gatein.cpp | 2 +- src/hid/gatein.h | 6 +- src/hid/led.h | 8 +- src/hid/logger.cpp | 2 +- src/hid/logger.h | 18 +- src/hid/logger_impl.h | 4 +- src/hid/midi.h | 14 +- src/hid/parameter.cpp | 2 +- src/hid/parameter.h | 2 +- src/hid/rgb_led.h | 2 +- src/hid/switch.h | 8 +- src/hid/usb.h | 4 +- src/hid/usb_host.cpp | 2 +- src/hid/usb_host.h | 30 +- src/hid/usb_midi.cpp | 4 +- src/hid/usb_midi.h | 4 +- src/hid/wavplayer.h | 4 +- src/per/adc.h | 20 +- src/per/dac.cpp | 2 +- src/per/dac.h | 24 +- src/per/gpio.h | 58 +- src/per/i2c.h | 44 +- src/per/qspi.cpp | 8 +- src/per/qspi.h | 52 +- src/per/rng.cpp | 2 +- src/per/rng.h | 30 +- src/per/sai.h | 28 +- src/per/sdmmc.cpp | 8 +- src/per/sdmmc.h | 10 +- src/per/spi.h | 18 +- src/per/spiMultislave.cpp | 2 +- src/per/spiMultislave.h | 18 +- src/per/tim.cpp | 2 +- src/per/tim.h | 48 +- src/per/uart.h | 18 +- src/sys/dma.h | 12 +- src/sys/fatfs.h | 30 +- src/sys/ffconf.h | 26 +- src/sys/system.cpp | 12 +- src/sys/system.h | 44 +- src/ui/AbstractMenu.cpp | 2 +- src/ui/AbstractMenu.h | 56 +- src/ui/ButtonMonitor.h | 8 +- src/ui/FullScreenItemMenu.cpp | 2 +- src/ui/FullScreenItemMenu.h | 28 +- src/ui/PotMonitor.h | 8 +- src/ui/UI.cpp | 2 +- src/ui/UI.h | 60 +- src/ui/UiEventQueue.h | 8 +- src/usbd/usbd_conf.c | 18 +- src/usbd/usbd_conf.h | 2 +- src/usbd/usbd_desc.c | 8 +- src/util/CpuLoadMeter.h | 6 +- src/util/FIFO.h | 4 +- src/util/FixedCapStr.h | 4 +- src/util/MappedValue.cpp | 2 +- src/util/MappedValue.h | 12 +- src/util/PersistentStorage.h | 24 +- src/util/Stack.h | 2 +- src/util/VoctCalibration.h | 28 +- src/util/WavWriter.h | 18 +- src/util/WaveTableLoader.h | 14 +- src/util/bsp_sd_diskio.c | 12 +- src/util/bsp_sd_diskio.h | 4 +- src/util/color.h | 4 +- src/util/hal_map.h | 4 +- src/util/oled_fonts.h | 4 +- src/util/ringbuffer.h | 10 +- src/util/unique_id.h | 2 +- src/util/wav_format.h | 2 +- tests/AbstractMenu_gtest.cpp | 6 +- tests/CpuLoadMeter_gtest.cpp | 2 +- tests/FIFO_gtest.cpp | 2 +- tests/FixedCapStr_gtest.cpp | 2 +- tests/MAX11300_gtest.cpp | 18 +- tests/Makefile | 4 +- tests/MappedValue_gtest.cpp | 2 +- tests/Midi_gtest.cpp | 2 +- tests/PersistentStorage_gtest.cpp | 2 +- tests/Rectangle_gtest.cpp | 2 +- tests/Stack_gtest.cpp | 12 +- tests/TestIsolator.h | 12 +- tests/VoctCalibration_gtest.cpp | 4 +- tests/gtest-all.cpp | 2 +- tests/gtest_main.cpp | 2 +- 142 files changed, 1594 insertions(+), 1594 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c1b33d0fe..45afc4958 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,7 @@ * bootloader: Working with the bootloader has been simplified. See [the new guide for updates on usage](https://electro-smith.github.io/libDaisy/md_doc_md__a7__getting__started__daisy__bootloader.html) * usb: `USBHost` class has added support for user callbacks on device connection, disconnection, and when the MSC class becomes active. * uart: Adds DMA RX and TX modes, similar to how they work on the I2C and SPI. -* uart: Update function names to be more in line with the new DMA / Blocking scheme. +* uart: Update function names to be more in line with the new DMA / Blocking scheme. * The old methods are wrappers for the new ones to preserve backwards compatibility, but **will be removed in a future version**. * Affected functions: `PollReceive`, `PollTx`, `StartRx`, `RxActive`, `FlushRx`, `PopRx`, `Readable` @@ -59,7 +59,7 @@ * testing: debugging configuration now uses `lldb` debugging extension to support unit test debugging on macOS with Apple Silicon * driver: oled_ssd130x.h - Add the SpiHandle:Config struct to SSD130x4WireTransport:Config to allow full access to the SPI peripheral configuration. * hid: fixed issue in `AnalogControl` where computed coeff could be out of range with certain block sizes -* driver: added missing alternate function pin mappings for SPI2, and UART for pins available on the patch_sm hardware +* driver: added missing alternate function pin mappings for SPI2, and UART for pins available on the patch_sm hardware * usb: fixed issue with MIDI output from USB * driver: fixed off-by-one error in qspi erase function. @@ -208,7 +208,7 @@ max11300driver.ConfigurePinAsAnalogWrite(daisy::MAX11300::PIN_1, daisy::MAX11300 ### Other -* switch: Use `System::GetNow()` rather than the update rate to calculate `TimeHeldMs()`. +* switch: Use `System::GetNow()` rather than the update rate to calculate `TimeHeldMs()`. * This has also been applied to the `Encoder` class (since it uses `Switch` internally). * usb host: ST Middleware for USB Host support has been added to the Middlewares folder * fatfs: changed default `FS_LOCK` to 0, allowing for more simultaneously open FIL objects. @@ -402,7 +402,7 @@ sdram.Init(); ### Other -* test: add unit testing for midi parser. +* test: add unit testing for midi parser. * tests: add tests for `FIFO` * docs: Update TODO comment in `uart.h` to reflect most recent uart update. * ci: add filters to the workflows diff --git a/Makefile b/Makefile index 812d0bcc6..8d18dc214 100644 --- a/Makefile +++ b/Makefile @@ -85,7 +85,7 @@ BUILD_DIR = build # manually adding necessary HAL files # generated by dump_filepath.py -C_SOURCES = +C_SOURCES = C_SOURCES += \ Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_hal.c \ Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_hal_adc.c \ @@ -197,7 +197,7 @@ Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_ll_swpmi.c \ Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_ll_tim.c \ Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_ll_usart.c \ Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_ll_usb.c \ -Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_ll_utils.c +Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_ll_utils.c # Middleware sources C_SOURCES += \ @@ -271,7 +271,7 @@ MCU = -mthumb $(FLOAT-ABI) $(FPU) $(CPU) # macros for gcc # AS defines -AS_DEFS = +AS_DEFS = # C defines C_DEFS = \ @@ -283,7 +283,7 @@ C_DEFS = \ -DHSE_VALUE=16000000 \ -DUSE_HAL_DRIVER \ -DUSE_FULL_LL_DRIVER \ --DDATA_IN_D2_SRAM +-DDATA_IN_D2_SRAM # ^ added for easy startup access @@ -302,7 +302,7 @@ C_INCLUDES = \ -IMiddlewares/ST/STM32_USB_Host_Library/Class/MSC/Inc \ -IMiddlewares/Third_Party/FatFs/src \ -I$(MODULE_DIR) \ --I. +-I. # suppressions for warnings introduced by HAL/FatFS WARNINGS += -Wall -Wno-attributes -Wno-strict-aliasing -Wno-maybe-uninitialized -Wno-missing-attributes -Wno-stringop-overflow #-Werror @@ -328,7 +328,7 @@ CFLAGS += \ CPPFLAGS = $(CFLAGS) $(CPP_WARNINGS) CPPFLAGS += \ -fno-exceptions \ --fno-rtti +-fno-rtti C_STANDARD = -std=gnu11 CPP_STANDARD += -std=gnu++14 @@ -369,7 +369,7 @@ $(BUILD_DIR)/$(TARGET).a: $(SORTED_OBJECTS) Makefile $(AR) -r $@ $(SORTED_OBJECTS) $(BUILD_DIR): - mkdir $@ + mkdir $@ ####################################### # clean up diff --git a/README.md b/README.md index 20fc6529b..87580737d 100644 --- a/README.md +++ b/README.md @@ -63,7 +63,7 @@ int main(void) midi.StartReceive(); hw.StartAdc(); hw.StartAudio(AudioCallback); - + for(;;) { midi.Listen(); diff --git a/core/Makefile b/core/Makefile index 0bc22fed7..00932da8f 100644 --- a/core/Makefile +++ b/core/Makefile @@ -47,7 +47,7 @@ SYSTEM_FILES_DIR ?= \ # source ###################################### -CPP_SOURCES ?= +CPP_SOURCES ?= C_SOURCES += \ $(SYSTEM_FILES_DIR)/startup_stm32h750xx.c @@ -68,13 +68,13 @@ PREFIX = arm-none-eabi- ifdef GCC_PATH CC = $(GCC_PATH)/$(PREFIX)gcc AS = $(GCC_PATH)/$(PREFIX)gcc -x assembler-with-cpp -CXX = $(GCC_PATH)/$(PREFIX)g++ +CXX = $(GCC_PATH)/$(PREFIX)g++ GDB = $(GCC_PATH)/$(PREFIX)gdb CP = $(GCC_PATH)/$(PREFIX)objcopy SZ = $(GCC_PATH)/$(PREFIX)size else CC = $(PREFIX)gcc -CXX = $(PREFIX)g++ +CXX = $(PREFIX)g++ GDB = $(PREFIX)gdb AS = $(PREFIX)gcc -x assembler-with-cpp CP = $(PREFIX)objcopy @@ -124,7 +124,7 @@ endif # AS includes AS_INCLUDES = -C_INCLUDES ?= +C_INCLUDES ?= C_INCLUDES += \ -I$(LIBDAISY_DIR) \ diff --git a/core/STM32H750IB_flash.lds b/core/STM32H750IB_flash.lds index ce2fe8fad..514cc2d00 100644 --- a/core/STM32H750IB_flash.lds +++ b/core/STM32H750IB_flash.lds @@ -122,7 +122,7 @@ SECTIONS PROVIDE(__bss_end__ = _ebss); } > SRAM - PROVIDE(end = .); + PROVIDE(end = .); .dtcmram_bss (NOLOAD) : { diff --git a/core/STM32H750IB_qspi.lds b/core/STM32H750IB_qspi.lds index fd48ed922..5d963f534 100644 --- a/core/STM32H750IB_qspi.lds +++ b/core/STM32H750IB_qspi.lds @@ -136,7 +136,7 @@ SECTIONS _ebss = .; PROVIDE(__bss_end__ = _ebss); - } > SRAM + } > SRAM .dtcmram_bss (NOLOAD) : { diff --git a/core/STM32H750IB_sram.lds b/core/STM32H750IB_sram.lds index f84f05df3..003f6bf84 100644 --- a/core/STM32H750IB_sram.lds +++ b/core/STM32H750IB_sram.lds @@ -135,7 +135,7 @@ SECTIONS _ebss = .; PROVIDE(__bss_end__ = _ebss); - } > DTCMRAM + } > DTCMRAM .dtcmram_bss (NOLOAD) : { diff --git a/core/startup_stm32h750xx.c b/core/startup_stm32h750xx.c index d51028089..5e6a638e0 100644 --- a/core/startup_stm32h750xx.c +++ b/core/startup_stm32h750xx.c @@ -11,1193 +11,1193 @@ void Reset_Handler(); void Default_Handler(); //#define DEBUG_DEFAULT_INTERRUPT_HANDLERS #ifdef DEBUG_DEFAULT_INTERRUPT_HANDLERS -void __attribute__ ((weak)) NMI_Handler() +void __attribute__ ((weak)) NMI_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void NMI_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HardFault_Handler() +void __attribute__ ((weak)) HardFault_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HardFault_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) MemManage_Handler() +void __attribute__ ((weak)) MemManage_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void MemManage_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BusFault_Handler() +void __attribute__ ((weak)) BusFault_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BusFault_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) UsageFault_Handler() +void __attribute__ ((weak)) UsageFault_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void UsageFault_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SVC_Handler() +void __attribute__ ((weak)) SVC_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SVC_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DebugMon_Handler() +void __attribute__ ((weak)) DebugMon_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DebugMon_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) PendSV_Handler() +void __attribute__ ((weak)) PendSV_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void PendSV_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SysTick_Handler() +void __attribute__ ((weak)) SysTick_Handler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SysTick_Handler(); asm("bkpt 255"); } -void __attribute__ ((weak)) WWDG_IRQHandler() +void __attribute__ ((weak)) WWDG_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void WWDG_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) PVD_AVD_IRQHandler() +void __attribute__ ((weak)) PVD_AVD_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void PVD_AVD_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TAMP_STAMP_IRQHandler() +void __attribute__ ((weak)) TAMP_STAMP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TAMP_STAMP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) RTC_WKUP_IRQHandler() +void __attribute__ ((weak)) RTC_WKUP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void RTC_WKUP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FLASH_IRQHandler() +void __attribute__ ((weak)) FLASH_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FLASH_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) RCC_IRQHandler() +void __attribute__ ((weak)) RCC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void RCC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI0_IRQHandler() +void __attribute__ ((weak)) EXTI0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI1_IRQHandler() +void __attribute__ ((weak)) EXTI1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI2_IRQHandler() +void __attribute__ ((weak)) EXTI2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI3_IRQHandler() +void __attribute__ ((weak)) EXTI3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI4_IRQHandler() +void __attribute__ ((weak)) EXTI4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream0_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream1_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream2_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream3_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream4_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream5_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream6_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream6_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream6_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) ADC_IRQHandler() +void __attribute__ ((weak)) ADC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void ADC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FDCAN1_IT0_IRQHandler() +void __attribute__ ((weak)) FDCAN1_IT0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FDCAN1_IT0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FDCAN2_IT0_IRQHandler() +void __attribute__ ((weak)) FDCAN2_IT0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FDCAN2_IT0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FDCAN1_IT1_IRQHandler() +void __attribute__ ((weak)) FDCAN1_IT1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FDCAN1_IT1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FDCAN2_IT1_IRQHandler() +void __attribute__ ((weak)) FDCAN2_IT1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FDCAN2_IT1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI9_5_IRQHandler() +void __attribute__ ((weak)) EXTI9_5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI9_5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM1_BRK_IRQHandler() +void __attribute__ ((weak)) TIM1_BRK_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM1_BRK_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM1_UP_IRQHandler() +void __attribute__ ((weak)) TIM1_UP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM1_UP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM1_TRG_COM_IRQHandler() +void __attribute__ ((weak)) TIM1_TRG_COM_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM1_TRG_COM_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM1_CC_IRQHandler() +void __attribute__ ((weak)) TIM1_CC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM1_CC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM2_IRQHandler() +void __attribute__ ((weak)) TIM2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM3_IRQHandler() +void __attribute__ ((weak)) TIM3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM4_IRQHandler() +void __attribute__ ((weak)) TIM4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C1_EV_IRQHandler() +void __attribute__ ((weak)) I2C1_EV_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C1_EV_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C1_ER_IRQHandler() +void __attribute__ ((weak)) I2C1_ER_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C1_ER_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C2_EV_IRQHandler() +void __attribute__ ((weak)) I2C2_EV_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C2_EV_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C2_ER_IRQHandler() +void __attribute__ ((weak)) I2C2_ER_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C2_ER_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPI1_IRQHandler() +void __attribute__ ((weak)) SPI1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPI1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPI2_IRQHandler() +void __attribute__ ((weak)) SPI2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPI2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) USART1_IRQHandler() +void __attribute__ ((weak)) USART1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void USART1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) USART2_IRQHandler() +void __attribute__ ((weak)) USART2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void USART2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) USART3_IRQHandler() +void __attribute__ ((weak)) USART3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void USART3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) EXTI15_10_IRQHandler() +void __attribute__ ((weak)) EXTI15_10_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void EXTI15_10_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) RTC_Alarm_IRQHandler() +void __attribute__ ((weak)) RTC_Alarm_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void RTC_Alarm_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM8_BRK_TIM12_IRQHandler() +void __attribute__ ((weak)) TIM8_BRK_TIM12_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM8_BRK_TIM12_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM8_UP_TIM13_IRQHandler() +void __attribute__ ((weak)) TIM8_UP_TIM13_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM8_UP_TIM13_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM8_TRG_COM_TIM14_IRQHandler() +void __attribute__ ((weak)) TIM8_TRG_COM_TIM14_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM8_TRG_COM_TIM14_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM8_CC_IRQHandler() +void __attribute__ ((weak)) TIM8_CC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM8_CC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA1_Stream7_IRQHandler() +void __attribute__ ((weak)) DMA1_Stream7_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA1_Stream7_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FMC_IRQHandler() +void __attribute__ ((weak)) FMC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FMC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SDMMC1_IRQHandler() +void __attribute__ ((weak)) SDMMC1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SDMMC1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM5_IRQHandler() +void __attribute__ ((weak)) TIM5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPI3_IRQHandler() +void __attribute__ ((weak)) SPI3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPI3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) UART4_IRQHandler() +void __attribute__ ((weak)) UART4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void UART4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) UART5_IRQHandler() +void __attribute__ ((weak)) UART5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void UART5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM6_DAC_IRQHandler() +void __attribute__ ((weak)) TIM6_DAC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM6_DAC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM7_IRQHandler() +void __attribute__ ((weak)) TIM7_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM7_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream0_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream1_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream2_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream3_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream4_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) ETH_IRQHandler() +void __attribute__ ((weak)) ETH_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void ETH_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) ETH_WKUP_IRQHandler() +void __attribute__ ((weak)) ETH_WKUP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void ETH_WKUP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FDCAN_CAL_IRQHandler() +void __attribute__ ((weak)) FDCAN_CAL_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FDCAN_CAL_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream5_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream6_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream6_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream6_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2_Stream7_IRQHandler() +void __attribute__ ((weak)) DMA2_Stream7_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2_Stream7_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) USART6_IRQHandler() +void __attribute__ ((weak)) USART6_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void USART6_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C3_EV_IRQHandler() +void __attribute__ ((weak)) I2C3_EV_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C3_EV_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C3_ER_IRQHandler() +void __attribute__ ((weak)) I2C3_ER_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C3_ER_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_HS_EP1_OUT_IRQHandler() +void __attribute__ ((weak)) OTG_HS_EP1_OUT_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_HS_EP1_OUT_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_HS_EP1_IN_IRQHandler() +void __attribute__ ((weak)) OTG_HS_EP1_IN_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_HS_EP1_IN_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_HS_WKUP_IRQHandler() +void __attribute__ ((weak)) OTG_HS_WKUP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_HS_WKUP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_HS_IRQHandler() +void __attribute__ ((weak)) OTG_HS_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_HS_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DCMI_IRQHandler() +void __attribute__ ((weak)) DCMI_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DCMI_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) CRYP_IRQHandler() +void __attribute__ ((weak)) CRYP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void CRYP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HASH_RNG_IRQHandler() +void __attribute__ ((weak)) HASH_RNG_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HASH_RNG_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) FPU_IRQHandler() +void __attribute__ ((weak)) FPU_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void FPU_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) UART7_IRQHandler() +void __attribute__ ((weak)) UART7_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void UART7_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) UART8_IRQHandler() +void __attribute__ ((weak)) UART8_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void UART8_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPI4_IRQHandler() +void __attribute__ ((weak)) SPI4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPI4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPI5_IRQHandler() +void __attribute__ ((weak)) SPI5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPI5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPI6_IRQHandler() +void __attribute__ ((weak)) SPI6_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPI6_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SAI1_IRQHandler() +void __attribute__ ((weak)) SAI1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SAI1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LTDC_IRQHandler() +void __attribute__ ((weak)) LTDC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LTDC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LTDC_ER_IRQHandler() +void __attribute__ ((weak)) LTDC_ER_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LTDC_ER_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMA2D_IRQHandler() +void __attribute__ ((weak)) DMA2D_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMA2D_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SAI2_IRQHandler() +void __attribute__ ((weak)) SAI2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SAI2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) QUADSPI_IRQHandler() +void __attribute__ ((weak)) QUADSPI_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void QUADSPI_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LPTIM1_IRQHandler() +void __attribute__ ((weak)) LPTIM1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LPTIM1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) CEC_IRQHandler() +void __attribute__ ((weak)) CEC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void CEC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C4_EV_IRQHandler() +void __attribute__ ((weak)) I2C4_EV_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C4_EV_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) I2C4_ER_IRQHandler() +void __attribute__ ((weak)) I2C4_ER_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void I2C4_ER_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SPDIF_RX_IRQHandler() +void __attribute__ ((weak)) SPDIF_RX_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SPDIF_RX_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_FS_EP1_OUT_IRQHandler() +void __attribute__ ((weak)) OTG_FS_EP1_OUT_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_FS_EP1_OUT_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_FS_EP1_IN_IRQHandler() +void __attribute__ ((weak)) OTG_FS_EP1_IN_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_FS_EP1_IN_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_FS_WKUP_IRQHandler() +void __attribute__ ((weak)) OTG_FS_WKUP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_FS_WKUP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) OTG_FS_IRQHandler() +void __attribute__ ((weak)) OTG_FS_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void OTG_FS_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMAMUX1_OVR_IRQHandler() +void __attribute__ ((weak)) DMAMUX1_OVR_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMAMUX1_OVR_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_Master_IRQHandler() +void __attribute__ ((weak)) HRTIM1_Master_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_Master_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_TIMA_IRQHandler() +void __attribute__ ((weak)) HRTIM1_TIMA_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_TIMA_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_TIMB_IRQHandler() +void __attribute__ ((weak)) HRTIM1_TIMB_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_TIMB_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_TIMC_IRQHandler() +void __attribute__ ((weak)) HRTIM1_TIMC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_TIMC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_TIMD_IRQHandler() +void __attribute__ ((weak)) HRTIM1_TIMD_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_TIMD_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_TIME_IRQHandler() +void __attribute__ ((weak)) HRTIM1_TIME_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_TIME_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HRTIM1_FLT_IRQHandler() +void __attribute__ ((weak)) HRTIM1_FLT_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HRTIM1_FLT_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DFSDM1_FLT0_IRQHandler() +void __attribute__ ((weak)) DFSDM1_FLT0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DFSDM1_FLT0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DFSDM1_FLT1_IRQHandler() +void __attribute__ ((weak)) DFSDM1_FLT1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DFSDM1_FLT1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DFSDM1_FLT2_IRQHandler() +void __attribute__ ((weak)) DFSDM1_FLT2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DFSDM1_FLT2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DFSDM1_FLT3_IRQHandler() +void __attribute__ ((weak)) DFSDM1_FLT3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DFSDM1_FLT3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SAI3_IRQHandler() +void __attribute__ ((weak)) SAI3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SAI3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SWPMI1_IRQHandler() +void __attribute__ ((weak)) SWPMI1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SWPMI1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM15_IRQHandler() +void __attribute__ ((weak)) TIM15_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM15_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM16_IRQHandler() +void __attribute__ ((weak)) TIM16_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM16_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) TIM17_IRQHandler() +void __attribute__ ((weak)) TIM17_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void TIM17_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) MDIOS_WKUP_IRQHandler() +void __attribute__ ((weak)) MDIOS_WKUP_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void MDIOS_WKUP_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) MDIOS_IRQHandler() +void __attribute__ ((weak)) MDIOS_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void MDIOS_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) JPEG_IRQHandler() +void __attribute__ ((weak)) JPEG_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void JPEG_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) MDMA_IRQHandler() +void __attribute__ ((weak)) MDMA_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void MDMA_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SDMMC2_IRQHandler() +void __attribute__ ((weak)) SDMMC2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SDMMC2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) HSEM1_IRQHandler() +void __attribute__ ((weak)) HSEM1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void HSEM1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) ADC3_IRQHandler() +void __attribute__ ((weak)) ADC3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void ADC3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) DMAMUX2_OVR_IRQHandler() +void __attribute__ ((weak)) DMAMUX2_OVR_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void DMAMUX2_OVR_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel0_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel0_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel0_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel1_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel2_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel3_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel4_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel5_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel6_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel6_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel6_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) BDMA_Channel7_IRQHandler() +void __attribute__ ((weak)) BDMA_Channel7_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void BDMA_Channel7_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) COMP1_IRQHandler() +void __attribute__ ((weak)) COMP1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void COMP1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LPTIM2_IRQHandler() +void __attribute__ ((weak)) LPTIM2_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LPTIM2_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LPTIM3_IRQHandler() +void __attribute__ ((weak)) LPTIM3_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LPTIM3_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LPTIM4_IRQHandler() +void __attribute__ ((weak)) LPTIM4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LPTIM4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LPTIM5_IRQHandler() +void __attribute__ ((weak)) LPTIM5_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LPTIM5_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) LPUART1_IRQHandler() +void __attribute__ ((weak)) LPUART1_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void LPUART1_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) CRS_IRQHandler() +void __attribute__ ((weak)) CRS_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void CRS_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) ECC_IRQHandler() +void __attribute__ ((weak)) ECC_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void ECC_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) SAI4_IRQHandler() +void __attribute__ ((weak)) SAI4_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void SAI4_IRQHandler(); asm("bkpt 255"); } -void __attribute__ ((weak)) WAKEUP_PIN_IRQHandler() +void __attribute__ ((weak)) WAKEUP_PIN_IRQHandler() { - //If you hit the breakpoint below, one of the interrupts was unhandled in your code. + //If you hit the breakpoint below, one of the interrupts was unhandled in your code. //Define the following function in your code to handle it: // extern "C" void WAKEUP_PIN_IRQHandler(); asm("bkpt 255"); @@ -1355,7 +1355,7 @@ void SAI4_IRQHandler() __attribute__ ((weak, alias ("Default_Hand void WAKEUP_PIN_IRQHandler() __attribute__ ((weak, alias ("Default_Handler"))); #endif -void * g_pfnVectors[0xa6] __attribute__ ((section (".isr_vector"), used)) = +void * g_pfnVectors[0xa6] __attribute__ ((section (".isr_vector"), used)) = { &_estack, &Reset_Handler, diff --git a/core/startup_stm32h750xx.s b/core/startup_stm32h750xx.s index 5020c2021..cb9c2e169 100644 --- a/core/startup_stm32h750xx.s +++ b/core/startup_stm32h750xx.s @@ -2,7 +2,7 @@ ****************************************************************************** * @file startup_stm32h750xx.s * @author MCD Application Team - * @brief STM32H750xx Devices vector table for GCC based toolchain. + * @brief STM32H750xx Devices vector table for GCC based toolchain. * This module performs: * - Set the initial SP * - Set the initial PC == Reset_Handler, @@ -24,7 +24,7 @@ * ****************************************************************************** */ - + .syntax unified .cpu cortex-m7 .fpu softvfp @@ -33,10 +33,10 @@ .global g_pfnVectors .global Default_Handler -/* start address for the initialization values of the .data section. +/* start address for the initialization values of the .data section. defined in linker script */ .word _sidata -/* start address for the .data section. defined in linker script */ +/* start address for the .data section. defined in linker script */ .word _sdata /* end address for the .data section. defined in linker script */ .word _edata @@ -50,7 +50,7 @@ defined in linker script */ * @brief This is the code that gets called when the processor first * starts execution following a reset event. Only the absolutely * necessary set is performed, after which the application - * supplied main() routine is called. + * supplied main() routine is called. * @param None * @retval : None */ @@ -58,10 +58,10 @@ defined in linker script */ .section .text.Reset_Handler .weak Reset_Handler .type Reset_Handler, %function -Reset_Handler: +Reset_Handler: ldr sp, =_estack /* set stack pointer */ -/* Copy the data segment initializers from flash to SRAM */ +/* Copy the data segment initializers from flash to SRAM */ movs r1, #0 b LoopCopyDataInit @@ -70,7 +70,7 @@ CopyDataInit: ldr r3, [r3, r1] str r3, [r0, r1] adds r1, r1, #4 - + LoopCopyDataInit: ldr r0, =_sdata ldr r3, =_edata @@ -79,31 +79,31 @@ LoopCopyDataInit: bcc CopyDataInit ldr r2, =_sbss b LoopFillZerobss -/* Zero fill the bss segment. */ +/* Zero fill the bss segment. */ FillZerobss: movs r3, #0 str r3, [r2], #4 - + LoopFillZerobss: ldr r3, = _ebss cmp r2, r3 bcc FillZerobss /* Call the clock system intitialization function.*/ - bl SystemInit + bl SystemInit /* Call static constructors */ bl __libc_init_array /* Call the application's entry point.*/ bl main - bx lr + bx lr .size Reset_Handler, .-Reset_Handler /** - * @brief This is the code that gets called when the processor receives an + * @brief This is the code that gets called when the processor receives an * unexpected interrupt. This simply enters an infinite loop, preserving * the system state for examination by a debugger. - * @param None - * @retval None + * @param None + * @retval None */ .section .text.Default_Handler,"ax",%progbits Default_Handler: @@ -115,13 +115,13 @@ Infinite_Loop: * The minimal vector table for a Cortex M. Note that the proper constructs * must be placed on this to ensure that it ends up at physical address * 0x0000.0000. -* +* *******************************************************************************/ .section .isr_vector,"a",%progbits .type g_pfnVectors, %object .size g_pfnVectors, .-g_pfnVectors - - + + g_pfnVectors: .word _estack .word Reset_Handler @@ -140,91 +140,91 @@ g_pfnVectors: .word 0 .word PendSV_Handler .word SysTick_Handler - + /* External Interrupts */ - .word WWDG_IRQHandler /* Window WatchDog */ - .word PVD_AVD_IRQHandler /* PVD/AVD through EXTI Line detection */ - .word TAMP_STAMP_IRQHandler /* Tamper and TimeStamps through the EXTI line */ - .word RTC_WKUP_IRQHandler /* RTC Wakeup through the EXTI line */ - .word FLASH_IRQHandler /* FLASH */ - .word RCC_IRQHandler /* RCC */ - .word EXTI0_IRQHandler /* EXTI Line0 */ - .word EXTI1_IRQHandler /* EXTI Line1 */ - .word EXTI2_IRQHandler /* EXTI Line2 */ - .word EXTI3_IRQHandler /* EXTI Line3 */ - .word EXTI4_IRQHandler /* EXTI Line4 */ - .word DMA1_Stream0_IRQHandler /* DMA1 Stream 0 */ - .word DMA1_Stream1_IRQHandler /* DMA1 Stream 1 */ - .word DMA1_Stream2_IRQHandler /* DMA1 Stream 2 */ - .word DMA1_Stream3_IRQHandler /* DMA1 Stream 3 */ - .word DMA1_Stream4_IRQHandler /* DMA1 Stream 4 */ - .word DMA1_Stream5_IRQHandler /* DMA1 Stream 5 */ - .word DMA1_Stream6_IRQHandler /* DMA1 Stream 6 */ - .word ADC_IRQHandler /* ADC1, ADC2 and ADC3s */ - .word FDCAN1_IT0_IRQHandler /* FDCAN1 interrupt line 0 */ - .word FDCAN2_IT0_IRQHandler /* FDCAN2 interrupt line 0 */ - .word FDCAN1_IT1_IRQHandler /* FDCAN1 interrupt line 1 */ - .word FDCAN2_IT1_IRQHandler /* FDCAN2 interrupt line 1 */ - .word EXTI9_5_IRQHandler /* External Line[9:5]s */ - .word TIM1_BRK_IRQHandler /* TIM1 Break interrupt */ - .word TIM1_UP_IRQHandler /* TIM1 Update interrupt */ + .word WWDG_IRQHandler /* Window WatchDog */ + .word PVD_AVD_IRQHandler /* PVD/AVD through EXTI Line detection */ + .word TAMP_STAMP_IRQHandler /* Tamper and TimeStamps through the EXTI line */ + .word RTC_WKUP_IRQHandler /* RTC Wakeup through the EXTI line */ + .word FLASH_IRQHandler /* FLASH */ + .word RCC_IRQHandler /* RCC */ + .word EXTI0_IRQHandler /* EXTI Line0 */ + .word EXTI1_IRQHandler /* EXTI Line1 */ + .word EXTI2_IRQHandler /* EXTI Line2 */ + .word EXTI3_IRQHandler /* EXTI Line3 */ + .word EXTI4_IRQHandler /* EXTI Line4 */ + .word DMA1_Stream0_IRQHandler /* DMA1 Stream 0 */ + .word DMA1_Stream1_IRQHandler /* DMA1 Stream 1 */ + .word DMA1_Stream2_IRQHandler /* DMA1 Stream 2 */ + .word DMA1_Stream3_IRQHandler /* DMA1 Stream 3 */ + .word DMA1_Stream4_IRQHandler /* DMA1 Stream 4 */ + .word DMA1_Stream5_IRQHandler /* DMA1 Stream 5 */ + .word DMA1_Stream6_IRQHandler /* DMA1 Stream 6 */ + .word ADC_IRQHandler /* ADC1, ADC2 and ADC3s */ + .word FDCAN1_IT0_IRQHandler /* FDCAN1 interrupt line 0 */ + .word FDCAN2_IT0_IRQHandler /* FDCAN2 interrupt line 0 */ + .word FDCAN1_IT1_IRQHandler /* FDCAN1 interrupt line 1 */ + .word FDCAN2_IT1_IRQHandler /* FDCAN2 interrupt line 1 */ + .word EXTI9_5_IRQHandler /* External Line[9:5]s */ + .word TIM1_BRK_IRQHandler /* TIM1 Break interrupt */ + .word TIM1_UP_IRQHandler /* TIM1 Update interrupt */ .word TIM1_TRG_COM_IRQHandler /* TIM1 Trigger and Commutation interrupt */ - .word TIM1_CC_IRQHandler /* TIM1 Capture Compare */ - .word TIM2_IRQHandler /* TIM2 */ - .word TIM3_IRQHandler /* TIM3 */ - .word TIM4_IRQHandler /* TIM4 */ - .word I2C1_EV_IRQHandler /* I2C1 Event */ - .word I2C1_ER_IRQHandler /* I2C1 Error */ - .word I2C2_EV_IRQHandler /* I2C2 Event */ - .word I2C2_ER_IRQHandler /* I2C2 Error */ - .word SPI1_IRQHandler /* SPI1 */ - .word SPI2_IRQHandler /* SPI2 */ - .word USART1_IRQHandler /* USART1 */ - .word USART2_IRQHandler /* USART2 */ - .word USART3_IRQHandler /* USART3 */ - .word EXTI15_10_IRQHandler /* External Line[15:10]s */ - .word RTC_Alarm_IRQHandler /* RTC Alarm (A and B) through EXTI Line */ - .word 0 /* Reserved */ - .word TIM8_BRK_TIM12_IRQHandler /* TIM8 Break and TIM12 */ - .word TIM8_UP_TIM13_IRQHandler /* TIM8 Update and TIM13 */ + .word TIM1_CC_IRQHandler /* TIM1 Capture Compare */ + .word TIM2_IRQHandler /* TIM2 */ + .word TIM3_IRQHandler /* TIM3 */ + .word TIM4_IRQHandler /* TIM4 */ + .word I2C1_EV_IRQHandler /* I2C1 Event */ + .word I2C1_ER_IRQHandler /* I2C1 Error */ + .word I2C2_EV_IRQHandler /* I2C2 Event */ + .word I2C2_ER_IRQHandler /* I2C2 Error */ + .word SPI1_IRQHandler /* SPI1 */ + .word SPI2_IRQHandler /* SPI2 */ + .word USART1_IRQHandler /* USART1 */ + .word USART2_IRQHandler /* USART2 */ + .word USART3_IRQHandler /* USART3 */ + .word EXTI15_10_IRQHandler /* External Line[15:10]s */ + .word RTC_Alarm_IRQHandler /* RTC Alarm (A and B) through EXTI Line */ + .word 0 /* Reserved */ + .word TIM8_BRK_TIM12_IRQHandler /* TIM8 Break and TIM12 */ + .word TIM8_UP_TIM13_IRQHandler /* TIM8 Update and TIM13 */ .word TIM8_TRG_COM_TIM14_IRQHandler /* TIM8 Trigger and Commutation and TIM14 */ - .word TIM8_CC_IRQHandler /* TIM8 Capture Compare */ - .word DMA1_Stream7_IRQHandler /* DMA1 Stream7 */ - .word FMC_IRQHandler /* FMC */ - .word SDMMC1_IRQHandler /* SDMMC1 */ - .word TIM5_IRQHandler /* TIM5 */ - .word SPI3_IRQHandler /* SPI3 */ - .word UART4_IRQHandler /* UART4 */ - .word UART5_IRQHandler /* UART5 */ - .word TIM6_DAC_IRQHandler /* TIM6 and DAC1&2 underrun errors */ + .word TIM8_CC_IRQHandler /* TIM8 Capture Compare */ + .word DMA1_Stream7_IRQHandler /* DMA1 Stream7 */ + .word FMC_IRQHandler /* FMC */ + .word SDMMC1_IRQHandler /* SDMMC1 */ + .word TIM5_IRQHandler /* TIM5 */ + .word SPI3_IRQHandler /* SPI3 */ + .word UART4_IRQHandler /* UART4 */ + .word UART5_IRQHandler /* UART5 */ + .word TIM6_DAC_IRQHandler /* TIM6 and DAC1&2 underrun errors */ .word TIM7_IRQHandler /* TIM7 */ - .word DMA2_Stream0_IRQHandler /* DMA2 Stream 0 */ - .word DMA2_Stream1_IRQHandler /* DMA2 Stream 1 */ - .word DMA2_Stream2_IRQHandler /* DMA2 Stream 2 */ - .word DMA2_Stream3_IRQHandler /* DMA2 Stream 3 */ - .word DMA2_Stream4_IRQHandler /* DMA2 Stream 4 */ - .word ETH_IRQHandler /* Ethernet */ - .word ETH_WKUP_IRQHandler /* Ethernet Wakeup through EXTI line */ - .word FDCAN_CAL_IRQHandler /* FDCAN calibration unit interrupt*/ - .word 0 /* Reserved */ - .word 0 /* Reserved */ - .word 0 /* Reserved */ - .word 0 /* Reserved */ - .word DMA2_Stream5_IRQHandler /* DMA2 Stream 5 */ - .word DMA2_Stream6_IRQHandler /* DMA2 Stream 6 */ - .word DMA2_Stream7_IRQHandler /* DMA2 Stream 7 */ - .word USART6_IRQHandler /* USART6 */ - .word I2C3_EV_IRQHandler /* I2C3 event */ - .word I2C3_ER_IRQHandler /* I2C3 error */ - .word OTG_HS_EP1_OUT_IRQHandler /* USB OTG HS End Point 1 Out */ - .word OTG_HS_EP1_IN_IRQHandler /* USB OTG HS End Point 1 In */ - .word OTG_HS_WKUP_IRQHandler /* USB OTG HS Wakeup through EXTI */ - .word OTG_HS_IRQHandler /* USB OTG HS */ - .word DCMI_IRQHandler /* DCMI */ - .word CRYP_IRQHandler /* Crypto */ + .word DMA2_Stream0_IRQHandler /* DMA2 Stream 0 */ + .word DMA2_Stream1_IRQHandler /* DMA2 Stream 1 */ + .word DMA2_Stream2_IRQHandler /* DMA2 Stream 2 */ + .word DMA2_Stream3_IRQHandler /* DMA2 Stream 3 */ + .word DMA2_Stream4_IRQHandler /* DMA2 Stream 4 */ + .word ETH_IRQHandler /* Ethernet */ + .word ETH_WKUP_IRQHandler /* Ethernet Wakeup through EXTI line */ + .word FDCAN_CAL_IRQHandler /* FDCAN calibration unit interrupt*/ + .word 0 /* Reserved */ + .word 0 /* Reserved */ + .word 0 /* Reserved */ + .word 0 /* Reserved */ + .word DMA2_Stream5_IRQHandler /* DMA2 Stream 5 */ + .word DMA2_Stream6_IRQHandler /* DMA2 Stream 6 */ + .word DMA2_Stream7_IRQHandler /* DMA2 Stream 7 */ + .word USART6_IRQHandler /* USART6 */ + .word I2C3_EV_IRQHandler /* I2C3 event */ + .word I2C3_ER_IRQHandler /* I2C3 error */ + .word OTG_HS_EP1_OUT_IRQHandler /* USB OTG HS End Point 1 Out */ + .word OTG_HS_EP1_IN_IRQHandler /* USB OTG HS End Point 1 In */ + .word OTG_HS_WKUP_IRQHandler /* USB OTG HS Wakeup through EXTI */ + .word OTG_HS_IRQHandler /* USB OTG HS */ + .word DCMI_IRQHandler /* DCMI */ + .word CRYP_IRQHandler /* Crypto */ .word HASH_RNG_IRQHandler /* Hash and Rng */ .word FPU_IRQHandler /* FPU */ - .word UART7_IRQHandler /* UART7 */ + .word UART7_IRQHandler /* UART7 */ .word UART8_IRQHandler /* UART8 */ .word SPI4_IRQHandler /* SPI4 */ .word SPI5_IRQHandler /* SPI5 */ @@ -239,76 +239,76 @@ g_pfnVectors: .word CEC_IRQHandler /* HDMI_CEC */ .word I2C4_EV_IRQHandler /* I2C4 Event */ .word I2C4_ER_IRQHandler /* I2C4 Error */ - .word SPDIF_RX_IRQHandler /* SPDIF_RX */ - .word OTG_FS_EP1_OUT_IRQHandler /* USB OTG FS End Point 1 Out */ - .word OTG_FS_EP1_IN_IRQHandler /* USB OTG FS End Point 1 In */ - .word OTG_FS_WKUP_IRQHandler /* USB OTG FS Wakeup through EXTI */ + .word SPDIF_RX_IRQHandler /* SPDIF_RX */ + .word OTG_FS_EP1_OUT_IRQHandler /* USB OTG FS End Point 1 Out */ + .word OTG_FS_EP1_IN_IRQHandler /* USB OTG FS End Point 1 In */ + .word OTG_FS_WKUP_IRQHandler /* USB OTG FS Wakeup through EXTI */ .word OTG_FS_IRQHandler /* USB OTG FS */ - .word DMAMUX1_OVR_IRQHandler /* DMAMUX1 Overrun interrupt */ + .word DMAMUX1_OVR_IRQHandler /* DMAMUX1 Overrun interrupt */ .word HRTIM1_Master_IRQHandler /* HRTIM Master Timer global Interrupt */ - .word HRTIM1_TIMA_IRQHandler /* HRTIM Timer A global Interrupt */ - .word HRTIM1_TIMB_IRQHandler /* HRTIM Timer B global Interrupt */ - .word HRTIM1_TIMC_IRQHandler /* HRTIM Timer C global Interrupt */ - .word HRTIM1_TIMD_IRQHandler /* HRTIM Timer D global Interrupt */ - .word HRTIM1_TIME_IRQHandler /* HRTIM Timer E global Interrupt */ - .word HRTIM1_FLT_IRQHandler /* HRTIM Fault global Interrupt */ + .word HRTIM1_TIMA_IRQHandler /* HRTIM Timer A global Interrupt */ + .word HRTIM1_TIMB_IRQHandler /* HRTIM Timer B global Interrupt */ + .word HRTIM1_TIMC_IRQHandler /* HRTIM Timer C global Interrupt */ + .word HRTIM1_TIMD_IRQHandler /* HRTIM Timer D global Interrupt */ + .word HRTIM1_TIME_IRQHandler /* HRTIM Timer E global Interrupt */ + .word HRTIM1_FLT_IRQHandler /* HRTIM Fault global Interrupt */ .word DFSDM1_FLT0_IRQHandler /* DFSDM Filter0 Interrupt */ - .word DFSDM1_FLT1_IRQHandler /* DFSDM Filter1 Interrupt */ - .word DFSDM1_FLT2_IRQHandler /* DFSDM Filter2 Interrupt */ - .word DFSDM1_FLT3_IRQHandler /* DFSDM Filter3 Interrupt */ - .word SAI3_IRQHandler /* SAI3 global Interrupt */ + .word DFSDM1_FLT1_IRQHandler /* DFSDM Filter1 Interrupt */ + .word DFSDM1_FLT2_IRQHandler /* DFSDM Filter2 Interrupt */ + .word DFSDM1_FLT3_IRQHandler /* DFSDM Filter3 Interrupt */ + .word SAI3_IRQHandler /* SAI3 global Interrupt */ .word SWPMI1_IRQHandler /* Serial Wire Interface 1 global interrupt */ - .word TIM15_IRQHandler /* TIM15 global Interrupt */ - .word TIM16_IRQHandler /* TIM16 global Interrupt */ - .word TIM17_IRQHandler /* TIM17 global Interrupt */ - .word MDIOS_WKUP_IRQHandler /* MDIOS Wakeup Interrupt */ - .word MDIOS_IRQHandler /* MDIOS global Interrupt */ - .word JPEG_IRQHandler /* JPEG global Interrupt */ - .word MDMA_IRQHandler /* MDMA global Interrupt */ - .word 0 /* Reserved */ - .word SDMMC2_IRQHandler /* SDMMC2 global Interrupt */ - .word HSEM1_IRQHandler /* HSEM1 global Interrupt */ - .word 0 /* Reserved */ - .word ADC3_IRQHandler /* ADC3 global Interrupt */ - .word DMAMUX2_OVR_IRQHandler /* DMAMUX Overrun interrupt */ + .word TIM15_IRQHandler /* TIM15 global Interrupt */ + .word TIM16_IRQHandler /* TIM16 global Interrupt */ + .word TIM17_IRQHandler /* TIM17 global Interrupt */ + .word MDIOS_WKUP_IRQHandler /* MDIOS Wakeup Interrupt */ + .word MDIOS_IRQHandler /* MDIOS global Interrupt */ + .word JPEG_IRQHandler /* JPEG global Interrupt */ + .word MDMA_IRQHandler /* MDMA global Interrupt */ + .word 0 /* Reserved */ + .word SDMMC2_IRQHandler /* SDMMC2 global Interrupt */ + .word HSEM1_IRQHandler /* HSEM1 global Interrupt */ + .word 0 /* Reserved */ + .word ADC3_IRQHandler /* ADC3 global Interrupt */ + .word DMAMUX2_OVR_IRQHandler /* DMAMUX Overrun interrupt */ .word BDMA_Channel0_IRQHandler /* BDMA Channel 0 global Interrupt */ - .word BDMA_Channel1_IRQHandler /* BDMA Channel 1 global Interrupt */ - .word BDMA_Channel2_IRQHandler /* BDMA Channel 2 global Interrupt */ - .word BDMA_Channel3_IRQHandler /* BDMA Channel 3 global Interrupt */ - .word BDMA_Channel4_IRQHandler /* BDMA Channel 4 global Interrupt */ - .word BDMA_Channel5_IRQHandler /* BDMA Channel 5 global Interrupt */ - .word BDMA_Channel6_IRQHandler /* BDMA Channel 6 global Interrupt */ - .word BDMA_Channel7_IRQHandler /* BDMA Channel 7 global Interrupt */ - .word COMP1_IRQHandler /* COMP1 global Interrupt */ - .word LPTIM2_IRQHandler /* LP TIM2 global interrupt */ - .word LPTIM3_IRQHandler /* LP TIM3 global interrupt */ - .word LPTIM4_IRQHandler /* LP TIM4 global interrupt */ - .word LPTIM5_IRQHandler /* LP TIM5 global interrupt */ - .word LPUART1_IRQHandler /* LP UART1 interrupt */ - .word 0 /* Reserved */ - .word CRS_IRQHandler /* Clock Recovery Global Interrupt */ - .word ECC_IRQHandler /* ECC diagnostic Global Interrupt */ - .word SAI4_IRQHandler /* SAI4 global interrupt */ - .word 0 /* Reserved */ - .word 0 /* Reserved */ + .word BDMA_Channel1_IRQHandler /* BDMA Channel 1 global Interrupt */ + .word BDMA_Channel2_IRQHandler /* BDMA Channel 2 global Interrupt */ + .word BDMA_Channel3_IRQHandler /* BDMA Channel 3 global Interrupt */ + .word BDMA_Channel4_IRQHandler /* BDMA Channel 4 global Interrupt */ + .word BDMA_Channel5_IRQHandler /* BDMA Channel 5 global Interrupt */ + .word BDMA_Channel6_IRQHandler /* BDMA Channel 6 global Interrupt */ + .word BDMA_Channel7_IRQHandler /* BDMA Channel 7 global Interrupt */ + .word COMP1_IRQHandler /* COMP1 global Interrupt */ + .word LPTIM2_IRQHandler /* LP TIM2 global interrupt */ + .word LPTIM3_IRQHandler /* LP TIM3 global interrupt */ + .word LPTIM4_IRQHandler /* LP TIM4 global interrupt */ + .word LPTIM5_IRQHandler /* LP TIM5 global interrupt */ + .word LPUART1_IRQHandler /* LP UART1 interrupt */ + .word 0 /* Reserved */ + .word CRS_IRQHandler /* Clock Recovery Global Interrupt */ + .word ECC_IRQHandler /* ECC diagnostic Global Interrupt */ + .word SAI4_IRQHandler /* SAI4 global interrupt */ + .word 0 /* Reserved */ + .word 0 /* Reserved */ .word WAKEUP_PIN_IRQHandler /* Interrupt for all 6 wake-up pins */ /******************************************************************************* * -* Provide weak aliases for each Exception handler to the Default_Handler. -* As they are weak aliases, any function with the same name will override +* Provide weak aliases for each Exception handler to the Default_Handler. +* As they are weak aliases, any function with the same name will override * this definition. -* +* *******************************************************************************/ .weak NMI_Handler .thumb_set NMI_Handler,Default_Handler - + .weak HardFault_Handler .thumb_set HardFault_Handler,Default_Handler - + .weak MemManage_Handler .thumb_set MemManage_Handler,Default_Handler - + .weak BusFault_Handler .thumb_set BusFault_Handler,Default_Handler @@ -325,427 +325,427 @@ g_pfnVectors: .thumb_set PendSV_Handler,Default_Handler .weak SysTick_Handler - .thumb_set SysTick_Handler,Default_Handler - - .weak WWDG_IRQHandler - .thumb_set WWDG_IRQHandler,Default_Handler - - .weak PVD_AVD_IRQHandler + .thumb_set SysTick_Handler,Default_Handler + + .weak WWDG_IRQHandler + .thumb_set WWDG_IRQHandler,Default_Handler + + .weak PVD_AVD_IRQHandler .thumb_set PVD_AVD_IRQHandler,Default_Handler - - .weak TAMP_STAMP_IRQHandler + + .weak TAMP_STAMP_IRQHandler .thumb_set TAMP_STAMP_IRQHandler,Default_Handler - - .weak RTC_WKUP_IRQHandler + + .weak RTC_WKUP_IRQHandler .thumb_set RTC_WKUP_IRQHandler,Default_Handler - - .weak FLASH_IRQHandler + + .weak FLASH_IRQHandler .thumb_set FLASH_IRQHandler,Default_Handler - - .weak RCC_IRQHandler + + .weak RCC_IRQHandler .thumb_set RCC_IRQHandler,Default_Handler - - .weak EXTI0_IRQHandler + + .weak EXTI0_IRQHandler .thumb_set EXTI0_IRQHandler,Default_Handler - - .weak EXTI1_IRQHandler + + .weak EXTI1_IRQHandler .thumb_set EXTI1_IRQHandler,Default_Handler - - .weak EXTI2_IRQHandler - .thumb_set EXTI2_IRQHandler,Default_Handler - - .weak EXTI3_IRQHandler + + .weak EXTI2_IRQHandler + .thumb_set EXTI2_IRQHandler,Default_Handler + + .weak EXTI3_IRQHandler .thumb_set EXTI3_IRQHandler,Default_Handler - - .weak EXTI4_IRQHandler + + .weak EXTI4_IRQHandler .thumb_set EXTI4_IRQHandler,Default_Handler - - .weak DMA1_Stream0_IRQHandler + + .weak DMA1_Stream0_IRQHandler .thumb_set DMA1_Stream0_IRQHandler,Default_Handler - - .weak DMA1_Stream1_IRQHandler + + .weak DMA1_Stream1_IRQHandler .thumb_set DMA1_Stream1_IRQHandler,Default_Handler - - .weak DMA1_Stream2_IRQHandler + + .weak DMA1_Stream2_IRQHandler .thumb_set DMA1_Stream2_IRQHandler,Default_Handler - - .weak DMA1_Stream3_IRQHandler - .thumb_set DMA1_Stream3_IRQHandler,Default_Handler - - .weak DMA1_Stream4_IRQHandler + + .weak DMA1_Stream3_IRQHandler + .thumb_set DMA1_Stream3_IRQHandler,Default_Handler + + .weak DMA1_Stream4_IRQHandler .thumb_set DMA1_Stream4_IRQHandler,Default_Handler - - .weak DMA1_Stream5_IRQHandler + + .weak DMA1_Stream5_IRQHandler .thumb_set DMA1_Stream5_IRQHandler,Default_Handler - - .weak DMA1_Stream6_IRQHandler + + .weak DMA1_Stream6_IRQHandler .thumb_set DMA1_Stream6_IRQHandler,Default_Handler - - .weak ADC_IRQHandler + + .weak ADC_IRQHandler .thumb_set ADC_IRQHandler,Default_Handler - - .weak FDCAN1_IT0_IRQHandler + + .weak FDCAN1_IT0_IRQHandler .thumb_set FDCAN1_IT0_IRQHandler,Default_Handler - - .weak FDCAN2_IT0_IRQHandler + + .weak FDCAN2_IT0_IRQHandler .thumb_set FDCAN2_IT0_IRQHandler,Default_Handler - - .weak FDCAN1_IT1_IRQHandler + + .weak FDCAN1_IT1_IRQHandler .thumb_set FDCAN1_IT1_IRQHandler,Default_Handler - - .weak FDCAN2_IT1_IRQHandler + + .weak FDCAN2_IT1_IRQHandler .thumb_set FDCAN2_IT1_IRQHandler,Default_Handler - - .weak EXTI9_5_IRQHandler + + .weak EXTI9_5_IRQHandler .thumb_set EXTI9_5_IRQHandler,Default_Handler - - .weak TIM1_BRK_IRQHandler + + .weak TIM1_BRK_IRQHandler .thumb_set TIM1_BRK_IRQHandler,Default_Handler - - .weak TIM1_UP_IRQHandler + + .weak TIM1_UP_IRQHandler .thumb_set TIM1_UP_IRQHandler,Default_Handler - .weak TIM1_TRG_COM_IRQHandler + .weak TIM1_TRG_COM_IRQHandler .thumb_set TIM1_TRG_COM_IRQHandler,Default_Handler - - .weak TIM1_CC_IRQHandler + + .weak TIM1_CC_IRQHandler .thumb_set TIM1_CC_IRQHandler,Default_Handler - - .weak TIM2_IRQHandler + + .weak TIM2_IRQHandler .thumb_set TIM2_IRQHandler,Default_Handler - - .weak TIM3_IRQHandler + + .weak TIM3_IRQHandler .thumb_set TIM3_IRQHandler,Default_Handler - - .weak TIM4_IRQHandler + + .weak TIM4_IRQHandler .thumb_set TIM4_IRQHandler,Default_Handler - - .weak I2C1_EV_IRQHandler + + .weak I2C1_EV_IRQHandler .thumb_set I2C1_EV_IRQHandler,Default_Handler - - .weak I2C1_ER_IRQHandler + + .weak I2C1_ER_IRQHandler .thumb_set I2C1_ER_IRQHandler,Default_Handler - - .weak I2C2_EV_IRQHandler + + .weak I2C2_EV_IRQHandler .thumb_set I2C2_EV_IRQHandler,Default_Handler - - .weak I2C2_ER_IRQHandler + + .weak I2C2_ER_IRQHandler .thumb_set I2C2_ER_IRQHandler,Default_Handler - - .weak SPI1_IRQHandler + + .weak SPI1_IRQHandler .thumb_set SPI1_IRQHandler,Default_Handler - - .weak SPI2_IRQHandler + + .weak SPI2_IRQHandler .thumb_set SPI2_IRQHandler,Default_Handler - - .weak USART1_IRQHandler + + .weak USART1_IRQHandler .thumb_set USART1_IRQHandler,Default_Handler - - .weak USART2_IRQHandler + + .weak USART2_IRQHandler .thumb_set USART2_IRQHandler,Default_Handler - - .weak USART3_IRQHandler + + .weak USART3_IRQHandler .thumb_set USART3_IRQHandler,Default_Handler - - .weak EXTI15_10_IRQHandler + + .weak EXTI15_10_IRQHandler .thumb_set EXTI15_10_IRQHandler,Default_Handler - - .weak RTC_Alarm_IRQHandler + + .weak RTC_Alarm_IRQHandler .thumb_set RTC_Alarm_IRQHandler,Default_Handler - - .weak TIM8_BRK_TIM12_IRQHandler + + .weak TIM8_BRK_TIM12_IRQHandler .thumb_set TIM8_BRK_TIM12_IRQHandler,Default_Handler - - .weak TIM8_UP_TIM13_IRQHandler + + .weak TIM8_UP_TIM13_IRQHandler .thumb_set TIM8_UP_TIM13_IRQHandler,Default_Handler - - .weak TIM8_TRG_COM_TIM14_IRQHandler + + .weak TIM8_TRG_COM_TIM14_IRQHandler .thumb_set TIM8_TRG_COM_TIM14_IRQHandler,Default_Handler - - .weak TIM8_CC_IRQHandler + + .weak TIM8_CC_IRQHandler .thumb_set TIM8_CC_IRQHandler,Default_Handler - - .weak DMA1_Stream7_IRQHandler + + .weak DMA1_Stream7_IRQHandler .thumb_set DMA1_Stream7_IRQHandler,Default_Handler - - .weak FMC_IRQHandler + + .weak FMC_IRQHandler .thumb_set FMC_IRQHandler,Default_Handler - - .weak SDMMC1_IRQHandler + + .weak SDMMC1_IRQHandler .thumb_set SDMMC1_IRQHandler,Default_Handler - - .weak TIM5_IRQHandler + + .weak TIM5_IRQHandler .thumb_set TIM5_IRQHandler,Default_Handler - - .weak SPI3_IRQHandler + + .weak SPI3_IRQHandler .thumb_set SPI3_IRQHandler,Default_Handler - - .weak UART4_IRQHandler + + .weak UART4_IRQHandler .thumb_set UART4_IRQHandler,Default_Handler - - .weak UART5_IRQHandler + + .weak UART5_IRQHandler .thumb_set UART5_IRQHandler,Default_Handler - - .weak TIM6_DAC_IRQHandler + + .weak TIM6_DAC_IRQHandler .thumb_set TIM6_DAC_IRQHandler,Default_Handler - - .weak TIM7_IRQHandler + + .weak TIM7_IRQHandler .thumb_set TIM7_IRQHandler,Default_Handler - - .weak DMA2_Stream0_IRQHandler + + .weak DMA2_Stream0_IRQHandler .thumb_set DMA2_Stream0_IRQHandler,Default_Handler - - .weak DMA2_Stream1_IRQHandler + + .weak DMA2_Stream1_IRQHandler .thumb_set DMA2_Stream1_IRQHandler,Default_Handler - - .weak DMA2_Stream2_IRQHandler + + .weak DMA2_Stream2_IRQHandler .thumb_set DMA2_Stream2_IRQHandler,Default_Handler - - .weak DMA2_Stream3_IRQHandler + + .weak DMA2_Stream3_IRQHandler .thumb_set DMA2_Stream3_IRQHandler,Default_Handler - - .weak DMA2_Stream4_IRQHandler + + .weak DMA2_Stream4_IRQHandler .thumb_set DMA2_Stream4_IRQHandler,Default_Handler - - .weak ETH_IRQHandler + + .weak ETH_IRQHandler .thumb_set ETH_IRQHandler,Default_Handler - - .weak ETH_WKUP_IRQHandler + + .weak ETH_WKUP_IRQHandler .thumb_set ETH_WKUP_IRQHandler,Default_Handler - .weak FDCAN_CAL_IRQHandler - .thumb_set FDCAN_CAL_IRQHandler,Default_Handler - - .weak DMA2_Stream5_IRQHandler + .weak FDCAN_CAL_IRQHandler + .thumb_set FDCAN_CAL_IRQHandler,Default_Handler + + .weak DMA2_Stream5_IRQHandler .thumb_set DMA2_Stream5_IRQHandler,Default_Handler - - .weak DMA2_Stream6_IRQHandler + + .weak DMA2_Stream6_IRQHandler .thumb_set DMA2_Stream6_IRQHandler,Default_Handler - - .weak DMA2_Stream7_IRQHandler + + .weak DMA2_Stream7_IRQHandler .thumb_set DMA2_Stream7_IRQHandler,Default_Handler - - .weak USART6_IRQHandler + + .weak USART6_IRQHandler .thumb_set USART6_IRQHandler,Default_Handler - - .weak I2C3_EV_IRQHandler + + .weak I2C3_EV_IRQHandler .thumb_set I2C3_EV_IRQHandler,Default_Handler - - .weak I2C3_ER_IRQHandler + + .weak I2C3_ER_IRQHandler .thumb_set I2C3_ER_IRQHandler,Default_Handler - - .weak OTG_HS_EP1_OUT_IRQHandler + + .weak OTG_HS_EP1_OUT_IRQHandler .thumb_set OTG_HS_EP1_OUT_IRQHandler,Default_Handler - - .weak OTG_HS_EP1_IN_IRQHandler + + .weak OTG_HS_EP1_IN_IRQHandler .thumb_set OTG_HS_EP1_IN_IRQHandler,Default_Handler - - .weak OTG_HS_WKUP_IRQHandler + + .weak OTG_HS_WKUP_IRQHandler .thumb_set OTG_HS_WKUP_IRQHandler,Default_Handler - - .weak OTG_HS_IRQHandler + + .weak OTG_HS_IRQHandler .thumb_set OTG_HS_IRQHandler,Default_Handler - - .weak DCMI_IRQHandler + + .weak DCMI_IRQHandler .thumb_set DCMI_IRQHandler,Default_Handler - .weak CRYP_IRQHandler + .weak CRYP_IRQHandler .thumb_set CRYP_IRQHandler,Default_Handler - .weak HASH_RNG_IRQHandler - .thumb_set HASH_RNG_IRQHandler,Default_Handler + .weak HASH_RNG_IRQHandler + .thumb_set HASH_RNG_IRQHandler,Default_Handler - .weak FPU_IRQHandler + .weak FPU_IRQHandler .thumb_set FPU_IRQHandler,Default_Handler - .weak UART7_IRQHandler + .weak UART7_IRQHandler .thumb_set UART7_IRQHandler,Default_Handler - .weak UART8_IRQHandler - .thumb_set UART8_IRQHandler,Default_Handler + .weak UART8_IRQHandler + .thumb_set UART8_IRQHandler,Default_Handler - .weak SPI4_IRQHandler + .weak SPI4_IRQHandler .thumb_set SPI4_IRQHandler,Default_Handler - - .weak SPI5_IRQHandler + + .weak SPI5_IRQHandler .thumb_set SPI5_IRQHandler,Default_Handler - .weak SPI6_IRQHandler - .thumb_set SPI6_IRQHandler,Default_Handler + .weak SPI6_IRQHandler + .thumb_set SPI6_IRQHandler,Default_Handler - .weak SAI1_IRQHandler + .weak SAI1_IRQHandler .thumb_set SAI1_IRQHandler,Default_Handler - - .weak LTDC_IRQHandler + + .weak LTDC_IRQHandler .thumb_set LTDC_IRQHandler,Default_Handler - .weak LTDC_ER_IRQHandler + .weak LTDC_ER_IRQHandler .thumb_set LTDC_ER_IRQHandler,Default_Handler - .weak DMA2D_IRQHandler - .thumb_set DMA2D_IRQHandler,Default_Handler + .weak DMA2D_IRQHandler + .thumb_set DMA2D_IRQHandler,Default_Handler - .weak SAI2_IRQHandler + .weak SAI2_IRQHandler .thumb_set SAI2_IRQHandler,Default_Handler - - .weak QUADSPI_IRQHandler + + .weak QUADSPI_IRQHandler .thumb_set QUADSPI_IRQHandler,Default_Handler - - .weak LPTIM1_IRQHandler + + .weak LPTIM1_IRQHandler .thumb_set LPTIM1_IRQHandler,Default_Handler - .weak CEC_IRQHandler + .weak CEC_IRQHandler .thumb_set CEC_IRQHandler,Default_Handler - - .weak I2C4_EV_IRQHandler - .thumb_set I2C4_EV_IRQHandler,Default_Handler - - .weak I2C4_ER_IRQHandler + + .weak I2C4_EV_IRQHandler + .thumb_set I2C4_EV_IRQHandler,Default_Handler + + .weak I2C4_ER_IRQHandler .thumb_set I2C4_ER_IRQHandler,Default_Handler - - .weak SPDIF_RX_IRQHandler + + .weak SPDIF_RX_IRQHandler .thumb_set SPDIF_RX_IRQHandler,Default_Handler - .weak OTG_FS_EP1_OUT_IRQHandler + .weak OTG_FS_EP1_OUT_IRQHandler .thumb_set OTG_FS_EP1_OUT_IRQHandler,Default_Handler - - .weak OTG_FS_EP1_IN_IRQHandler - .thumb_set OTG_FS_EP1_IN_IRQHandler,Default_Handler - .weak OTG_FS_WKUP_IRQHandler + .weak OTG_FS_EP1_IN_IRQHandler + .thumb_set OTG_FS_EP1_IN_IRQHandler,Default_Handler + + .weak OTG_FS_WKUP_IRQHandler .thumb_set OTG_FS_WKUP_IRQHandler,Default_Handler - .weak OTG_FS_IRQHandler + .weak OTG_FS_IRQHandler .thumb_set OTG_FS_IRQHandler,Default_Handler - - .weak DMAMUX1_OVR_IRQHandler + + .weak DMAMUX1_OVR_IRQHandler .thumb_set DMAMUX1_OVR_IRQHandler,Default_Handler - .weak HRTIM1_Master_IRQHandler + .weak HRTIM1_Master_IRQHandler .thumb_set HRTIM1_Master_IRQHandler,Default_Handler - - .weak HRTIM1_TIMA_IRQHandler + + .weak HRTIM1_TIMA_IRQHandler .thumb_set HRTIM1_TIMA_IRQHandler,Default_Handler - .weak HRTIM1_TIMB_IRQHandler - .thumb_set HRTIM1_TIMB_IRQHandler,Default_Handler + .weak HRTIM1_TIMB_IRQHandler + .thumb_set HRTIM1_TIMB_IRQHandler,Default_Handler - .weak HRTIM1_TIMC_IRQHandler - .thumb_set HRTIM1_TIMC_IRQHandler,Default_Handler + .weak HRTIM1_TIMC_IRQHandler + .thumb_set HRTIM1_TIMC_IRQHandler,Default_Handler - .weak HRTIM1_TIMD_IRQHandler - .thumb_set HRTIM1_TIMD_IRQHandler,Default_Handler + .weak HRTIM1_TIMD_IRQHandler + .thumb_set HRTIM1_TIMD_IRQHandler,Default_Handler - .weak HRTIM1_TIME_IRQHandler - .thumb_set HRTIM1_TIME_IRQHandler,Default_Handler + .weak HRTIM1_TIME_IRQHandler + .thumb_set HRTIM1_TIME_IRQHandler,Default_Handler - .weak HRTIM1_FLT_IRQHandler + .weak HRTIM1_FLT_IRQHandler .thumb_set HRTIM1_FLT_IRQHandler,Default_Handler - .weak DFSDM1_FLT0_IRQHandler - .thumb_set DFSDM1_FLT0_IRQHandler,Default_Handler + .weak DFSDM1_FLT0_IRQHandler + .thumb_set DFSDM1_FLT0_IRQHandler,Default_Handler + + .weak DFSDM1_FLT1_IRQHandler + .thumb_set DFSDM1_FLT1_IRQHandler,Default_Handler - .weak DFSDM1_FLT1_IRQHandler - .thumb_set DFSDM1_FLT1_IRQHandler,Default_Handler + .weak DFSDM1_FLT2_IRQHandler + .thumb_set DFSDM1_FLT2_IRQHandler,Default_Handler - .weak DFSDM1_FLT2_IRQHandler - .thumb_set DFSDM1_FLT2_IRQHandler,Default_Handler + .weak DFSDM1_FLT3_IRQHandler + .thumb_set DFSDM1_FLT3_IRQHandler,Default_Handler - .weak DFSDM1_FLT3_IRQHandler - .thumb_set DFSDM1_FLT3_IRQHandler,Default_Handler - - .weak SAI3_IRQHandler + .weak SAI3_IRQHandler .thumb_set SAI3_IRQHandler,Default_Handler - - .weak SWPMI1_IRQHandler + + .weak SWPMI1_IRQHandler .thumb_set SWPMI1_IRQHandler,Default_Handler - .weak TIM15_IRQHandler - .thumb_set TIM15_IRQHandler,Default_Handler + .weak TIM15_IRQHandler + .thumb_set TIM15_IRQHandler,Default_Handler - .weak TIM16_IRQHandler - .thumb_set TIM16_IRQHandler,Default_Handler + .weak TIM16_IRQHandler + .thumb_set TIM16_IRQHandler,Default_Handler - .weak TIM17_IRQHandler - .thumb_set TIM17_IRQHandler,Default_Handler + .weak TIM17_IRQHandler + .thumb_set TIM17_IRQHandler,Default_Handler - .weak MDIOS_WKUP_IRQHandler - .thumb_set MDIOS_WKUP_IRQHandler,Default_Handler + .weak MDIOS_WKUP_IRQHandler + .thumb_set MDIOS_WKUP_IRQHandler,Default_Handler - .weak MDIOS_IRQHandler - .thumb_set MDIOS_IRQHandler,Default_Handler + .weak MDIOS_IRQHandler + .thumb_set MDIOS_IRQHandler,Default_Handler - .weak JPEG_IRQHandler - .thumb_set JPEG_IRQHandler,Default_Handler + .weak JPEG_IRQHandler + .thumb_set JPEG_IRQHandler,Default_Handler - .weak MDMA_IRQHandler - .thumb_set MDMA_IRQHandler,Default_Handler + .weak MDMA_IRQHandler + .thumb_set MDMA_IRQHandler,Default_Handler - .weak SDMMC2_IRQHandler - .thumb_set SDMMC2_IRQHandler,Default_Handler - - .weak HSEM1_IRQHandler + .weak SDMMC2_IRQHandler + .thumb_set SDMMC2_IRQHandler,Default_Handler + + .weak HSEM1_IRQHandler .thumb_set HSEM1_IRQHandler,Default_Handler - .weak ADC3_IRQHandler - .thumb_set ADC3_IRQHandler,Default_Handler + .weak ADC3_IRQHandler + .thumb_set ADC3_IRQHandler,Default_Handler - .weak DMAMUX2_OVR_IRQHandler - .thumb_set DMAMUX2_OVR_IRQHandler,Default_Handler + .weak DMAMUX2_OVR_IRQHandler + .thumb_set DMAMUX2_OVR_IRQHandler,Default_Handler - .weak BDMA_Channel0_IRQHandler - .thumb_set BDMA_Channel0_IRQHandler,Default_Handler + .weak BDMA_Channel0_IRQHandler + .thumb_set BDMA_Channel0_IRQHandler,Default_Handler - .weak BDMA_Channel1_IRQHandler - .thumb_set BDMA_Channel1_IRQHandler,Default_Handler + .weak BDMA_Channel1_IRQHandler + .thumb_set BDMA_Channel1_IRQHandler,Default_Handler - .weak BDMA_Channel2_IRQHandler - .thumb_set BDMA_Channel2_IRQHandler,Default_Handler + .weak BDMA_Channel2_IRQHandler + .thumb_set BDMA_Channel2_IRQHandler,Default_Handler - .weak BDMA_Channel3_IRQHandler - .thumb_set BDMA_Channel3_IRQHandler,Default_Handler + .weak BDMA_Channel3_IRQHandler + .thumb_set BDMA_Channel3_IRQHandler,Default_Handler - .weak BDMA_Channel4_IRQHandler - .thumb_set BDMA_Channel4_IRQHandler,Default_Handler + .weak BDMA_Channel4_IRQHandler + .thumb_set BDMA_Channel4_IRQHandler,Default_Handler - .weak BDMA_Channel5_IRQHandler - .thumb_set BDMA_Channel5_IRQHandler,Default_Handler + .weak BDMA_Channel5_IRQHandler + .thumb_set BDMA_Channel5_IRQHandler,Default_Handler - .weak BDMA_Channel6_IRQHandler + .weak BDMA_Channel6_IRQHandler .thumb_set BDMA_Channel6_IRQHandler,Default_Handler - .weak BDMA_Channel7_IRQHandler - .thumb_set BDMA_Channel7_IRQHandler,Default_Handler + .weak BDMA_Channel7_IRQHandler + .thumb_set BDMA_Channel7_IRQHandler,Default_Handler - .weak COMP1_IRQHandler - .thumb_set COMP1_IRQHandler,Default_Handler + .weak COMP1_IRQHandler + .thumb_set COMP1_IRQHandler,Default_Handler - .weak LPTIM2_IRQHandler - .thumb_set LPTIM2_IRQHandler,Default_Handler + .weak LPTIM2_IRQHandler + .thumb_set LPTIM2_IRQHandler,Default_Handler - .weak LPTIM3_IRQHandler - .thumb_set LPTIM3_IRQHandler,Default_Handler + .weak LPTIM3_IRQHandler + .thumb_set LPTIM3_IRQHandler,Default_Handler - .weak LPTIM4_IRQHandler - .thumb_set LPTIM4_IRQHandler,Default_Handler + .weak LPTIM4_IRQHandler + .thumb_set LPTIM4_IRQHandler,Default_Handler - .weak LPTIM5_IRQHandler - .thumb_set LPTIM5_IRQHandler,Default_Handler + .weak LPTIM5_IRQHandler + .thumb_set LPTIM5_IRQHandler,Default_Handler - .weak LPUART1_IRQHandler - .thumb_set LPUART1_IRQHandler,Default_Handler + .weak LPUART1_IRQHandler + .thumb_set LPUART1_IRQHandler,Default_Handler - .weak CRS_IRQHandler - .thumb_set CRS_IRQHandler,Default_Handler + .weak CRS_IRQHandler + .thumb_set CRS_IRQHandler,Default_Handler - .weak ECC_IRQHandler + .weak ECC_IRQHandler .thumb_set ECC_IRQHandler,Default_Handler - .weak SAI4_IRQHandler - .thumb_set SAI4_IRQHandler,Default_Handler + .weak SAI4_IRQHandler + .thumb_set SAI4_IRQHandler,Default_Handler + + .weak WAKEUP_PIN_IRQHandler + .thumb_set WAKEUP_PIN_IRQHandler,Default_Handler + +/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ - .weak WAKEUP_PIN_IRQHandler - .thumb_set WAKEUP_PIN_IRQHandler,Default_Handler - -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ - diff --git a/examples/CopyingWavs/CopyingWavs.cpp b/examples/CopyingWavs/CopyingWavs.cpp index 6ad030faf..11e693770 100644 --- a/examples/CopyingWavs/CopyingWavs.cpp +++ b/examples/CopyingWavs/CopyingWavs.cpp @@ -70,7 +70,7 @@ void copy_wav(const char* filename) UINT data_read; WAV_FormatTypeDef wav_header; - // This will populate the wav_header struct with all the data we + // This will populate the wav_header struct with all the data we // need to parse the wav file. Currently, the code doesn't actually use this header, // but you could write code that converts from the // several possible WAV storage types to int16_t or float for consistency. @@ -92,7 +92,7 @@ void copy_wav(const char* filename) // This avoids attempted writes beyond the QSPI's address space if (current_qspi_offset >= QSPI_LEN) break; - + // The QSPI chip must be erased before any writes can be made, // and it can only be erased in certain sizes (4K, 32K, 64K, and full chip erase). // 64K is the fastest per byte without being too large, so that's what we'll use. @@ -107,4 +107,4 @@ void copy_wav(const char* filename) } while (data_read == DATA_BUFFER_LEN); f_close(&file); -} \ No newline at end of file +} diff --git a/examples/README.md b/examples/README.md index db398d085..c8c6e7fc9 100644 --- a/examples/README.md +++ b/examples/README.md @@ -8,7 +8,7 @@ These examples are meant to serve a few purposes: These should not be considered replacements for, unit tests, but rather as a form of integration tests. -To keep this lightweight, we won't include the standard debug files (vscode, or elsewhere), etc. +To keep this lightweight, we won't include the standard debug files (vscode, or elsewhere), etc. All wiring information for required external circuits, or wiring should be included in the opening comments of the source file. diff --git a/examples/SPI/SpiBlockingTransmit/SpiBlockingTransmit.cpp b/examples/SPI/SpiBlockingTransmit/SpiBlockingTransmit.cpp index 157a994b8..41ec7f52e 100644 --- a/examples/SPI/SpiBlockingTransmit/SpiBlockingTransmit.cpp +++ b/examples/SPI/SpiBlockingTransmit/SpiBlockingTransmit.cpp @@ -1,8 +1,8 @@ /** * @author beserge - * @brief + * @brief * @date 2022-05-19 - * + * * SPI Blocking Transmit Example * Shows how to transmit some data over SPI on the Daisy Seed in a blocking manner. * This means the code will wait while the transmission is occurring. @@ -45,7 +45,7 @@ int main(void) spi_handle.Init(spi_conf); // loop forever - while(1) + while(1) { // put these four bytes in a buffer uint8_t buffer[4] = {0, 1, 2, 3}; diff --git a/examples/SPI/SpiDmaTransmit/SpiDmaTransmit.cpp b/examples/SPI/SpiDmaTransmit/SpiDmaTransmit.cpp index 9bfe524cf..9395326aa 100644 --- a/examples/SPI/SpiDmaTransmit/SpiDmaTransmit.cpp +++ b/examples/SPI/SpiDmaTransmit/SpiDmaTransmit.cpp @@ -1,8 +1,8 @@ /** * @author beserge - * @brief + * @brief * @date 2022-05-19 - * + * * SPI DMA Transmit * Shows how to transmit some data over SPI on the Daisy Patch SM using DMA. * (DMA = Direct Memory Access). This method is non-blocking, meaning the hardware will @@ -50,7 +50,7 @@ int main(void) spi_handle.Init(spi_conf); // loop forever - while(1) + while(1) { // Use DMA to Transmit those 4 bytes. We don't have to wait for this to complete, we could go on and do other things here // We won't use the callback or callback data features either, so we'll set them to NULL diff --git a/examples/TIM_SingleCallback/TIM_SingleCallback.cpp b/examples/TIM_SingleCallback/TIM_SingleCallback.cpp index 6ffd03dc4..932a3957b 100644 --- a/examples/TIM_SingleCallback/TIM_SingleCallback.cpp +++ b/examples/TIM_SingleCallback/TIM_SingleCallback.cpp @@ -1,7 +1,7 @@ -/** TIM Single Callback +/** TIM Single Callback * Example of setting up and using a TIM peripheral * to generate periodic callbacks - * + * * To demonstrate, the LED will be toggled from the callback */ #include "daisy_seed.h" @@ -12,7 +12,7 @@ using namespace daisy; DaisySeed hw; /** This is our Timer-generated callback - * + * * Once the timer has been configured, and started, this function will be called * at the end of each timer period. */ @@ -29,9 +29,9 @@ int main(void) /** Initialize Daisy Seed */ hw.Init(); - /** Create Handle and config + /** Create Handle and config * We'll use TIM5 here, but TIM3, and TIM4 are also available - * At this time, TIM2 is used by the System class for sub-millisecond time/delay functions + * At this time, TIM2 is used by the System class for sub-millisecond time/delay functions */ TimerHandle tim5; TimerHandle::Config tim_cfg; diff --git a/examples/uart/Blocking_Transmit_Fifo_Receive/Blocking_Transmit_Fifo_Receive.cpp b/examples/uart/Blocking_Transmit_Fifo_Receive/Blocking_Transmit_Fifo_Receive.cpp index c2b13e229..b1495000f 100644 --- a/examples/uart/Blocking_Transmit_Fifo_Receive/Blocking_Transmit_Fifo_Receive.cpp +++ b/examples/uart/Blocking_Transmit_Fifo_Receive/Blocking_Transmit_Fifo_Receive.cpp @@ -32,7 +32,7 @@ int main(void) // if there's data, pop it from the FIFO if(uart.ReadableFifo()){ pop = uart.PopFifo(); - } + } // clear the display hw.display.Fill(false); diff --git a/examples/uart/Dma_Fifo_Receive/Dma_Fifo_Receive.cpp b/examples/uart/Dma_Fifo_Receive/Dma_Fifo_Receive.cpp index c49be8470..505965faf 100644 --- a/examples/uart/Dma_Fifo_Receive/Dma_Fifo_Receive.cpp +++ b/examples/uart/Dma_Fifo_Receive/Dma_Fifo_Receive.cpp @@ -29,7 +29,7 @@ int main(void) if(uart.ReadableFifo()){ pop = uart.PopFifo(); hw.seed.SetLed(false); - } + } else{ hw.seed.SetLed(true); } @@ -47,7 +47,7 @@ int main(void) sprintf(cstr, "%d", pop); hw.display.SetCursor(0, 12); hw.display.WriteString(cstr, Font_7x10, true); - + // update the display hw.display.Update(); diff --git a/src/daisy_core.h b/src/daisy_core.h index db7c4f46d..c669fa38d 100644 --- a/src/daisy_core.h +++ b/src/daisy_core.h @@ -23,9 +23,9 @@ This should be used primarily for DMA buffers, and the like. */ #define DMA_BUFFER_MEM_SECTION __attribute__((section(".sram1_bss"))) -/** -THE DTCM RAM section is also non-cached. However, is not suitable -for DMA transfers. Performance is on par with internal SRAM w/ +/** +THE DTCM RAM section is also non-cached. However, is not suitable +for DMA transfers. Performance is on par with internal SRAM w/ cache enabled. */ #define DTCM_MEM_SECTION __attribute__((section(".dtcmram_bss"))) @@ -45,23 +45,23 @@ cache enabled. #define F2S32_SCALE 2147483647.f /**< (2 ** 31) - 1 */ -/** shorthand macro for simplifying the reading of the left +/** shorthand macro for simplifying the reading of the left * channel of a non-interleaved output buffer named out */ #define OUT_L out[0] -/** shorthand macro for simplifying the reading of the right +/** shorthand macro for simplifying the reading of the right * channel of a non-interleaved output buffer named out */ #define OUT_R out[1] -/** shorthand macro for simplifying the reading of the left +/** shorthand macro for simplifying the reading of the left * channel of a non-interleaved input buffer named in */ #define IN_L in[0] -/** shorthand macro for simplifying the reading of the right +/** shorthand macro for simplifying the reading of the right * channel of a non-interleaved input buffer named in */ #define IN_R in[1] -/** +/** Computes cube. \param x Number to be cubed \return x ^ 3 @@ -71,7 +71,7 @@ FORCE_INLINE float cube(float x) return (x * x) * x; } -/** +/** Converts unsigned 8-bit to float \param x Number to be scaled. \return Scaled number. @@ -92,7 +92,7 @@ FORCE_INLINE uint8_t f2u8(float x) } -/** +/** Converts Signed 8-bit to float \param x Number to be scaled. \return Scaled number. @@ -112,7 +112,7 @@ FORCE_INLINE int8_t f2s8(float x) return (int32_t)(x * F2S8_SCALE); } -/** +/** Converts Signed 16-bit to float \param x Number to be scaled. \return Scaled number. @@ -171,10 +171,10 @@ FORCE_INLINE int32_t f2s32(float x) /** Enums and a simple struct for defining a hardware pin on the MCU * These correlate with the stm32 datasheet, and are used to configure * the hardware. - * + * * This along with the dsy_gpio_pin class should no longer be used. - * They are available for backwards compatability. - * + * They are available for backwards compatability. + * * Please use GPIOPort enum and the Pin struct instead. */ typedef enum @@ -194,11 +194,11 @@ typedef enum DSY_GPIO_LAST, /** Final enum member */ } dsy_gpio_port; -/** Hardware define pins - * +/** Hardware define pins + * * The dsy_gpio_pin struct should no longer be used, and is only available for * backwards compatability. - * + * * Please use Pin struct instead. */ typedef struct @@ -208,10 +208,10 @@ typedef struct } dsy_gpio_pin; /** Helper for creating pins from port/pin combos easily - * + * * The dsy_gpio_pin struct should no longer be used, and is only available for * backwards compatability. - * + * * Please use Pin struct instead. */ FORCE_INLINE dsy_gpio_pin dsy_pin(dsy_gpio_port port, uint8_t pin) @@ -224,10 +224,10 @@ FORCE_INLINE dsy_gpio_pin dsy_pin(dsy_gpio_port port, uint8_t pin) /** Helper for testing sameness of two dsy_gpio_pins * \return 1 if same, 0 if different - * + * * The dsy_gpio_pin struct should no longer be used, and is only available for * backwards compatability. - * + * * Please use Pin struct instead. */ FORCE_INLINE uint8_t dsy_pin_cmp(dsy_gpio_pin *a, dsy_gpio_pin *b) @@ -262,7 +262,7 @@ struct Pin GPIOPort port; uint8_t pin; - /** @brief Constructor creates a valid pin. + /** @brief Constructor creates a valid pin. * @param pt GPIOPort between PA, and PK corresponding to STM32 Port. * @param pn pin number in range of 0-15 */ @@ -271,7 +271,7 @@ struct Pin /** @brief Basic Constructor creates an invalid Pin object */ constexpr Pin() : port(PORTX), pin(255) {} - /** @brief checks validity of a Pin + /** @brief checks validity of a Pin * @retval returns true if the port is a valid hardware pin, otherwise false. */ constexpr bool IsValid() const { return port != PORTX && pin < 16; } @@ -287,7 +287,7 @@ struct Pin /** @brief conversion operation for converting to the old-style representation * of a pin. - * + * * This allows the new Pin type to be used in place of the older, dsy_gpio_pin * type. */ diff --git a/src/daisy_field.cpp b/src/daisy_field.cpp index 9fbc9195a..b4ced5b80 100644 --- a/src/daisy_field.cpp +++ b/src/daisy_field.cpp @@ -386,4 +386,4 @@ void DaisyField::VegasMode() display.Update(); led_driver.SwapBuffersAndTransmit(); } -} \ No newline at end of file +} diff --git a/src/daisy_field.h b/src/daisy_field.h index c31ef368d..5f0cfc7dd 100644 --- a/src/daisy_field.h +++ b/src/daisy_field.h @@ -86,7 +86,7 @@ class DaisyField /**Initializes the Daisy Field, and all of its hardware.*/ void Init(bool boost = false); - /** + /** Wait some ms before going on. \param del Delay time in ms. */ @@ -143,7 +143,7 @@ class DaisyField void StopAdc(); /** Turns on the built-in 12-bit DAC on the Daisy Seed */ - /** **This is now deprecated and does nothing.** + /** **This is now deprecated and does nothing.** ** The polling use of the DACs now handles starting the tranmission. */ void StartDac(); diff --git a/src/daisy_legio.cpp b/src/daisy_legio.cpp index 9eb339eca..4f1a9dc62 100644 --- a/src/daisy_legio.cpp +++ b/src/daisy_legio.cpp @@ -198,4 +198,4 @@ void DaisyLegio::UpdateExample() sw[SW_RIGHT].Read() / 2.0, controls[CONTROL_KNOB_BOTTOM].Value(), gate.State() ? 1.0 : 0.0); -} \ No newline at end of file +} diff --git a/src/daisy_legio.h b/src/daisy_legio.h index 667ac0fe4..eded3524d 100644 --- a/src/daisy_legio.h +++ b/src/daisy_legio.h @@ -4,7 +4,7 @@ namespace daisy { /** - @brief Class that handles initializing all of the hardware specific to the Virt Iter Legio hardware. \n + @brief Class that handles initializing all of the hardware specific to the Virt Iter Legio hardware. \n Helper funtions are also in place to provide easy access to built-in controls and peripherals. @author Eris Fairbanks, Olivia Artz Modular + Noise Engineering @date June 2022 @@ -42,7 +42,7 @@ class DaisyLegio /**Initializes the Legio, and all of its hardware.*/ void Init(bool boost = false); - /** + /** Wait some ms before going on. \param del Delay time in ms. */ @@ -139,4 +139,4 @@ class DaisyLegio void SetHidUpdateRates(); }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/daisy_patch.h b/src/daisy_patch.h index 68b16c500..fc039d2cd 100644 --- a/src/daisy_patch.h +++ b/src/daisy_patch.h @@ -7,7 +7,7 @@ namespace daisy { /** - @brief Class that handles initializing all of the hardware specific to the Daisy Patch Board. \n + @brief Class that handles initializing all of the hardware specific to the Daisy Patch Board. \n Helper funtions are also in place to provide easy access to built-in controls and peripherals. @author Stephen Hensley @date November 2019 @@ -43,7 +43,7 @@ class DaisyPatch /** Initializes the daisy seed, and patch hardware.*/ void Init(bool boost = false); - /** + /** Wait some ms before going on. \param del Delay time in ms. */ diff --git a/src/daisy_patch_sm.cpp b/src/daisy_patch_sm.cpp index badcc68ac..c01a3215a 100644 --- a/src/daisy_patch_sm.cpp +++ b/src/daisy_patch_sm.cpp @@ -216,7 +216,7 @@ namespace patch_sm } } - /** Actual DaisyPatchSM implementation + /** Actual DaisyPatchSM implementation * With the pimpl model in place, we can/should probably * move the rest of the implementation to the Impl class */ @@ -525,4 +525,4 @@ namespace patch_sm } // namespace patch_sm -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/daisy_patch_sm.h b/src/daisy_patch_sm.h index 03241f8a2..672ec86ce 100644 --- a/src/daisy_patch_sm.h +++ b/src/daisy_patch_sm.h @@ -6,13 +6,13 @@ namespace daisy { namespace patch_sm { - /** Accessors for the Analog Controls. + /** Accessors for the Analog Controls. * These cover the 8x Bipolar CV inputs * as well as the 4x 0-3V3 ADC inputs on - * the hardware - * + * the hardware + * * When reading a value with DaisyPatchSM::GetAdcValue() - * + * * patch.GetAdcValue(patch_sm::CV_1); */ enum @@ -44,9 +44,9 @@ namespace patch_sm /** @brief Board support file for DaisyPatchSM hardware * @author shensley * @ingroup boards - * + * * Daisy Patch SM is a complete Eurorack module DSP engine. - * Based on the Daisy Seed, with circuits added for + * Based on the Daisy Seed, with circuits added for * interfacing directly with eurorack modular synthesizers. */ class DaisyPatchSM @@ -86,12 +86,12 @@ namespace patch_sm /** Stops the transmission of audio. */ void StopAudio(); - /** Sets the number of samples processed in an audio callback. + /** Sets the number of samples processed in an audio callback. * This will only take effect on the next invocation of `StartAudio` */ void SetAudioBlockSize(size_t size); - /** Sets the samplerate for the audio engine + /** Sets the samplerate for the audio engine * This will set it to the closest valid samplerate. Options being: * 8kHz, 16kHz, 32kHz, 48kHz, and 96kHz */ @@ -108,8 +108,8 @@ namespace patch_sm /** Returns the rate at which the audio callback will be called in Hz */ float AudioCallbackRate(); - /** Starts the Control ADCs - * + /** Starts the Control ADCs + * * This is started automatically when Init() is called. */ void StartAdc(); @@ -120,7 +120,7 @@ namespace patch_sm /** Reads and filters all of the analog control inputs */ void ProcessAnalogControls(); - /** Reads and debounces any of the digital control inputs + /** Reads and debounces any of the digital control inputs * This does nothing on this board at this time. */ void ProcessDigitalControls(); @@ -138,39 +138,39 @@ namespace patch_sm /** Returns the STM32 port/pin combo for the desired pin (or an invalid pin for HW only pins) * * Macros at top of file can be used in place of separate arguments (i.e. GetPin(A4), etc.) - * + * * \param bank should be one of the PinBank options above * \param idx pin number between 1 and 10 for each of the pins on each header. */ dsy_gpio_pin GetPin(const PinBank bank, const int idx); - /** Starts the DAC for the CV Outputs - * - * By default this starts by running the - * internal callback at 48kHz, which will - * update the values based on the SetCvOut + /** Starts the DAC for the CV Outputs + * + * By default this starts by running the + * internal callback at 48kHz, which will + * update the values based on the SetCvOut * function. - * + * * This is started automatically when Init() is called. */ void StartDac(DacHandle::DacCallback callback = nullptr); - /** Stop the DAC from updating. - * This will suspend the CV Outputs from changing + /** Stop the DAC from updating. + * This will suspend the CV Outputs from changing */ void StopDac(); - /** Sets specified DAC channel to the target voltage. - * This may not be 100% accurate without calibration. - * + /** Sets specified DAC channel to the target voltage. + * This may not be 100% accurate without calibration. + * * \todo Add Calibration to CV Outputs - * + * * \param channel desired channel to update. 0 is both, otherwise 1 or 2 are valid. * \param voltage value in Volts that you'd like to write to the DAC. The valid range is 0-5V. */ void WriteCvOut(const int channel, float voltage); - /** Here are some wrappers around libDaisy Static functions + /** Here are some wrappers around libDaisy Static functions * to provide simpler syntax to those who prefer it. */ /** Delays for a specified number of milliseconds */ @@ -213,28 +213,28 @@ namespace patch_sm Log::StartLog(wait_for_pc); } - /** @brief Tests entirety of SDRAM for validity - * This will wipe contents of SDRAM when testing. - * - * @note If using the SDRAM for the default bss, or heap, - * and using constructors as initializers do not - * call this function. Otherwise, it could + /** @brief Tests entirety of SDRAM for validity + * This will wipe contents of SDRAM when testing. + * + * @note If using the SDRAM for the default bss, or heap, + * and using constructors as initializers do not + * call this function. Otherwise, it could * overwrite changes performed by constructors. - * + * * \retval returns true if SDRAM is okay, otherwise false */ bool ValidateSDRAM(); - /** @brief Tests the QSPI for validity - * This will wipe contents of QSPI when testing. - * + /** @brief Tests the QSPI for validity + * This will wipe contents of QSPI when testing. + * * @note If called with quick = false, this will erase all memory * the "quick" test starts 0x400000 bytes into the memory and * test 16kB of data - * + * * \param quick if this is true the test will only test a small piece of the QSPI * checking the entire 8MB can take roughly over a minute. - * + * * \retval returns true if SDRAM is okay, otherwise false */ bool ValidateQSPI(bool quick = true); diff --git a/src/daisy_pod.h b/src/daisy_pod.h index 43a063cb1..238792f2d 100644 --- a/src/daisy_pod.h +++ b/src/daisy_pod.h @@ -7,7 +7,7 @@ namespace daisy { /** - @brief Class that handles initializing all of the hardware specific to the Daisy Patch Board. \n + @brief Class that handles initializing all of the hardware specific to the Daisy Patch Board. \n Helper funtions are also in place to provide easy access to built-in controls and peripherals. @author Stephen Hensley @date November 2019 diff --git a/src/daisy_seed.h b/src/daisy_seed.h index af69944f9..8a01c6c16 100644 --- a/src/daisy_seed.h +++ b/src/daisy_seed.h @@ -10,7 +10,7 @@ namespace daisy { /** - @brief This is the higher-level interface for the Daisy board. \n + @brief This is the higher-level interface for the Daisy board. \n All basic peripheral configuration/initialization is setup here. \n @ingroup boards @@ -21,12 +21,12 @@ class DaisySeed DaisySeed() {} ~DaisySeed() {} - /** This function used to provide a pre-initialization configuraiton + /** This function used to provide a pre-initialization configuraiton * it has since been deprecated, and does nothing. */ void Configure(); - /** + /** Initializes the Daisy Seed and the following peripherals: SDRAM, QSPI, 24-bit 48kHz Audio via AK4556, Internal USB, as well as the built-in LED and Testpoint. @@ -37,18 +37,18 @@ class DaisySeed */ void Init(bool boost = false); - /** + /** Deinitializes all peripherals automatically handled by `Init`. */ void DeInit(); - /** + /** Wait some ms before going on. \param del Delay time in ms. */ void DelayMs(size_t del); - /** + /** Returns the gpio_pin corresponding to the index 0-31. For the given GPIO on the Daisy Seed (labeled 1-32 in docs). */ @@ -141,7 +141,7 @@ class DaisySeed dsy_gpio led, testpoint; System system; - /** Internal indices for DaisySeed-equivalent devices + /** Internal indices for DaisySeed-equivalent devices * This shouldn't have any effect on user-facing code, * and only needs to be checked to properly initialize * the onboard-circuits. @@ -174,7 +174,7 @@ class DaisySeed float callback_rate_; }; -/** seed namespace contains pinout constants for addressing +/** seed namespace contains pinout constants for addressing * the pins on the Daisy Seed SOM. */ namespace seed diff --git a/src/daisy_versio.h b/src/daisy_versio.h index bb183800f..d256f2095 100644 --- a/src/daisy_versio.h +++ b/src/daisy_versio.h @@ -4,7 +4,7 @@ namespace daisy { /** - @brief Class that handles initializing all of the hardware specific to the Desmodus Versio hardware. \n + @brief Class that handles initializing all of the hardware specific to the Desmodus Versio hardware. \n Helper funtions are also in place to provide easy access to built-in controls and peripherals. @author Ankoor Apte, Noise Engineering @date October 2020 @@ -48,7 +48,7 @@ class DaisyVersio /**Initializes the Versio, and all of its hardware.*/ void Init(bool boost = false); - /** + /** Wait some ms before going on. \param del Delay time in ms. */ diff --git a/src/dev/apds9960.h b/src/dev/apds9960.h index e65c698d8..253699ba4 100644 --- a/src/dev/apds9960.h +++ b/src/dev/apds9960.h @@ -63,8 +63,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for APDS9960 */ @@ -272,7 +272,7 @@ class Apds9960 } /** Sets gesture sensor offset - \param offset_up Up offset + \param offset_up Up offset \param offset_down Down offset \param offset_left Left offset \param offset_right Right offset @@ -322,7 +322,7 @@ class Apds9960 Write8(APDS9960_GPENTH, thresh); } - /** Enables the device / Disables the device + /** Enables the device / Disables the device (putting it in lower power sleep mode) \param en Enable */ @@ -333,7 +333,7 @@ class Apds9960 } /** Enable gesture readings - \param en Enable + \param en Enable */ void EnableGesture(bool en) { @@ -575,7 +575,7 @@ class Apds9960 \param r Red value \param g Green value \param b Blue value - + \return Color temperature */ uint16_t CalculateColorTemperature(uint16_t r, uint16_t g, uint16_t b) diff --git a/src/dev/codec_ak4556.h b/src/dev/codec_ak4556.h index 612391b5e..e5bb7244d 100644 --- a/src/dev/codec_ak4556.h +++ b/src/dev/codec_ak4556.h @@ -6,10 +6,10 @@ namespace daisy { -/** @brief Ak4556 Codec support +/** @brief Ak4556 Codec support ** @author shensley ** @addtogroup codec - ** + ** ** I don't see any real reason to have this be more than a function, but in case we want ** to add other functions down the road I wrapped the function in a class. ***/ @@ -19,15 +19,15 @@ class Ak4556 Ak4556() {} ~Ak4556() {} - /** Initialization function for Ak4556 + /** Initialization function for Ak4556 ** Can be called statically: - ** Ak4556::Init(pin); + ** Ak4556::Init(pin); ** */ static void Init(dsy_gpio_pin reset_pin); - /** Deinitialization function for Ak4556 + /** Deinitialization function for Ak4556 ** Can be called statically: - ** Ak4556::DeInit(pin); + ** Ak4556::DeInit(pin); ** */ static void DeInit(dsy_gpio_pin reset_pin); }; diff --git a/src/dev/codec_pcm3060.h b/src/dev/codec_pcm3060.h index 0dd5d646b..cab4f0dea 100644 --- a/src/dev/codec_pcm3060.h +++ b/src/dev/codec_pcm3060.h @@ -7,12 +7,12 @@ namespace daisy /** * @brief Driver for the TI PCM3060 Audio Codec. * @addtogroup codec - * + * * For now this is a limited interface that uses I2C to communicate with the PCM3060 * The device can also be accessed with SPI, which is not yet supported. - * - * For now all registers are set to their defaults, and the Init function will - * perform a MRST and SRST before setting the format to 24bit LJ, and disabling + * + * For now all registers are set to their defaults, and the Init function will + * perform a MRST and SRST before setting the format to 24bit LJ, and disabling * power save for both the ADC and DAC. * */ @@ -28,7 +28,7 @@ class Pcm3060 Pcm3060() {} ~Pcm3060() {} - /** Initializes the PCM3060 in 24-bit MSB aligned I2S mode, and disables powersave + /** Initializes the PCM3060 in 24-bit MSB aligned I2S mode, and disables powersave * \param i2c Initialized I2CHandle configured at 400kHz or less */ Result Init(I2CHandle i2c); @@ -45,4 +45,4 @@ class Pcm3060 }; } // namespace daisy -#endif \ No newline at end of file +#endif diff --git a/src/dev/codec_wm8731.h b/src/dev/codec_wm8731.h index 993f6b9bd..1a36e73e1 100644 --- a/src/dev/codec_wm8731.h +++ b/src/dev/codec_wm8731.h @@ -6,14 +6,14 @@ namespace daisy { /** Device driver for Cirrus (Wolfsen) WM8731 Audio Codec - ** - ** Currently only two-wire (I2C) interface format is supported, + ** + ** Currently only two-wire (I2C) interface format is supported, ** and only a limited set of features are configurable: ** * Line inputs/outputs ** * audio format/word length ** * 48kHZ ** - ** Support for headphones, microphone, and full functionality + ** Support for headphones, microphone, and full functionality ** still needs to be added. ** ** Use the Driver like this (this will be compatible with the Daisy Seed audio/sai config): @@ -27,8 +27,8 @@ namespace daisy i2c_config.pin_config.sda = {DSY_GPIOB, 9}; i2c1_handle.Init(i2c_config); codec_cfg.Defaults(); // MCU is master, 24-bit, MSB LJ - codec.Init(codec_cfg, i2c1_handle); - ** + codec.Init(codec_cfg, i2c1_handle); + ** ***/ class Wm8731 { @@ -40,8 +40,8 @@ class Wm8731 ERR, }; - /** Configuration struct for use in initializing the device. - ** For now, only 48kHz is supported. + /** Configuration struct for use in initializing the device. + ** For now, only 48kHz is supported. ** USB Mode is also not yet supported. */ struct Config { @@ -72,8 +72,8 @@ class Wm8731 /** Sets whether the left/right channels are swapped or not. */ bool lr_swap; - /** Set true if tied high, and false if tied low. - ** determines the I2C address for communicating + /** Set true if tied high, and false if tied low. + ** determines the I2C address for communicating ** with the device */ bool csb_pin_state; @@ -81,10 +81,10 @@ class Wm8731 WordLength wl; /** Sets the following config: - ** MCU is master = true + ** MCU is master = true ** L/R Swap = false ** CSB Pin state = false - ** Format = MSB First LJ + ** Format = MSB First LJ ** WordLength = 24-bit */ void Defaults() { diff --git a/src/dev/dps310.h b/src/dev/dps310.h index 5457a4c2a..65aeaf568 100644 --- a/src/dev/dps310.h +++ b/src/dev/dps310.h @@ -16,8 +16,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for Dps310 */ @@ -517,8 +517,8 @@ class Dps310 } - /** Read the XYZ data from the sensor and store in the internal - raw_pressure, raw_temperature, _pressure and _temperature variables. + /** Read the XYZ data from the sensor and store in the internal + raw_pressure, raw_temperature, _pressure and _temperature variables. */ void Process(void) { @@ -652,4 +652,4 @@ class Dps310 using Dps310I2C = Dps310; using Dps310Spi = Dps310; } // namespace daisy -#endif \ No newline at end of file +#endif diff --git a/src/dev/flash_IS25LP064A.h b/src/dev/flash_IS25LP064A.h index c6df5b407..adb3a098d 100644 --- a/src/dev/flash_IS25LP064A.h +++ b/src/dev/flash_IS25LP064A.h @@ -23,7 +23,7 @@ extern "C" #define IS25LP064A_SECTOR_ERASE_MAX_TIME 400 /**< & */ /** - * @brief IS25LP08D Commands + * @brief IS25LP08D Commands */ /** @addtogroup flash @@ -111,8 +111,8 @@ extern "C" #define ENTER_QUAD_CMD 0x35 #define EXIT_QUAD_CMD 0xF5 /**< & */ - /** - * @brief IS25LP08D Registers + /** + * @brief IS25LP08D Registers */ /* Status Register */ #define IS25LP064A_SR_WIP ((uint8_t)0x01) /*!< Write in progress */ diff --git a/src/dev/flash_IS25LP080D.h b/src/dev/flash_IS25LP080D.h index f6a20fa43..ba88e5a37 100644 --- a/src/dev/flash_IS25LP080D.h +++ b/src/dev/flash_IS25LP080D.h @@ -23,7 +23,7 @@ extern "C" #define IS25LP080D_SECTOR_ERASE_MAX_TIME 400 /**< & */ /** - * @brief IS25LP08D Commands + * @brief IS25LP08D Commands */ /** @addtogroup flash @@ -128,8 +128,8 @@ extern "C" #define ENTER_QUAD_CMD 0x35 #define EXIT_QUAD_CMD 0xF5 /**< & */ - /** - * @brief IS25LP08D Registers + /** + * @brief IS25LP08D Registers */ /** Status Register */ #define IS25LP080D_SR_WIP ((uint8_t)0x01) /*!< Write in progress */ diff --git a/src/dev/icm20948.h b/src/dev/icm20948.h index c782e35d1..9b5422111 100644 --- a/src/dev/icm20948.h +++ b/src/dev/icm20948.h @@ -72,8 +72,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for Icm20948 */ @@ -994,4 +994,4 @@ class Icm20948 using Icm20948I2C = Icm20948; using Icm20948Spi = Icm20948; } // namespace daisy -#endif \ No newline at end of file +#endif diff --git a/src/dev/lcd_hd44780.cpp b/src/dev/lcd_hd44780.cpp index 5d09332d1..1e0e0ee2b 100644 --- a/src/dev/lcd_hd44780.cpp +++ b/src/dev/lcd_hd44780.cpp @@ -1,5 +1,5 @@ /* - + Project: LCD library for Electrosmith's Daisy Seed Description: LCD class for a 16x2 LCD using the Hitachi HD44780 driver chip Author: Staffan Melin, staffan.melin@oscillator.se diff --git a/src/dev/lcd_hd44780.h b/src/dev/lcd_hd44780.h index 8261bd6b7..71a3cc8ed 100644 --- a/src/dev/lcd_hd44780.h +++ b/src/dev/lcd_hd44780.h @@ -9,7 +9,7 @@ namespace daisy { /** - @brief Device Driver for 16x2 LCD panel. \n + @brief Device Driver for 16x2 LCD panel. \n HD44780 with 4 data lines. \n Example product: https://www.adafruit.com/product/181 @author StaffanMelin @@ -29,32 +29,32 @@ class LcdHD44780 dsy_gpio_pin rs, en, d4, d5, d6, d7; }; - /** + /** Initializes the LCD. * \param config is a struct that sets cursor on/off, cursor blink on/off and the dsy_gpio_pin's that connects to the LCD. */ void Init(const Config &config); - /** + /** Prints a string on the LCD. * \param string is a C-formatted string to print. */ void Print(const char *string); - /** + /** Prints an integer value on the LCD. * \param number is an integer to print. */ void PrintInt(int number); - /** + /** Moves the cursor of the LCD (the place to print the next value). * \param row is the row number (0 or 1). * \param col is the column number (0 to 15). */ void SetCursor(uint8_t row, uint8_t col); - /** + /** Clears the contents of the LCD. */ void Clear(); diff --git a/src/dev/leddriver.h b/src/dev/leddriver.h index 6c2b99ef0..aae5c3914 100644 --- a/src/dev/leddriver.h +++ b/src/dev/leddriver.h @@ -12,20 +12,20 @@ namespace daisy { /** LED driver for one or multiple PCA9685 12bit PWM chips connected to * a single I2C peripheral. - * It includes gamma correction from 8bit brightness values but it + * It includes gamma correction from 8bit brightness values but it * can also be supplied with raw 12bit values. * This driver uses two buffers - one for drawing, one for transmitting. * Multiple LedDriverPca9685 instances can be used at the same time. * \param numDrivers The number of PCA9685 driver attached to the I2C * peripheral. - * \param persistentBufferContents If set to true, the current draw buffer - * contents will be copied to the next draw buffer + * \param persistentBufferContents If set to true, the current draw buffer + * contents will be copied to the next draw buffer * during SwapBuffersAndTransmit(). Use this, if you plan - * to write single leds at a time. - * If you will alway update all leds before calling + * to write single leds at a time. + * If you will alway update all leds before calling * SwapBuffersAndTransmit(), you can set this to false * and safe some cycles. - * + * * @ingroup device */ template @@ -50,13 +50,13 @@ class LedDriverPca9685 /** Buffer type for the entire DMA buffer. */ using DmaBuffer = PCA9685TransmitBuffer[numDrivers]; - /** Initialises the driver. + /** Initialises the driver. * \param i2c The I2C peripheral to use. * \param addresses An array of addresses for each of the driver chips. - * \param dma_buffer_a The first buffer for the DMA. This must be placed in + * \param dma_buffer_a The first buffer for the DMA. This must be placed in * D2 memory by adding the DMA_BUFFER_MEM_SECTION attribute * like this: `LedDriverPca9685<2>::DmaBuffer DMA_BUFFER_MEM_SECTION bufferA;` - * \param dma_buffer_b The second buffer for the DMA. This must be placed in + * \param dma_buffer_b The second buffer for the DMA. This must be placed in * D2 memory by adding the DMA_BUFFER_MEM_SECTION attribute * like this: `LedDriverPca9685<2>::DmaBuffer DMA_BUFFER_MEM_SECTION bufferB;` * \param oe_pin If the output enable pin is used, supply its configuration here. diff --git a/src/dev/max11300.h b/src/dev/max11300.h index 12f8c3d70..cdc94c0c0 100644 --- a/src/dev/max11300.h +++ b/src/dev/max11300.h @@ -58,13 +58,13 @@ namespace MAX11300Types }; /** - * Pins of the MAX11300 configured for AnalogRead may be defined to - * operate within several pre-defined voltage ranges (assuming the power supply + * Pins of the MAX11300 configured for AnalogRead may be defined to + * operate within several pre-defined voltage ranges (assuming the power supply * requirements for the range is met). - * + * * Pins configiured for DigitalRead are 0-5V only, and do not tolerate negative * voltages. - * + * * WARNING, when a pin is configured as DigitalRead and a voltage lower than * -250mV is applied, the codes read from ALL other pins confiured as * AnalogRead will become unusuably corrupted. @@ -78,10 +78,10 @@ namespace MAX11300Types }; /** - * Pins of the MAX11300 configured for AnalogWrite may be defined to - * operate within several pre-defined voltage ranges (assuming the power supply + * Pins of the MAX11300 configured for AnalogWrite may be defined to + * operate within several pre-defined voltage ranges (assuming the power supply * requirements for the range is met). - * + * * Pins configiured for DigitalWrite are 0-5V only, and do not produce negative * voltages. */ @@ -253,14 +253,14 @@ class MAX11300MultiSlaveSpiTransport * @brief Device Driver for the MAX11300 20 port ADC/DAC/GPIO device. * @author sam.braam * @date Oct. 2021 - * + * * This is a highly opinionated driver implementation for the MAX11300 - * DAC/ADC/GPIO device. - * + * DAC/ADC/GPIO device. + * * This implemetation has been designed for use in the context of Eurorack * modular systems. There are a number of features the MAX11300 offers - * which are not exposed, as well as a number of configuration decisions - * that were made in order to simplify usage and improve ergonomics, + * which are not exposed, as well as a number of configuration decisions + * that were made in order to simplify usage and improve ergonomics, * even at the cost of flexibility. */ template @@ -277,14 +277,14 @@ class MAX11300Driver ~MAX11300Driver(){}; /** - * Initialize the MAX11300 - * + * Initialize the MAX11300 + * * This method verifies SPI connectivity, configures the chip to - * operate within the scope of this implementation, and + * operate within the scope of this implementation, and * intitalizes all pins by default to High-Z mode. - * + * * \param config - The MAX11300 configuration - * \param dma_buffer a buffer in DMA-accessible memory. + * \param dma_buffer a buffer in DMA-accessible memory. * Allocate it like this: `MAX11300DmaBuffer DMA_BUFFER_MEM_SECTION myBuffer;` */ MAX11300Types::Result Init(Config config, @@ -439,9 +439,9 @@ class MAX11300Driver /** * Read the raw 12 bit (0-4095) value of a given ANALOG_IN (ADC) pin. - * + * * *note this read is local, call MAX11300::Start() to sync with the MAX11300 - * + * * \param pin - The pin of which to read the value * \return - The raw, 12 bit value of the given ANALOG_IN (ADC) pin. */ @@ -458,9 +458,9 @@ class MAX11300Driver /** * Read the value of a given ADC pin in volts. - * + * * *note this read is local, call MAX11300::Start() to sync with the MAX11300 - * + * * \param pin - The pin of which to read the voltage * \return - The value of the given ANALOG_IN (ADC) pin in volts */ @@ -475,9 +475,9 @@ class MAX11300Driver /** * Write a raw 12 bit (0-4095) value to a given ANALOG_OUT (DAC) pin - * + * * *note this write is local, call MAX11300::Start() to sync with the MAX11300 - * + * * \param pin - The pin of which to write the value * \param raw_value - the 12-bit code to write to the given Pin */ @@ -495,11 +495,11 @@ class MAX11300Driver } /** - * Write a voltage value, within the bounds of the configured volatge range, + * Write a voltage value, within the bounds of the configured volatge range, * to a given ANALOG_OUT (DAC) pin. - * + * * *note this write is local, call MAX11300::Start() to sync with the MAX11300 - * + * * \param pin - The pin of which to write the voltage * \param voltage - Target voltage */ @@ -518,9 +518,9 @@ class MAX11300Driver /** * Read the state of a GPI pin - * + * * *note this read is local, call MAX11300::Start() to sync with the MAX11300 - * + * * \param pin - The pin of which to read the value * \return - The boolean state of the pin */ @@ -544,9 +544,9 @@ class MAX11300Driver /** * Write a digital state to the given GPO pin - * + * * *note this write is local, call MAX11300::Start() to sync with the MAX11300 - * + * * \param pin - The pin of which to write the value * \param value - the boolean state to write */ @@ -591,17 +591,17 @@ class MAX11300Driver /** * Starts to update and synchronize the MAX11300 - This method does the following: - * + * * - Write all current ANALOG_OUT (DAC) values to all MAX11300s * - Read all current ANALOG_IN (ADC) values to memory * - Write all GPO states to all MAX11300s * - Read all GPI states to memory * - call the provided callback function when complete (from an interrupt) * - repeat - * + * * The driver can be stopped by calling Stop(). * @see Stop() - * + * * \param complete_callback An optional callback function that's called after each successful update * Keep this callback function simple and fast, it's called from an interrupt. * \param complete_callback_context An optional context pointer provided to the complete_callback @@ -636,8 +636,8 @@ class MAX11300Driver /** * A utility funtion for converting a voltage (float) value, bound to a given - * voltage range, to the first 12 bits (0-4095) of an unsigned 16 bit integer value. - * + * voltage range, to the first 12 bits (0-4095) of an unsigned 16 bit integer value. + * * \param volts the voltage to convert * \param range the MAX11300Types::DacVoltageRange to constrain to * \return the voltage as 12 bit unsigned integer @@ -678,9 +678,9 @@ class MAX11300Driver /** * A utility funtion for converting the first 12 bits (0-4095) of an unsigned - * 16 bit integer value, to a voltage (float) value. The voltage value is + * 16 bit integer value, to a voltage (float) value. The voltage value is * scaled and bound to the given voltage range. - * + * * \param value the 12 bit value to convert * \param range the MAX11300Types::AdcVoltageRange to constrain to * \return the value as a float voltage constrained to the given voltage range @@ -723,8 +723,8 @@ class MAX11300Driver private: /** - * Pins/ports of the MAX11300 are freely configurable to function as - * ANALOG_IN (ADC), ANALOG_OUT (DAC), GPI, or GPO. + * Pins/ports of the MAX11300 are freely configurable to function as + * ANALOG_IN (ADC), ANALOG_OUT (DAC), GPI, or GPO. * This enum describes these modes. */ enum class PinMode @@ -738,7 +738,7 @@ class MAX11300Driver /** * The PinConfig struct holds the necessary information needed to configure a - * pin/port of the MAX11300, as well as a pointer to the stateful pin data. + * pin/port of the MAX11300, as well as a pointer to the stateful pin data. */ struct PinConfig { @@ -750,13 +750,13 @@ class MAX11300Driver } range; /**< & */ /** * This is a voltage value used as follows: - * + * * GPI - Defines what input voltage constituates a logical 1 * GPO - The output voltage of the pin at logical 1 */ float threshold; /** - * In the case of ANALOG_IN or ANALOG_OUT modes, this points to the + * In the case of ANALOG_IN or ANALOG_OUT modes, this points to the * current 12 bit value of the pin. */ uint16_t* value; @@ -774,7 +774,7 @@ class MAX11300Driver /** * Apply the current configuration to the given pin - * + * * \param pin - The pin to configure * \return - OK if the configuration was successfully applied */ @@ -941,7 +941,7 @@ class MAX11300Driver /** * Read the value of a single register address from the MAX11300 * \param address - the register address to read - * \return the value at the given register as returned by the MAX11300 + * \return the value at the given register as returned by the MAX11300 */ uint16_t ReadRegister(size_t device_index, uint8_t address) { @@ -953,9 +953,9 @@ class MAX11300Driver /** * Read the values, starting at the given address, from the MAX11300. * \param address - the register address to begin from - * \param values - a pointer to which the values from the MAX11300 will be written + * \param values - a pointer to which the values from the MAX11300 will be written * \param size - the number of bytes to read - * \return OK if the transaction was successful + * \return OK if the transaction was successful */ MAX11300Types::Result ReadRegister(size_t device_index, uint8_t address, @@ -988,7 +988,7 @@ class MAX11300Driver * Write a value to a single register address of the MAX11300 * \param address - the register address to write to * \param value - the value to write at the given register - * \return OK if the transaction was successful + * \return OK if the transaction was successful */ MAX11300Types::Result WriteRegister(size_t device_index, uint8_t address, uint16_t value) @@ -999,9 +999,9 @@ class MAX11300Driver /** * Write the values, starting at the given address, to the MAX11300. * \param address - the register address to begin from - * \param values - a pointer to which the values to be written to the MAX11300 will be read + * \param values - a pointer to which the values to be written to the MAX11300 will be read * \param size - the number of bytes to written - * \return OK if the transaction was successful + * \return OK if the transaction was successful */ MAX11300Types::Result WriteRegister(size_t device_index, uint8_t address, diff --git a/src/dev/mcp23x17.h b/src/dev/mcp23x17.h index 06a48f81b..88a748db1 100644 --- a/src/dev/mcp23x17.h +++ b/src/dev/mcp23x17.h @@ -69,7 +69,7 @@ enum class MCPMode : uint8_t /** * Barebones driver for MCP23017 I2C 16-Bit I/O Expander * For now it supports only polling approach. - * + * * Usage: * Mcp23017 mcp; * mcp.Init(); @@ -181,11 +181,11 @@ class Mcp23X17 /** * Controls the pins direction on a whole port at once. - * + * * directions: 0 - output, 1 - input * pullups: 0 - disabled, 1 - enabled * inverted: 0 - false/normal, 1 - true/inverted - * + * * See "3.5.1 I/O Direction register". */ void PortMode(MCPPort port, @@ -199,9 +199,9 @@ class Mcp23X17 } /** - * Controls a single pin direction. + * Controls a single pin direction. * Pin 0-7 for port A, 8-15 fo port B. - * + * * 1 = Pin is configured as an input. * 0 = Pin is configured as an output. * @@ -243,10 +243,10 @@ class Mcp23X17 /** * Writes a single pin state. * Pin 0-7 for port A, 8-15 for port B. - * + * * 1 = Logic-high * 0 = Logic-low - * + * * See "3.5.10 Port register". */ void WritePin(uint8_t pin, uint8_t state) @@ -275,10 +275,10 @@ class Mcp23X17 /** * Reads a single pin state. * Pin 0-7 for port A, 8-15 for port B. - * + * * 1 = Logic-high * 0 = Logic-low - * + * * See "3.5.10 Port register". */ uint8_t ReadPin(uint8_t pin) @@ -302,10 +302,10 @@ class Mcp23X17 /** * Writes pins state to a whole port. - * + * * 1 = Logic-high * 0 = Logic-low - * + * * See "3.5.10 Port register". */ void WritePort(MCPPort port, uint8_t value) @@ -315,10 +315,10 @@ class Mcp23X17 /** * Reads pins state for a whole port. - * + * * 1 = Logic-high * 0 = Logic-low - * + * * See "3.5.10 Port register". */ uint8_t ReadPort(MCPPort port) @@ -328,10 +328,10 @@ class Mcp23X17 /** * Writes pins state to both ports. - * + * * 1 = Logic-high * 0 = Logic-low - * + * * See "3.5.10 Port register". */ void Write(uint16_t value) @@ -341,11 +341,11 @@ class Mcp23X17 } /** - * Reads pins state for both ports. - * + * Reads pins state for both ports. + * * 1 = Logic-high * 0 = Logic-low - * + * * See "3.5.10 Port register". */ uint16_t Read() @@ -359,7 +359,7 @@ class Mcp23X17 /** * @brief Fetches pin state from the result of recent Read() call. Useful to preserve unneeded reads - * + * * @param id pin ID * @return uint8_t pin state: 0x00 or 0xFF */ @@ -398,4 +398,4 @@ class Mcp23X17 }; using Mcp23017 = Mcp23X17; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/dev/mpr121.h b/src/dev/mpr121.h index 1a20868ca..f406f034e 100644 --- a/src/dev/mpr121.h +++ b/src/dev/mpr121.h @@ -9,8 +9,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for MPR121 */ diff --git a/src/dev/neopixel.h b/src/dev/neopixel.h index e6fad6c4a..82814f685 100644 --- a/src/dev/neopixel.h +++ b/src/dev/neopixel.h @@ -53,8 +53,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for NeoPixel */ @@ -319,7 +319,7 @@ class NeoPixel */ Result GetTransportError() { return transport_.GetError() ? ERR : OK; } - /** Perform a software reset. + /** Perform a software reset. This resets all seesaw registers to their default values. This is called automatically from Init(). */ @@ -629,4 +629,4 @@ class NeoPixel using NeoPixelI2C = NeoPixel; } // namespace daisy -#endif \ No newline at end of file +#endif diff --git a/src/dev/neotrellis.h b/src/dev/neotrellis.h index 503f1a2da..459ab9e33 100644 --- a/src/dev/neotrellis.h +++ b/src/dev/neotrellis.h @@ -24,8 +24,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for NeoTrellis */ @@ -305,7 +305,7 @@ class NeoTrellis */ Result GetTransportError() { return transport_.GetError() ? ERR : OK; } - /** Perform a software reset. + /** Perform a software reset. This resets all seesaw registers to their default values. This is called automatically from Init(). */ @@ -329,9 +329,9 @@ class NeoTrellis NEO_TRELLIS_KEY(NEO_TRELLIS_XY(xkey, ykey)), edge, enable); } - /** read all events currently stored in the seesaw fifo and call any callbacks. + /** read all events currently stored in the seesaw fifo and call any callbacks. \param polling pass true if the interrupt pin is not being used, false if - it is. Defaults to true. + it is. Defaults to true. */ void Process(bool polling = true) { @@ -494,4 +494,4 @@ class NeoTrellis using NeoTrellisI2C = NeoTrellis; } // namespace daisy -#endif \ No newline at end of file +#endif diff --git a/src/dev/oled_ssd130x.h b/src/dev/oled_ssd130x.h index 50f665afc..f2ec30fa5 100644 --- a/src/dev/oled_ssd130x.h +++ b/src/dev/oled_ssd130x.h @@ -268,7 +268,7 @@ class SSD130xDriver }; /** - * Update the display + * Update the display */ void Update() { @@ -295,63 +295,63 @@ class SSD130xDriver }; /** - * A driver for the SSD1306/SSD1309 128x64 OLED displays connected via 4 wire SPI + * A driver for the SSD1306/SSD1309 128x64 OLED displays connected via 4 wire SPI */ using SSD130x4WireSpi128x64Driver = daisy::SSD130xDriver<128, 64, SSD130x4WireSpiTransport>; /** - * A driver for the SSD1306/SSD1309 128x32 OLED displays connected via 4 wire SPI + * A driver for the SSD1306/SSD1309 128x32 OLED displays connected via 4 wire SPI */ using SSD130x4WireSpi128x32Driver = daisy::SSD130xDriver<128, 32, SSD130x4WireSpiTransport>; /** - * A driver for the SSD1306/SSD1309 98x16 OLED displays connected via 4 wire SPI + * A driver for the SSD1306/SSD1309 98x16 OLED displays connected via 4 wire SPI */ using SSD130x4WireSpi98x16Driver = daisy::SSD130xDriver<98, 16, SSD130x4WireSpiTransport>; /** - * A driver for the SSD1306/SSD1309 64x48 OLED displays connected via 4 wire SPI + * A driver for the SSD1306/SSD1309 64x48 OLED displays connected via 4 wire SPI */ using SSD130x4WireSpi64x48Driver = daisy::SSD130xDriver<64, 48, SSD130x4WireSpiTransport>; /** - * A driver for the SSD1306/SSD1309 64x32 OLED displays connected via 4 wire SPI + * A driver for the SSD1306/SSD1309 64x32 OLED displays connected via 4 wire SPI */ using SSD130x4WireSpi64x32Driver = daisy::SSD130xDriver<64, 32, SSD130x4WireSpiTransport>; /** - * A driver for the SSD1306/SSD1309 128x64 OLED displays connected via I2C + * A driver for the SSD1306/SSD1309 128x64 OLED displays connected via I2C */ using SSD130xI2c128x64Driver = daisy::SSD130xDriver<128, 64, SSD130xI2CTransport>; /** - * A driver for the SSD1306/SSD1309 128x32 OLED displays connected via I2C + * A driver for the SSD1306/SSD1309 128x32 OLED displays connected via I2C */ using SSD130xI2c128x32Driver = daisy::SSD130xDriver<128, 32, SSD130xI2CTransport>; /** - * A driver for the SSD1306/SSD1309 98x16 OLED displays connected via I2C + * A driver for the SSD1306/SSD1309 98x16 OLED displays connected via I2C */ using SSD130xI2c98x16Driver = daisy::SSD130xDriver<98, 16, SSD130xI2CTransport>; /** - * A driver for the SSD1306/SSD1309 64x48 OLED displays connected via I2C + * A driver for the SSD1306/SSD1309 64x48 OLED displays connected via I2C */ using SSD130xI2c64x48Driver = daisy::SSD130xDriver<64, 48, SSD130xI2CTransport>; /** - * A driver for the SSD1306/SSD1309 64x32 OLED displays connected via I2C + * A driver for the SSD1306/SSD1309 64x32 OLED displays connected via I2C */ using SSD130xI2c64x32Driver = daisy::SSD130xDriver<64, 32, SSD130xI2CTransport>; }; // namespace daisy -#endif \ No newline at end of file +#endif diff --git a/src/dev/sdram.cpp b/src/dev/sdram.cpp index 366aab3df..e5e6dbfc0 100644 --- a/src/dev/sdram.cpp +++ b/src/dev/sdram.cpp @@ -208,7 +208,7 @@ static void HAL_FMC_MspInit(void) __HAL_RCC_GPIOC_CLK_ENABLE(); - /** FMC GPIO Configuration + /** FMC GPIO Configuration PE1 ------> FMC_NBL1 PE0 ------> FMC_NBL0 PG15 ------> FMC_SDNCAS @@ -372,7 +372,7 @@ static void HAL_FMC_MspDeInit(void) /* Peripheral clock enable */ __HAL_RCC_FMC_CLK_DISABLE(); - /** FMC GPIO Configuration + /** FMC GPIO Configuration PE1 ------> FMC_NBL1 PE0 ------> FMC_NBL0 PG15 ------> FMC_SDNCAS diff --git a/src/dev/sdram.h b/src/dev/sdram.h index bc53de04f..701ca3440 100644 --- a/src/dev/sdram.h +++ b/src/dev/sdram.h @@ -69,13 +69,13 @@ SECTIONS The variables placed here will also need to fit inside of the flash in order to initialize. */ -/** Usage: \n +/** Usage: \n E.g. int DSY_SDRAM_DATA initialized_var = 1; */ #define DSY_SDRAM_DATA __attribute__((section(".sdram_data"))) -/** Variables placed here will not be initialized. \n - Usage \n +/** Variables placed here will not be initialized. \n + Usage \n E.g. int DSY_SDRAM_BSS uninitialized_var; */ #define DSY_SDRAM_BSS __attribute__((section(".sdram_bss"))) diff --git a/src/dev/sr_4021.h b/src/dev/sr_4021.h index 9ccbca027..39f8cb954 100644 --- a/src/dev/sr_4021.h +++ b/src/dev/sr_4021.h @@ -11,7 +11,7 @@ namespace daisy ** @ingroup shiftregister ** ** CD4021B-Q1: CMOS 8-STAGE STATIC SHIFT REGISTER - ** + ** ** Supply Voltage: 3V to 18V ** Clock Freq: 3MHz at 5V (less at 3v3) -> 8.5MHz at 15V ** Pin Descriptions: @@ -21,14 +21,14 @@ namespace daisy ** - P/!S - 9 ** - Q[6-8] - 2, 12, 3 ** - ** Driver has support for daisy chaining and running up to 2 same-sized - ** chains in parallel from a single set of clk/latch pins to reduce + ** Driver has support for daisy chaining and running up to 2 same-sized + ** chains in parallel from a single set of clk/latch pins to reduce ** pin/code overhead when using multiple devices. ** - ** When dealing with multiple parallel/daisy-chained devices the + ** When dealing with multiple parallel/daisy-chained devices the ** states of all inputs will be filled in the following order (example uses two chained and two parallel): ** data[chain0,parallel0], data[chain1,parallel0], data[chain0,parallel1], data[chain1,parallel1]; - ** + ** ** When combining multiple daisy chained and parallel devices the number of devices chained should match ** for each parallel device chain. ** @@ -98,10 +98,10 @@ class ShiftRegister4021 } } - /** returns the last read state of the input at the index. + /** returns the last read state of the input at the index. ** true indicates the pin is held HIGH. - ** - ** See above for the layout of data when using multiple + ** + ** See above for the layout of data when using multiple ** devices in series or parallel. ***/ inline bool State(int index) const { return states_[index]; } diff --git a/src/dev/sr_595.h b/src/dev/sr_595.h index 6c2f666c7..171f7180e 100644 --- a/src/dev/sr_595.h +++ b/src/dev/sr_595.h @@ -13,7 +13,7 @@ const size_t kMaxSr595DaisyChain */ /** - @brief Device Driver for 8-bit shift register. \n + @brief Device Driver for 8-bit shift register. \n CD74HC595 - 8-bit serial to parallel output shift @author shensley @date May 2020 @@ -22,7 +22,7 @@ class ShiftRegister595 { public: /** The following pins correspond to the hardware connections - to the 595. + to the 595. */ enum Pins { @@ -34,7 +34,7 @@ class ShiftRegister595 ShiftRegister595() {} ~ShiftRegister595() {} - /** + /** Initializes the GPIO, and data for the ShiftRegister * \param pin_cfg is an array of dsy_gpio_pin corresponding the the Pins enum above. * \param num_daisy_chained (default = 1) is the number of 595 devices daisy chained together. diff --git a/src/dev/tlv493d.h b/src/dev/tlv493d.h index d64d8e540..2037a92c6 100644 --- a/src/dev/tlv493d.h +++ b/src/dev/tlv493d.h @@ -21,8 +21,8 @@ namespace daisy { -/** @addtogroup external - @{ +/** @addtogroup external + @{ */ /** I2C Transport for TLV493D */ diff --git a/src/hid/MidiEvent.h b/src/hid/MidiEvent.h index abe121008..1926e8f5a 100644 --- a/src/hid/MidiEvent.h +++ b/src/hid/MidiEvent.h @@ -7,7 +7,7 @@ namespace daisy * @{ */ -/** @defgroup midi_events MIDI_EVENTS +/** @defgroup midi_events MIDI_EVENTS * @{ */ @@ -200,7 +200,7 @@ struct AllNotesOffEvent { int channel; /**< & */ }; -/** Struct containing OmniModeOffEvent data. +/** Struct containing OmniModeOffEvent data. * Can be made from MidiEvent */ struct OmniModeOffEvent @@ -413,4 +413,4 @@ struct MidiEvent /** @} */ // End midi_events /** @} */ // End midi -} //namespace daisy \ No newline at end of file +} //namespace daisy diff --git a/src/hid/audio.h b/src/hid/audio.h index cfbe1aa8d..414d3767c 100644 --- a/src/hid/audio.h +++ b/src/hid/audio.h @@ -6,9 +6,9 @@ namespace daisy { /** @brief Audio Engine Handle - * @ingroup audio + * @ingroup audio * @details This class allows for higher level access to an audio engine. - * If you're using a SOM like the DaisySeed or DaisyPatchSM (or any + * If you're using a SOM like the DaisySeed or DaisyPatchSM (or any * board that includes one of those objects) then the intialization * is already taken care of. * If you're setting up your own custom hardware, or need to make changes @@ -57,17 +57,17 @@ class AudioHandle }; /** Non-Interleaving input buffer - * Buffer arranged by float[chn][sample] + * Buffer arranged by float[chn][sample] * const so that the user can't modify the input */ typedef const float* const* InputBuffer; /** Non-Interleaving output buffer - * Arranged by float[chn][sample] + * Arranged by float[chn][sample] */ typedef float** OutputBuffer; - /** Type for a Non-Interleaving audio callback + /** Type for a Non-Interleaving audio callback * Non-Interleaving audio callbacks in daisy will be of this type */ typedef void (*AudioCallback)(InputBuffer in, @@ -80,12 +80,12 @@ class AudioHandle */ typedef const float* InterleavingInputBuffer; - /** Interleaving Output buffer + /** Interleaving Output buffer ** audio is prepared as { L0, R0, L1, R1, . . . LN, RN } */ typedef float* InterleavingOutputBuffer; - /** Interleaving Audio Callback + /** Interleaving Audio Callback * Interleaving audio callbacks in daisy must be of this type */ typedef void (*InterleavingAudioCallback)(InterleavingInputBuffer in, @@ -110,7 +110,7 @@ class AudioHandle /** Returns the Global Configuration struct for the Audio */ const Config& GetConfig() const; - /** Returns the number of channels of audio. + /** Returns the number of channels of audio. ** ** When using a single SAI this returns 2, when using two SAI it returns 4 ** If no SAI is initialized this returns 0 @@ -126,13 +126,13 @@ class AudioHandle Result SetSampleRate(SaiHandle::Config::SampleRate samplerate); /** Sets the block size after initialization, and updates the internal configuration struct. - ** Get BlockSize and other details via the GetConfig + ** Get BlockSize and other details via the GetConfig */ Result SetBlockSize(size_t size); /** Sets the amount of gain adjustment to perform before and after callback. - ** useful if the hardware has additional headroom, and the nominal value shouldn't be 1.0 - ** + ** useful if the hardware has additional headroom, and the nominal value shouldn't be 1.0 + ** ** \param val Gain adjustment amount. The hardware will clip at the reciprical of this value. */ Result SetPostGain(float val); @@ -147,8 +147,8 @@ class AudioHandle /** Starts the Audio using the non-interleaving callback. */ Result Start(AudioCallback callback); - /** Starts the Audio using the interleaving callback. - ** For now only two channels are supported via this method. + /** Starts the Audio using the interleaving callback. + ** For now only two channels are supported via this method. */ Result Start(InterleavingAudioCallback callback); diff --git a/src/hid/ctrl.cpp b/src/hid/ctrl.cpp index a9662be40..e2e36a60f 100644 --- a/src/hid/ctrl.cpp +++ b/src/hid/ctrl.cpp @@ -51,4 +51,4 @@ void AnalogControl::SetSampleRate(float sample_rate) samplerate_ = sample_rate; float slew = is_bipolar_ ? .002f : slew_seconds_; SetCoeff(1.0f / (slew * samplerate_ * 0.5f)); -} \ No newline at end of file +} diff --git a/src/hid/ctrl.h b/src/hid/ctrl.h index b915bc830..e29fad68f 100644 --- a/src/hid/ctrl.h +++ b/src/hid/ctrl.h @@ -7,9 +7,9 @@ namespace daisy { /** - @brief Hardware Interface for control inputs \n - Primarily designed for ADC input controls such as \n - potentiometers, and control voltage. \n + @brief Hardware Interface for control inputs \n + Primarily designed for ADC input controls such as \n + potentiometers, and control voltage. \n @author Stephen Hensley @date November 2019 @ingroup controls @@ -22,7 +22,7 @@ class AnalogControl /** destructor */ ~AnalogControl() {} - /** + /** Initializes the control \param *adcptr is a pointer to the raw adc read value -- This can be acquired with dsy_adc_get_rawptr(), or dsy_adc_get_mux_rawptr() \param sr is the samplerate in Hz that the Process function will be called at. @@ -36,7 +36,7 @@ class AnalogControl bool invert = false, float slew_seconds = 0.002f); - /** + /** This Initializes the AnalogControl for a -5V to 5V inverted input All of the Init details are the same otherwise \param *adcptr Pointer to analog digital converter @@ -44,9 +44,9 @@ class AnalogControl */ void InitBipolarCv(uint16_t *adcptr, float sr); - /** + /** Filters, and transforms a raw ADC read into a normalized range. - this should be called at the rate of specified by samplerate at Init time. + this should be called at the rate of specified by samplerate at Init time. Default Initializations will return 0.0 -> 1.0 Bi-polar CV inputs will return -1.0 -> 1.0 */ @@ -55,7 +55,7 @@ class AnalogControl /** Returns the current stored value, without reprocessing */ inline float Value() const { return val_; } - /** Directly set the Coefficient of the one pole smoothing filter. + /** Directly set the Coefficient of the one pole smoothing filter. \param val Value to set coefficient to. Max of 1, min of 0. */ // using conditionals since clamp() is unavailable diff --git a/src/hid/disp/display.h b/src/hid/disp/display.h index 0ef3cdba8..0e0155227 100644 --- a/src/hid/disp/display.h +++ b/src/hid/disp/display.h @@ -12,7 +12,7 @@ namespace daisy { -/** +/** * This interface is used as a base class for all types of 1bit-per-pixel * graphics displays. */ @@ -34,7 +34,7 @@ class OneBitGraphicsDisplay size_t CurrentX() { return currentX_; }; size_t CurrentY() { return currentY_; }; - /** + /** Fills the entire display with either on/off. \param on Sets on or off. */ @@ -126,7 +126,7 @@ class OneBitGraphicsDisplay DrawArc(x, y, radius, 0, 360, on); }; - /** + /** Writes the character with the specific FontDef to the display buffer at the current Cursor position. \param ch character to be written @@ -136,7 +136,7 @@ class OneBitGraphicsDisplay */ virtual char WriteChar(char ch, FontDef font, bool on) = 0; - /** + /** Similar to WriteChar, except it will handle an entire String. Wrapping does not happen automatically, so the width of the string must be kept within the dimensions of the screen. @@ -147,7 +147,7 @@ class OneBitGraphicsDisplay */ virtual char WriteString(const char* str, FontDef font, bool on) = 0; - /** + /** Similar to WriteString but justified within a bounding box. \param str string to be written \param font font to use @@ -163,7 +163,7 @@ class OneBitGraphicsDisplay bool on) = 0; - /** + /** Moves the 'Cursor' position used for WriteChar, and WriteStr to the specified coordinate. \param x x pos \param y y pos @@ -174,8 +174,8 @@ class OneBitGraphicsDisplay currentY_ = (y >= Height()) ? Height() - 1 : y; } - /** - Writes the current display buffer to the OLED device using SPI or I2C depending on + /** + Writes the current display buffer to the OLED device using SPI or I2C depending on how the object was initialized. */ virtual void Update() = 0; @@ -186,30 +186,30 @@ class OneBitGraphicsDisplay }; /** This class is intended as a intermediary class for your actual implementation of the OneBitGraphicsDisplay - * interface. It uses the CRTP design pattern where the template argument is the child class. It provides + * interface. It uses the CRTP design pattern where the template argument is the child class. It provides * implementations for most of the functions, except DrawPixel(), Update() and Fill(), which you'll have * to provide in your child class. - * The main goal of this class is to provide common drawing functions without relying on massive amounts of + * The main goal of this class is to provide common drawing functions without relying on massive amounts of * virtual function calls that would result in a performance loss. To achieve this, any drawing function that * is implemented here and internally calls other drawing functions (e.g. DrawRect() which internally calls - * DrawPixel() and DrawLine()) makes these calls via the qualified name of these functions to explicitly + * DrawPixel() and DrawLine()) makes these calls via the qualified name of these functions to explicitly * suppress the virtual dispatch mechanism like this: - * + * * ChildType::DrawPixel(...); // no virtual function call; direct call into the child class function - * - * To create a custom OneBitGraphicsDisplay implementation, you can + * + * To create a custom OneBitGraphicsDisplay implementation, you can * A) inherit from OneBitGraphicsDisplay directly and provide all the drawing functions yourself * B) Inherit from OneBitGraphicsDisplayImpl and only provide DrawPixel(), Fill() and Update() * like this: - * - * class MyDisplayClass : public OneBitGraphicsDisplayImpl + * + * class MyDisplayClass : public OneBitGraphicsDisplayImpl * { * public: * void Fill() override { ... }; * void DrawPixel(uint_fast8_t x, uint_fast8_t y, bool on) override { ... }; * void Update() override { ... } * }; - * + * */ template class OneBitGraphicsDisplayImpl : public OneBitGraphicsDisplay diff --git a/src/hid/disp/graphics_common.h b/src/hid/disp/graphics_common.h index 412ee2805..689fb00aa 100644 --- a/src/hid/disp/graphics_common.h +++ b/src/hid/disp/graphics_common.h @@ -262,4 +262,4 @@ class Rectangle int16_t min(int16_t a, int16_t b) { return (a < b) ? a : b; } }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/hid/disp/oled_display.h b/src/hid/disp/oled_display.h index 6b2cd035e..1fd12b168 100644 --- a/src/hid/disp/oled_display.h +++ b/src/hid/disp/oled_display.h @@ -6,8 +6,8 @@ namespace daisy { -/** - * This class is for drawing to a monochrome OLED display. +/** + * This class is for drawing to a monochrome OLED display. * @ingroup device */ template @@ -27,7 +27,7 @@ class OledDisplay : public OneBitGraphicsDisplayImpl> uint16_t Height() const override { return driver_.Height(); } uint16_t Width() const override { return driver_.Width(); } - /** + /** Fills the entire display with either on/off. \param on Sets on or off. */ @@ -44,8 +44,8 @@ class OledDisplay : public OneBitGraphicsDisplayImpl> driver_.DrawPixel(x, y, on); } - /** - Writes the current display buffer to the OLED device using SPI or I2C depending on + /** + Writes the current display buffer to the OLED device using SPI or I2C depending on how the object was initialized. */ void Update() override { driver_.Update(); } diff --git a/src/hid/encoder.h b/src/hid/encoder.h index e2e7601b2..a8a132829 100644 --- a/src/hid/encoder.h +++ b/src/hid/encoder.h @@ -7,8 +7,8 @@ namespace daisy { -/** - @brief Generic Class for handling Quadrature Encoders \n +/** + @brief Generic Class for handling Quadrature Encoders \n Inspired/influenced by Mutable Instruments (pichenettes) Encoder classes @author Stephen Hensley @date December 2019 diff --git a/src/hid/gatein.cpp b/src/hid/gatein.cpp index c5f4a44c1..bb49f1b44 100644 --- a/src/hid/gatein.cpp +++ b/src/hid/gatein.cpp @@ -19,4 +19,4 @@ bool GateIn::Trig() prev_state_ = state_; state_ = invert_ ? !dsy_gpio_read(&pin_) : dsy_gpio_read(&pin_); return state_ && !prev_state_; -} \ No newline at end of file +} diff --git a/src/hid/gatein.h b/src/hid/gatein.h index 954b68a73..45fd9ec67 100644 --- a/src/hid/gatein.h +++ b/src/hid/gatein.h @@ -14,12 +14,12 @@ namespace daisy class GateIn { public: - /** GateIn - Constructor + /** GateIn + Constructor */ GateIn() {} /** GateIn~ - Destructor + Destructor */ ~GateIn() {} diff --git a/src/hid/led.h b/src/hid/led.h index e4f38aa66..8bb34e29b 100644 --- a/src/hid/led.h +++ b/src/hid/led.h @@ -12,7 +12,7 @@ namespace daisy { /** - @brief LED Class providing simple Software PWM ability, etc \n + @brief LED Class providing simple Software PWM ability, etc \n Eventually this will work with hardware PWM, and external LED Driver devices as well. @author shensley @date March 2020 @@ -24,7 +24,7 @@ class Led Led() {} ~Led() {} - /** + /** Initializes an LED using the specified hardware pin. \param pin chooses LED pin \param invert will set whether to internally invert the brightness due to hardware config. @@ -32,14 +32,14 @@ class Led */ void Init(dsy_gpio_pin pin, bool invert, float samplerate = 1000.0f); - /** + /** Sets the brightness of the Led. \param val will be cubed for gamma correction, and then quantized to 8-bit values for Software PWM 8-bit is for more flexible update rate options, as 12-bit or more would require faster update rates. */ void Set(float val); - /** + /** This processes the pwm of the LED sets the hardware accordingly. */ diff --git a/src/hid/logger.cpp b/src/hid/logger.cpp index a95ff2a6d..f4f215329 100644 --- a/src/hid/logger.cpp +++ b/src/hid/logger.cpp @@ -84,7 +84,7 @@ void Logger::TransmitBuf() tx_ptr_ = 0; } /** otherwise do not reset tx_ptr_ - * accumulate data while buffer size permits + * accumulate data while buffer size permits */ } } diff --git a/src/hid/logger.h b/src/hid/logger.h index 69fbdfa1b..bb67a8996 100644 --- a/src/hid/logger.h +++ b/src/hid/logger.h @@ -9,26 +9,26 @@ namespace daisy { -/** +/** * @addtogroup hid_logging LOGGING * @brief Intefaces for Logging over USB, etc. * @ingroup human_interface * @ingroup libdaisy - * + * * The following is a short example of using the DaisySeed::Logger * to print to a serial port. * @include SerialPrint.cpp * @{ */ -/** @defgroup logging_macros LoggerHelperMacros +/** @defgroup logging_macros LoggerHelperMacros * @{ */ /** Logger configuration */ #define LOGGER_NEWLINE "\r\n" /**< custom newline character sequence */ #define LOGGER_BUFFER 128 /**< size in bytes */ -/** +/** * Helper macros for string concatenation and macro expansion */ #define PPCAT_NX(A, B) A##B /**< non-expanding concatenation */ @@ -43,7 +43,7 @@ namespace daisy #define FLT_FMT(_n) STRINGIZE(PPCAT(PPCAT(%c%d.%0, _n), d)) // clang-format on -/** Floating point output variable preprocessing +/** Floating point output variable preprocessing * Note: uses truncation instead of rounding -> the last digit may be off */ #define FLT_VAR(_n, _x) \ @@ -62,10 +62,10 @@ namespace daisy /** @brief Interface for simple USB logging * @author Alexander Petrov-Savchenko (axp@soft-amp.com) * @date November 2020 - * + * * Simple Example: * @include SerialPrint.cpp - * + * */ template class Logger @@ -83,7 +83,7 @@ class Logger */ static void PrintLine(const char* format, ...); - /** Start the logging session. + /** Start the logging session. * \param wait_for_pc block until remote terminal is ready */ static void StartLog(bool wait_for_pc = false); @@ -102,7 +102,7 @@ class Logger enum LoggerConsts { LOGGER_SYNC_OUT = 0, - LOGGER_SYNC_IN = 2 /**< successfully transmit this many packets + LOGGER_SYNC_IN = 2 /**< successfully transmit this many packets * before switching to blocking transfers */ }; diff --git a/src/hid/logger_impl.h b/src/hid/logger_impl.h index d739cdf9b..4ab83a107 100644 --- a/src/hid/logger_impl.h +++ b/src/hid/logger_impl.h @@ -63,7 +63,7 @@ class LoggerImpl } protected: - /** USB Handle for CDC transfers + /** USB Handle for CDC transfers */ static UsbHandle usb_handle_; }; @@ -95,7 +95,7 @@ class LoggerImpl } protected: - /** USB Handle for CDC transfers + /** USB Handle for CDC transfers */ static UsbHandle usb_handle_; }; diff --git a/src/hid/midi.h b/src/hid/midi.h index 16dcd1dc6..c1b2fac63 100644 --- a/src/hid/midi.h +++ b/src/hid/midi.h @@ -15,7 +15,7 @@ namespace daisy { -/** @brief Transport layer for sending and receiving MIDI data over UART +/** @brief Transport layer for sending and receiving MIDI data over UART * @details This is the mode of communication used for TRS and DIN MIDI * @ingroup midi */ @@ -69,9 +69,9 @@ class MidiUartTransport UartHandler uart_; }; -/** - @brief Simple MIDI Handler \n - Parses bytes from an input into valid MidiEvents. \n +/** + @brief Simple MIDI Handler \n + Parses bytes from an input into valid MidiEvents. \n The MidiEvents fill a FIFO queue that the user can pop messages from. @author shensley @date March 2020 @@ -89,7 +89,7 @@ class MidiHandler typename Transport::Config transport_config; }; - /** Initializes the MidiHandler + /** Initializes the MidiHandler * \param config Configuration structure used to define specifics to the MIDI Handler. */ void Init(Config config) @@ -128,7 +128,7 @@ class MidiHandler } } - /** Checks if there are unhandled messages in the queue + /** Checks if there are unhandled messages in the queue \return True if there are events to be handled, else false. */ bool HasEvents() const { return event_q_.readable(); } @@ -345,7 +345,7 @@ class MidiHandler }; /** - * @{ + * @{ * @ingroup midi * @brief shorthand accessors for MIDI Handlers * */ diff --git a/src/hid/parameter.cpp b/src/hid/parameter.cpp index 368b2ff8a..9c9a09a26 100644 --- a/src/hid/parameter.cpp +++ b/src/hid/parameter.cpp @@ -32,4 +32,4 @@ float Parameter::Process() default: break; } return val_; -} \ No newline at end of file +} diff --git a/src/hid/parameter.h b/src/hid/parameter.h index 394c37b8d..0a64f6f0e 100644 --- a/src/hid/parameter.h +++ b/src/hid/parameter.h @@ -39,7 +39,7 @@ class Parameter */ float Process(); - /** + /** \return the current value from the parameter without processing another sample. this is useful if you need to use the value multiple times, and don't store diff --git a/src/hid/rgb_led.h b/src/hid/rgb_led.h index 382df448f..7cda567fb 100644 --- a/src/hid/rgb_led.h +++ b/src/hid/rgb_led.h @@ -26,7 +26,7 @@ class RgbLed void Init(dsy_gpio_pin red, dsy_gpio_pin green, dsy_gpio_pin blue, bool invert); - /** Sets each element of the LED with a floating point number 0-1 + /** Sets each element of the LED with a floating point number 0-1 \param r Red element \param g Green element \param b Blue element diff --git a/src/hid/switch.h b/src/hid/switch.h index f6bc87509..e061e8164 100644 --- a/src/hid/switch.h +++ b/src/hid/switch.h @@ -7,8 +7,8 @@ namespace daisy { -/** - Generic Class for handling momentary/latching switches \n +/** + Generic Class for handling momentary/latching switches \n Inspired/influenced by Mutable Instruments (pichenettes) Switch classes @author Stephen Hensley @date December 2019 @@ -41,7 +41,7 @@ class Switch Switch() {} ~Switch() {} - /** + /** Initializes the switch object with a given port/pin combo. \param pin port/pin object to tell the switch which hardware pin to use. \param update_rate Does nothing. Backwards compatibility until next breaking update. @@ -59,7 +59,7 @@ class Switch */ void Init(dsy_gpio_pin pin, float update_rate = 0.f); - /** + /** Called at update_rate to debounce and handle timing for the switch. In order for events not to be missed, its important that the Edge/Pressed checks be made at the same rate as the debounce function is being called. diff --git a/src/hid/usb.h b/src/hid/usb.h index a6f39f62e..517e706ef 100644 --- a/src/hid/usb.h +++ b/src/hid/usb.h @@ -10,7 +10,7 @@ namespace daisy */ { -/** +/** @brief Interface for initializing and using the USB Peripherals on the daisy @author Stephen Hensley @date December 2019 @@ -51,7 +51,7 @@ class UsbHandle */ void DeInit(UsbPeriph dev); - /** Transmits a buffer of 'size' bytes from the on board USB FS port. + /** Transmits a buffer of 'size' bytes from the on board USB FS port. \param buff Buffer to transmit \param size Buffer size */ diff --git a/src/hid/usb_host.cpp b/src/hid/usb_host.cpp index f3c1ea6b4..29798792d 100644 --- a/src/hid/usb_host.cpp +++ b/src/hid/usb_host.cpp @@ -180,4 +180,4 @@ static void USBH_UserProcess(USBH_HandleTypeDef *phost, uint8_t id) break; default: break; } -} \ No newline at end of file +} diff --git a/src/hid/usb_host.h b/src/hid/usb_host.h index 102b5ae5a..969b6fd49 100644 --- a/src/hid/usb_host.h +++ b/src/hid/usb_host.h @@ -6,7 +6,7 @@ namespace daisy { /** Status of USB Host application - * + * */ typedef enum { @@ -16,7 +16,7 @@ typedef enum APPLICATION_DISCONNECT } ApplicationTypeDef; -/** +/** @author Gabriel Ball @date September 16, 2021 @@ -25,10 +25,10 @@ typedef enum class USBHostHandle { public: - /** @brief return codes from the USB Processing + /** @brief return codes from the USB Processing * can be used to check the state of USB while running * outside of what may be happening with the limited user callbacks. - * + * * At this time, these correlate directly to the ST Middleware * USBH_StatusTypeDef codes */ @@ -48,19 +48,19 @@ class USBHostHandle /** @brief User defineable callback for USB Disconnection */ typedef void (*DisconnectCallback)(void* data); - /** @brief User defineable callback upon completion of class initialization - * For example, when a USB drive is connected and the mass storage class + /** @brief User defineable callback upon completion of class initialization + * For example, when a USB drive is connected and the mass storage class * initialization has finished, this callback will fire. - * + * * @param userdata a pointer to some arbitrary data for use by the user. * this is supplied in the Config struct. Can be used to avoid globals. - * + * * @todo At some point this may be replaced for individual callbacks * for each supported USB Host class. */ typedef void (*ClassActiveCallback)(void* userdata); - /** @brief User defineable callback for USB Unrecoverable Error + /** @brief User defineable callback for USB Unrecoverable Error * @todo add some sort of feedback about the type of error, etc. * if possible */ @@ -85,18 +85,18 @@ class USBHostHandle }; /** Initializes the USB drivers and starts timeout. - * + * * \param config Configuration struct for initialization */ Result Init(Config config); /** Deinitializes MSD-related peripherals - * + * */ Result Deinit(); /** Manages usb host functionality - * + * */ Result Process(); @@ -105,13 +105,13 @@ class USBHostHandle /** Returns true if a Mass Storage Device is connected * and ready for communicaton - * + * */ bool GetReady(); /** Run after the first `Process` call to detect if * a device is present - * + * */ bool GetPresent(); @@ -127,4 +127,4 @@ class USBHostHandle } // namespace daisy -#endif // DSY_MSD \ No newline at end of file +#endif // DSY_MSD diff --git a/src/hid/usb_midi.cpp b/src/hid/usb_midi.cpp index 8686e868f..1dddd1001 100644 --- a/src/hid/usb_midi.cpp +++ b/src/hid/usb_midi.cpp @@ -23,7 +23,7 @@ class MidiUsbTransport::Impl private: void MidiToUsbSingle(uint8_t* buffer, size_t length); - /** USB Handle for CDC transfers + /** USB Handle for CDC transfers */ UsbHandle usb_handle_; Config config_; @@ -299,4 +299,4 @@ void MidiUsbTransport::FlushRx() void MidiUsbTransport::Tx(uint8_t* buffer, size_t size) { pimpl_->Tx(buffer, size); -} \ No newline at end of file +} diff --git a/src/hid/usb_midi.h b/src/hid/usb_midi.h index 944ff37e7..04bcf0406 100644 --- a/src/hid/usb_midi.h +++ b/src/hid/usb_midi.h @@ -8,7 +8,7 @@ namespace daisy { -/** @brief USB Transport for MIDI +/** @brief USB Transport for MIDI * @ingroup midi */ class MidiUsbTransport @@ -49,4 +49,4 @@ class MidiUsbTransport } // namespace daisy -#endif // __DSY_MIDIUSBTRANSPORT_H__ \ No newline at end of file +#endif // __DSY_MIDIUSBTRANSPORT_H__ diff --git a/src/hid/wavplayer.h b/src/hid/wavplayer.h index 481949d72..6fec19cf5 100644 --- a/src/hid/wavplayer.h +++ b/src/hid/wavplayer.h @@ -25,7 +25,7 @@ struct WavFileInfo char name[WAV_FILENAME_MAX]; /**< Wav filename */ }; -/* +/* TODO: - Make template-y to reduce memory usage. */ @@ -62,7 +62,7 @@ class WavPlayer /** Resets the playback position to the beginning of the file immediately */ void Restart(); - /** Sets whether or not the current file will repeat after completing playback. + /** Sets whether or not the current file will repeat after completing playback. \param loop To loop or not to loop. */ inline void SetLooping(bool loop) { looping_ = loop; } diff --git a/src/per/adc.h b/src/per/adc.h index bb3161a04..2bda9b4b1 100644 --- a/src/per/adc.h +++ b/src/per/adc.h @@ -19,9 +19,9 @@ using a struct like this allows us to add more configuration later without breaking existing functionality. */ -/** @brief Configuration Structure for an ADC Channel - * @details This can be used to configure a a single input, - * or a multiplexed input, allowing up to 8 inputs on +/** @brief Configuration Structure for an ADC Channel + * @details This can be used to configure a a single input, + * or a multiplexed input, allowing up to 8 inputs on * one channel. * @note Sharing data lines to multiple muxes _is_ possible, but * each channel sharing data lines must be set to the maximum @@ -39,12 +39,12 @@ struct AdcChannelConfig MUX_SEL_LAST, /**< & */ }; - /** Initializes a single ADC pin as an ADC. + /** Initializes a single ADC pin as an ADC. \param pin Pin to init. */ void InitSingle(dsy_gpio_pin pin); - /** + /** Initializes a single ADC pin as a Multiplexed ADC. Requires a CD405X Multiplexer connected to the pin. You only need to supply the mux pins that are required, @@ -91,7 +91,7 @@ class AdcHandle AdcHandle() {} ~AdcHandle() {} - /** + /** Initializes the ADC with the pins passed in. \param *cfg an array of AdcChannelConfig of the desired channel \param num_channels number of ADC channels to initialize @@ -106,7 +106,7 @@ class AdcHandle /** Stops reading from the ADC */ void Stop(); - /** + /** Single channel getter \param chn channel to get \return Converted value @@ -120,7 +120,7 @@ class AdcHandle */ uint16_t *GetPtr(uint8_t chn) const; - /** + /** Get floating point from single channel \param chn Channel to get from \return Floating point converted value @@ -128,7 +128,7 @@ class AdcHandle float GetFloat(uint8_t chn) const; /** - Getters for multiplexed inputs on a single channel (up to 8 per ADC input). + Getters for multiplexed inputs on a single channel (up to 8 per ADC input). \param chn Channel to get from \param idx & \return data @@ -144,7 +144,7 @@ class AdcHandle uint16_t *GetMuxPtr(uint8_t chn, uint8_t idx) const; /** - Getters for multiplexed inputs on a single channel (up to 8 per ADC input). + Getters for multiplexed inputs on a single channel (up to 8 per ADC input). \param chn Channel to get from \param idx & \return Floating point data diff --git a/src/per/dac.cpp b/src/per/dac.cpp index 23c34bf20..ebe93385b 100644 --- a/src/per/dac.cpp +++ b/src/per/dac.cpp @@ -169,7 +169,7 @@ DacHandle::Impl::Start(uint16_t *buffer, size_t size, DacHandle::DacCallback cb) return Result::OK; } -/** Not fully implemented -- I had the intention of setting up both DACs to work from a single callback, which +/** Not fully implemented -- I had the intention of setting up both DACs to work from a single callback, which ** it seems like will require a bit more setup in the Init (basically set it to dual mode). */ DacHandle::Result DacHandle::Impl::Start(uint16_t * buffer_1, uint16_t * buffer_2, diff --git a/src/per/dac.h b/src/per/dac.h index 01db93d51..5aa75b167 100644 --- a/src/per/dac.h +++ b/src/per/dac.h @@ -6,9 +6,9 @@ namespace daisy { -/** @brief DAC handle for Built-in DAC Peripheral +/** @brief DAC handle for Built-in DAC Peripheral * @ingroup per_analog - ** + ** ** For now only Normal Mode is supported, ** Sample and hold mode provides reduced power consumption, but requires a bit more setup. ** @@ -40,7 +40,7 @@ class DacHandle ** ** Polling mode uses the blocking mode to transmit a single value at a time. ** - ** DMA mode uses a buffer, and periodically transmits it triggering a + ** DMA mode uses a buffer, and periodically transmits it triggering a ** callback to fill the buffer when it is ready for more samples. ***/ enum class Mode @@ -51,7 +51,7 @@ class DacHandle /** Sets the number of bits per sample transmitted out of the DAC. ** The output range will be: 0V - VDDA - ** The resolution will be roughly: bitdepth / (VDDA - 0V) + ** The resolution will be roughly: bitdepth / (VDDA - 0V) ***/ enum class BitDepth { @@ -69,9 +69,9 @@ class DacHandle /** Configuration structure for initializing the DAC structure. */ struct Config { - /** Target Samplerate in Hz used to configure the internal + /** Target Samplerate in Hz used to configure the internal ** timebase for DMA mode. Does nothing in POLLING mode. - ** If the value is 0 at Init time this will default to 48000Hz + ** If the value is 0 at Init time this will default to 48000Hz ** otherwise the driver will attempt meet the target.*/ uint32_t target_samplerate; @@ -85,10 +85,10 @@ class DacHandle DacHandle(const DacHandle &other) = default; DacHandle &operator=(const DacHandle &other) = default; - /** Callback for DMA transfers. This is called every time half + /** Callback for DMA transfers. This is called every time half ** of the samples of the buffer are transmitted, and the buffer is ready ** to be filled again. - ** + ** ** The data is organized in arrays per channel, for example if both channels are in use: ** { {ch1-0, ch1-1, ch1-2 . . . ch1-N}, {ch2-0, ch2-1, ch2-2 . . . ch2--N} } ** @@ -99,14 +99,14 @@ class DacHandle Result Init(const Config &config); const Config &GetConfig() const; - /** Starts the DAC conversion on the DMA calling the user callback - ** whenever new samples are ready to be filled. + /** Starts the DAC conversion on the DMA calling the user callback + ** whenever new samples are ready to be filled. ** ** This will return Result::ERR if used when configured to BOTH channels. */ Result Start(uint16_t *buffer, size_t size, DacCallback cb); - /** If using both channels, use this function to start the DMA transfer for both. + /** If using both channels, use this function to start the DMA transfer for both. ** The callback will provide an array per-channel to fill. */ Result Start(uint16_t *buffer_1, uint16_t *buffer_2, size_t size, DacCallback cb); @@ -114,7 +114,7 @@ class DacHandle /** Stops the DAC channel(s). */ Result Stop(); - /** Sets and Writes value in Polling Mode + /** Sets and Writes value in Polling Mode ** Has no effect in DMA mode.*/ Result WriteValue(Channel chn, uint16_t val); diff --git a/src/per/gpio.h b/src/per/gpio.h index e212681bb..f015d5068 100644 --- a/src/per/gpio.h +++ b/src/per/gpio.h @@ -7,16 +7,16 @@ namespace daisy { -/** @brief General Purpose I/O control +/** @brief General Purpose I/O control * @details peripheral control over a single GPIO * @ingroup peripheral - * + * * Button Input (with internal Pullup resistor) - * @include GPIO_Input.cpp - * + * @include GPIO_Input.cpp + * * Output Example (perfect for blinking an LED) * @include GPIO_Output.cpp - * + * */ class GPIO { @@ -30,13 +30,13 @@ class GPIO ANALOG, /**< Analog for connection to ADC or DAC peripheral */ }; - /** @brief Configures whether an internal Pull up or Pull down resistor is used. - * + /** @brief Configures whether an internal Pull up or Pull down resistor is used. + * * Internal Pull up/down resistors are typically 40k ohms, and will be between * 30k and 50k - * + * * When the Pin is configured in Analog mode, the pull up/down resistors are - * disabled by hardware. + * disabled by hardware. */ enum class Pull { @@ -63,7 +63,7 @@ class GPIO Speed speed; /** Constructor with no arguments will prepare an invalid GPIO set as - * an input, with no pullup. + * an input, with no pullup. */ Config() : pin(), mode(Mode::INPUT), pull(Pull::NOPULL), speed(Speed::LOW) @@ -73,19 +73,19 @@ class GPIO GPIO() {} - /** @brief Initialize the GPIO from a Config struct + /** @brief Initialize the GPIO from a Config struct * @param cfg reference to a Config struct populated with the desired settings */ void Init(const Config &cfg); - /** @brief Initialize the GPIO with a Configuration struct, and explicit pin + /** @brief Initialize the GPIO with a Configuration struct, and explicit pin * @param p Pin specifying the physical connection on the hardware - * @param cfg reference to a Config struct populated with the desired settings. + * @param cfg reference to a Config struct populated with the desired settings. * Config::pin will be overwritten */ void Init(Pin p, const Config &cfg); - /** @brief Explicity initialize all configuration for the GPIO + /** @brief Explicity initialize all configuration for the GPIO * @param p Pin specifying the physical connection on the hardware * @param m Mode specifying the behavior of the GPIO (input, output, etc.). Defaults to Mode::INPUT * @param pu Pull up/down state for the GPIO. Defaults to Pull::NOPULL @@ -104,12 +104,12 @@ class GPIO */ bool Read(); - /** @brief Changes the state of the GPIO hardware when configured as an OUTPUT. + /** @brief Changes the state of the GPIO hardware when configured as an OUTPUT. * @param state setting true writes an output HIGH, while setting false writes an output LOW. */ void Write(bool state); - /** @brief flips the current state of the GPIO. + /** @brief flips the current state of the GPIO. * If it was HIGH, it will go LOW, and vice versa. */ void Toggle(); @@ -118,13 +118,13 @@ class GPIO Config &GetConfig() { return cfg_; } private: - /** This will internally be cast to the - * STM32H7 GPIO_Typedef* type, which + /** This will internally be cast to the + * STM32H7 GPIO_Typedef* type, which * is just the base address to the - * specified GPIO register. - * + * specified GPIO register. + * * This prevents us needing to have an internal - * Impl class just to store the GPIO_Typedef* + * Impl class just to store the GPIO_Typedef* */ uint32_t *GetGPIOBaseRegister(); @@ -140,10 +140,10 @@ class GPIO /** @ingroup peripheral * @addtogroup DEPRECATED-OLD-GPIO - * - * @brief Deprecated C API for GPIO is staying in place for a + * + * @brief Deprecated C API for GPIO is staying in place for a * few versions to support backwards compatibility. - * + * * This should not be used for anything new. * @deprecated These should only be used for casting to configs, and are planned to be reomved in a future version. * @{ @@ -178,23 +178,23 @@ extern "C" dsy_gpio_pull pull; /**< & */ } dsy_gpio; - /** Initializes the gpio with the settings configured. + /** Initializes the gpio with the settings configured. \param *p Pin pointer */ void dsy_gpio_init(const dsy_gpio *p); - /** Deinitializes the gpio pin + /** Deinitializes the gpio pin \param *p Pin pointer */ void dsy_gpio_deinit(const dsy_gpio *p); - /** + /** Reads the state of the gpio pin - \param *p Pin pointer + \param *p Pin pointer \return 1 if the pin is HIGH, and 0 if the pin is LOW */ uint8_t dsy_gpio_read(const dsy_gpio *p); - /** + /** Writes the state to the gpio pin Pin will be set to 3v3 when state is 1, and 0V when state is 0 \param *p Pin pointer diff --git a/src/per/i2c.h b/src/per/i2c.h index f7d7a89d1..70f44fc94 100644 --- a/src/per/i2c.h +++ b/src/per/i2c.h @@ -7,7 +7,7 @@ namespace daisy * gateway that internally points to one of the four I2C peripherals * after it was initialised. It can then be copied and passed around. * Use an I2CHandle like this: - * + * * // setup the configuration * I2CHandle::Config i2c_conf; * i2c_conf.periph = I2CHandle::Config::Peripheral::I2C_1; @@ -91,7 +91,7 @@ class I2CHandle /** Transmits data and blocks until the transmission is complete. * Use this for smaller transmissions of a few bytes. - * + * * \param address The slave device address. Unused in slave mode. * \param data A pointer to the data to be sent. * \param size The size of the data to be sent, in bytes. @@ -104,7 +104,7 @@ class I2CHandle /** Receives data and blocks until the reception is complete. * Use this for smaller transmissions of a few bytes. - * + * * \param address The slave device address. Unused in slave mode. * \param data A pointer to the data to be received. * \param size The size of the data to be received, in bytes. @@ -119,23 +119,23 @@ class I2CHandle typedef void (*CallbackFunctionPtr)(void* context, Result result); /** Transmits data with a DMA and returns immediately. Use this for larger transmissions. - * The pointer to data must be located in the D2 memory domain by adding the + * The pointer to data must be located in the D2 memory domain by adding the * `DMA_BUFFER_MEM_SECTION` attribute like this: * uint8_t DMA_BUFFER_MEM_SECTION my_buffer[100]; - * If that is not possible for some reason, you MUST clear the cachelines spanning the size of - * the buffer, before initiating the dma transfer by calling + * If that is not possible for some reason, you MUST clear the cachelines spanning the size of + * the buffer, before initiating the dma transfer by calling * `dsy_dma_clear_cache_for_buffer(buffer, size);` - * + * * A single DMA is shared across I2C1, I2C2 and I2C3. I2C4 has no DMA support (yet). * If the DMA is busy with another transfer, the job will be queued and executed later. * If there is a job waiting to be executed for this I2C peripheral, this function * will block until the queue is free and the job can be queued. - * + * * \param address The slave device address. Unused in slave mode. * \param data A pointer to the data to be sent. * \param size The size of the data to be sent, in bytes. * \param callback A callback to execute when the transfer finishes, or NULL. - * \param callback_context A pointer that will be passed back to you in the callback. + * \param callback_context A pointer that will be passed back to you in the callback. */ Result TransmitDma(uint16_t address, uint8_t* data, @@ -144,23 +144,23 @@ class I2CHandle void* callback_context); /** Receives data with a DMA and returns immediately. Use this for larger transmissions. - * The pointer to data must be located in the D2 memory domain by adding the + * The pointer to data must be located in the D2 memory domain by adding the * `DMA_BUFFER_MEM_SECTION` attribute like this: * uint8_t DMA_BUFFER_MEM_SECTION my_buffer[100]; - * If that is not possible for some reason, you MUST clear the cachelines spanning the size of - * the buffer, before initiating the dma transfer by calling + * If that is not possible for some reason, you MUST clear the cachelines spanning the size of + * the buffer, before initiating the dma transfer by calling * `dsy_dma_clear_cache_for_buffer(buffer, size);` - * + * * A single DMA is shared across I2C, I2C2 and I2C3. I2C4 has no DMA support (yet). * If the DMA is busy with another transfer, the job will be queued and executed later. * If there is a job waiting to be executed for this I2C peripheral, this function * will block until the queue is free and the job can be queued. - * + * * \param address The slave device address. Unused in slave mode. * \param data A pointer to the data buffer. * \param size The size of the data to be received, in bytes. * \param callback A callback to execute when the transfer finishes, or NULL. - * \param callback_context A pointer that will be passed back to you in the callback. + * \param callback_context A pointer that will be passed back to you in the callback. */ Result ReceiveDma(uint16_t address, uint8_t* data, @@ -168,9 +168,9 @@ class I2CHandle CallbackFunctionPtr callback, void* callback_context); - /** Reads an amount of data from a specific memory address. - * This method will return an error if the I2C peripheral is in slave mode. - * + /** Reads an amount of data from a specific memory address. + * This method will return an error if the I2C peripheral is in slave mode. + * * \param address The slave device address. * \param mem_address Pointer to data containing the address to read from device. * \param mem_address_size Size of the memory address in bytes. @@ -185,9 +185,9 @@ class I2CHandle uint16_t data_size, uint32_t timeout); - /** Writes an amount of data from a specific memory address. - * This method will return an error if the I2C peripheral is in slave mode. - * + /** Writes an amount of data from a specific memory address. + * This method will return an error if the I2C peripheral is in slave mode. + * * \param address The slave device address. * \param mem_address Pointer to data containing the address to write to device. * \param mem_address_size Size of the memory address in bytes. @@ -215,4 +215,4 @@ extern "C" void dsy_i2c_global_init(); }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/per/qspi.cpp b/src/per/qspi.cpp index 17727910a..29101b642 100644 --- a/src/per/qspi.cpp +++ b/src/per/qspi.cpp @@ -982,28 +982,28 @@ extern "C" void QUADSPI_IRQHandler(void) /* HAL Overwrite Implementation */ -/**QUADSPI GPIO Configuration +/**QUADSPI GPIO Configuration On Daisy Rev3: PG6 ------> QUADSPI_BK1_NCS PF8 ------> QUADSPI_BK1_IO0 PF9 ------> QUADSPI_BK1_IO1 PF7 ------> QUADSPI_BK1_IO2 PF6 ------> QUADSPI_BK1_IO3 - PB2 ------> QUADSPI_CLK + PB2 ------> QUADSPI_CLK On Daisy Seed: PG6 ------> QUADSPI_BK1_NCS PF8 ------> QUADSPI_BK1_IO0 PF9 ------> QUADSPI_BK1_IO1 PF7 ------> QUADSPI_BK1_IO2 PF6 ------> QUADSPI_BK1_IO3 - PF10 ------> QUADSPI_CLK + PF10 ------> QUADSPI_CLK On Audio BB: PG6 ------> QUADSPI_BK1_NCS PF8 ------> QUADSPI_BK1_IO0 PF9 ------> QUADSPI_BK1_IO1 PE2 ------> QUADSPI_BK1_IO2 PF6 ------> QUADSPI_BK1_IO3 - PF10 ------> QUADSPI_CLK + PF10 ------> QUADSPI_CLK */ //enum //{ diff --git a/src/per/qspi.h b/src/per/qspi.h index b1da9efd4..de6c4c78f 100644 --- a/src/per/qspi.h +++ b/src/per/qspi.h @@ -22,9 +22,9 @@ namespace daisy @{ */ -/** - Driver for QSPI peripheral to interface with external flash memory. \n - Currently supported QSPI Devices: \n +/** + Driver for QSPI peripheral to interface with external flash memory. \n + Currently supported QSPI Devices: \n * IS25LP080D */ class QSPIHandle @@ -36,10 +36,10 @@ class QSPIHandle ERR }; - /** Indicates the current status of the module. + /** Indicates the current status of the module. * Warnings are indicated by a leading W. * Errors are indicated by a leading E and cause an immediate exit. - * + * * \param GOOD - No errors have been reported. * \param E_HAL_ERROR - HAL code did not return HAL_OK. * \param E_SWITCHING_MODES - An error was encountered while switching QSPI peripheral mode. @@ -64,12 +64,12 @@ class QSPIHandle DEVICE_LAST, /**< & */ }; - /** + /** Modes of operation. Memory Mapped mode: QSPI configured so that the QSPI can be read from starting address 0x90000000. Writing is not - possible in this mode. \n - Indirect Polling mode: Device driver enabled. + possible in this mode. \n + Indirect Polling mode: Device driver enabled. */ enum Mode { @@ -93,7 +93,7 @@ class QSPIHandle Mode mode; }; - /** + /** Initializes QSPI peripheral, and Resets, and prepares memory for access. \param config should be populated with the mode, device and pin_config before calling this function. \return Result::OK or Result::ERR @@ -105,14 +105,14 @@ class QSPIHandle // Couldn't this just be called before anything else in init? That // would make manually calling it unnecessary. - /** + /** Deinitializes the peripheral This should be called before reinitializing QSPI in a different mode. \return Result::OK or Result::ERR */ Result DeInit(); - /** + /** Writes a single page to to the specified address on the QSPI chip. For IS25LP*, page size is 256 bytes. \param address Address to write to @@ -122,8 +122,8 @@ class QSPIHandle */ Result WritePage(uint32_t address, uint32_t size, uint8_t* buffer); - /** - Writes data in buffer to to the QSPI. Starting at address to address+size + /** + Writes data in buffer to to the QSPI. Starting at address to address+size \param address Address to write to \param size Buffer size \param buffer Buffer to write @@ -131,7 +131,7 @@ class QSPIHandle */ Result Write(uint32_t address, uint32_t size, uint8_t* buffer); - /** + /** Erases the area specified on the chip. Erasures will happen by 4K, 32K or 64K increments. Smallest erase possible is 4kB at a time. (on IS25LP*) @@ -141,9 +141,9 @@ class QSPIHandle */ Result Erase(uint32_t start_addr, uint32_t end_addr); - /** - Erases a single sector of the chip. - TODO: Document the size of this function. + /** + Erases a single sector of the chip. + TODO: Document the size of this function. \param address Address of sector to erase \return Result::OK or Result::ERR */ @@ -154,11 +154,11 @@ class QSPIHandle */ Status GetStatus(); - /** Returns a pointer to the actual memory used + /** Returns a pointer to the actual memory used * The memory at this address is read-only * to write to it use the Write function. - * - * \param offset returns the pointer starting this + * + * \param offset returns the pointer starting this * many bytes into the memory */ void* GetData(uint32_t offset = 0); @@ -184,9 +184,9 @@ class QSPIHandle namespace daisy { -/** This is a dummy implementation for use in tests. - * In your tests you can use this as a placeholder - * for the physical volatile memory. +/** This is a dummy implementation for use in tests. + * In your tests you can use this as a placeholder + * for the physical volatile memory. * This provides a block of memory that can be erased, or written * to. */ @@ -199,7 +199,7 @@ class QSPIHandle ERR }; - /** A mock-only function for resetting the memory to clean state + /** A mock-only function for resetting the memory to clean state * This should be called at the beginning of any test to ensure that * data from a previous test does not interfere. */ @@ -243,7 +243,7 @@ class QSPIHandle return Result::OK; } - /** Returns a pointer to the actual memory used + /** Returns a pointer to the actual memory used */ static void* GetData(uint32_t offset = 0) { @@ -254,7 +254,7 @@ class QSPIHandle } /** Returns the current size of the memory vector. - * + * * This is not in the hardware class its just for testing purposes */ static size_t GetCurrentSize() diff --git a/src/per/rng.cpp b/src/per/rng.cpp index 2603d6d9f..bffd9d177 100644 --- a/src/per/rng.cpp +++ b/src/per/rng.cpp @@ -49,4 +49,4 @@ bool Random::IsReady() return ((RNG->SR & RNG_FLAG_DRDY) == RNG_FLAG_DRDY) == SET; } -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/per/rng.h b/src/per/rng.h index 06ef4d617..a640bae38 100644 --- a/src/per/rng.h +++ b/src/per/rng.h @@ -6,7 +6,7 @@ namespace daisy /** @brief True Random Number Generator access * @author shensley * @ingroup utility - * + * * Provides static access to the built-in True Random Number Generator */ class Random @@ -16,11 +16,11 @@ class Random ~Random() {} /** Initializes the Peripheral - * - * This is called from System::Init, + * + * This is called from System::Init, * so the GetValue, and GetFloat functions - * can be used without the application needing to - * manually initialize the RNG. + * can be used without the application needing to + * manually initialize the RNG. */ static void Init(); @@ -28,32 +28,32 @@ class Random static void DeInit(); /** Returns a randomly generated 32-bit number - * This is done by polling the peripheral, + * This is done by polling the peripheral, * and can block for up to 100ms. - * - * To avoid blocking issues, the IsReady function can be + * + * To avoid blocking issues, the IsReady function can be * used to check if a value is ready before calling this function. - * + * * If there is an issue with the peripheral, or a timeout occurs * the return value will be 0. - * + * * @return a 32-bit random number */ static uint32_t GetValue(); /** Returns a floating point value between the specified - * minimum and maximum. Calls GetValue() internally. - * + * minimum and maximum. Calls GetValue() internally. + * * \param min the minimum value to return, defaults to 0.f * \param max the maximum value to return, defaults to 1.f */ static float GetFloat(float min = 0.f, float max = 1.f); - /** Checks the peripheral to see if a new value is ready - * + /** Checks the peripheral to see if a new value is ready + * * @return true if conditioning has finished and a new value can be read */ static bool IsReady(); }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/per/sai.h b/src/per/sai.h index bec5c06e9..e1f0ebe2c 100644 --- a/src/per/sai.h +++ b/src/per/sai.h @@ -6,20 +6,20 @@ namespace daisy { -/** +/** * Support for I2S Audio Protocol with different bit-depth, samplerate options - * Allows for master or slave, as well as freedom of selecting direction, + * Allows for master or slave, as well as freedom of selecting direction, * and other behavior for each peripheral, and block. - * + * * DMA Transfer commands must use buffers located within non-cached memory or use cache maintenance * To declare an unitialized global element in the DMA memory section: * int32_t DSY_DMA_BUFFER_SECTOR my_buffer[96]; * - * Callback functions will be called once per half of the buffer. In the above example, + * Callback functions will be called once per half of the buffer. In the above example, * the callback function would be called once for every 48 samples. - * + * * Use SAI Handle like this: - * + * * SaiHandle::Config sai_config; * sai_config.periph = SaiHandle::Config::Peripheral::SAI_1; * sai_config.sr = SaiHandle::Config::SampleRate::SAI_48KHZ; @@ -70,7 +70,7 @@ class SaiHandle SAI_32BIT, }; - /** Specifies whether a particular block is the master or the slave + /** Specifies whether a particular block is the master or the slave ** If both are set to slave, no MCLK signal will be used, and it is ** expected that the codec will have its own xtal. */ @@ -118,16 +118,16 @@ class SaiHandle /** Returns the current configuration */ const Config& GetConfig() const; - /** Callback Function to be called when DMA transfer is complete and half complete. + /** Callback Function to be called when DMA transfer is complete and half complete. ** This callback is prepared however the data is transmitted/received from the device. ** For example, using an AK4556 the data will be interleaved 24bit MSB Justified - ** + ** ** The hid/audio class will be allow for type conversions, de-interleaving, etc. */ typedef void (*CallbackFunctionPtr)(int32_t* in, int32_t* out, size_t size); - /** Starts Rx and Tx in Circular Buffer Mode - ** The callback will be called when half of the buffer is ready, + /** Starts Rx and Tx in Circular Buffer Mode + ** The callback will be called when half of the buffer is ready, ** and will handle size/2 samples per callback. */ Result StartDma(int32_t* buffer_rx, @@ -141,12 +141,12 @@ class SaiHandle /** Returns the samplerate based on the current configuration */ float GetSampleRate(); - /** Returns the number of samples per audio block + /** Returns the number of samples per audio block ** Calculated as Buffer Size / 2 / number of channels */ size_t GetBlockSize(); - /** Returns the Block Rate of the current stream based on the size - ** of the buffer passed in, and the current samplerate. + /** Returns the Block Rate of the current stream based on the size + ** of the buffer passed in, and the current samplerate. */ float GetBlockRate(); diff --git a/src/per/sdmmc.cpp b/src/per/sdmmc.cpp index 600a10f97..6d62855ea 100644 --- a/src/per/sdmmc.cpp +++ b/src/per/sdmmc.cpp @@ -46,13 +46,13 @@ void HAL_SD_MspInit(SD_HandleTypeDef* sdHandle) __HAL_RCC_GPIOC_CLK_ENABLE(); __HAL_RCC_GPIOD_CLK_ENABLE(); - /**SDMMC1 GPIO Configuration + /**SDMMC1 GPIO Configuration PC12 ------> SDMMC1_CK PC11 ------> SDMMC1_D3 PC10 ------> SDMMC1_D2 PD2 ------> SDMMC1_CMD PC9 ------> SDMMC1_D1 - PC8 ------> SDMMC1_D0 + PC8 ------> SDMMC1_D0 */ // Adjust the gpio drive strength based on the clock divider, @@ -102,13 +102,13 @@ void HAL_SD_MspDeInit(SD_HandleTypeDef* sdHandle) /* Peripheral clock disable */ __HAL_RCC_SDMMC1_CLK_DISABLE(); - /**SDMMC1 GPIO Configuration + /**SDMMC1 GPIO Configuration PC12 ------> SDMMC1_CK PC11 ------> SDMMC1_D3 PC10 ------> SDMMC1_D2 PD2 ------> SDMMC1_CMD PC9 ------> SDMMC1_D1 - PC8 ------> SDMMC1_D0 + PC8 ------> SDMMC1_D0 */ HAL_GPIO_DeInit(GPIOC, GPIO_PIN_12 | GPIO_PIN_11 | GPIO_PIN_10 | GPIO_PIN_9 diff --git a/src/per/sdmmc.h b/src/per/sdmmc.h index 625704263..4c10a7d22 100644 --- a/src/per/sdmmc.h +++ b/src/per/sdmmc.h @@ -1,5 +1,5 @@ /* -TODO: +TODO: - Implement configuration (currently all settings are fixed). */ #pragma once @@ -17,7 +17,7 @@ namespace daisy /** Configuration for interfacing with SD cards. * Currently only supports operation using FatFS filesystem - * + * * Only SDMMC1 is supported at this time. * * Pins are fixed to the following: @@ -45,8 +45,8 @@ class SdmmcHandler BITS_4, /**< 4-bits of parallel data for each clock pulse */ }; - /** - Sets the desired clock speed of the SD card bus. \n + /** + Sets the desired clock speed of the SD card bus. \n Initialization is always done at or below 400kHz, and then the user speed is set. */ enum class Speed @@ -78,7 +78,7 @@ class SdmmcHandler ~SdmmcHandler() {} /** Configures the SDMMC Peripheral with the user defined settings. - * Initialization does not happen immediatly and will be called by the + * Initialization does not happen immediatly and will be called by the * filesystem (i.e. FatFS). */ Result Init(const Config& cfg); diff --git a/src/per/spi.h b/src/per/spi.h index 30e4e38c9..be4a58e8d 100644 --- a/src/per/spi.h +++ b/src/per/spi.h @@ -133,10 +133,10 @@ class SpiHandle typedef void (*EndCallbackFunctionPtr)(void* context, Result result); - /** Blocking transmit + /** Blocking transmit \param buff input buffer \param size buffer size - \param timeout how long in milliseconds the function will wait + \param timeout how long in milliseconds the function will wait before returning without successful communication */ Result BlockingTransmit(uint8_t* buff, size_t size, uint32_t timeout = 100); @@ -153,7 +153,7 @@ class SpiHandle \param tx_buff the transmit buffer \param rx_buff the receive buffer \param size the length of the transaction - \param timeout how long in milliseconds the function will wait + \param timeout how long in milliseconds the function will wait before returning without successful communication */ Result BlockingTransmitAndReceive(uint8_t* tx_buff, @@ -161,14 +161,14 @@ class SpiHandle size_t size, uint32_t timeout = 100); - /** DMA-based transmit + /** DMA-based transmit \param *buff input buffer \param size buffer size \param start_callback A callback to execute when the transfer starts, or NULL. The callback is called from an interrupt, so keep it fast. \param end_callback A callback to execute when the transfer finishes, or NULL. The callback is called from an interrupt, so keep it fast. - \param callback_context A pointer that will be passed back to you in the callbacks. + \param callback_context A pointer that will be passed back to you in the callbacks. \return Whether the transmit was successful or not */ Result DmaTransmit(uint8_t* buff, @@ -177,14 +177,14 @@ class SpiHandle SpiHandle::EndCallbackFunctionPtr end_callback, void* callback_context); - /** DMA-based receive + /** DMA-based receive \param *buff input buffer \param size buffer size \param start_callback A callback to execute when the transfer starts, or NULL. The callback is called from an interrupt, so keep it fast. \param end_callback A callback to execute when the transfer finishes, or NULL. The callback is called from an interrupt, so keep it fast. - \param callback_context A pointer that will be passed back to you in the callbacks. + \param callback_context A pointer that will be passed back to you in the callbacks. \return Whether the receive was successful or not */ Result DmaReceive(uint8_t* buff, @@ -193,7 +193,7 @@ class SpiHandle SpiHandle::EndCallbackFunctionPtr end_callback, void* callback_context); - /** DMA-based transmit and receive + /** DMA-based transmit and receive \param tx_buff the transmit buffer \param rx_buff the receive buffer \param size buffer size @@ -201,7 +201,7 @@ class SpiHandle The callback is called from an interrupt, so keep it fast. \param end_callback A callback to execute when the transfer finishes, or NULL. The callback is called from an interrupt, so keep it fast. - \param callback_context A pointer that will be passed back to you in the callbacks. + \param callback_context A pointer that will be passed back to you in the callbacks. \return Whether the receive was successful or not */ Result diff --git a/src/per/spiMultislave.cpp b/src/per/spiMultislave.cpp index 4d8329ef9..b55333150 100644 --- a/src/per/spiMultislave.cpp +++ b/src/per/spiMultislave.cpp @@ -199,4 +199,4 @@ void MultiSlaveSpiHandle::DmaEndCallback(void* context, } } -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/per/spiMultislave.h b/src/per/spiMultislave.h index b6753caee..ead67d1f2 100644 --- a/src/per/spiMultislave.h +++ b/src/per/spiMultislave.h @@ -12,10 +12,10 @@ namespace daisy @{ */ -/** +/** * Handler for a serial peripheral interface that connects to multiple devices on one bus * such that up to 4 devices can share the same MOSI, MISO and SCLK pins. - * Each device has its own NSS/CS pin which is software driven by the MultiSlaveSpiHandle. + * Each device has its own NSS/CS pin which is software driven by the MultiSlaveSpiHandle. */ class MultiSlaveSpiHandle { @@ -49,7 +49,7 @@ class MultiSlaveSpiHandle /** Returns the current config. */ const Config& GetConfig() const { return config_; } - /** Blocking transmit + /** Blocking transmit * \param device_index the index of the device * \param buff input buffer * \param size buffer size @@ -85,13 +85,13 @@ class MultiSlaveSpiHandle size_t size, uint32_t timeout = 100); - /** DMA-based transmit + /** DMA-based transmit * \param device_index the index of the device * \param buff transmit buffer * \param size buffer size * \param start_callback A callback to execute when the transfer starts, or NULL. * \param end_callback A callback to execute when the transfer finishes, or NULL. - * \param callback_context A pointer that will be passed back to you in the callbacks. + * \param callback_context A pointer that will be passed back to you in the callbacks. * \return Whether the transmit was successful or not */ SpiHandle::Result @@ -102,13 +102,13 @@ class MultiSlaveSpiHandle SpiHandle::EndCallbackFunctionPtr end_callback, void* callback_context); - /** DMA-based receive + /** DMA-based receive * \param device_index the index of the device * \param buff receive buffer * \param size buffer size * \param start_callback A callback to execute when the transfer starts, or NULL. * \param end_callback A callback to execute when the transfer finishes, or NULL. - * \param callback_context A pointer that will be passed back to you in the callbacks. + * \param callback_context A pointer that will be passed back to you in the callbacks. * \return Whether the receive was successful or not */ SpiHandle::Result @@ -119,14 +119,14 @@ class MultiSlaveSpiHandle SpiHandle::EndCallbackFunctionPtr end_callback, void* callback_context); - /** DMA-based transmit and receive + /** DMA-based transmit and receive * \param device_index the index of the device * \param tx_buff the transmit buffer * \param rx_buff the receive buffer * \param size buffer size * \param start_callback A callback to execute when the transfer starts, or NULL. * \param end_callback A callback to execute when the transfer finishes, or NULL. - * \param callback_context A pointer that will be passed back to you in the callbacks. + * \param callback_context A pointer that will be passed back to you in the callbacks. * \return Whether the receive was successful or not */ SpiHandle::Result diff --git a/src/per/tim.cpp b/src/per/tim.cpp index fbd1a1a84..a84b570e7 100644 --- a/src/per/tim.cpp +++ b/src/per/tim.cpp @@ -253,7 +253,7 @@ extern "C" = get_tim_impl_from_instance(tim_baseHandle->Instance); /** In the case of TIM6 (DAC usage) there will be no impl. * The preceding enable_irq checks should be false - * since the default constructor sets it that way + * since the default constructor sets it that way */ TimerHandle::Config cfg; if(impl) diff --git a/src/per/tim.h b/src/per/tim.h index c37b25e0c..761ac4bb9 100644 --- a/src/per/tim.h +++ b/src/per/tim.h @@ -7,16 +7,16 @@ namespace daisy { /** @brief Hardare timer peripheral support. - ** + ** ** Supports general-function TIM peripherals: ** - TIM2, TIM3, TIM4, TIM5 ** ** DaisySeed, and many internal peripherals utilize TIM2 for timing/delay purposes. - ** It is configured to be at the maximum frequency: typically 200MHz or 240MHz (boost) - ** for measuring/delaying for very short periods. + ** It is configured to be at the maximum frequency: typically 200MHz or 240MHz (boost) + ** for measuring/delaying for very short periods. ** ** The GetUs/GetMs functions are available for convenience (and backwards compatibility), - ** but to avoid wrapping errors on math when doing time-delta calculations, using ticks is + ** but to avoid wrapping errors on math when doing time-delta calculations, using ticks is ** recommended. The data can be converted to the final time-base after getting the difference in ticks. ** (Using GetFreq() can be used for these time-base calculations). ** @@ -52,8 +52,8 @@ class TimerHandle TIM_5, /**< 32-bit counter*/ }; - /** @brief Direction of the auto-reload counter. - ** @todo Add support for the various + /** @brief Direction of the auto-reload counter. + ** @todo Add support for the various ** versions of Up/Down counters. ** */ enum class CounterDir @@ -88,7 +88,7 @@ class TimerHandle ERR, }; - /** @brief User Callback type that will fire at the end of each timer + /** @brief User Callback type that will fire at the end of each timer * period. This requires that Config::enable_irq is true before Init * @param data pointer to arbitrary user-provided data */ @@ -109,22 +109,22 @@ class TimerHandle const Config& GetConfig() const; /** @brief Sets the period of the Timer. - * + * ** This is the number of ticks it takes before it wraps back around. ** For self-managed timing, this can be left at the default. (0xffff for 16-bit - ** and 0xffffffff for 32-bit timers). - ** This can be changed "on-the-fly" + ** and 0xffffffff for 32-bit timers). + ** This can be changed "on-the-fly" ** */ Result SetPeriod(uint32_t ticks); - /** @brief Sets the Prescalar applied to the TIM peripheral. - * - ** This can be any number up to 0xffff + /** @brief Sets the Prescalar applied to the TIM peripheral. + * + ** This can be any number up to 0xffff ** This will adjust the rate of ticks: ** Calculated as APBN_Freq / prescalar per tick ** where APBN is APB1 for Most general purpose timers, - ** and APB2 for HRTIM,a nd the advanced timers. - ** This can be changed "on-the-fly" + ** and APB2 for HRTIM,a nd the advanced timers. + ** This can be changed "on-the-fly" ** */ Result SetPrescaler(uint32_t val); @@ -137,23 +137,23 @@ class TimerHandle /** @brief Returns the frequency of each tick of the timer in Hz */ uint32_t GetFreq(); - /** @brief Returns the number of counter position. - * - ** This increments according to Config::CounterDir, - ** and wraps around at the specified period (maxing out + /** @brief Returns the number of counter position. + * + ** This increments according to Config::CounterDir, + ** and wraps around at the specified period (maxing out ** at 2^16 or 2^32 depending on the chosen TIM peripheral. */ uint32_t GetTick(); - /** @brief Returns the ticks scaled as milliseconds + /** @brief Returns the ticks scaled as milliseconds ** - ** Use care when using for measurements and ensure that + ** Use care when using for measurements and ensure that ** the TIM period can handle the maximum desired measurement. ***/ uint32_t GetMs(); - /** @brief Returns the ticks scaled as microseconds + /** @brief Returns the ticks scaled as microseconds ** - ** Use care when using for measurements and ensure that + ** Use care when using for measurements and ensure that ** the TIM period can handle the maximum desired measurement. ***/ uint32_t GetUs(); @@ -167,7 +167,7 @@ class TimerHandle /** @brief Stay within this function for del microseconds */ void DelayUs(uint32_t del); - /** @brief Sets the PeriodElapsedCallback that will fire + /** @brief Sets the PeriodElapsedCallback that will fire * whenever the timer reaches the end of it's period. * @param cb user callback * @param data optional pointer to arbitrary data (defaults to nullptr) diff --git a/src/per/uart.h b/src/per/uart.h index 197b45d9a..f71237f96 100644 --- a/src/per/uart.h +++ b/src/per/uart.h @@ -1,4 +1,4 @@ -/* +/* TODO - UART1 defaults to DMA, add flexible config for DMA on all periphs - Transmit function improvements. @@ -17,7 +17,7 @@ namespace daisy @{ */ -/** +/** Uart Peripheral @author shensley @date March 2020 @@ -122,10 +122,10 @@ class UartHandler /** A callback to be executed after a dma transfer is completed. */ typedef void (*EndCallbackFunctionPtr)(void* context, Result result); - /** Blocking transmit + /** Blocking transmit \param buff input buffer \param size buffer size - \param timeout how long in milliseconds the function will wait + \param timeout how long in milliseconds the function will wait before returning without successful communication */ Result BlockingTransmit(uint8_t* buff, size_t size, uint32_t timeout = 100); @@ -139,14 +139,14 @@ class UartHandler Result BlockingReceive(uint8_t* buffer, uint16_t size, uint32_t timeout = 100); - /** DMA-based transmit + /** DMA-based transmit \param *buff input buffer \param size buffer size \param start_callback A callback to execute when the transfer starts, or NULL. The callback is called from an interrupt, so keep it fast. \param end_callback A callback to execute when the transfer finishes, or NULL. The callback is called from an interrupt, so keep it fast. - \param callback_context A pointer that will be passed back to you in the callbacks. + \param callback_context A pointer that will be passed back to you in the callbacks. \return Whether the transmit was successful or not */ Result DmaTransmit(uint8_t* buff, @@ -155,14 +155,14 @@ class UartHandler UartHandler::EndCallbackFunctionPtr end_callback, void* callback_context); - /** DMA-based receive + /** DMA-based receive \param *buff input buffer \param size buffer size \param start_callback A callback to execute when the transfer starts, or NULL. The callback is called from an interrupt, so keep it fast. \param end_callback A callback to execute when the transfer finishes, or NULL. The callback is called from an interrupt, so keep it fast. - \param callback_context A pointer that will be passed back to you in the callbacks. + \param callback_context A pointer that will be passed back to you in the callbacks. \return Whether the receive was successful or not */ Result DmaReceive(uint8_t* buff, @@ -203,7 +203,7 @@ class UartHandler /** Will be deprecated soon! Wrapper for DmaReceiveFifo */ Result StartRx(); - /** Will be deprecated soon! + /** Will be deprecated soon! \return true. New DMA will always restart itself. */ bool RxActive() { return true; } diff --git a/src/sys/dma.h b/src/sys/dma.h index a9a25e36e..ad286e2b6 100644 --- a/src/sys/dma.h +++ b/src/sys/dma.h @@ -20,24 +20,24 @@ extern "C" /** DMA transfers require the buffers to be excluded from the cache because the DMA * reads / writes directly to the SRAM whereas the processor itself accesses the cache. - * Otherwise the DMA will access whatever is in the SRAM at the time which may not be - * in sync with the data in the cache - resulting in wrong data transmitted / received. + * Otherwise the DMA will access whatever is in the SRAM at the time which may not be + * in sync with the data in the cache - resulting in wrong data transmitted / received. * You can place buffers in the D2 memory domain, in a section that has the cache disabled * like this: * uint8_t DMA_BUFFER_MEM_SECTION my_buffer[100]; - * If this is not possible for some reason, call this function to clear the cache (write + * If this is not possible for some reason, call this function to clear the cache (write * cache contents to SRAM if required) before starting to transmit data via the DMA. */ void dsy_dma_clear_cache_for_buffer(uint8_t* buffer, size_t size); /** DMA transfers require the buffers to be excluded from the cache because the DMA * reads / writes directly to the SRAM whereas the processor itself accesses the cache. - * Otherwise the DMA will access whatever is in the SRAM at the time which may not be - * in sync with the data in the cache - resulting in wrong data transmitted / received. + * Otherwise the DMA will access whatever is in the SRAM at the time which may not be + * in sync with the data in the cache - resulting in wrong data transmitted / received. * You can place buffers in the D2 memory domain, in a section that has the cache disabled * like this: * uint8_t DMA_BUFFER_MEM_SECTION my_buffer[100]; - * If this is not possible for some reason, call this function to invalidate the cache (read + * If this is not possible for some reason, call this function to invalidate the cache (read * SRAM contents to cache if required) after reading data from peripherals via the DMA. */ void dsy_dma_invalidate_cache_for_buffer(uint8_t* buffer, size_t size); diff --git a/src/sys/fatfs.h b/src/sys/fatfs.h index 8f950f08a..378353709 100644 --- a/src/sys/fatfs.h +++ b/src/sys/fatfs.h @@ -8,21 +8,21 @@ namespace daisy /** @brief Daisy FatFS Driver Interface * @details Specifies the desired media (SD Card, USB, etc.) to be mountable with FatFS * within a given application. Once initialization is called, the standard - * FatFS API will be usable with the media mounted in the order - * they are listed in the Media config struct. + * FatFS API will be usable with the media mounted in the order + * they are listed in the Media config struct. * For example, when only using an SD Card, it will mount at "0:/", - * when only using USB, it will mount at "0:/". However, when mounting - * with SD card and USB, the SD card will mount at "0:/", and the USB + * when only using USB, it will mount at "0:/". However, when mounting + * with SD card and USB, the SD card will mount at "0:/", and the USB * will mount at "1:/". * The relevant hardware peripheral (SDMMC, or MSD) needs to be initialized * separately by the application before using FatFS. - * + * * This object has some memory limitations due to the media connected to it. - * The SDMMC1 peripheral can only communicate with the AXI SRAM, and the DTCMRAM + * The SDMMC1 peripheral can only communicate with the AXI SRAM, and the DTCMRAM * cannot communicate with the DMA. So the FatFSInterface object should always be * located in the AXI SRAM. This is the default location for all data/bss memory * using the standard build. However, applciations using the electrosmith bootloader - * will need special consideration when using this object AND an SD Card. + * will need special consideration when using this object AND an SD Card. */ class FatFSInterface { @@ -39,14 +39,14 @@ class FatFSInterface /** Config structure for configuring Daisy to FatFS */ struct Config { - /** Selected Media that will be linked to FatFS + /** Selected Media that will be linked to FatFS * These values can be OR'd together when multiple - * volumes are desired + * volumes are desired * i.e. config.media = Media::SD | Media::USBH; - * - * When mounting multiple volumes, ffconf.h must have + * + * When mounting multiple volumes, ffconf.h must have * _VOLUMES set to an appropriate value. - * + * * FatFS will register multiple volumes in the order of the enum, * the first registered class will mount at "0:/", * the second registered class will mount at "1:/", and so on @@ -66,8 +66,8 @@ class FatFSInterface /** Link the desired hardware specified via Config::Media */ Result Init(const Config& cfg); - /** Link the desired hardware specified via Config::Media - * + /** Link the desired hardware specified via Config::Media + * * Alternate, explicit initialization provided for simplified syntax. */ Result Init(const uint8_t media); @@ -104,7 +104,7 @@ class FatFSInterface } // namespace daisy -/** Implementation of FatFS time method +/** Implementation of FatFS time method * @return 0 */ extern "C" DWORD get_fattime(void); diff --git a/src/sys/ffconf.h b/src/sys/ffconf.h index 99fe4ffd1..26c19ba98 100644 --- a/src/sys/ffconf.h +++ b/src/sys/ffconf.h @@ -22,7 +22,7 @@ #define _FFCONF 68300 /**< Revision ID */ /*-----------------------------------------------------------------------------/ -/ Additional user header to be used +/ Additional user header to be used /-----------------------------------------------------------------------------*/ #include "util/bsp_sd_diskio.h" @@ -32,14 +32,14 @@ /-----------------------------------------------------------------------------*/ #define _FS_READONLY \ - 0 /**< 0:Read/Write or 1:Read only + 0 /**< 0:Read/Write or 1:Read only This option switches read-only configuration. (0:Read/Write or 1:Read-only) / Read-only configuration removes writing API functions, f_write(), f_sync(), / f_unlink(), f_mkdir(), f_chmod(), f_rename(), f_truncate(), f_getfree() / and optional writing functions as well. */ #define _FS_MINIMIZE \ - 0 /**< 0 to 3 + 0 /**< 0 to 3 This option defines minimization level to remove some basic API functions. / / 0: All basic functions are enabled. @@ -49,7 +49,7 @@ / 3: f_lseek() function is removed in addition to 2. */ #define _USE_STRFUNC \ - 2 /**< 0:Disable or 1-2:Enable + 2 /**< 0:Disable or 1-2:Enable This option switches string functions, f_gets(), f_putc(), f_puts() and / f_printf(). / @@ -132,7 +132,7 @@ / ff_memfree(), must be added to the project. */ #define _LFN_UNICODE \ - 0 /**< 0:ANSI/OEM or 1:Unicode + 0 /**< 0:ANSI/OEM or 1:Unicode This option switches character encoding on the API. (0:ANSI/OEM or 1:UTF-16) / To use Unicode string for the path name, enable LFN and set _LFN_UNICODE = 1. / This option also affects behavior of string I/O functions. */ @@ -149,7 +149,7 @@ This option switches character encoding on the API. (0:ANSI/OEM or 1:UTF-16) / This option has no effect when _LFN_UNICODE == 0. */ #define _FS_RPATH \ - 0 /**< 0 to 2 + 0 /**< 0 to 2 This option configures support of relative path. / / 0: Disable relative path and remove related functions. @@ -186,7 +186,7 @@ This option switches support of multi-partition on a physical drive. / funciton will be available. */ #define _MIN_SS 512 /**< 512, 1024, 2048 or 4096 */ #define _MAX_SS \ - 512 /**< 512, 1024, 2048 or 4096 + 512 /**< 512, 1024, 2048 or 4096 These options configure the range of sector size to be supported. (512, 1024, / 2048 or 4096) Always set both 512 for most systems, all type of memory cards and / harddisk. But a larger value may be required for on-board flash memory and some @@ -200,7 +200,7 @@ This option switches support of multi-partition on a physical drive. / disk_ioctl() function. */ #define _FS_NOFSINFO \ - 0 /**< 0,1,2 or 3 + 0 /**< 0,1,2 or 3 If you need to know correct free space on the FAT32 volume, set bit 0 of this / option, and f_getfree() function at first time after volume mount will force / a full FAT scan. Bit 1 controls the use of last allocated cluster number. @@ -216,7 +216,7 @@ This option switches support of multi-partition on a physical drive. /----------------------------------------------------------------------------*/ #define _FS_TINY \ - 0 /**< 0:Normal or 1:Tiny + 0 /**< 0:Normal or 1:Tiny This option switches tiny buffer configuration. (0:Normal or 1:Tiny) / At the tiny configuration, size of file object (FIL) is reduced _MAX_SS bytes. / Instead of private sector buffer eliminated from the file object, common sector @@ -231,18 +231,18 @@ This option switches support of multi-partition on a physical drive. #define _NORTC_MON 6 /**< & */ #define _NORTC_MDAY 4 /**< & */ #define _NORTC_YEAR \ - 2015 /**< -The option _FS_NORTC switches timestamp functiton. If the system does not have + 2015 /**< +The option _FS_NORTC switches timestamp functiton. If the system does not have / any RTC function or valid timestamp is not needed, set _FS_NORTC = 1 to disable / the timestamp function. All objects modified by FatFs will have a fixed timestamp / defined by _NORTC_MON, _NORTC_MDAY and _NORTC_YEAR in local time. / To enable timestamp function (_FS_NORTC = 0), get_fattime() function need to be / added to the project to get current time form real-time clock. _NORTC_MON, -/ _NORTC_MDAY and _NORTC_YEAR have no effect. +/ _NORTC_MDAY and _NORTC_YEAR have no effect. / These options have no effect at read-only configuration (_FS_READONLY = 1). */ #define _FS_LOCK \ - 0 /**< 0:Disable or >=1:Enable + 0 /**< 0:Disable or >=1:Enable The option _FS_LOCK switches file lock function to control duplicated file open / and illegal operation to open objects. This option must be 0 when _FS_READONLY / is 1. diff --git a/src/sys/system.cpp b/src/sys/system.cpp index acead70e2..035a1d4f2 100644 --- a/src/sys/system.cpp +++ b/src/sys/system.cpp @@ -322,14 +322,14 @@ void System::ConfigureClocks() RCC_ClkInitTypeDef RCC_ClkInitStruct = {0}; RCC_PeriphCLKInitTypeDef PeriphClkInitStruct = {0}; - /** Supply configuration update enable + /** Supply configuration update enable */ HAL_PWREx_ConfigSupply(PWR_LDO_SUPPLY); - /** Configure the main internal regulator output voltage + /** Configure the main internal regulator output voltage ** and set PLLN value, and flash-latency. ** - ** See page 159 of Reference manual for VOS/Freq relationship + ** See page 159 of Reference manual for VOS/Freq relationship ** and table for flash latency. */ @@ -350,10 +350,10 @@ void System::ConfigureClocks() } while(!__HAL_PWR_GET_FLAG(PWR_FLAG_VOSRDY)) {} - /** Macro to configure the PLL clock source + /** Macro to configure the PLL clock source */ __HAL_RCC_PLL_PLLSOURCE_CONFIG(RCC_PLLSOURCE_HSE); - /** Initializes the CPU, AHB and APB busses clocks + /** Initializes the CPU, AHB and APB busses clocks */ RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI48 | RCC_OSCILLATORTYPE_HSE; @@ -374,7 +374,7 @@ void System::ConfigureClocks() { Error_Handler(); } - /** Initializes the CPU, AHB and APB busses clocks + /** Initializes the CPU, AHB and APB busses clocks */ RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_HCLK | RCC_CLOCKTYPE_SYSCLK | RCC_CLOCKTYPE_PCLK1 diff --git a/src/sys/system.h b/src/sys/system.h index 5aa3f3ebd..f1149bdad 100644 --- a/src/sys/system.h +++ b/src/sys/system.h @@ -8,7 +8,7 @@ namespace daisy { -/** A handle for interacting with the Core System. +/** A handle for interacting with the Core System. ** This includes the Clock tree, MPU, global DMA initialization, ** cache handling, and any other necessary global initiailzation ** @@ -30,7 +30,7 @@ class System /** Method to call on the struct to set to defaults ** CPU Freq set to 400MHz - ** Cache Enabled + ** Cache Enabled ** */ void Defaults() { @@ -42,7 +42,7 @@ class System /** Method to call on the struct to set to boost mode: ** CPU Freq set to 480MHz - ** Cache Enabled + ** Cache Enabled ** */ void Boost() { @@ -59,7 +59,7 @@ class System }; /** Describes the different regions of memory available to the Daisy - * + * */ enum MemoryRegion { @@ -77,19 +77,19 @@ class System System() {} ~System() {} - /** Default Initializer with no input will create an internal config, + /** Default Initializer with no input will create an internal config, ** and set everything to Defaults */ void Init(); /** Configurable Initializer - ** Initializes clock tree, DMA initializaiton and + ** Initializes clock tree, DMA initializaiton and ** any necessary global inits. */ void Init(const Config& config); /** Deinitializer - ** Deinitializes all modules and peripherals + ** Deinitializes all modules and peripherals ** set up with `Init`. */ void DeInit(); @@ -100,15 +100,15 @@ class System */ void JumpToQspi(); - /** \return a uint32_t value of milliseconds since the SysTick started + /** \return a uint32_t value of milliseconds since the SysTick started */ static uint32_t GetNow(); /** \return a uint32_t of microseconds within the internal timer. */ static uint32_t GetUs(); - /** \return a uint32_t of ticks at (PCLk1 * 2)Hz - ** Useful for measuring the number of CPU ticks + /** \return a uint32_t of ticks at (PCLk1 * 2)Hz + ** Useful for measuring the number of CPU ticks ** something is taking. ** */ static uint32_t GetTick(); @@ -118,12 +118,12 @@ class System */ static void Delay(uint32_t delay_ms); - /** Blocking Delay using internal timer to wait + /** Blocking Delay using internal timer to wait ** \param delay_us Time to ddelay in microseconds */ static void DelayUs(uint32_t delay_us); - /** Blocking Delay using internal timer to wait + /** Blocking Delay using internal timer to wait ** \param delay_ticks Time to ddelay in microseconds */ static void DelayTicks(uint32_t delay_ticks); @@ -134,7 +134,7 @@ class System /** Returns the tick rate in Hz with which GetTick() is incremented. */ static uint32_t GetTickFreq(); - /** Returns the Frequency of the system clock in Hz + /** Returns the Frequency of the system clock in Hz ** This is the primary system clock that is used to generate ** AXI Peripheral, APB, and AHB clocks. */ static uint32_t GetSysClkFreq(); @@ -148,16 +148,16 @@ class System /** Returns the frequency of the PCLK1 (APB1) clock ** This is used to clock various peripherals, and timers. ** - ** It's important to note that many timers run on a - ** clock twice as fast as the peripheral clock for the timer. + ** It's important to note that many timers run on a + ** clock twice as fast as the peripheral clock for the timer. ** */ static uint32_t GetPClk1Freq(); /** Returns the frequency of the PCLK2 (APB2) clock ** This is used to clock various peripherals, and timers. ** - ** It's important to note that many timers run on a - ** clock twice as fast as the peripheral clock for the timer. + ** It's important to note that many timers run on a + ** clock twice as fast as the peripheral clock for the timer. ** */ static uint32_t GetPClk2Freq(); @@ -166,20 +166,20 @@ class System */ const Config& GetConfig() const { return cfg_; } - /** Returns an enum representing the current (primary) memory space used + /** Returns an enum representing the current (primary) memory space used * for executing the program. */ static MemoryRegion GetProgramMemoryRegion(); - /** Returns an enum representing the the memory region + /** Returns an enum representing the the memory region * that the given address belongs to. * \param address The address to be checked */ static MemoryRegion GetMemoryRegion(uint32_t address); /** This constant indicates the Daisy bootloader's offset from - * the beginning of QSPI's address space. - * Data written within the first 256K will remain + * the beginning of QSPI's address space. + * Data written within the first 256K will remain * untouched by the Daisy bootloader. */ static constexpr uint32_t kQspiBootloaderOffset = 0x40000U; @@ -207,7 +207,7 @@ namespace daisy * Only the time-related functions are added here. If * your tests need some of the other functions, feel * free to add them here as well. - * + * * To decouple tests that are running in parallel, each * test can independently modify the current time. */ diff --git a/src/ui/AbstractMenu.cpp b/src/ui/AbstractMenu.cpp index f0d31e8ab..f3f35c891 100644 --- a/src/ui/AbstractMenu.cpp +++ b/src/ui/AbstractMenu.cpp @@ -272,4 +272,4 @@ void AbstractMenu::TriggerItemAction(uint16_t itemIdx) } } -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/ui/AbstractMenu.h b/src/ui/AbstractMenu.h index c7159155f..e45f00100 100644 --- a/src/ui/AbstractMenu.h +++ b/src/ui/AbstractMenu.h @@ -9,41 +9,41 @@ namespace daisy /** @brief Base class for complex menus. * @author jelliesen * @ingroup ui - * + * * This is the base class for any form of UiPage that displays a menu with multiple items. * It handles all the logic behind a menu (selecting items, editing items, etc.) but doesn't * implement any form of drawing. Implement your own drawing routines by overriding * UiPage::Draw() or use `FullScreenItemMenu` - * - * Vaious types of items can be added to the menu, e.g. + * + * Vaious types of items can be added to the menu, e.g. * - Checkbox items to toggle something on/off, * - Generic action items that call a function when activated, * - Value editing items for editing int/float/enum values, * - Close items that close the menu when activated (useful when no cancel button is available), - * - Custom items that do whatever you want them to do, by providing a CustomItem object that + * - Custom items that do whatever you want them to do, by providing a CustomItem object that * handles the item-specific functionality. - * - * The Abstract Menu can work with a wide variety of physical controls, here are a couple + * + * The Abstract Menu can work with a wide variety of physical controls, here are a couple * of combinations that are possible: * - 3 buttons: Left/Right to select and edit items, Ok to activate or enter/leave editing mode - * - 5 buttons: Up/Down to select, Ok to activate/enter/leave, Cancel to close menu, function + * - 5 buttons: Up/Down to select, Ok to activate/enter/leave, Cancel to close menu, function * button to use coarse step size when editing * - 6 buttons: Left/Right to select, Up/Down to quickly edit selected items, Ok/Cancel to enter/leave * - 1 encoder with pushbutton * - 1 encoder for selecting items, another one for editing their values * - 1 encoder for selecting items and a value slider potentiometer for editing * - ... any other combination of the above - * + * * These are the controls that the AbstractMenu will react to and their associated function: * - Left/Right buttons: Select items when `Orientation::leftRightSelectUpDownModify`, - * directly edit value of the selected item when + * directly edit value of the selected item when * `Orientation::upDownSelectLeftRightModify`. * - Up/Down buttons: Select items when `Orientation::upDownSelectLeftRightModify`, - * directly edit value of the selected item when + * directly edit value of the selected item when * `Orientation::leftRightSelectUpDownModify`. - * - Ok button: Activate the action of the selected item (if it has an action, e.g. - * `ItemType::closeMenuItem`) otherwise enter/leave editing mode where the - * arrow buttons used for selection will now edit the value instead (only + * - Ok button: Activate the action of the selected item (if it has an action, e.g. + * `ItemType::closeMenuItem`) otherwise enter/leave editing mode where the + * arrow buttons used for selection will now edit the value instead (only * possible if `allowEntering` is set to `true`). * - Cancel button: Closes the menu page or leaves editing mode * - Menu encoder: Selects items; edits item value when in editing mode @@ -55,8 +55,8 @@ namespace daisy class AbstractMenu : public UiPage { public: - /** Controls which buttons are used to navigate back and forth between the menu - * items (selection buttons) and which buttons can be used to modify their value + /** Controls which buttons are used to navigate back and forth between the menu + * items (selection buttons) and which buttons can be used to modify their value * directly without pressing the enter button first (modify buttons; these don't * have to be available). * @see AbstractMenuPage @@ -83,7 +83,7 @@ class AbstractMenu : public UiPage valueItem, /** Displays a name and opens another UiPage when selected. */ openUiPageItem, - /** Displays a text and closes the menu page when selected. This is useful when no cancel + /** Displays a text and closes the menu page when selected. This is useful when no cancel * button is available to close a menu and return to the page below. */ closeMenuItem, /** A custom item. @see CustomItem */ @@ -170,7 +170,7 @@ class AbstractMenu : public UiPage struct { /** The UiPage to open when the okay button is pressed. - * The object must stay alive longer than the MenuPage, + * The object must stay alive longer than the MenuPage, * e.g. as a global variable. */ UiPage* pageToOpen; } asOpenUiPageItem; @@ -178,7 +178,7 @@ class AbstractMenu : public UiPage /** Properties for type == ItemType::customItem */ struct { - /** The CustomItem to display. The object provided here must + /** The CustomItem to display. The object provided here must * stay alive longer than the MenuPage, e.g. as a global variable. */ CustomItem* itemObject; } asCustomItem; @@ -215,16 +215,16 @@ class AbstractMenu : public UiPage /** Call this from your child class to initialize the menu. It's okay to * re-initialize an AbstractMene multiple times, even while it's displayed * on the UI. - * @param items An array of ItemConfig that determine which items are + * @param items An array of ItemConfig that determine which items are * available in the menu. * @param numItems The number of items in the `items` array. - * @param orientation Controls which pair of arrow buttons are used for + * @param orientation Controls which pair of arrow buttons are used for * selection / editing - * @param allowEntering Globally controls if the Ok button can enter items - * for editing. If you have a physical controls that can edit - * selected items directly (value slider, a second arrow button + * @param allowEntering Globally controls if the Ok button can enter items + * for editing. If you have a physical controls that can edit + * selected items directly (value slider, a second arrow button * pair, value encoder) you can set this to false, otherwise you - * set it to true so that the controls used for selecting items + * set it to true so that the controls used for selecting items * can now also be used to edit the values. */ void Init(const ItemConfig* items, @@ -235,7 +235,7 @@ class AbstractMenu : public UiPage /** Returns the state of the function button. */ bool IsFunctionButtonDown() const { return isFuncButtonDown_; } - /** The orientation of the menu. This is used to determine + /** The orientation of the menu. This is used to determine * which function the arrow keys will be assigned to. */ Orientation orientation_ = Orientation::upDownSelectLeftRightModify; /** A list of items to include in the menu. */ @@ -244,10 +244,10 @@ class AbstractMenu : public UiPage uint16_t numItems_ = 0; /** The currently selected item index */ int16_t selectedItemIdx_ = -1; - /** If true, the menu allows "entering" an item to modify + /** If true, the menu allows "entering" an item to modify * its value with the encoder / selection buttons. */ bool allowEntering_ = true; - /** If true, the currently selected item index is + /** If true, the currently selected item index is * "entered" so that it can be edited with the encoder/ * selection buttons. */ bool isEditing_ = false; @@ -270,4 +270,4 @@ class AbstractMenu : public UiPage }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/ui/ButtonMonitor.h b/src/ui/ButtonMonitor.h index 99e910b77..aeec40283 100644 --- a/src/ui/ButtonMonitor.h +++ b/src/ui/ButtonMonitor.h @@ -8,7 +8,7 @@ namespace daisy /** @brief A button monitor that generates events in a UiEventQueue * @author jelliesen * @ingroup ui - * + * * This class monitors a number of buttons and detects changes in their state. * When a change is detected, an event is added to a UiEventQueue. If required, software * debouncing can be applied. @@ -17,9 +17,9 @@ namespace daisy * template argument `numButtons`. Each of the buttons is identified by an ID number from * `0 .. numButtons - 1`. This number will also be used when events are posted to the * UiEventQueue. It's suggested to define an enum in your project like this: - * + * * enum ButtonId { bttnOkay = 0, bttnCancel = 1, bttnStart = 2 }; - * + * * In different projects, diffent ways of reading the button states will be * used. That's why this class uses a generic backend that you'll have to write. * The BackendType class will provide the source data for each button or switch. @@ -208,4 +208,4 @@ class ButtonMonitor uint32_t lastCallSysTime_; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/ui/FullScreenItemMenu.cpp b/src/ui/FullScreenItemMenu.cpp index 6adf9d759..500b6e238 100644 --- a/src/ui/FullScreenItemMenu.cpp +++ b/src/ui/FullScreenItemMenu.cpp @@ -351,4 +351,4 @@ FontDef FullScreenItemMenu::GetNameFont(const char* textToDraw, return Font_11x18; } -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/ui/FullScreenItemMenu.h b/src/ui/FullScreenItemMenu.h index 3f2b0a805..d994ec17b 100644 --- a/src/ui/FullScreenItemMenu.h +++ b/src/ui/FullScreenItemMenu.h @@ -7,17 +7,17 @@ namespace daisy /** @brief A menu page for small screens * @author jelliesen * @ingroup ui - * - * This class builds upon the menu logic of AbstractMenu and adds + * + * This class builds upon the menu logic of AbstractMenu and adds * drawing routines that are suitable for small screens. - * - * By default, it will paint to the canvas returned by - * `UI::GetPrimaryOneBitGraphicsDisplayId()`. It can also be + * + * By default, it will paint to the canvas returned by + * `UI::GetPrimaryOneBitGraphicsDisplayId()`. It can also be * configured to paint to a different canvas. - * + * * Each item will occupy the entire display. * FullScreenItemMenu uses the LookAndFeel system to draw draw the - * items. This means that you can create your own graphics design + * items. This means that you can create your own graphics design * by creating your own LookAndFeel based on the OneBitGraphicsLookAndFeel * class and apply that either globally (UI::SetOneBitGraphicsLookAndFeel()) * or to this page only (UiPage::SetOneBitGraphicsLookAndFeel()). @@ -25,18 +25,18 @@ namespace daisy class FullScreenItemMenu : public AbstractMenu { public: - /** Call this to initialize the menu. It's okay to re-initialize a + /** Call this to initialize the menu. It's okay to re-initialize a * FullScreenItemMenu multiple times, even while it's displayed on the UI. - * @param items An array of ItemConfig that determine which items are + * @param items An array of ItemConfig that determine which items are * available in the menu. * @param numItems The number of items in the `items` array. - * @param orientation Controls which pair of arrow buttons are used for + * @param orientation Controls which pair of arrow buttons are used for * selection / editing - * @param allowEntering Globally controls if the Ok button can enter items - * for editing. If you have a physical controls that can edit - * selected items directly (value slider, a second arrow button + * @param allowEntering Globally controls if the Ok button can enter items + * for editing. If you have a physical controls that can edit + * selected items directly (value slider, a second arrow button * pair, value encoder) you can set this to false, otherwise you - * set it to true so that the controls used for selecting items + * set it to true so that the controls used for selecting items * can now also be used to edit the values. */ void Init(const AbstractMenu::ItemConfig* items, diff --git a/src/ui/PotMonitor.h b/src/ui/PotMonitor.h index 5af6b0585..68c2a0afe 100644 --- a/src/ui/PotMonitor.h +++ b/src/ui/PotMonitor.h @@ -8,7 +8,7 @@ namespace daisy /** @brief A potentiometer monitor that generates events in a UiEventQueue * @author jelliesen * @ingroup ui - * + * * This class monitors a number of potentiometers and detects pot movements. * When a movement is detected, an event is added to a UiEventQueue. * Pots can be either "idle" or "moving" in which case different dead bands @@ -18,9 +18,9 @@ namespace daisy * template argument `numPots`. Each of the pots is identified by an ID number from * `0 .. numPots - 1`. This number will also be used when events are posted to the * UiEventQueue. It's suggested to define an enum in your project like this: - * + * * enum PotId { potA = 0, potB = 1, potC = 2 }; - * + * * In different projects, diffent ways of reading the potentiometer positions will be * used. That's why this class uses a generic backend that you'll have to write. * The BackendType class will provide the source data for each potentiometer. @@ -181,4 +181,4 @@ class PotMonitor uint32_t lastCallSysTime_; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/ui/UI.cpp b/src/ui/UI.cpp index 9ddddc278..cdaa6a8c2 100644 --- a/src/ui/UI.cpp +++ b/src/ui/UI.cpp @@ -357,4 +357,4 @@ void UI::ForwardToButtonHandler(const uint16_t buttonID, } } -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/ui/UI.h b/src/ui/UI.h index 74f2cb9ee..c58afd4f3 100644 --- a/src/ui/UI.h +++ b/src/ui/UI.h @@ -26,18 +26,18 @@ enum class ArrowButtonType /** @brief A descriptor for a canvas in the UI system. * @author jelliesen * @ingroup ui - * - * A descriptor for a generic display / led / output device + * + * A descriptor for a generic display / led / output device * that's used in the UI system. */ struct UiCanvasDescriptor { - /** An id number to tell apart various types of canvases that + /** An id number to tell apart various types of canvases that * are used concurrently in your system. */ uint8_t id_; - /** A pointer to some object that allows to draw to the canvas. - * In your UI pages, you will use the id_ to identify which canvas this is, + /** A pointer to some object that allows to draw to the canvas. + * In your UI pages, you will use the id_ to identify which canvas this is, * and then cast this pointer to whatever object it represents, e.g. OledDisplay. */ void* handle_; @@ -45,10 +45,10 @@ struct UiCanvasDescriptor /** The desired update rate in ms */ uint32_t updateRateMs_; - /** The desired timeout in ms before a display will shut off. + /** The desired timeout in ms before a display will shut off. * This defaults to 0, which will keep the display on all the time. * Nonzero values are useful for displays that can suffer from burn-in, - * such as OLEDs. + * such as OLEDs. */ uint32_t screenSaverTimeOut = 0; @@ -58,7 +58,7 @@ struct UiCanvasDescriptor using ClearFuncPtr = void (*)(const UiCanvasDescriptor& canvasToClear); ClearFuncPtr clearFunction_; - /** A function to call when all UIPages have finished the drawing procedure + /** A function to call when all UIPages have finished the drawing procedure * and the results can be flushed out to the device. */ using FlushFuncPtr = void (*)(const UiCanvasDescriptor& canvasToFlush); @@ -93,7 +93,7 @@ class UiPage bool IsActive() { return parent_ != nullptr; } /** Called on any user input event, after the respective callback has completed. - * OnUserInteraction will be invoked for all pages in the page stack and can be used to + * OnUserInteraction will be invoked for all pages in the page stack and can be used to * track general user activity. */ virtual void OnUserInteraction() {} @@ -107,7 +107,7 @@ class UiPage * It will be 1 on the first call and increasing by 1 * with each successive call. A button down event is * signaled by numberOfButtonPresses == 0. - * @param isRetriggering True if the button is auto-retriggering (due to being + * @param isRetriggering True if the button is auto-retriggering (due to being * held down) * @returns false, if you want the event to be passed on to the page below. */ @@ -123,7 +123,7 @@ class UiPage * It will be 1 on the first call and increasing by 1 * with each successive call. A button down event is * signaled by numberOfButtonPresses == 0. - * @param isRetriggering True if the button is auto-retriggering (due to being + * @param isRetriggering True if the button is auto-retriggering (due to being * held down) * @returns false, if you want the event to be passed on to the page below. */ @@ -140,7 +140,7 @@ class UiPage * It will be 1 on the first call and increasing by 1 * with each successive call. A button down event is * signaled by numberOfButtonPresses == 0. - * @param isRetriggering True if the button is auto-retriggering (due to being + * @param isRetriggering True if the button is auto-retriggering (due to being * held down) * @returns false, if you want the event to be passed on to the page below. */ @@ -159,7 +159,7 @@ class UiPage * It will be 1 on the first call and increasing by 1 * with each successive call. A button down event is * signaled by numberOfButtonPresses == 0. - * @param isRetriggering True if the button is auto-retriggering (due to being + * @param isRetriggering True if the button is auto-retriggering (due to being * held down) * @returns false, if you want the event to be passed on to the page below. */ @@ -177,7 +177,7 @@ class UiPage * It will be 1 on the first call and increasing by 1 * with each successive call. A button down event is * signaled by numberOfButtonPresses == 0. - * @param isRetriggering True if the button is auto-retriggering (due to being + * @param isRetriggering True if the button is auto-retriggering (due to being * held down) * @returns false, if you want the event to be passed on to the page below. */ @@ -251,7 +251,7 @@ class UiPage return true; } - /** Called when the user starts or stops turning an encoder that is not the menu + /** Called when the user starts or stops turning an encoder that is not the menu * encoder or the value encoder. * @param encoderID The ID of the affected encoder. * @param isCurrentlyActive True, if the user currently moves this encoder. @@ -323,7 +323,7 @@ class UiPage /** Called when the page is no longer the topmost page in the page stack. */ virtual void OnFocusLost(){}; - /** Called to make the UIPage repaint everything on a canvas. + /** Called to make the UIPage repaint everything on a canvas. * Check the ID to determine which display this corresponds to. * Cast the handle to the corresponding type and do your draw operations on it. */ @@ -343,19 +343,19 @@ class UiPage * @author jelliesen * @ingroup ui * - * This system allows you to create complex and dynamic user interfaces - * with menus, pages and dialogs. It holds a stack of pages. Each page + * This system allows you to create complex and dynamic user interfaces + * with menus, pages and dialogs. It holds a stack of pages. Each page * can react to user input on buttons, potentiometers, and encoders * while drawing to one or multiple displays, leds or other output devices. - * + * * User input is consumed from a UiEventQueue and distributed to the pages - * from the top down. If a page doesn't handle an event, it will be + * from the top down. If a page doesn't handle an event, it will be * forwarded to the next page below. - * - * Pages are drawn from the bottom up. Multiple abstract canvases can be - * used for the drawing, where each canvas could be a graphics display, - * LEDs, alphanumeric displays, etc. The UI system makes sure that drawing - * is executed with a constant refresh rate that can be individually + * + * Pages are drawn from the bottom up. Multiple abstract canvases can be + * used for the drawing, where each canvas could be a graphics display, + * LEDs, alphanumeric displays, etc. The UI system makes sure that drawing + * is executed with a constant refresh rate that can be individually * specified for each canvas. */ class UI @@ -366,7 +366,7 @@ class UI /** Contains information about the control IDs used for special functions * such as arrow buttons, okay/cancel, function buttons, value sliders, etc. - * If such a control is available, set the corresponding variable to + * If such a control is available, set the corresponding variable to * the control ID that's used when events are pushed to the UiEventQueue. * If such a control is not available, use UiEventQueue::invalidButtonId, * UiEventQueue::invalidEncoderId or UiEventQueue::invalidPotId. @@ -395,11 +395,11 @@ class UI * @param inputQueue The UiEventQueue to read user input events from. * @param specialControlIds Information about the control IDs used for special buttons/encoders/pots. * @param canvases A list of UiCanvasDescriptor that define which canvases to use. - * @param primaryOneBitGraphicsDisplayId - * The ID of a OneBitGraphicsDisplay canvas that should be used as the + * @param primaryOneBitGraphicsDisplayId + * The ID of a OneBitGraphicsDisplay canvas that should be used as the * main display. Menus will draw to this canvas. If no such dispaly is available, * use Ui::invalidCanvasId. - * + * */ void Init(UiEventQueue& inputQueue, const SpecialControlIds& specialControlIds, @@ -430,7 +430,7 @@ class UI /** Called to close a page. */ void ClosePage(UiPage& page); - /** If this UI has a canvas that uses a OneBitGraphicsDisplay AND this canvas should be used + /** If this UI has a canvas that uses a OneBitGraphicsDisplay AND this canvas should be used * as the main display for menus, etc. then this function returns the canvas ID of this display. * If no such canvas exists, this function returns UI::invalidCanvasId. */ diff --git a/src/ui/UiEventQueue.h b/src/ui/UiEventQueue.h index eeb9ae9e3..89026e7c5 100644 --- a/src/ui/UiEventQueue.h +++ b/src/ui/UiEventQueue.h @@ -7,8 +7,8 @@ namespace daisy { /** @brief A queue that holds user input events in the UI system. * @author jelliesen - * @ingroup ui - * + * @ingroup ui + * * A queue that holds user interface events such as button presses or encoder turns. * The queue can be filled from hardware drivers and read from a UI object. * Access to the queue is protected by a ScopedIrqBlocker - that means it's safe to add @@ -68,7 +68,7 @@ class UiEventQueue uint16_t id; /** The number of successive button presses (e.g. double click). */ uint16_t numSuccessivePresses; - /** True if the event was generated because a button was retriggered + /** True if the event was generated because a button was retriggered * automatically while being held down. */ bool isRetriggering; } asButtonPressed; @@ -215,4 +215,4 @@ class UiEventQueue FIFO events_; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/usbd/usbd_conf.c b/src/usbd/usbd_conf.c index db98e50d2..efc20445a 100644 --- a/src/usbd/usbd_conf.c +++ b/src/usbd/usbd_conf.c @@ -78,10 +78,10 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *pcdHandle) /* USER CODE END USB_OTG_FS_MspInit 0 */ __HAL_RCC_GPIOA_CLK_ENABLE(); - /**USB_OTG_FS GPIO Configuration + /**USB_OTG_FS GPIO Configuration PA12 ------> USB_OTG_FS_DP PA11 ------> USB_OTG_FS_DM - PA9 ------> USB_OTG_FS_VBUS + PA9 ------> USB_OTG_FS_VBUS */ GPIO_InitStruct.Pin = GPIO_PIN_12 | GPIO_PIN_11; GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; @@ -116,9 +116,9 @@ void HAL_PCD_MspInit(PCD_HandleTypeDef *pcdHandle) /* USER CODE END USB_OTG_HS_MspInit 0 */ __HAL_RCC_GPIOB_CLK_ENABLE(); - /**USB_OTG_HS GPIO Configuration + /**USB_OTG_HS GPIO Configuration PB14 ------> USB_OTG_HS_DM - PB15 ------> USB_OTG_HS_DP + PB15 ------> USB_OTG_HS_DP */ GPIO_InitStruct.Pin = GPIO_PIN_14 | GPIO_PIN_15; GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; @@ -153,10 +153,10 @@ void HAL_PCD_MspDeInit(PCD_HandleTypeDef *pcdHandle) /* Peripheral clock disable */ __HAL_RCC_USB_OTG_FS_CLK_DISABLE(); - /**USB_OTG_FS GPIO Configuration + /**USB_OTG_FS GPIO Configuration PA12 ------> USB_OTG_FS_DP PA11 ------> USB_OTG_FS_DM - PA9 ------> USB_OTG_FS_VBUS + PA9 ------> USB_OTG_FS_VBUS */ HAL_GPIO_DeInit(GPIOA, GPIO_PIN_12 | GPIO_PIN_11 | GPIO_PIN_9); @@ -179,9 +179,9 @@ void HAL_PCD_MspDeInit(PCD_HandleTypeDef *pcdHandle) /* Peripheral clock disable */ __HAL_RCC_USB_OTG_HS_CLK_DISABLE(); - /**USB_OTG_HS GPIO Configuration + /**USB_OTG_HS GPIO Configuration PB14 ------> USB_OTG_HS_DM - PB15 ------> USB_OTG_HS_DP + PB15 ------> USB_OTG_HS_DP */ HAL_GPIO_DeInit(GPIOB, GPIO_PIN_14 | GPIO_PIN_15); @@ -705,7 +705,7 @@ USBD_StatusTypeDef USBD_LL_SetUSBAddress(USBD_HandleTypeDef *pdev, * @param pdev: Device handle * @param ep_addr: Endpoint number * @param pbuf: Pointer to data to be sent - * @param size: Data size + * @param size: Data size * @retval USBD status */ USBD_StatusTypeDef USBD_LL_Transmit(USBD_HandleTypeDef *pdev, diff --git a/src/usbd/usbd_conf.h b/src/usbd/usbd_conf.h index 37dee70fa..b8ea6b13f 100644 --- a/src/usbd/usbd_conf.h +++ b/src/usbd/usbd_conf.h @@ -79,7 +79,7 @@ extern "C" #define DEVICE_HS 1 /**< & */ /** - * @} + * @} */ /** @defgroup USBD_CONF_Exported_Macros USBD_CONF_Exported_Macros diff --git a/src/usbd/usbd_desc.c b/src/usbd/usbd_desc.c index 3a9941c2d..778292e40 100644 --- a/src/usbd/usbd_desc.c +++ b/src/usbd/usbd_desc.c @@ -561,8 +561,8 @@ uint8_t *USBD_FS_InterfaceStrDescriptor(USBD_SpeedTypeDef speed, } /** - * @brief Create the serial number string descriptor - * @param None + * @brief Create the serial number string descriptor + * @param None * @retval None */ static void Get_SerialNum(void) @@ -583,9 +583,9 @@ static void Get_SerialNum(void) } /** - * @brief Convert Hex 32Bits value into char + * @brief Convert Hex 32Bits value into char * @param value: value to convert - * @param pbuf: pointer to the buffer + * @param pbuf: pointer to the buffer * @param len: buffer length * @retval None */ diff --git a/src/util/CpuLoadMeter.h b/src/util/CpuLoadMeter.h index 5ae1c1c3e..1ae3fcd41 100644 --- a/src/util/CpuLoadMeter.h +++ b/src/util/CpuLoadMeter.h @@ -8,10 +8,10 @@ namespace daisy /** @brief CPU load metering * @author jelliesen * @addtogroup utility - * + * * To measure the CPU load of your audio processing, create a CpuLoadMeter * and initialize it with your block size and sample rate. - * Then at the beginning of the audio callback, call `OnBlockStart()`, + * Then at the beginning of the audio callback, call `OnBlockStart()`, * and at the end of the audio callback, call `OnBlockEnd()`. * You can then read out the minimum, maximum and average CPU load. */ @@ -99,4 +99,4 @@ class CpuLoadMeter CpuLoadMeter(const CpuLoadMeter&) = delete; CpuLoadMeter& operator=(const CpuLoadMeter&) = delete; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/FIFO.h b/src/util/FIFO.h index e44208014..193d8e687 100644 --- a/src/util/FIFO.h +++ b/src/util/FIFO.h @@ -198,7 +198,7 @@ class FIFOBase return true; } - /** removes the element "idx" positions behind the first element + /** removes the element "idx" positions behind the first element * and returns true if successful */ bool Remove(size_t idx) { @@ -326,4 +326,4 @@ class FIFO : public FIFOBase T buffer_[capacity + 1]; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/FixedCapStr.h b/src/util/FixedCapStr.h index 38350774b..da4eaaad5 100644 --- a/src/util/FixedCapStr.h +++ b/src/util/FixedCapStr.h @@ -1,4 +1,4 @@ -/** +/** * Copyright (C) Johannes Elliesen, 2021 */ @@ -481,7 +481,7 @@ class FixedCapStrBase /** @brief A safe and convenient statically allocated string with constexpr powers * @author jelliesen * @addtogroup utility - * + * * This string class is statically allocated. All of its functions can be evaluated at compile time * through the power of constexpr. */ diff --git a/src/util/MappedValue.cpp b/src/util/MappedValue.cpp index d9c3bab3b..f283103b1 100644 --- a/src/util/MappedValue.cpp +++ b/src/util/MappedValue.cpp @@ -208,4 +208,4 @@ void MappedStringListValue::Step(int16_t numStepsUp, bool useCoarseStepSize) } } -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/MappedValue.h b/src/util/MappedValue.h index 7b29f4a35..9503f325e 100644 --- a/src/util/MappedValue.h +++ b/src/util/MappedValue.h @@ -21,7 +21,7 @@ class MappedValue /** Resets the value to its default. */ virtual void ResetToDefault() = 0; - /** Returns the 0..1 normalized representation of the value, + /** Returns the 0..1 normalized representation of the value, * e.g. to display a slider/knob on a UI. */ virtual float GetAs0to1() const = 0; @@ -29,7 +29,7 @@ class MappedValue virtual void SetFrom0to1(float normalizedValue0to1) = 0; /** Steps the value up by whatever is appropriate. This function can be used - * to increment/decrement the value with buttons/encoders while making use + * to increment/decrement the value with buttons/encoders while making use * of the specific mapping. */ virtual void Step(int16_t numStepsUp, bool useCoarseStepSize) = 0; }; @@ -46,7 +46,7 @@ class MappedFloatValue : public MappedValue { /** The value is mapped linearly between min and max. */ lin, - /** The value is mapped logarithmically. Note that the valid + /** The value is mapped logarithmically. Note that the valid * values must be strictly larger than zero, so: min > 0, max > 0 */ log, @@ -62,7 +62,7 @@ class MappedFloatValue : public MappedValue * `min`, `max` and ``defaultValue` must be > 0 * @param unitStr A string for the unit, e.g. "Hz" * @param numDecimals Controls the number of decimals in `AppendToString()` - * @param forceSign Controls whether `AppendToString()` always prints the sign, + * @param forceSign Controls whether `AppendToString()` always prints the sign, * even for positive numbers */ MappedFloatValue(float min, @@ -138,7 +138,7 @@ class MappedIntValue : public MappedValue * @param stepSizeFine A fine step size to use in the `Step()` function * @param stepSizeCoarse A coarse step size to use in the `Step()` function * @param unitStr A string for the unit, e.g. "Hz" - * @param forceSign Controls whether `AppendToString()` always prints the sign, + * @param forceSign Controls whether `AppendToString()` always prints the sign, * even for positive numbers */ MappedIntValue(int min, @@ -262,4 +262,4 @@ class MappedStringListValue : public MappedValue }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/PersistentStorage.h b/src/util/PersistentStorage.h index 9661da4b3..23a8b1189 100644 --- a/src/util/PersistentStorage.h +++ b/src/util/PersistentStorage.h @@ -7,30 +7,30 @@ namespace daisy { /** @brief Non Volatile storage class for persistent settings on an external flash device. * @author shensley - * - * Storage occupied by the struct will be one word larger than + * + * Storage occupied by the struct will be one word larger than * the SettingStruct used. The extra word is used to store the * state of the data, and whether it's been overwritten or not. - * + * * \todo - Make Save() non-blocking * \todo - Add wear leveling - * + * **/ template class PersistentStorage { public: - /** State of the storage. + /** State of the storage. * When created, prior to initialiation, the state will be Unknown - * + * * During initialization, the state will be changed to either FACTORY, - * or USER. - * + * or USER. + * * If this is the first time these settings are being written to the * target address, the defaults will be written to that location, * and the state will be set to FACTORY. - * - * Once the first user-trigger save has been made, the state will be + * + * Once the first user-trigger save has been made, the state will be * updated to USER to indicate that the defaults have overwritten. */ enum class State @@ -40,7 +40,7 @@ class PersistentStorage USER = 2, }; - /** Constructor for storage class + /** Constructor for storage class * \param qspi reference to the hardware qspi peripheral. */ PersistentStorage(QSPIHandle &qspi) @@ -137,4 +137,4 @@ class PersistentStorage State state_; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/Stack.h b/src/util/Stack.h index a388cb36d..06ad61119 100644 --- a/src/util/Stack.h +++ b/src/util/Stack.h @@ -230,4 +230,4 @@ class Stack : public StackBase T buffer_[capacity]; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/VoctCalibration.h b/src/util/VoctCalibration.h index 31edcc5b3..a04069b98 100644 --- a/src/util/VoctCalibration.h +++ b/src/util/VoctCalibration.h @@ -2,17 +2,17 @@ namespace daisy { -/** @brief Helper class for calibrating an input to 1V/oct response +/** @brief Helper class for calibrating an input to 1V/oct response * @author shensley - * + * * This provides a scale and offset value for converting * incoming CV into MIDI note numbers accurately for musical pitch tracking. - * + * * To use, record both the 1V and 3V values using the specified functions * once calibration is complete you can use the GetData function to retrieve * the calibration values. - * - * This can also be used for 100mV/Semitone calibration as used by Buchla synthesizer + * + * This can also be used for 100mV/Semitone calibration as used by Buchla synthesizer * modules. To calibrate for this standard. You would send 1.2V, and 3.6V */ class VoctCalibration @@ -23,17 +23,17 @@ class VoctCalibration ~VoctCalibration() {} /** Uses the values retrieved for 1V and 3V in order to compute - * a scale and offset value that can be used to convert a CV input - * signal to a calibrated 1V/oct range. - * + * a scale and offset value that can be used to convert a CV input + * signal to a calibrated 1V/oct range. + * * \param val1V ADC reading for 1 volt * \param val3V ADC reading for 3 volts * \retval returns true if the calibraiton is successful - this is always true - * + * * \todo Add some sort of range validation. Originally we had a check * for a valid range on the input, but given that the input circuit * or the AnalogControl configuration can have a drastic effect on - * input, that could cause unintentional failure to calibrate, + * input, that could cause unintentional failure to calibrate, * it was removed. **/ bool Record(float val1V, float val3V) @@ -45,7 +45,7 @@ class VoctCalibration return cal_; } - /** Get the scale and offset data from the calibration + /** Get the scale and offset data from the calibration * \retval returns true if calibration has been performed. */ bool GetData(float &scale, float &offset) @@ -55,8 +55,8 @@ class VoctCalibration return cal_; } - /** Manually set the calibration data and mark internally as "calibrated" - * This is used to reset the data after a power cycle without having to + /** Manually set the calibration data and mark internally as "calibrated" + * This is used to reset the data after a power cycle without having to * redo the calibration procedure. */ void SetData(float scale, float offset) @@ -77,4 +77,4 @@ class VoctCalibration bool cal_; }; -} // namespace daisy \ No newline at end of file +} // namespace daisy diff --git a/src/util/WavWriter.h b/src/util/WavWriter.h index eee826d7f..efa6c5e01 100644 --- a/src/util/WavWriter.h +++ b/src/util/WavWriter.h @@ -5,11 +5,11 @@ namespace daisy { /** Audio Recording Module - ** - ** Record audio into a working buffer that is gradually written to a WAV file on an SD Card. ** - ** Recordings are made with floating point input, and will be converted to the - ** specified bits per sample internally + ** Record audio into a working buffer that is gradually written to a WAV file on an SD Card. + ** + ** Recordings are made with floating point input, and will be converted to the + ** specified bits per sample internally ** ** For now only 16-bit and 32-bit (signed int) formats are supported ** f32 and s24 formats will be added next @@ -18,7 +18,7 @@ namespace daisy ** effect on the performance of the streaming behavior of the WavWriter. ** Memory use can be calculated as: (2 * transfer_size) bytes ** Performance optimal with sizes: 16384, 32768 - ** + ** ** To use: ** 1. Create a WavWriter object (e.g. WavWriter<32768> writer) ** 2. Configure the settings as desired by creating a WavWriter<32768>::Config struct and setting the settings. @@ -27,7 +27,7 @@ namespace daisy ** 5. Write to it within your audio callback using: writer.Sample(value) ** 6. Fill the Wav File on the SD Card with data from your main loop by running: writer.Write() ** 7. When finished with the recording finalize, and close the file with: writer.SaveFile(); - ** + ** ** */ template class WavWriter @@ -52,7 +52,7 @@ class WavWriter int32_t bitspersample; }; - /** State of the internal Writing mechanism. + /** State of the internal Writing mechanism. ** When the buffer is a certain amount full one section will write its contents ** while the other is still being written to. This is performed circularly ** so that audio will be uninterrupted during writing. */ @@ -87,8 +87,8 @@ class WavWriter } /** Records the current sample into the working buffer, - ** queues writes to media when necessary. - ** + ** queues writes to media when necessary. + ** ** \param in should be a pointer to an array of samples */ void Sample(const float *in) { diff --git a/src/util/WaveTableLoader.h b/src/util/WaveTableLoader.h index 47e148f4e..0901b8f95 100644 --- a/src/util/WaveTableLoader.h +++ b/src/util/WaveTableLoader.h @@ -3,12 +3,12 @@ #include "util/wav_format.h" namespace daisy { -/** Loads a bank of wavetables into memory. - ** Pointers to the start of each waveform will be provided, +/** Loads a bank of wavetables into memory. + ** Pointers to the start of each waveform will be provided, ** but the user can do whatever they want with the data once - ** it's imported. + ** it's imported. ** - ** A internal 4kB workspace is used for reading from the file, and conveting to the correct memory location. + ** A internal 4kB workspace is used for reading from the file, and conveting to the correct memory location. ** */ class WaveTableLoader { @@ -29,13 +29,13 @@ class WaveTableLoader /** Sets the size of the tables to allow access to the specific waveforms */ Result SetWaveTableInfo(size_t samps, size_t count); - /** Opens and loads the file + /** Opens and loads the file ** The data will be converted from its original type to float - ** And the wavheader data will be stored internally to the class, + ** And the wavheader data will be stored internally to the class, ** but will not be stored in the user-provided buffer. ** ** Currently only 16-bit and 32-bit data is supported. - ** The importer also assumes data is mono so stereo data will be loaded as-is + ** The importer also assumes data is mono so stereo data will be loaded as-is ** (i.e. interleaved) ** */ Result Import(const char *filename); diff --git a/src/util/bsp_sd_diskio.c b/src/util/bsp_sd_diskio.c index a42276a65..f83039278 100644 --- a/src/util/bsp_sd_diskio.c +++ b/src/util/bsp_sd_diskio.c @@ -48,7 +48,7 @@ uint8_t BSP_SD_Init(void) /** * @brief Configures Interrupt mode for SD detection pin. - * @retval Returns 0 in success otherwise 1. + * @retval Returns 0 in success otherwise 1. */ uint8_t BSP_SD_ITConfig(void) { @@ -89,7 +89,7 @@ uint8_t BSP_SD_ReadBlocks(uint32_t *pData, /* can be used to modify previous code / undefine following code / add code */ /* USER CODE END BeforeWriteBlocksSection */ /** - * @brief Writes block(s) to a specified address in an SD card, in polling mode. + * @brief Writes block(s) to a specified address in an SD card, in polling mode. * @param pData: Pointer to the buffer that will contain the data to transmit * @param WriteAddr: Address from where data is to be written * @param NumOfBlocks: Number of SD blocks to write @@ -120,7 +120,7 @@ uint8_t BSP_SD_WriteBlocks(uint32_t *pData, * @brief Reads block(s) from a specified address in an SD card, in DMA mode. * @param pData: Pointer to the buffer that will contain the data to transmit * @param ReadAddr: Address from where data is to be read - * @param NumOfBlocks: Number of SD blocks to read + * @param NumOfBlocks: Number of SD blocks to read * @retval SD status */ uint8_t @@ -145,7 +145,7 @@ BSP_SD_ReadBlocks_DMA(uint32_t *pData, uint32_t ReadAddr, uint32_t NumOfBlocks) * @brief Writes block(s) to a specified address in an SD card, in DMA mode. * @param pData: Pointer to the buffer that will contain the data to transmit * @param WriteAddr: Address from where data is to be written - * @param NumOfBlocks: Number of SD blocks to write + * @param NumOfBlocks: Number of SD blocks to write * @retval SD status */ uint8_t BSP_SD_WriteBlocks_DMA(uint32_t *pData, @@ -168,7 +168,7 @@ uint8_t BSP_SD_WriteBlocks_DMA(uint32_t *pData, /* can be used to modify previous code / undefine following code / add code */ /* USER CODE END BeforeEraseSection */ /** - * @brief Erases the specified memory area of the given SD card. + * @brief Erases the specified memory area of the given SD card. * @param StartAddr: Start byte address * @param EndAddr: End byte address * @retval SD status @@ -206,7 +206,7 @@ uint8_t BSP_SD_GetCardState(void) /** * @brief Get SD information about specific SD card. * @param CardInfo: Pointer to HAL_SD_CardInfoTypedef structure - * @retval None + * @retval None */ //void BSP_SD_GetCardInfo(HAL_SD_CardInfoTypeDef *CardInfo) void BSP_SD_GetCardInfo(DSY_SD_CardInfoTypeDef *CardInfo) diff --git a/src/util/bsp_sd_diskio.h b/src/util/bsp_sd_diskio.h index 0cee7986e..d1ba17768 100644 --- a/src/util/bsp_sd_diskio.h +++ b/src/util/bsp_sd_diskio.h @@ -13,7 +13,7 @@ and won't need to be accessed directly often. */ -/* +/* This struct is identical to the struct provided as "HAL_SD_CardInfoTypeDef" I'm using this to allow users to link to the fatfs middleware without having to then link in the entire HAL to their project. */ @@ -110,7 +110,7 @@ void BSP_SD_GetCardInfo(BSP_SD_CardInfo *CardInfo); uint8_t BSP_SD_IsDetected(void); /** These functions can be modified in case the current settings (e.g. DMA stream) - need to be changed for specific application needs /n + need to be changed for specific application needs /n Abort the callback */ void BSP_SD_AbortCallback(void); diff --git a/src/util/color.h b/src/util/color.h index ef7036b66..e496649b0 100644 --- a/src/util/color.h +++ b/src/util/color.h @@ -1,4 +1,4 @@ -/* +/* TODO: - Add Blend(), Scale(), etc. - I'd also like to change the way the Color names are accessed. @@ -39,7 +39,7 @@ class Color LAST /**< & */ }; - /** Initializes the Color with a given preset. + /** Initializes the Color with a given preset. \param c Color to init to */ void Init(PresetColor c); diff --git a/src/util/hal_map.h b/src/util/hal_map.h index acb7d23e4..808d26976 100644 --- a/src/util/hal_map.h +++ b/src/util/hal_map.h @@ -17,12 +17,12 @@ */ /** \param *p Pin pin to get - \return HAL GPIO_TypeDef as used in the HAL from a dsy_gpio_pin input. + \return HAL GPIO_TypeDef as used in the HAL from a dsy_gpio_pin input. */ GPIO_TypeDef *dsy_hal_map_get_port(const dsy_gpio_pin *p); /** \param *p Pin pin to get - \return HAL GPIO Pin as used in the HAL from a dsy_gpio_pin input. + \return HAL GPIO Pin as used in the HAL from a dsy_gpio_pin input. */ uint16_t dsy_hal_map_get_pin(const dsy_gpio_pin *p); diff --git a/src/util/oled_fonts.h b/src/util/oled_fonts.h index 57653b8d2..15416ba3d 100644 --- a/src/util/oled_fonts.h +++ b/src/util/oled_fonts.h @@ -7,8 +7,8 @@ @{ */ -/** Utility for displaying fonts on OLED displays \n -Migrated to work with libdaisy from stm32-ssd1306 +/** Utility for displaying fonts on OLED displays \n +Migrated to work with libdaisy from stm32-ssd1306 @author afiskon on github. */ diff --git a/src/util/ringbuffer.h b/src/util/ringbuffer.h index 9d8640cb0..e0c921219 100644 --- a/src/util/ringbuffer.h +++ b/src/util/ringbuffer.h @@ -11,7 +11,7 @@ namespace daisy */ /** -Utility Ring Buffer \n +Utility Ring Buffer \n imported from pichenettes/stmlib */ template @@ -48,7 +48,7 @@ class RingBuffer Overwrite(v); } - /** Writes the new element to the ring buffer, overwriting unread data if necessary. + /** Writes the new element to the ring buffer, overwriting unread data if necessary. \param v Value to overwrite */ inline void Overwrite(T v) @@ -82,7 +82,7 @@ class RingBuffer /** Flushes unread elements from the ring buffer */ inline void Flush() { write_ptr_ = read_ptr_; } - /** Read enough samples to make it possible to read 1 sample. + /** Read enough samples to make it possible to read 1 sample. \param n Size of T ? */ inline void Swallow(size_t n) @@ -96,7 +96,7 @@ class RingBuffer /** Reads a number of elements into a buffer immediately \param destination buffer to write to - \param num_elements number of elements in buffer + \param num_elements number of elements in buffer */ inline void ImmediateRead(T* destination, size_t num_elements) { @@ -116,7 +116,7 @@ class RingBuffer read_ptr_ = (r + num_elements) % size; } - /** Overwrites a number of elements using the source buffer as input. + /** Overwrites a number of elements using the source buffer as input. \param source Input buffer \param num_elements Number of elements in source */ diff --git a/src/util/unique_id.h b/src/util/unique_id.h index 7998c4bec..770dfb7f2 100644 --- a/src/util/unique_id.h +++ b/src/util/unique_id.h @@ -19,7 +19,7 @@ extern "C" @date May 2020 */ - /** fills the three pointer arguments with the unique ID of the MCU. + /** fills the three pointer arguments with the unique ID of the MCU. \param *w0 First pointer \param *w1 Second pointer \param *w2 Third pointer diff --git a/src/util/wav_format.h b/src/util/wav_format.h index 36282a5cd..deb15a7c8 100644 --- a/src/util/wav_format.h +++ b/src/util/wav_format.h @@ -18,7 +18,7 @@ const uint32_t kWavFileSubChunk1Id = 0x20746d66; /**< "fmt " */ const uint32_t kWavFileSubChunk2Id = 0x61746164; /**< "data" */ /** Standard Format codes for the waveform data. - ** + ** ** According to spec, extensible should be used whenever: ** * PCM data has more than 16 bits/sample ** * The number of channels is more than 2 diff --git a/tests/AbstractMenu_gtest.cpp b/tests/AbstractMenu_gtest.cpp index 29d8eab9c..b9573f104 100644 --- a/tests/AbstractMenu_gtest.cpp +++ b/tests/AbstractMenu_gtest.cpp @@ -5,7 +5,7 @@ using namespace daisy; -/** Exposes some of the internals of AbstractMenu to make them +/** Exposes some of the internals of AbstractMenu to make them * accessible from unit tests. */ class ExposedAbstractMenu : public AbstractMenu @@ -119,7 +119,7 @@ class ExposedAbstractMenu : public AbstractMenu testObject.callbackFunctionCalled_ = true; } - /** A MappedIntValue that exposes calls to its functions so + /** A MappedIntValue that exposes calls to its functions so * that unit tests can observer when the Abstractmenu calls them. */ class ExposedMappedIntValue : public MappedIntValue @@ -979,4 +979,4 @@ TEST(ui_AbstractMenu, m_closeMenu) // close menu with the cancel button menu.OnCancelButton(1, false); EXPECT_FALSE(menu.IsActive()); -} \ No newline at end of file +} diff --git a/tests/CpuLoadMeter_gtest.cpp b/tests/CpuLoadMeter_gtest.cpp index cbbb65559..78d9ff054 100644 --- a/tests/CpuLoadMeter_gtest.cpp +++ b/tests/CpuLoadMeter_gtest.cpp @@ -152,4 +152,4 @@ TEST(util_CpuLoadMeter, e_tolerateTickOverflow) // check results - meter should have tolerated the overflow EXPECT_FLOAT_EQ(meter.GetMinCpuLoad(), 0.5f); EXPECT_FLOAT_EQ(meter.GetMaxCpuLoad(), 0.5f); -} \ No newline at end of file +} diff --git a/tests/FIFO_gtest.cpp b/tests/FIFO_gtest.cpp index 095785e26..8fa65e01f 100644 --- a/tests/FIFO_gtest.cpp +++ b/tests/FIFO_gtest.cpp @@ -204,4 +204,4 @@ TEST_F(util_FIFO, j_countEqualTo) EXPECT_EQ(fifo_.CountEqualTo(2), 2u); EXPECT_EQ(fifo_.CountEqualTo(3), 1u); -} \ No newline at end of file +} diff --git a/tests/FixedCapStr_gtest.cpp b/tests/FixedCapStr_gtest.cpp index 13b486f7c..91d170243 100644 --- a/tests/FixedCapStr_gtest.cpp +++ b/tests/FixedCapStr_gtest.cpp @@ -543,4 +543,4 @@ TEST(util_FixedCapStr, u_appendFloat) static constexpr auto constexprAppendFloatTest = getStringFunc(); EXPECT_STREQ(constexprAppendFloatTest, "ab12.35"); #endif -} \ No newline at end of file +} diff --git a/tests/MAX11300_gtest.cpp b/tests/MAX11300_gtest.cpp index 25776bab4..4cb0dbefc 100644 --- a/tests/MAX11300_gtest.cpp +++ b/tests/MAX11300_gtest.cpp @@ -11,7 +11,7 @@ using namespace daisy; static constexpr size_t num_devices = 2; /** - * This is a mock transport implementation with hooks for verifying the + * This is a mock transport implementation with hooks for verifying the * SPI transactions invoked by the driver at the byte level. All calls from * the MAX11300 driver (our system-under-test) to the transport will be * examined during the test to verify that the driver sent the correct @@ -146,14 +146,14 @@ using MAX11300Test = daisy::MAX11300Driver; * It manages some common setup/teardown and provides basic testing functions for each * test case. This helps keep the test cases small and readable by extracting commonly used * "helper" code out of the test cases. - * + * * Internally, it holds a buffer of expected SPI transactions. The individual test cases * can fill that buffer with expected transactions and eventually call some function on the * MAX11300 driver (our SUT). The SUT will execute and call its transport layer to send and * receive data via SPI. We use a mocked transport layer that doesn't actually use a hardware * SPI - instead it refers to the buffer of expected SPI transactions; comparing the actual * transaction to the expected transaction and failing the test if there's a mismatch. - * + * * For that reason, all test cases look like this: * - init the driver (this is done implicitly at the start of each test when the * googletest framework executes SetUp() here in the fixture base class): @@ -175,7 +175,7 @@ class MAX11300TestFixture : public ::testing::Test public: /** * This struct holds a TX SPI transaction with which the contents of "buff" will be - * compared, byte for byte, with the output of the driver. If these do not match, + * compared, byte for byte, with the output of the driver. If these do not match, * The test will fail. */ struct TxTransaction @@ -188,9 +188,9 @@ class MAX11300TestFixture : public ::testing::Test /** * This struct holds a TXRX SPI transaction with which the contents of "tx_buff" will be - * compared, byte for byte, with the tx_buffer of the SPI transaction. If these do not match, + * compared, byte for byte, with the tx_buffer of the SPI transaction. If these do not match, * The test will fail. - * + * * Bytes added to the "rx_buff" will be interpreted by the driver, as if they were received * by the MAX11300 device itself, and can be used to further verify driver behavior. */ @@ -204,10 +204,10 @@ class MAX11300TestFixture : public ::testing::Test }; /** - * Pins/ports of the MAX11300 are freely configurable to function as - * ANALOG_IN (ADC), ANALOG_OUT (DAC), GPI, or GPO. + * Pins/ports of the MAX11300 are freely configurable to function as + * ANALOG_IN (ADC), ANALOG_OUT (DAC), GPI, or GPO. * This enum describes these modes. - * We don't use the same enum from the actual driver code, so that we + * We don't use the same enum from the actual driver code, so that we * don't end up testing the code with itself. */ enum class PinMode diff --git a/tests/Makefile b/tests/Makefile index 9e904eef1..bdc8aec08 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -1,14 +1,14 @@ ### Based on: https://gist.github.com/mauriciopoppe/de8908f67923091982c8c8136a063ea6 ### Thanks! -CXX ?= clang++ +CXX ?= clang++ # path # SRC_PATH = . BUILD_PATH = build BIN_PATH = $(BUILD_PATH)/bin -# executable # +# executable # BIN_NAME = libDaisy_gtest # extensions # diff --git a/tests/MappedValue_gtest.cpp b/tests/MappedValue_gtest.cpp index 2d0c4da8c..75b4b5ef4 100644 --- a/tests/MappedValue_gtest.cpp +++ b/tests/MappedValue_gtest.cpp @@ -495,4 +495,4 @@ TEST(util_MappedStringListValue, e_stepUpDown) val = 4; val.Step(-100, false); EXPECT_EQ(val, 0); -} \ No newline at end of file +} diff --git a/tests/Midi_gtest.cpp b/tests/Midi_gtest.cpp index 28b15a037..7c7816072 100644 --- a/tests/Midi_gtest.cpp +++ b/tests/Midi_gtest.cpp @@ -783,4 +783,4 @@ TEST_F(MidiTest, singleByteRunningStatusTest) } EXPECT_FALSE(midi.HasEvents()); -} \ No newline at end of file +} diff --git a/tests/PersistentStorage_gtest.cpp b/tests/PersistentStorage_gtest.cpp index b00a32f34..9cfc21774 100644 --- a/tests/PersistentStorage_gtest.cpp +++ b/tests/PersistentStorage_gtest.cpp @@ -151,4 +151,4 @@ TEST(per_QSPIHandle_mock, c_testWrite) val = testsize / 2; test = data[testoffset+val]; EXPECT_EQ(test, val & 0xff); -} \ No newline at end of file +} diff --git a/tests/Rectangle_gtest.cpp b/tests/Rectangle_gtest.cpp index b44ce0242..93b911937 100644 --- a/tests/Rectangle_gtest.cpp +++ b/tests/Rectangle_gtest.cpp @@ -212,4 +212,4 @@ TEST(hid_disp_Rectangle, k_alignedWithin) Rectangle(90, 45, 10, 10)); EXPECT_EQ(srcRect.AlignedWithin(boundingBox, Alignment::centered), Rectangle(45, 45, 10, 10)); -} \ No newline at end of file +} diff --git a/tests/Stack_gtest.cpp b/tests/Stack_gtest.cpp index 5c5d78fb1..9ccdad4ec 100644 --- a/tests/Stack_gtest.cpp +++ b/tests/Stack_gtest.cpp @@ -103,7 +103,7 @@ TEST_F(util_Stack, e_removeByIndex) EXPECT_TRUE(stack_.Remove(1)); // cannot remove at index 2 (only two items left) EXPECT_FALSE(stack_.Remove(2)); - + // values are correct EXPECT_EQ(stack_[0], 1); EXPECT_EQ(stack_[1], 3); @@ -123,7 +123,7 @@ TEST_F(util_Stack, f_removeByValue) EXPECT_EQ(stack_.RemoveAllEqualTo(2), 1); // remove all values "2" => no items removed EXPECT_EQ(stack_.RemoveAllEqualTo(2), 0); - + // values are correct EXPECT_EQ(stack_[0], 1); EXPECT_EQ(stack_[1], 3); @@ -133,7 +133,7 @@ TEST_F(util_Stack, g_passByReference) { stack_.PushBack(1); EXPECT_EQ(stack_[0], 1); - + // operator[] passes by reference so that we can modify the values // like a plain old C-array. stack_[0] = 4; @@ -143,7 +143,7 @@ TEST_F(util_Stack, g_passByReference) TEST_F(util_Stack, h_contains) { stack_.PushBack({1, 2, 3}); - + EXPECT_TRUE(stack_.Contains(1)); EXPECT_TRUE(stack_.Contains(2)); EXPECT_TRUE(stack_.Contains(3)); @@ -153,8 +153,8 @@ TEST_F(util_Stack, h_contains) TEST_F(util_Stack, i_countEqualTo) { stack_.PushBack({1, 2, 2}); - + EXPECT_EQ(stack_.CountEqualTo(1), 1u); EXPECT_EQ(stack_.CountEqualTo(2), 2u); EXPECT_EQ(stack_.CountEqualTo(3), 0u); -} \ No newline at end of file +} diff --git a/tests/TestIsolator.h b/tests/TestIsolator.h index 622976624..9b6f100fd 100644 --- a/tests/TestIsolator.h +++ b/tests/TestIsolator.h @@ -4,20 +4,20 @@ #include #include -/** Whenever you need to provide a "fake" implementation +/** Whenever you need to provide a "fake" implementation * for a static class or function (e.g. System::GetNow()) - * your dummy implementation will be "global" because it is + * your dummy implementation will be "global" because it is * static. This can lead to problems when multiple tests are * run in parallel and influence each other. Or when one test * modifies the state of the "static" function/class and thus * creates an unknown initial condition for a following test. * This can lead to unreliable, flaky tests. - * + * * This little helper class is designed to deal with that. * It keeps a unique "State" for each test and returns * the correct "State" based on the test that's currently - * executing. This way, each test gets its own, unique - * "State" and all tests stay separated from each other, + * executing. This way, each test gets its own, unique + * "State" and all tests stay separated from each other, * even though they call the same static functions. */ template @@ -60,4 +60,4 @@ class TestIsolator std::mutex mutex_; std::map> testStates_; -}; \ No newline at end of file +}; diff --git a/tests/VoctCalibration_gtest.cpp b/tests/VoctCalibration_gtest.cpp index c9c78f2d8..1f7be54a3 100644 --- a/tests/VoctCalibration_gtest.cpp +++ b/tests/VoctCalibration_gtest.cpp @@ -64,7 +64,7 @@ TEST(util_VoctCalibration, c_postCalibrationProcessing) EXPECT_FLOAT_EQ(testValues[3], octMidiNotes[3]); } -TEST(util_VoctCalibration, d_manualValueSetting) +TEST(util_VoctCalibration, d_manualValueSetting) { VoctCalibration cal; @@ -81,4 +81,4 @@ TEST(util_VoctCalibration, d_manualValueSetting) EXPECT_TRUE(isCalibrated); EXPECT_FLOAT_EQ(scale, 60.f); EXPECT_FLOAT_EQ(offset, -1.f); -} \ No newline at end of file +} diff --git a/tests/gtest-all.cpp b/tests/gtest-all.cpp index f88e520a0..c57ee36d5 100644 --- a/tests/gtest-all.cpp +++ b/tests/gtest-all.cpp @@ -1,3 +1,3 @@ // The .cpp => .o rule relies on the cpp files being in the exact same folder hierarchy as the .o files in the build directory. // I'm no makefile guru - how can we add files in ../googletest/src to the makefile directly without this ugly include here?! -#include "googletest/src/gtest-all.cc" \ No newline at end of file +#include "googletest/src/gtest-all.cc" diff --git a/tests/gtest_main.cpp b/tests/gtest_main.cpp index 950d6df20..8bc786b70 100644 --- a/tests/gtest_main.cpp +++ b/tests/gtest_main.cpp @@ -38,4 +38,4 @@ int main(int argc, char **argv) #endif testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); -} \ No newline at end of file +}