Good afternoon,
I am writing a custom build and deployment script for an RP2040 board (pi pico). Everything is working as expected, my build and deployment (including a custom reset, etc) is working as intended. The dependencies on the various targets work as expected as well.
In my script I setup my custom targets like this:
env.AddCustomTarget(
name="deployonly",
dependencies="$BUILD_DIR\${PROGNAME}.uf2",
actions=[
force_reset_cb,
run_loader_cb
],
title="Deploy Only",
description="Manually reset RP2040 to BL mode, upload firmware."
)'
In my code I grab the custom defined variables from the PIO.ini file like so:
tries = int(env.GetProjectOption("bootload_verify_tries"))
The .ini:
[env:pico]
board = pico
extra_scripts = picodeploy.py
bootload_verify_tries = 10
This is how the PIO build system API examples do this as well.
These are working perfectly! The variables change when I update the ini file, however when I run my target, I still get warnings in the output:
Warning! Ignore unknown configuration option `bootload_verify_tries` in section [env:pico]
Though these warnings aren’t impacting the performance, I’d like to know how I tell the build system that these options are being used? Please note that this is just one example, I have a handful of these config options, each of which results in a warning, even though it is used and is working correctly.
This is my first week using PIO, and it’s really excellent. I love the expandable build system, and there is tons of documentation. Thanks for the help!
I have gone through all the options here: Redirecting...
But I did not find anything pertaining to this warning specifically, I could be missing something though.
Best,
D
EDIT: It’s also worth noting that my custom targets DO show up in the PIO targets menu.