Question about PX4 parameter XML document generation

Hello, all.

I heard that it is possible to generate the list of all tunable parameters in the XML form.
So, after I received v1.8.0 (stable) of px4, I tried to execute it. But, none of them does work.
Do you know how to generate it?

Here is the list of my trials

Trial 1
…Firmware/src/lib$ ./parameters/px_process_params.py --xml
Traceback (most recent call last):
File “./parameters/px_process_params.py”, line 200, in
main()
File “./parameters/px_process_params.py”, line 146, in main
if not scanner.ScanDir(args.src_path, parser):
File “/home/tgkim/uavfuzz/uavs/px4_recent/Firmware/src/lib/parameters/px4params/srcscanner.py”, line 20, in ScanDir
for filename in os.listdir(srcdir):
OSError: [Errno 2] No such file or directory: ‘…/src’

Trial 2
…Firmware/src$ ./lib/parameters/px_process_params.py --xml
Warning: no parameters found
Traceback (most recent call last):
File “./lib/parameters/px_process_params.py”, line 200, in
main()
File “./lib/parameters/px_process_params.py”, line 172, in main
os.path.join(cur_dir, args.inject_xml))
File “/usr/lib/python2.7/posixpath.py”, line 68, in join
if b.startswith(’/’):
AttributeError: ‘NoneType’ object has no attribute ‘startswith’

Other than them, I tried other options but none of them work.
They are the only error message variants that I saw.

Thank you

The parameters can be built from the command line using the standard build tools:

make parameters_metadata

At the end of the build both markdown and xml files will be created, and the console will tell you exactly where they have been created to.
If you need to do actually understand the setup you can debug the make.

Hope that helps!

1 Like