Skip to content

Commit

Permalink
Add missing yaml types (#138)
Browse files Browse the repository at this point in the history
  • Loading branch information
bugadani authored Jun 26, 2024
1 parent 2b834f2 commit a6123d7
Showing 1 changed file with 32 additions and 4 deletions.
36 changes: 32 additions & 4 deletions src/targets/_data.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,9 @@ export const loadTargets = async (ref) => {
const variants = targetDescription.variants;
const jep = targetDescription.manufacturer
? getJep106Manufacturer(
targetDescription.manufacturer.cc,
targetDescription.manufacturer.id
)
targetDescription.manufacturer.cc,
targetDescription.manufacturer.id
)
: undefined;

for (const variant of variants) {
Expand Down Expand Up @@ -172,8 +172,36 @@ function schema() {
kind: "mapping",
});

const espressif = new Type("!Espressif", {
construct(data) {
return data !== null ? { Espressif: data } : {};
},
kind: "mapping",
});

const atsam_dsu = new Type("!AtsamDsu", {
construct(data) {
return data !== null ? { AtsamDsu: data } : {};
},
kind: "mapping",
});

const nordic_configid = new Type("!NordicConfigId", {
construct(data) {
return data !== null ? { NordicConfigId: data } : {};
},
kind: "mapping",
});

const nordic_ficr_info = new Type("!NordicFicrInfo", {
construct(data) {
return data !== null ? { NordicFicrInfo: data } : {};
},
kind: "mapping",
});

const extended = new Schema({
explicit: [arm, riscv, xtensa, ram, nvm, flash, generic],
explicit: [arm, riscv, xtensa, ram, nvm, flash, generic, espressif, atsam_dsu, nordic_configid, nordic_ficr_info],
include: [def],
});

Expand Down

0 comments on commit a6123d7

Please sign in to comment.