boards/b-g474e-dpow1: Add note about udev/sudo regarding openocd

* boards/arm/stm32/b-g474e-dpow1/README.txt:
  (Debugging): OpenOCD requires permissions for certain operations. The
   preferred thing to do is to properly configure udev rules. The
   expedient thing to do is to run it as root with 'sudo', but we do not
   want to encourage that, as discussed earlier on this PR [1]. This
   revised text offers a compromise where we mention both options, but
   we talk about udev rules first and explicitly say that using 'sudo'
   is not encouraged. We leave it up to developers to decide what is
   best in their particular situation.

References:
[1] https://github.com/apache/incubator-nuttx/pull/7177
This commit is contained in:
Nathan Hartman 2022-09-23 10:34:15 -04:00 committed by Brennan Ashton
parent 70290b6e38
commit d129c95fd2

View File

@ -55,6 +55,12 @@ Development Environment
$ openocd -f interface/stlink.cfg -f target/stm32g4x.cfg -c init \
-c "reset halt" -c "flash write_image erase nuttx.bin 0x08000000"
NOTE: The above command might fail unless either: udev rules have been
configured on the development system (preferred) or the command is run as
root with 'sudo' (not encouraged). See:
- https://openocd.org/doc/html/Running.html
- https://forgge.github.io/theCore/guides/running-openocd-without-sudo.html
* Start GDB with:
$ arm-nuttx-eabi-gdb -tui nuttx