Giter Site home page Giter Site logo

arduino / arduino-lint Goto Github PK

View Code? Open in Web Editor NEW
100.0 9.0 13.0 10.48 MB

Tool to check for problems with Arduino projects

Home Page: https://arduino.github.io/arduino-lint/latest/

License: GNU General Public License v3.0

Go 98.17% Python 1.24% Shell 0.59%
arduino lint linter continuous-integration ci tooling-team golang command-line

arduino-lint's Introduction

Arduino Lint

Test Go status Test Integration status Check Go status Check Code Generation status Check Go Dependencies status Publish Tester Build status Publish Nightly Build status Check Python status Check Markdown status Spell Check status Check Website status Deploy Website status Codecov Check Prettier Formatting status Check General Formatting status Check Workflows status Check Shell Scripts status Check Certificates status Sync Labels status

Arduino Lint is a command line tool that checks for common problems in Arduino projects:

  • Sketches
  • Libraries
  • Boards platforms

Documentation

For usage instructions, see the documentation

Continuous Integration

There is a GitHub Actions action that makes it easy to use Arduino Lint` in your CI workflows!

See https://github.com/arduino/arduino-lint-action for more information.

How to contribute

Contributions are welcome!

Please see the How to contribute page for information on building the source code, running tests, and contributing your changes to the project.

Beta testing

Nightly builds are available for beta testing.

Security

If you think you found a vulnerability or other security-related bug in this project, please read our security policy and report the bug to our Security Team ๐Ÿ›ก๏ธ Thank you!

e-mail contact: [email protected]

arduino-lint's People

Contributors

aliphys avatar dependabot[bot] avatar per1234 avatar silvanocerza avatar ubidefeo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

arduino-lint's Issues

Broken symlinks in libraries results in linter panic

Describe the problem

If there is a broken symlink in a library the linter panics.

To reproduce

Try to lint this library: eloquent_edgeimpulse.tar.gz

cmaglie:~$ tar xfv eloquent_edgeimpulse.tar.gz 
eloquent_edgeimpulse/
eloquent_edgeimpulse/library.properties
eloquent_edgeimpulse/examples/
eloquent_edgeimpulse/examples/EdgeImpulse_Serial/
eloquent_edgeimpulse/examples/EdgeImpulse_Serial/EdgeImpulse_Serial.ino
eloquent_edgeimpulse/LICENSE
eloquent_edgeimpulse/README.md
eloquent_edgeimpulse/src/
eloquent_edgeimpulse/src/eloquent_edgeimpulse.h
eloquent_edgeimpulse/src/eloquent_edgeimpulse/
eloquent_edgeimpulse/src/eloquent_edgeimpulse/impulse.h
eloquent_edgeimpulse/src/eloquent_edgeimpulse/math.h
eloquent_edgeimpulse/src/eloquent_edgeimpulse/exception.h
eloquent_edgeimpulse/src/eloquent_edgeimpulse/circular_buffer.h

cmaglie:~$ cd eloquent_edgeimpulse/
cmaglie:~/eloquent_edgeimpulse$ ../Software/arduino-lint 
Linting library in /home/cmaglie/eloquent_edgeimpulse
panic: stat /home/cmaglie/eloquent_edgeimpulse/src/eloquent_edgeimpulse/circular_buffer.h: no such file or directory

goroutine 1 [running]:
github.com/arduino/arduino-lint/internal/rule/rulefunction.LibraryContainsSymlinks()
	/home/build/internal/rule/rulefunction/library.go:90 +0x1f6
github.com/arduino/arduino-lint/internal/rule.Runner({0xc0002ff270, 0x1633db8, 0x0})
	/home/build/internal/rule/rule.go:53 +0x24a
github.com/arduino/arduino-lint/internal/command.ArduinoLint(0xc000034900, {0x1633db8, 0x0, 0x0})
	/home/build/internal/command/command.go:77 +0x645
github.com/spf13/cobra.(*Command).execute(0xc000034900, {0xc0000321e0, 0x0, 0x0})
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:987 +0xa87
github.com/spf13/cobra.(*Command).ExecuteC(0xc000034900)
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:1115 +0x41e
github.com/spf13/cobra.(*Command).Execute(...)
	/go/pkg/mod/github.com/spf13/[email protected]/command.go:1039
main.main()
	/home/build/main.go:33 +0x1e

cmaglie:~/eloquent_edgeimpulse$ ls -l /home/cmaglie/eloquent_edgeimpulse/src/eloquent_edgeimpulse/circular_buffer.h
lrwxrwxrwx 1 cmaglie cmaglie 76 gen  9 16:24 /home/cmaglie/eloquent_edgeimpulse/src/eloquent_edgeimpulse/circular_buffer.h -> /Users/simone/Documents/Arduino/libraries/eloquent_commons/circular_buffer.h

Expected behavior

Do not panic, and output an error about broken symlinks.
It should also output an error if the symlink points outside the library.

Arduino Lint version

nightly

Operating system

Linux

Operating system version

Ubuntu 23.02

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest version
  • My report contains all necessary details

`library.json` reported as incorrectly spelled `library.properties`

The reported error is:

error: Incorrectly spelled library.properties file name found: /home/megabug/Workspace/FlashStorage/library.json. See: https://arduino.github.io/arduino-cli/latest/library-specification/#library-metadata

I've discovered this by testing my FlashStorage library.

Consider raising LP048 to error instead of warning

LP048 checks whether all libraries mentioned in the depends field of library.properties exist in the Library Manager, however it is a warning and not an error.

The issue is that arduino-cli lib install will refuse to install any library whose dependencies are not in the Library Manager:

% arduino-cli lib install "OpenMV Arduino RPC"
Error installing OpenMV Arduino RPC: No valid dependencies solution found: dependency 'SoftwareSerial' is not available

I saw quite a few libraries mentioning built-in classes such as SoftwareSerial or EEPROM, which are not known to the Library Manager. When trying to install such libraries from the IDE 2.0, it will just refuse to install them without providing any error.

The easiest way to fix this asymmetry would probably be to raise this check to error level. Other fixes could be to implement ways to bypass this check at library installation time in CLI and IDE.

What do you think @per1234?

Allow test sketches to be outside examples folder

Describe the request

The linter should allow for sketches outside of the examples folder to be within spec. Main reason, is to keep two types of .ino files seperate based on their functionality

  • Example sketches -> These showcase the functionality of the library and have practical and/or pedagogical value
  • Test sketches -> These are meant to strain the compile-sketches.yml workflow to the limit, as part of continuous testing (CT) procedures.

Including test sketches, which have no/little pedagogical value, will increase the complexity of the user experience. Advanced users can always see the test sketches in the repository or local installation of the library.

Describe the current behavior

According to Rule LD003, the linter does not allow for sketches outside the examples folder in the root directory of the library.

ID: "LD003",
Brief: "stray sketch",
Description: "A sketch was found outside the library's `examples` and/or `extras` subfolders. Example sketches must be placed in the standardized location.",
MessageTemplate: "Sketch(es) found outside examples and extras folders:\n{{.}}",

Arduino Lint version

arduino/arduino-lint-action@v1

Operating system

N/A

Operating system version

runs-on: ubuntu-latest

Additional context

Running Linter via check-arduino.yml workflow kindly provided by @per1234

Issue checklist

  • I searched for previous requests in the issue tracker
  • I verified the feature was still missing when using the latest version
  • My request contains all necessary details

My `examples` directory is getting ignored

Describe the problem

I run the linter in GitHub actions, output is here: https://github.com/docwilco/MFIButton/actions/runs/3159910327/jobs/5143724723

But running it locally gives the same result:

$ arduino-lint --compliance strict
Linting library in /redacted/MFIButton
WARNING: No example sketches found. Please provide examples.
         See: https://arduino.github.io/arduino-cli/latest/library-specification/#library-examples
         (Rule LD004)

Linter results for project: 0 ERRORS, 1 WARNINGS

-------------------

But there's definitely an example: https://github.com/docwilco/MFIButton/blob/main/examples/Example_1-Basics_and_ESP32_timers.ino

To reproduce

Expected behavior

Find the example that is present

Arduino Lint version

nightly-20220930 2022-09-30T01:37:12Z

Operating system

Linux

Operating system version

Ubuntu 20.04.3 LTS

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest version
  • My report contains all necessary details

Specify link to Github, BitBucket or GitLab as requirement for `url` field

Describe the request

Add rule so that the linter checks for a link to Github, BitBucket or GitLab as in the url field. In many instances, for example https://github.com/arduino-libraries/MIDIUSB/blob/f9bcc4eaf7bb983ac1827ccf0f8b833f75001ac2/library.properties the url field links to another location.

Describe the current behavior

According to the library registery FAQ:

- [ ] The library repository must be hosted on a major Git-hosting website like GitHub, BitBucket or GitLab (other hosting sites may be considered on request).

Currently, we do have some useful checks in place for the url field. As an example, rule LP040 checks to see if the url is included, but does not check to see if it points back to GitHub, BitBucket or GitLab.

{
ProjectType: projecttype.Library,
SuperprojectType: projecttype.All,
Category: "library.properties",
Subcategory: "url field",
ID: "LP040",
Brief: "missing url field",
Description: "The `url` field is missing from the library's `library.properties` metadata file.",
MessageTemplate: "Missing url field in library.properties",
Reference: "https://arduino.github.io/arduino-cli/latest/library-specification/#libraryproperties-file-format",
DisableModes: nil,
EnableModes: []rulemode.Type{rulemode.Default},
InfoModes: nil,
WarningModes: nil,
ErrorModes: []rulemode.Type{rulemode.Default},
RuleFunction: rulefunction.LibraryPropertiesURLFieldMissing,
},

Arduino Lint version

latest

Operating system

N/A

Operating system version

N/A

Additional context

No response

Issue checklist

  • I searched for previous requests in the issue tracker
  • I verified the feature was still missing when using the latest version
  • My request contains all necessary details

Documentation and linter setup mismatch

Describe the request

The linter have a warning about recommended library name lengths, but the cited documentation says nothing about that. Either the linter setup is wrong, or the documentation is wrong.

Describe the current behavior

Just submit a library with a lengthy library name.

Additional context

No response

Issue checklist

  • I searched for previous requests in the issue tracker
  • My request contains all necessary details

Add maximum file system size rule for libraries

Although the file sizes of an Arduino library's source code is always small enough to not be worth consideration, some library authors have added supplemental files which make the total file system size of the library unexpectedly large.

An example I have seen repeatedly causing problems by exceeding the maximum storage size for a standard Arduino Cloud account upon import is this popular library, currently ~40 MB:
https://github.com/itead/ITEADLIB_Arduino_Nextion

Excessive library sizes are inconvenient for users, who might have no interest in, nor even awareness of, the supplemental files that make installation and updates of the library take forever. This also causes an burden on the Library Manager infrastructure, which must index, store, and serve every release of every library.

For this reason, it would be helpful to add a rule that checks for library size exceeding some maximum value (e.g., 10 MB). This could be promoted from a warning to an error when in --library-manager=submit or --library-manager=update modes if we decide to prohibit such libraries from inclusion in the Library Manager index.

Such a rule would encourage library maintainers to package and distribute supplemental files separate from the library itself, which will likely be in the best interest of users, who often don't even know (or want to know) where the library is on their system. They also might find that the files are unnecessarily large (e.g., raw high resolution images where offering such level of detail is of no benefit).

Feature Request: Add ability to exclude certain sub-folders from checks

I would like to exclude some folders from library structure checks - essentially the same folders from my .gitignore. In my case, I'm getting "ERROR: Sketch(es) found outside examples and extras folders" because I have a local .pio folder with local libraries in it and another local .history folder for a VSCode extension.

Please add check for invalid examples e.g. containing no ino file

By accident I released a few versions of the IRremote library with the IRremoteExtensionTest example containing a IRremoteExtensionTest.cpp instead of a IRremoteExtensionTest.ino file.
It would be nice to add such a check, or do you have another tool which can do this task.

Is the keywords.txt also checked by arduino-lint?

Feature request: Support macOS arm64

It would be nice to release a version for MacOS arm64 to support the new M1 architecture Macs.

I would be happy to contribute and help test/verify if needed! ๐Ÿ˜ƒ

Question: Why are library names limited to 16 characters? (low prio)

Why are library names limited to 16 characters?
Is there a technical reason?

Rule LP010 result: fail
ERROR: library.properties name value FunctionGenerator is longer than the recommended length of 16 characters.

Think the error message should not use the word "recommended" but "maximum"
"recommended" sounds more like warning level to me

It is also not mentioned here - https://arduino.github.io/arduino-cli/latest/library-specification/#libraryproperties-file-format

Same problem occurred recently with the DallasTemperatureControlLibrary

Where can I find the list of rules?

Is there a published list of all the linter rules? I couldn't find a reference to it in the documentation.

Alternately, is there a sample project that (on purpose) triggers every possible linter error?

Add the ability to mute some rules

Hi,

Thank you for this excellent tool ๐Ÿ‘

I wish I could include it in my GitHub workflow, but unfortunately, rule LP012 fails for my library
Indeed, the name of my library starts with Arduino; I created it at a time when this prefix was allowed for unofficial libraries.

Please add a command-line flag (and a setting in arduino-lint-action) that allows the user to exclude or mute some rules.
Thanks!!!

Best regards,
Benoit

Update link LP018

I even looked for where to do this to make the modification but I didn't find it, the suggested link is outdated.

ERROR: Library name XXX not found in the Library Manager index. Library                                                 
       names are not allowed to change after being added to the index. See:                                             
       https://github.com/arduino/Arduino/wiki/Library-Manager-FAQ#how-can-i-change-my-librarys-name (Rule LP018)   

Leverage the GitHub Checks API to annotate file/line problems

Some (but certainly not all) lint rules pertain to a specific file and line. Other rules pertain to a file that is missing lines. By using the GitHub Checks API, this report could be surfaced in native form in a GitHub UI with appropriate links to files and/or lines in question. Additionally, the error messages could (eventually) link to rule descriptions hosted at some public URL (see #158)

An example of a GItHub action that creates annotations (and a summary) via the Checks API using typescript is https://github.com/Attest/annotations-action

Unable to write tests for schema-based check functions

The schemas themselves and the schema handling functions have pretty good coverage, but I'm still missing the ability to add tests for the check functions based on them, For example:

// LibraryPropertiesNameFieldLTMinLength checks if the library.properties "name" value is less than the minimum length.
func LibraryPropertiesNameFieldLTMinLength() (result checkresult.Type, output string) {
if checkdata.LibraryPropertiesLoadError() != nil {
return checkresult.NotRun, "Couldn't load library.properties"
}
if !checkdata.LibraryProperties().ContainsKey("name") {
return checkresult.NotRun, "Field not present"
}
if schema.PropertyLessThanMinLength("name", checkdata.LibraryPropertiesSchemaValidationResult()[compliancelevel.Specification], configuration.SchemasPath()) {
return checkresult.Fail, ""
}
return checkresult.Pass, ""
}

I haven't figured out how to do this.

This is related to the previous discussion here:
#14 (review)

The trouble is that the schema path is configured relative to the executable path (#21):

executablePath, err := os.Executable()

which doesn't work when running tests.

The tests I have written for functions using the schemas were possible because they had a schema path parameter. But the check functions don't have such a parameter and I don't like the idea of adding such a parameter to every check function.

Publish Arduino project JSON schemas to "JSON Schema Store"

Describe the request

Many of the Arduino Lint rules related to the contents of the Arduino Project data files (library.properties, boards.txt, boards.local.txt, platform.txt, platform.local.txt, programmers.txt, package index) are based on a collection of JSON schemas:

https://github.com/arduino/arduino-lint/tree/main/etc/schemas

It is possible that, in addition to their primary purpose of use internal to Arduino Lint, the schemas might be used by Arduino developers to obtain on the fly validations while editing these project configuration files, as is done with other common data files. High quality programming editors (e.g., VS Code) have the capability to use schemas in this way.

JSON Schema Store is a popular source of JSON schemas. There is some level of integration of the schemas listed on the store with common programming editors and IDEs:

https://www.schemastore.org/json/#editors

๐Ÿ™‚ Publishing the Arduino project data file JSON schemas on JSON Schema Store will make it easier for the Arduino community to discover and use these existing resources.

Describe the current behavior

The existence of the schemas is not advertised in any way.

๐Ÿ™ It is likely that very few Arduino developers are aware of the availability of these schemas. Even after they become aware of their existence, it may be unnecessarily difficult to integrate them into a programming editor and maintain them.

Additional context

Hosting Strategy

JSON Schema Store allows self-hosting schemas, which would be convenient as it would allow us to continue maintaining only a single copy of these files. However, the use of $ref in the Arduino project schemas makes this impossible:

https://github.com/SchemaStore/schemastore/blob/master/CONTRIBUTING.md#how-to-ref-from-schema_xjson-to-schema_yjson

How to $ref from schema_x.json to schema_y.json

  • Both schemas must exist locally in SchemaStore.

So it will be necessary to host the schemas in the SchemaStore/schemastore repository. Since work on the Arduino Lint codebase is often coupled with work in the schemas, removing the schemas from this repository and consuming the files from the JSON Schema Store would make development of Arduino Lint more difficult and time consuming so I think it will be best to host a copy of the schemas in the arduino/arduino-lint and SchemaStore/schemastore repositories both.

It will be important to keep these copies in sync (pushing changes made in the arduino/arduino-lint repository to JSON Schema Store as well as pulling in any changes that might have been made by contributors in the SchemaStore/schemastore repository). I recommend adding a GitHub Actions workflow to this repository to check for an out of sync state between the two copies. This can be done by downloading the schemas from JSON Schema Store and then doing a diff between the downloaded files and the files in the arduino/arduino-lint repository.

From my experience making several contributions to various schemas in the SchemaStore/schemastore repository over the years, I have been very impressed by the level of maintenance of the repository. High quality PRs are merged in a matter of days if not hours.

Usability of Schemas

The library.properties, boards.txt, boards.local.txt, platform.txt, platform.local.txt, and programmers.txt files use Arduino's bespoke "properties" data format. I fear this would make it quite difficult to integrate those JSON schemas into an editor in a useful capacity. I think the capability to parse the data files into a standard data structure would need to be implemented (which could be done using the github.com/arduino/go-properties-orderedmap Go module). So I'm not sure the very hypothetical benefits of publishing those schemas to the JSON Schema Store would be worth the effort to submit and maintain them on that platform.

Since the package index files use the standard JSON data format, I think the package index schema should be relatively easy to use.


Requested by @Freed-Wu at arduino/arduino-language-server#164 (comment)

Issue checklist

  • I searched for previous requests in the issue tracker
  • I verified the feature was still missing when using the latest nightly build
  • My request contains all necessary details

Change of LP010: Increase character limit for naming Arduino libraries

Describe the request

In my daily usage of this action I often find myself violating rule LP010, which recommends a maximum amount of characters of 16 for the name of any given Arduino library, i.e. here:

WARNING: library.properties name value Arduino_USBHostMbed5 is longer than the recommended length of 16 characters.
         See: https://arduino.github.io/arduino-cli/latest/library-specification/#libraryproperties-file-format    
         (Rule LP010)                                                                                              

Given the fact, that our official Arduino libraries have to be prefixed with Arduino_ already 8 out of 16 characters are given away to that mandated prefix.

I therefore suggest to increase the character limit for Arduino library names to at least 32 characters.

Describe the current behavior

arduino-lint behaves as it should this is about a rule change ;).

Arduino Lint version

1.2.1 2022-06-28T08:38:52Z

Operating system

N/A

Operating system version

Any.

Additional context

No response

Issue checklist

  • I searched for previous requests in the issue tracker
  • I verified the feature was still missing when using the latest version
  • My request contains all necessary details

New error raised with 1.2.1 while it should not

Describe the problem

Wtih 1.2.1 I got this:

Linting platform in STMicroelectronics\hardware\stm32\2.3.0
    ERROR: Missing upload.tool.<protocol_name> property for board ID(s) Nucleo_144, Nucleo_64, Nucleo_32, Disco, Eval,
           STM32MP1, GenF0, GenF1, GenF2, GenF3, GenF4, GenF7, GenG0, GenG4, GenH7, GenL0, GenL1, GenL4, GenL5, GenU5,
           GenWB, GenWL, 3dprinter, BluesW, Elecgator, ESC_board, Garatronic, GenFlight, LoRa, Midatronics
           See: https://arduino.github.io/arduino-cli/latest/platform-specification/#sketch-upload-configuration
           (Rule PF016)
    WARNING: Missing upload.maximum_size property for board ID(s) Nucleo_144, Nucleo_64, Nucleo_32, Disco, Eval, STM32MP1,
             GenF0, GenF1, GenF2, GenF3, GenF4, GenF7, GenG0, GenG4, GenH7, GenL0, GenL1, GenL4, GenL5, GenU5, GenWB, GenWL,
             3dprinter, BluesW, Elecgator, ESC_board, Garatronic, GenFlight, LoRa, Midatronics
             See: https://arduino.github.io/arduino-cli/latest/platform-specification/#recipes-to-compute-binary-sketch-size
             (Rule PF018)
    WARNING: Missing upload.maximum_data_size property for board ID(s) Nucleo_144, Nucleo_64, Nucleo_32, Disco, Eval,
             STM32MP1, GenF0, GenF1, GenF2, GenF3, GenF4, GenF7, GenG0, GenG4, GenH7, GenL0, GenL1, GenL4, GenL5, GenU5,
             GenWB, GenWL, 3dprinter, BluesW, Elecgator, ESC_board, Garatronic, GenFlight, LoRa, Midatronics
             See: https://arduino.github.io/arduino-cli/latest/platform-specification/#recipes-to-compute-binary-sketch-size
             (Rule PF020)
    
    Linter results for project: 1 ERRORS, 2 WARNINGS

It seems the linter check only one level in the boards.txt while it should go deeply as those value are well defined for each entries but at sub level (see: https://github.com/stm32duino/Arduino_Core_STM32/blob/main/boards.txt)
Ex:

Nucleo_144.menu.pnum.NUCLEO_F207ZG.upload.maximum_size=1048576
Nucleo_144.menu.pnum.NUCLEO_F207ZG.upload.maximum_data_size=131072

and:
Nucleo_144.menu.upload_method.MassStorage.upload.tool=massStorageCopy

I've made a fix but I think it should be great to handle those case (see stm32duino/Arduino_Core_STM32#1754)

To reproduce

Apply linter 1.21 on core version 2.3.0.

Expected behavior

No errors or warnings with default boards.txt

Arduino Lint version

1.2.1

Operating system

Windows

Operating system version

Win 10 but same on Linux Ubuntu 20.04

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest version
  • My report contains all necessary details

Add "zero-length board ID" rule

I am running the linter using your github-action (thanks for making it available) and I am faced with these three rules failing and it seems that everything is defined as per the specification. It does load fine in the IDE. (two of them are errors, one is a warning)

For reference, here is the link to my boards.txt. It's based on Adafruit's nRF52 Feather BSP.
Here is the github action output. It does not provide any hint which board is causing the problem.

Are the identifiers too long? Are they too short? Is it a rule parsing problem? is it a problem with the rule or my file?

Here is a short section of my board.txt file (1 out of 9 boards):

# ----------------------------------
# 4x4 macropad nRF52832
# ----------------------------------

4x4macropad_nrf52832.name=4x4 Macropad (nRF52832)
4x4macropad_nrf52832.bootloader.tool=bootburn

# Upload
4x4macropad_nrf52832.upload.tool=nrfutil
4x4macropad_nrf52832.upload.protocol=nrfutil
4x4macropad_nrf52832.upload.use_1200bps_touch=false
4x4macropad_nrf52832.upload.wait_for_upload_port=false
4x4macropad_nrf52832.upload.native_usb=false
4x4macropad_nrf52832.upload.maximum_size=290816
4x4macropad_nrf52832.upload.maximum_data_size=52224

# Build
4x4macropad_nrf52832.build.mcu=cortex-m4
4x4macropad_nrf52832.build.f_cpu=64000000
4x4macropad_nrf52832.build.board=4X4MACROPAD_NRF52832
4x4macropad_nrf52832.build.core=nRF5
4x4macropad_nrf52832.build.variant=4x4macropad_nrf52832
4x4macropad_nrf52832.build.usb_manufacturer="BlueMicro"
4x4macropad_nrf52832.build.usb_product="4x4 Macropad nRF52832"
4x4macropad_nrf52832.build.extra_flags=-DNRF52832_XXAA -DNRF52
4x4macropad_nrf52832.build.ldscript=nrf52832_s132_v6.ld

# SofDevice Menu
4x4macropad_nrf52832.menu.softdevice.s132v6=0.4.0 SoftDevice s132 6.1.1
4x4macropad_nrf52832.menu.softdevice.s132v6.build.sd_name=s132
4x4macropad_nrf52832.menu.softdevice.s132v6.build.bl_version=0.4.0
4x4macropad_nrf52832.menu.softdevice.s132v6.build.sd_version=6.1.1
4x4macropad_nrf52832.menu.softdevice.s132v6.build.sd_fwid=0x00B7


# Debug Menu
4x4macropad_nrf52832.menu.debug.l0=Level 0 (Release)
4x4macropad_nrf52832.menu.debug.l0.build.debug_flags=-DCFG_DEBUG=0
4x4macropad_nrf52832.menu.debug.l1=Level 1 (Error Message)
4x4macropad_nrf52832.menu.debug.l1.build.debug_flags=-DCFG_DEBUG=1
4x4macropad_nrf52832.menu.debug.l2=Level 2 (Full Debug)
4x4macropad_nrf52832.menu.debug.l2.build.debug_flags=-DCFG_DEBUG=2
4x4macropad_nrf52832.menu.debug.l3=Level 3 (Segger SystemView)
4x4macropad_nrf52832.menu.debug.l3.build.debug_flags=-DCFG_DEBUG=3
4x4macropad_nrf52832.menu.debug.l3.build.sysview_flags=-DCFG_SYSVIEW=1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.