I saw that in the STM32 database directory there's also an SQLite database including the exact MPNs for all MCUs. Since the MPNs are now useful for LibrePCB (to export accurate BOMs), I extended the script to also extract that data from this database and include it in the generated JSON files.
Note that the temperature min/max are now redundant in the output files, but it makes sense to have them in the parts section because they may be different for the different MPNs. We might consider removing them from the outer node now...
In addition, there are actually many more attributes stored in the database but for now I extracted only 5 of them which are most useful for LibrePCB. One might argue that we should include all existing data into the JSON files(?)
Regarding license, probably it doesn't make a difference whether we fetch data from an XML file or from an SQLite database so I suspect this change does not affect the license situation of our generated parts.
TODO:
[ ] Check if STM8CubeMX provides this database as well and re-generate STM8 files.
[ ] As many existing JSON files have been modified because of using the latest STM32CubeMX, there's some risk of breaking LibrePCB library elements. We should check somehow if this is the case. But this might be a task for librepcb-parts-generator since this repository is just responsible for putting data from ST into a useful format...
I saw that in the STM32 database directory there's also an SQLite database including the exact MPNs for all MCUs. Since the MPNs are now useful for LibrePCB (to export accurate BOMs), I extended the script to also extract that data from this database and include it in the generated JSON files.
Example output (new node
parts
):Note that the temperature min/max are now redundant in the output files, but it makes sense to have them in the
parts
section because they may be different for the different MPNs. We might consider removing them from the outer node now...In addition, there are actually many more attributes stored in the database but for now I extracted only 5 of them which are most useful for LibrePCB. One might argue that we should include all existing data into the JSON files(?)
Regarding license, probably it doesn't make a difference whether we fetch data from an XML file or from an SQLite database so I suspect this change does not affect the license situation of our generated parts.
TODO:
librepcb-parts-generator
since this repository is just responsible for putting data from ST into a useful format.../cc @dbrgn