From 25d802532c27f11a6445f71ef44af98a2a780864 Mon Sep 17 00:00:00 2001 From: hathach Date: Fri, 17 Mar 2023 17:27:34 +0700 Subject: [PATCH] fix spelling --- .codespell/ignore-words.txt | 2 ++ .codespellrc | 2 +- .pre-commit-config.yaml | 2 ++ .../da1469x/SDK_10.0.8.105/sdk/bsp/include/DA1469xAB.h | 10 +++++----- hw/mcu/dialog/da1469x/src/system_da1469x.c | 2 +- .../nrf5x/s140_nrf52_6.1.1_API/include/ble_l2cap.h | 2 +- hw/mcu/sony/cxd56/tools/flash_writer.py | 6 +++--- hw/mcu/sony/cxd56/tools/xmodem.py | 4 ++-- test/unit-test/vendor/ceedling/bin/ceedling | 2 +- test/unit-test/vendor/ceedling/lib/ceedling.rb | 2 +- .../lib/ceedling/preprocessinator_includes_handler.rb | 2 +- .../vendor/ceedling/lib/ceedling/rules_preprocess.rake | 2 +- .../vendor/ceedling/lib/ceedling/system_utils.rb | 2 +- .../ceedling/plugins/dependencies/dependencies.rake | 2 +- .../ceedling/plugins/fake_function_framework/README.md | 2 +- .../examples/fff_example/project.yml | 2 +- .../examples/fff_example/test/test_event_processor.c | 2 +- .../lib/fake_function_framework.rb | 2 +- .../plugins/gcov/lib/reportgenerator_reportinator.rb | 2 +- .../vendor/ceedling/plugins/module_generator/README.md | 2 +- .../ceedling/vendor/cmock/lib/cmock_header_parser.rb | 4 ++-- .../ceedling/vendor/unity/auto/generate_test_runner.rb | 2 +- .../unit-test/vendor/ceedling/vendor/unity/src/unity.c | 2 +- 23 files changed, 33 insertions(+), 29 deletions(-) diff --git a/.codespell/ignore-words.txt b/.codespell/ignore-words.txt index e1ad88a07..fc14fe417 100644 --- a/.codespell/ignore-words.txt +++ b/.codespell/ignore-words.txt @@ -7,3 +7,5 @@ dout mot te attch +endianess +pris diff --git a/.codespellrc b/.codespellrc index 8c32ed706..dc089903c 100644 --- a/.codespellrc +++ b/.codespellrc @@ -7,4 +7,4 @@ exclude-file = .codespell/exclude-file.txt check-filenames = check-hidden = count = -skip = .cproject,./.git,./hw/mcu,./lib,./examples/*/*/_build,./examples/*/*/ses,./examples/*/*/ozone,./hw/mcu,./test/unit-test/vendor,./tests_obsolete,./tools/uf2 +skip = *.rb,.cproject,.git,./lib,./examples/*/*/_build,./examples/*/*/ses,./examples/*/*/ozone,./hw/mcu,./tests_obsolete diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7d7c1a3ce..d37c27d40 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,6 +15,8 @@ repos: rev: v2.2.4 hooks: - id: codespell + args: [-w] + exclude: ^lib/ - repo: local hooks: diff --git a/hw/mcu/dialog/da1469x/SDK_10.0.8.105/sdk/bsp/include/DA1469xAB.h b/hw/mcu/dialog/da1469x/SDK_10.0.8.105/sdk/bsp/include/DA1469xAB.h index fa2ca5d94..faf8b852a 100644 --- a/hw/mcu/dialog/da1469x/SDK_10.0.8.105/sdk/bsp/include/DA1469xAB.h +++ b/hw/mcu/dialog/da1469x/SDK_10.0.8.105/sdk/bsp/include/DA1469xAB.h @@ -954,11 +954,11 @@ typedef struct { /*!< (@ 0x50030A00) LRA Structur __IOM uint32_t LRA_FLT_COEF3_REG; /*!< (@ 0x00000034) LRA Filter Coefficient Register */ __IOM uint32_t LRA_BRD_LS_REG; /*!< (@ 0x00000038) LRA Bridge Register */ __IOM uint32_t LRA_BRD_HS_REG; /*!< (@ 0x0000003C) LRA Bridge Register */ - __IOM uint32_t LRA_BRD_STAT_REG; /*!< (@ 0x00000040) LRA Bridge Staus Register */ + __IOM uint32_t LRA_BRD_STAT_REG; /*!< (@ 0x00000040) LRA Bridge Status Register */ __IOM uint32_t LRA_ADC_CTRL1_REG; /*!< (@ 0x00000044) General Purpose ADC Control Register */ __IM uint32_t RESERVED[2]; __IOM uint32_t LRA_ADC_RESULT_REG; /*!< (@ 0x00000050) General Purpose ADC Result Register */ - __IOM uint32_t LRA_LDO_REG; /*!< (@ 0x00000054) LRA LDO Regsiter */ + __IOM uint32_t LRA_LDO_REG; /*!< (@ 0x00000054) LRA LDO Register */ __IOM uint32_t LRA_DFT_REG; /*!< (@ 0x00000058) LRA test Register */ } LRA_Type; /*!< Size = 92 (0x5c) */ @@ -1043,7 +1043,7 @@ typedef struct { /*!< (@ 0x50000200) PDC Structur __IOM uint32_t PDC_CTRL15_REG; /*!< (@ 0x0000003C) PDC control register */ __IM uint32_t RESERVED[16]; __IOM uint32_t PDC_ACKNOWLEDGE_REG; /*!< (@ 0x00000080) Clear a pending PDC bit */ - __IOM uint32_t PDC_PENDING_REG; /*!< (@ 0x00000084) Shows any pending wakup event */ + __IOM uint32_t PDC_PENDING_REG; /*!< (@ 0x00000084) Shows any pending wakeup event */ __IOM uint32_t PDC_PENDING_SNC_REG; /*!< (@ 0x00000088) Shows any pending IRQ to SNC */ __IOM uint32_t PDC_PENDING_CM33_REG; /*!< (@ 0x0000008C) Shows any pending IRQ to CM33 */ __IOM uint32_t PDC_PENDING_CMAC_REG; /*!< (@ 0x00000090) Shows any pending IRQ to CM33 */ @@ -1752,8 +1752,8 @@ typedef struct { /*!< (@ 0x50000100) WAKEUP Struc __IOM uint32_t WKUP_SELECT_P1_REG; /*!< (@ 0x00000018) select which inputs from P1 port can trigger wkup counter */ __IM uint32_t RESERVED2[3]; - __IOM uint32_t WKUP_POL_P0_REG; /*!< (@ 0x00000028) select the sesitivity polarity for each P0 input */ - __IOM uint32_t WKUP_POL_P1_REG; /*!< (@ 0x0000002C) select the sesitivity polarity for each P1 input */ + __IOM uint32_t WKUP_POL_P0_REG; /*!< (@ 0x00000028) select the sensitivity polarity for each P0 input */ + __IOM uint32_t WKUP_POL_P1_REG; /*!< (@ 0x0000002C) select the sensitivity polarity for each P1 input */ __IM uint32_t RESERVED3[3]; __IOM uint32_t WKUP_STATUS_P0_REG; /*!< (@ 0x0000003C) Event status register for P0 */ __IOM uint32_t WKUP_STATUS_P1_REG; /*!< (@ 0x00000040) Event status register for P1 */ diff --git a/hw/mcu/dialog/da1469x/src/system_da1469x.c b/hw/mcu/dialog/da1469x/src/system_da1469x.c index 538bac79f..91477b553 100644 --- a/hw/mcu/dialog/da1469x/src/system_da1469x.c +++ b/hw/mcu/dialog/da1469x/src/system_da1469x.c @@ -34,7 +34,7 @@ SystemInit(void) __ISB(); #endif - /* Freez watchdog */ + /* Freeze watchdog */ GPREG->SET_FREEZE_REG |= GPREG_SET_FREEZE_REG_FRZ_SYS_WDOG_Msk; /* Initialize power domains (disable radio only) */ CRG_TOP->PMU_CTRL_REG = CRG_TOP_PMU_CTRL_REG_RADIO_SLEEP_Msk; diff --git a/hw/mcu/nordic/nrf5x/s140_nrf52_6.1.1_API/include/ble_l2cap.h b/hw/mcu/nordic/nrf5x/s140_nrf52_6.1.1_API/include/ble_l2cap.h index edaf6641f..8cbed0fac 100644 --- a/hw/mcu/nordic/nrf5x/s140_nrf52_6.1.1_API/include/ble_l2cap.h +++ b/hw/mcu/nordic/nrf5x/s140_nrf52_6.1.1_API/include/ble_l2cap.h @@ -286,7 +286,7 @@ typedef struct /**@brief L2CAP event structure. */ typedef struct { - uint16_t conn_handle; /**< Connection Handle on which the event occured. */ + uint16_t conn_handle; /**< Connection Handle on which the event occurred. */ uint16_t local_cid; /**< Local Channel ID of the L2CAP channel, or @ref BLE_L2CAP_CID_INVALID if not present. */ union diff --git a/hw/mcu/sony/cxd56/tools/flash_writer.py b/hw/mcu/sony/cxd56/tools/flash_writer.py index 840f10c32..bf630547a 100755 --- a/hw/mcu/sony/cxd56/tools/flash_writer.py +++ b/hw/mcu/sony/cxd56/tools/flash_writer.py @@ -46,7 +46,7 @@ import xmodem import_serial_module = True -# When SDK release, plase set SDK_RELEASE as True. +# When SDK release, please set SDK_RELEASE as True. SDK_RELEASE = False if SDK_RELEASE : @@ -508,7 +508,7 @@ def main(): do_wait_reset = True if ConfigArgs.AUTO_RESET: if subprocess.call("cd " + sys.path[0] + "; ./reset_board.sh", shell=True) == 0: - print("auto reset board sucess!!") + print("auto reset board success!!") do_wait_reset = False bootrom_msg = writer.cancel_autoboot() @@ -536,7 +536,7 @@ def main(): # Remove files if ConfigArgs.ERASE_NAME : - print(">>> Remove exisiting files ...") + print(">>> Remove existing files ...") writer.delete_files(ConfigArgs.ERASE_NAME) # Install files diff --git a/hw/mcu/sony/cxd56/tools/xmodem.py b/hw/mcu/sony/cxd56/tools/xmodem.py index c93430056..60fcc952c 100644 --- a/hw/mcu/sony/cxd56/tools/xmodem.py +++ b/hw/mcu/sony/cxd56/tools/xmodem.py @@ -147,7 +147,7 @@ class XMODEM(object): >>> modem = XMODEM(getc, putc) - :param getc: Function to retreive bytes from a stream + :param getc: Function to retrieve bytes from a stream :type getc: callable :param putc: Function to transmit bytes to a stream :type putc: callable @@ -215,7 +215,7 @@ class XMODEM(object): >>> print modem.send(stream) True - Returns ``True`` upon succesful transmission or ``False`` in case of + Returns ``True`` upon successful transmission or ``False`` in case of failure. :param stream: The stream object to send data from. diff --git a/test/unit-test/vendor/ceedling/bin/ceedling b/test/unit-test/vendor/ceedling/bin/ceedling index d110f3d4c..b317db2f1 100644 --- a/test/unit-test/vendor/ceedling/bin/ceedling +++ b/test/unit-test/vendor/ceedling/bin/ceedling @@ -86,7 +86,7 @@ unless (project_found) end end - # Genarate gitkeep in test support path + # Generate gitkeep in test support path FileUtils.touch(File.join(test_support_path, '.gitkeep')) # If documentation requested, create a place to dump them and do so diff --git a/test/unit-test/vendor/ceedling/lib/ceedling.rb b/test/unit-test/vendor/ceedling/lib/ceedling.rb index 6c57fb48d..063cfddd5 100644 --- a/test/unit-test/vendor/ceedling/lib/ceedling.rb +++ b/test/unit-test/vendor/ceedling/lib/ceedling.rb @@ -77,7 +77,7 @@ module Ceedling # * The gem name must be prefixed with 'ceedling-' followed by the plugin # name (ex. 'ceedling-bullseye') # - # * The contents of the plugin must be isntalled into a subdirectory of + # * The contents of the plugin must be installed into a subdirectory of # the gem with the same name as the plugin (ex. 'bullseye/') # # === Arguments diff --git a/test/unit-test/vendor/ceedling/lib/ceedling/preprocessinator_includes_handler.rb b/test/unit-test/vendor/ceedling/lib/ceedling/preprocessinator_includes_handler.rb index 916d31332..9e5ae1fbf 100644 --- a/test/unit-test/vendor/ceedling/lib/ceedling/preprocessinator_includes_handler.rb +++ b/test/unit-test/vendor/ceedling/lib/ceedling/preprocessinator_includes_handler.rb @@ -181,7 +181,7 @@ class PreprocessinatorIncludesHandler end # If we found a real file, delete it from the array and return it, # otherwise return nil. Since nil is falsy this has the effect of making - # find_all return only the annotated filess for which a real file was + # find_all return only the annotated files for which a real file was # found/deleted idx ? real_files.delete_at(idx) : nil end.compact diff --git a/test/unit-test/vendor/ceedling/lib/ceedling/rules_preprocess.rake b/test/unit-test/vendor/ceedling/lib/ceedling/rules_preprocess.rake index 936961ce8..d599421c0 100644 --- a/test/unit-test/vendor/ceedling/lib/ceedling/rules_preprocess.rake +++ b/test/unit-test/vendor/ceedling/lib/ceedling/rules_preprocess.rake @@ -9,7 +9,7 @@ rule(/#{PROJECT_TEST_PREPROCESS_FILES_PATH}\/.+/ => [ end ]) do |file| if (not @ceedling[:configurator].project_use_deep_dependencies) - raise 'ERROR: Ceedling preprocessing rule invoked though neccessary auxiliary dependency support not enabled.' + raise 'ERROR: Ceedling preprocessing rule invoked though necessary auxiliary dependency support not enabled.' end @ceedling[:generator].generate_preprocessed_file(TEST_SYM, file.source) end diff --git a/test/unit-test/vendor/ceedling/lib/ceedling/system_utils.rb b/test/unit-test/vendor/ceedling/lib/ceedling/system_utils.rb index 81bb7bc54..7d232a7fb 100644 --- a/test/unit-test/vendor/ceedling/lib/ceedling/system_utils.rb +++ b/test/unit-test/vendor/ceedling/lib/ceedling/system_utils.rb @@ -7,7 +7,7 @@ end ## -# Class containing system utility funcions. +# Class containing system utility functions. class SystemUtils constructor :system_wrapper diff --git a/test/unit-test/vendor/ceedling/plugins/dependencies/dependencies.rake b/test/unit-test/vendor/ceedling/plugins/dependencies/dependencies.rake index 08a1a48eb..4b9409bed 100644 --- a/test/unit-test/vendor/ceedling/plugins/dependencies/dependencies.rake +++ b/test/unit-test/vendor/ceedling/plugins/dependencies/dependencies.rake @@ -113,7 +113,7 @@ end # Add any artifact:include or :source folders to our release & test includes paths so linking and mocking work. @ceedling[DEPENDENCIES_SYM].add_headers_and_sources() -# Add tasks for building or cleaning ALL depencies +# Add tasks for building or cleaning ALL dependencies namespace DEPENDENCIES_SYM do desc "Deploy missing dependencies." task :deploy => DEPENDENCIES_LIBRARIES.map{|deplib| "#{DEPENDENCIES_SYM}:deploy:#{@ceedling[DEPENDENCIES_SYM].get_name(deplib)}"} diff --git a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/README.md b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/README.md index 8042775e5..c99a95196 100644 --- a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/README.md +++ b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/README.md @@ -34,7 +34,7 @@ In the `:plugins` configuration, add `fake_function_framework` to the list of en - module_generator - fake_function_framework ``` -*Note that you could put the plugin source in some other loaction. +*Note that you could put the plugin source in some other location. In that case you'd need to add a new path the `:load_paths`.* ## How to use it diff --git a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/project.yml b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/project.yml index 00e395d0c..3253acf69 100644 --- a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/project.yml +++ b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/project.yml @@ -33,7 +33,7 @@ # in order to add common defines: # 1) remove the trailing [] from the :common: section # 2) add entries to the :common: section (e.g. :test: has TEST defined) - :commmon: &common_defines [] + :common: &common_defines [] :test: - *common_defines - TEST diff --git a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/test/test_event_processor.c b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/test/test_event_processor.c index 9f999443d..ea59cd3e6 100644 --- a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/test/test_event_processor.c +++ b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/examples/fff_example/test/test_event_processor.c @@ -41,7 +41,7 @@ test_whenThePowerReadingIsLessThan5_thenTheStatusLedIsNotTurnedOn(void) } /* - Test that a single function was called with the correct arugment. + Test that a single function was called with the correct argument. */ void test_whenTheVolumeKnobIsMaxed_thenVolumeDisplayIsSetTo11(void) diff --git a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/lib/fake_function_framework.rb b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/lib/fake_function_framework.rb index 51a90b3a5..8fbb1e9b5 100644 --- a/test/unit-test/vendor/ceedling/plugins/fake_function_framework/lib/fake_function_framework.rb +++ b/test/unit-test/vendor/ceedling/plugins/fake_function_framework/lib/fake_function_framework.rb @@ -23,7 +23,7 @@ class FakeFunctionFramework < Plugin # all mocks linked into the test. File.open(arg_hash[:runner_file], 'a') do |f| f.puts - f.puts "//=======Defintions of FFF variables=====" + f.puts "//=======Definitions of FFF variables=====" f.puts %{#include "fff.h"} f.puts "DEFINE_FFF_GLOBALS;" end diff --git a/test/unit-test/vendor/ceedling/plugins/gcov/lib/reportgenerator_reportinator.rb b/test/unit-test/vendor/ceedling/plugins/gcov/lib/reportgenerator_reportinator.rb index d4a885c97..96cf89163 100644 --- a/test/unit-test/vendor/ceedling/plugins/gcov/lib/reportgenerator_reportinator.rb +++ b/test/unit-test/vendor/ceedling/plugins/gcov/lib/reportgenerator_reportinator.rb @@ -138,7 +138,7 @@ class ReportGeneratorReportinator # Removing trailing ';' after the last report type. args = args.chomp(";") - # Append a space seperator after the report type. + # Append a space separator after the report type. args += "\" " end diff --git a/test/unit-test/vendor/ceedling/plugins/module_generator/README.md b/test/unit-test/vendor/ceedling/plugins/module_generator/README.md index 61cf45bd6..c7e982352 100644 --- a/test/unit-test/vendor/ceedling/plugins/module_generator/README.md +++ b/test/unit-test/vendor/ceedling/plugins/module_generator/README.md @@ -82,7 +82,7 @@ by adding to the `:includes` array. For example: ### Boilerplates You can specify the actual boilerplate used for each of your files. This is the handy place to -put that corporate copyright notice (or maybe a copyleft notice, if that's your perference?) +put that corporate copyright notice (or maybe a copyleft notice, if that's your preference?) ``` :module_generator: diff --git a/test/unit-test/vendor/ceedling/vendor/cmock/lib/cmock_header_parser.rb b/test/unit-test/vendor/ceedling/vendor/cmock/lib/cmock_header_parser.rb index 9730bf40b..b008dc149 100644 --- a/test/unit-test/vendor/ceedling/vendor/cmock/lib/cmock_header_parser.rb +++ b/test/unit-test/vendor/ceedling/vendor/cmock/lib/cmock_header_parser.rb @@ -119,7 +119,7 @@ class CMockHeaderParser square_bracket_pair_regex_format = /\{[^\{\}]*\}/ # Regex to match one whole block enclosed by two square brackets # Convert user provided string patterns to regex - # Use word bounderies before and after the user regex to limit matching to actual word iso part of a word + # Use word boundaries before and after the user regex to limit matching to actual word iso part of a word @inline_function_patterns.each do |user_format_string| user_regex = Regexp.new(user_format_string) word_boundary_before_user_regex = /\b/ @@ -258,7 +258,7 @@ class CMockHeaderParser source.gsub!(/\s*=\s*['"a-zA-Z0-9_\.]+\s*/, '') # remove default value statements from argument lists source.gsub!(/^(?:[\w\s]*\W)?typedef\W[^;]*/m, '') # remove typedef statements - source.gsub!(/\)(\w)/, ') \1') # add space between parenthese and alphanumeric + source.gsub!(/\)(\w)/, ') \1') # add space between parentheses and alphanumeric source.gsub!(/(^|\W+)(?:#{@c_strippables.join('|')})(?=$|\W+)/, '\1') unless @c_strippables.empty? # remove known attributes slated to be stripped # scan standalone function pointers and remove them, because they can just be ignored diff --git a/test/unit-test/vendor/ceedling/vendor/unity/auto/generate_test_runner.rb b/test/unit-test/vendor/ceedling/vendor/unity/auto/generate_test_runner.rb index d1d8f91af..6821bdc60 100644 --- a/test/unit-test/vendor/ceedling/vendor/unity/auto/generate_test_runner.rb +++ b/test/unit-test/vendor/ceedling/vendor/unity/auto/generate_test_runner.rb @@ -114,7 +114,7 @@ class UnityTestRunnerGenerator # @ is not a valid C character, so there should be no clashes with files genuinely containing these markers substring_subs = { '{' => '@co@', '}' => '@cc@', ';' => '@ss@', '/' => '@fs@' } substring_re = Regexp.union(substring_subs.keys) - substring_unsubs = substring_subs.invert # the inverse map will be used to fix the strings afterwords + substring_unsubs = substring_subs.invert # the inverse map will be used to fix the strings afterwards substring_unsubs['@quote@'] = '\\"' substring_unsubs['@apos@'] = '\\\'' substring_unre = Regexp.union(substring_unsubs.keys) diff --git a/test/unit-test/vendor/ceedling/vendor/unity/src/unity.c b/test/unit-test/vendor/ceedling/vendor/unity/src/unity.c index 764a42b18..ae5afa856 100644 --- a/test/unit-test/vendor/ceedling/vendor/unity/src/unity.c +++ b/test/unit-test/vendor/ceedling/vendor/unity/src/unity.c @@ -13,7 +13,7 @@ #define PROGMEM #endif -/* If omitted from header, declare overrideable prototypes here so they're ready for use */ +/* If omitted from header, declare overridable prototypes here so they're ready for use */ #ifdef UNITY_OMIT_OUTPUT_CHAR_HEADER_DECLARATION void UNITY_OUTPUT_CHAR(int); #endif