@mchp-mcc/scf-pic8-interrupt-v3 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Changelog.md +8 -0
- package/LICENSE.txt +21 -0
- package/Readme.md +14 -0
- package/lib/generated_module/src/index.js +11 -0
- package/output/autoCreator.js +3859 -0
- package/output/autoCreator.js.map +1 -0
- package/output/autoProcessor.js +3861 -0
- package/output/autoProcessor.js.map +1 -0
- package/output/creator.js +7482 -0
- package/output/creator.js.map +1 -0
- package/output/interrupt_manager_priorityDisabled.c.ftl +169 -0
- package/output/interrupt_manager_priorityDisabled.h.ftl +178 -0
- package/output/nullPrototype.json +49 -0
- package/output/processor.js +7482 -0
- package/output/processor.js.map +1 -0
- package/package.json +221 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["webpack://autoProcessor/webpack/bootstrap","webpack://autoProcessor/./generated_module/src/Utils.ts","webpack://autoProcessor/./generated_module/src/autoProcessor.ts","webpack://autoProcessor/./generated_module/src/getUserData.ts","webpack://autoProcessor/./generated_module/src/pins/PCPHelper.ts","webpack://autoProcessor/./node_modules/@microchip/initializer-system/lib/src/index.js","webpack://autoProcessor/./node_modules/@microchip/initializer-system/lib/src/initializer-system.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/InterruptTableView/InterruptTableViewHelper.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/InterruptTableView/TableActions.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/InterruptTableView/reduce.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/index.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/manager_helper/InterruptManagerHelper.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/manager_helper/StateHelper.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-manager-generic/lib/types/TableCell.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-standard/lib/src/index.js","webpack://autoProcessor/./node_modules/@microchip/interrupt-standard/lib/src/interrupt-standard.js","webpack://autoProcessor/./node_modules/@microchip/melody-automodule-interface/lib/src/Tables.js","webpack://autoProcessor/./node_modules/@microchip/scf-automodule-impl/lib/Utils.js","webpack://autoProcessor/./node_modules/@microchip/scf-automodule-impl/lib/autoModule/AutoModuleHelpers.js","webpack://autoProcessor/./node_modules/@microchip/scf-automodule-impl/lib/autoModule/getConfigData.js","webpack://autoProcessor/./node_modules/@microchip/scf-automodule-impl/lib/interrupts/InterruptActions.js","webpack://autoProcessor/./node_modules/@microchip/scf-automodule-impl/lib/tables/UidMapBuilder.js","webpack://autoProcessor/./node_modules/@microchip/scf-automodule-impl/lib/tables/tables.js","webpack://autoProcessor/./node_modules/@microchip/scf-common/lib/Processor.js","webpack://autoProcessor/./node_modules/@microchip/scf-device/lib/CalculateRegisterValue.js","webpack://autoProcessor/./node_modules/@microchip/scf-device/lib/Register.js","webpack://autoProcessor/./node_modules/@microchip/scf-device/lib/Setting.js","webpack://autoProcessor/./node_modules/@microchip/scf-device/lib/util/Arrays.js","webpack://autoProcessor/./node_modules/@microchip/scf-interface/lib/c-function-types.js","webpack://autoProcessor/./node_modules/@microchip/scf-interface/lib/helpers.js","webpack://autoProcessor/./node_modules/@microchip/scf-interface/lib/index.js","webpack://autoProcessor/./src/Constants.ts","webpack://autoProcessor/./src/CreatorFunctions.ts","webpack://autoProcessor/./src/DerivedData.ts","webpack://autoProcessor/./src/GeneratorModel.tsx","webpack://autoProcessor/./src/PinsLogic.ts","webpack://autoProcessor/./src/table_data/NoPrioTable.ts","webpack://autoProcessor/./src/types/TableTypes.ts"],"names":["getKeys","obj","Object","getOwnPropertyNames","values","map","key","forEach","action","mapper","assertNotNull","val","msg","Error","toDictionary","arr","keyMapper","valueMapper","result","entry","createAutoProcessor","getDerivedData","derivedDataGetter","dataModel","getModuleConfig","getModuleConfigFromFile","getDerivedDataUser","getPinsDataFromFile","require","undefined","getPinsLogicFromFile","mockPinsLogic","getPinsData","getCompletePinData","appModel","getRowData","rowData","rows","getPinsLogic","pinsLogic","InterruptComponentNames","INTI","INT0I","INT1I","INT2I","INT3I","EdgeSettings","EXTINT_NAME","MACROS_NO_PRIORITY","GIE_status","GIE_enable","GIE_disable","MACROS_WITH_PRIORITY","GIEH_status","GIEL_status","GIEH_enable","GIEL_enable","GIEH_disable","GIEL_disable","getCreatorFunctions","shouldImport","getCreatorImportArgs","importKey","state","MyDerivedData","EmptyDerivedData","templateData","getMyTemplateData","moduleName","getModuleName","alerts","getMyAlerts","isVisible","getGeneralPayload","interrupt_standard_payloads","initializer_system_results","initializer_main_results","pin_standard_args","isInterruptListNotEmpty","isPriorityEnabled","getModel","isComponentValue","isPriorityDisabled","intePie0","getBooleanValue","int0iePie0","int1iePie0","int2iePie0","int3iePie0","noPriorityTable","getNoPriorityTable","interruptStore","getInterruptStore","noPrioTableVisible","isNoPrioTableVisible","prioNonVectTableVisible","isPrioNonVectTableVisible","isHidden","importName","friendlyImportName","noPrioInterruptHelper","InterruptManagerHelper","getNoPrioDefData","getState","mapNoPrioInterruptData","setNonVectorTableOrder","interruptHelper","interrupts","getInterrupts","getInterruptResults","value","dataMap","interruptList","hookData","find","name","module","rowId","interruptName","enable","isEnabled","actions","interruptActions","filter","validFor","split","tableComponentName","tableState","main","interruptTable","setOrder","rowIds","uids","rowUid","i","index","row","uid","sort","row1","row2","results","getExportInterfaces","getInterface","interrupt_standard","getInterfaceId","getExtInterruptResults","getSystemInterruptsResults","externalInterrupts","NoMetaModule","iocInterrupts","getIOCResults","id","interrupt","push","generateISR","isrCallback","header","path","isHighPriority","interruptStoreState","int","isEnabledActions","InterruptActionsBuilder","createActionBuilder","createActionFor","addActionIfEnabled","addActionIfDisabled","buildActions","componentName","toLowerCase","getComponentValue","replace","getHeaderFiles","args","addressedPayload","processedState","moduleId","scriptId","getInterruptStandardRequests","getRequestsPayloadFor","isVectoredInterrupt","hasPriority","requests","requestsPayload","request","requestFor","data","mode","concat","Array","isArray","indexOf","interruptIds","interruptId","macros","macroFilter","macro","Constants","getGeneratorModel","getNoPrioInterruptHelper","getProcessedInterruptData","ppsData","getImportValue","getPeripheralDescription","type","Processor","Hint","text","noPrioData","length","getRegisterValues","settings","PEIE","EXT_INT_INTI","initializer","priority","initializer_system","END","initSectionMessage","initSection","message","queryAdapters","table","model","tab","currentTable","initIndex","getProcessedTableData","order","addRowToTable","columns","initRowData","noPrioIntList","highInterrupts","lowInterrupts","extIntList","registerValues","pieAvailable","isPeripheralInterrupt","moduleNameLowerCase","getName","moduleNameUpperCase","toUpperCase","hasHighInterrupts","hasLowInterrupts","preemptiveHigh","serviceSingleIsrPerInterrupt","initRegisters","GIE","allocatedPins","getAllocatedPins","vectoredInterruptEnabled","registerSettings","edge","interruptEdges","interruptHandlerName","slice","getIRQname","customName","functionName","SFREdgeDetectFromPin","edgeSettingAlias","bitName","flagName","flag","enableBitName","interruptEnabled","retRowJSONdata","tableId","NO_PRIO_TABLE_ID","tableDescription","hasReorder","showOrderColumn","headers","description","show","readonly"],"mappings":";;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;;;;;AChFA;AAAA;AAAA;AA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AACA;AACA;AACA;AACA;AACA,sBAAsB,gCAAgC;AACtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8C;;;;;;;;;;;;ACtGa;AACb,8CAA8C,cAAc;AAC5D;AACA,oBAAoB,mBAAO,CAAC,4HAA+B;AAC3D;AACA;AACA,oBAAoB,uBAAuB;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oD;;;;;;;;;;;;AC/Ba;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA,wC;;;;;;;;;;;;ACvBa;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D;AACA,qBAAqB,mBAAO,CAAC,kHAAgB;AAC7C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mCAAmC,kDAAkD,KAAK,sCAAsC,oHAAoH,KAAK,2BAA2B,wKAAwK,YAAY,oDAAoD,gPAAgP,YAAY,iDAAiD,oWAAoW,YAAY,0EAA0E,GAAG;AACtuC;AACA;AACA,kC;;;;;;;;;;;;AC9Ba;AACb,WAAW,uBAAuB;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,8CAA8C,cAAc;AAC5D;AACA,kBAAkB,mBAAO,CAAC,qGAAmB;AAC7C,gDAAgD,qCAAqC,iCAAiC,EAAE,EAAE;AAC1H,+BAA+B,mBAAO,CAAC,iJAAyC;AAChF,0DAA0D,qCAAqC,wDAAwD,EAAE,EAAE;AAC3J,oBAAoB,mBAAO,CAAC,2HAA8B;AAC1D,0DAA0D,qCAAqC,6CAA6C,EAAE,EAAE;AAChJ,4DAA4D,qCAAqC,+CAA+C,EAAE,EAAE;AACpJ,6DAA6D,qCAAqC,gDAAgD,EAAE,EAAE;AACtJ;AACA;AACA;AACA,IAAI;AACJ,qBAAqB,mBAAO,CAAC,qIAAmC;AAChE,2CAA2C,qCAAqC,+BAA+B,EAAE,EAAE;AACnH,oDAAoD,qCAAqC,wCAAwC,EAAE,EAAE;AACrI,iCAAiC,mBAAO,CAAC,6JAA+C;AACxF,yDAAyD,qCAAqC,yDAAyD,EAAE,EAAE;AAC3J,eAAe,mBAAO,CAAC,yHAA6B;AACpD,0CAA0C,qCAAqC,wBAAwB,EAAE,EAAE;AAC3G,iC;;;;;;;;;;;;ACjCa;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D;AACA,kBAAkB,mBAAO,CAAC,sGAAoB;AAC9C,oBAAoB,mBAAO,CAAC,4GAAe;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kDAAkD,oBAAoB;AACtE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,yBAAyB;AACzB,qBAAqB;AACrB;AACA,aAAa;AACb,8DAA8D,wCAAwC;AACtG;AACA,yCAAyC,iCAAiC;AAC1E;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,2DAA2D,qCAAqC;AAChG,kDAAkD,4BAA4B;AAC9E;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gDAAgD,sBAAsB;AACtE,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwB,uBAAuB;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+CAA+C,iBAAiB;AAChE,iBAAiB;AACjB;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6CAA6C,uBAAuB,kCAAkC,4HAA4H,qHAAqH;AACvV,SAAS;AACT;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA,kD;;;;;;;;;;;;ACzJa;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uC;;;;;;;;;;;;AClBa;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA,qC;;;;;;;;;;;;;;;;;;;;;;;ACJa;AACb,8CAA8C,cAAc;AAC5D,2BAA2B,mBAAO,CAAC,wGAAsB;AACzD;AACA,iC;;;;;;;;;;;;ACJa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D,kCAAkC,mBAAO,CAAC,sFAA0B;AACpE,2BAA2B,mBAAO,CAAC,sFAAiB;AACpD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sBAAsB,wCAAwC;AAC9D;AACA;AACA;AACA;AACA;AACA,mBAAmB;AACnB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAqB;AACrB;AACA;AACA;AACA;AACA,qBAAqB;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qCAAqC;AACrC,iCAAiC;AACjC,6BAA6B;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qCAAqC;AACrC,iCAAiC;AACjC,6BAA6B;AAC7B;AACA,qBAAqB;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qCAAqC;AACrC,iCAAiC;AACjC,6BAA6B;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qCAAqC;AACrC,iCAAiC;AACjC,6BAA6B;AAC7B;AACA,qBAAqB;AACrB,iBAAiB;AACjB,aAAa;AACb,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8C;;;;;;;;;;;;AC7Ga;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA,CAAC,0DAA0D;AAC3D,kC;;;;;;;;;;;;ACRa;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,yDAAyD,iBAAiB,EAAE;AAC5E;AACA;AACA;AACA,sDAAsD,8BAA8B,EAAE;AACtF;AACA;AACA;AACA,yDAAyD,8BAA8B,EAAE;AACzF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,iC;;;;;;;;;;;;ACvCa;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4CAA4C;AAC5C;AACA,8CAA8C,cAAc;AAC5D;AACA,+CAA+C,mBAAO,CAAC,4HAAkD;AACzG,gBAAgB,mBAAO,CAAC,8FAAmC;AAC3D,eAAe,mBAAO,CAAC,sGAAuC;AAC9D,cAAc,mBAAO,CAAC,4EAAU;AAChC,sBAAsB,mBAAO,CAAC,sGAAiB;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kGAAkG;AAClG;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gCAAgC;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8GAA8G;AAC9G;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA,+FAA+F;AAC/F;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8JAA8J;AAC9J,0FAA0F,gBAAgB;AAC1G;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sIAAsI,YAAY,oJAAoJ,EAAE;AACxS;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,iLAAiL;AACjL;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA,qCAAqC,YAAY,8TAA8T;AAC/W;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8BAA8B;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kEAAkE,iCAAiC,EAAE;AACrG;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6C;;;;;;;;;;;;ACrVa;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D;AACA;AACA,cAAc,mBAAO,CAAC,4EAAU;AAChC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,iBAAiB,wBAAwB,kBAAkB,EAAE;AAC7D,gEAAgE;AAChE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,yC;;;;;;;;;;;;AC3Da;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D;AACA,0BAA0B,mBAAO,CAAC,0HAAiC;AACnE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,aAAa,2IAA2I;AACtM;AACA;AACA,8CAA8C,aAAa,iFAAiF;AAC5I;AACA;AACA;AACA;AACA;AACA;AACA,iBAAiB;AACjB,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,aAAa,2IAA2I;AACtM;AACA;AACA,8CAA8C,aAAa,iFAAiF;AAC5I;AACA;AACA;AACA;AACA;AACA;AACA,iBAAiB;AACjB,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAqB;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4GAA4G,+BAA+B,EAAE;AAC7I;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4GAA4G,+BAA+B,EAAE;AAC7I;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4C;;;;;;;;;;;;ACrKa;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oCAAoC;AACpC,SAAS;AACT,sDAAsD,oDAAoD,EAAE;AAC5G;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA,yC;;;;;;;;;;;;ACtEa;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4EAA4E,OAAO;AACnF;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D;AACA,eAAe,mBAAO,CAAC,sIAAuD;AAC9E,eAAe,mBAAO,CAAC,sGAAuC;AAC9D,sBAAsB,mBAAO,CAAC,kGAAiB;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mCAAmC;AACnC,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0CAA0C,4CAA4C,EAAE;AACxF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sDAAsD;AACtD,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,gBAAgB;AAC9D;AACA,aAAa;AACb,2CAA2C,SAAS,yEAAyE;AAC7H;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA,mCAAmC,oBAAoB;AACvD;AACA;AACA,mBAAmB,iBAAiB;AACpC,uCAAuC,mBAAmB,6DAA6D;AACvH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sEAAsE,YAAY,uDAAuD;AACzI;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6CAA6C,mBAAmB;AAChE;AACA;AACA;AACA,SAAS;AACT;AACA;AACA,uBAAuB,4BAA4B;AACnD;AACA,qDAAqD,wBAAwB,0BAA0B;AACvG;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wDAAwD,4BAA4B,EAAE;AACtF,mBAAmB,yBAAyB;AAC5C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mDAAmD,oBAAoB,EAAE;AACzE;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA,sEAAsE;AACtE;AACA,SAAS;AACT,KAAK;AACL,6DAA6D,YAAY,EAAE;AAC3E,mBAAmB,4BAA4B;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,mBAAmB,4BAA4B;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+HAA+H,uFAAuF,EAAE;AACxN;AACA,uBAAuB,oBAAoB;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA,2CAA2C,4CAA4C,KAAK,qHAAqH,sEAAsE,EAAE,8FAA8F;AACvX,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwB,UAAU;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,iBAAiB;AACjB;AACA;AACA;AACA;AACA;AACA,+DAA+D,8BAA8B,iOAAiO;AAC9T;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sCAAsC,aAAa,uCAAuC;AAC1F;AACA;AACA,sCAAsC,aAAa,qCAAqC;AACxF;AACA;AACA,sCAAsC,aAAa,oHAAoH;AACvK;AACA;AACA,sCAAsC,aAAa,oHAAoH;AACvK;AACA;AACA;AACA;AACA,0BAA0B;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA,qCAAqC;AACrC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sBAAsB,wBAAwB;AAC9C,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sBAAsB,wBAAwB;AAC9C,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA,kC;;;;;;;;;;;;AC7iBa;AACb;AACA;AACA,gDAAgD,OAAO;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,6DAA6D;AAC9D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mCAAmC,qBAAqB,wDAAwD;AAChH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mCAAmC,qBAAqB;AACxD,2CAA2C,YAAY,6BAA6B,mBAAmB,8BAA8B,GAAG;AACxI,aAAa,GAAG;AAChB;AACA;AACA;AACA;AACA,qC;;;;;;;;;;;;AChFa;AACb;AACA;AACA;AACA,cAAc,gBAAgB,sCAAsC,iBAAiB,EAAE;AACvF,6BAA6B,8EAA8E;AAC3G;AACA;AACA;AACA;AACA;AACA;AACA,uBAAuB,sBAAsB;AAC7C;AACA;AACA,CAAC;AACD;AACA,4EAA4E,OAAO;AACnF;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8CAA8C,cAAc;AAC5D,gBAAgB,mBAAO,CAAC,sEAAW;AACnC,iBAAiB,mBAAO,CAAC,wEAAY;AACrC,eAAe,mBAAO,CAAC,8EAAe;AACtC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA,wCAAwC;AACxC,+CAA+C;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb,qIAAqI,4DAA4D,uDAAuD,EAAE;AAC1P;AACA;AACA,wCAAwC,8DAA8D;AACtG;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qCAAqC,0BAA0B;AAC/D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA,oCAAoC,mCAAmC;AACvE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4CAA4C,6CAA6C;AACzF,oCAAoC,2BAA2B;AAC/D;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA,sCAAsC,oBAAoB;AAC1D;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA,sCAAsC,mCAAmC;AACzE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,kD;;;;;;;;;;;;AC5Na;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA;AACA,oC;;;;;;;;;;;;ACRa;AACb,8CAA8C,cAAc;AAC5D;AACA,eAAe,mBAAO,CAAC,8EAAe;AACtC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+JAA+J,8BAA8B,EAAE;AAC/L;AACA;AACA;AACA;AACA,+JAA+J,4BAA4B,EAAE;AAC7L;AACA;AACA;AACA;AACA,6GAA6G,0CAA0C,EAAE;AACzJ;AACA;AACA;AACA;AACA,4GAA4G,oBAAoB,EAAE;AAClI;AACA;AACA;AACA;AACA,4GAA4G,2BAA2B,EAAE;AACzI;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mC;;;;;;;;;;;;AC9Ea;AACb,8CAA8C,cAAc;AAC5D;AACA;AACA;AACA;AACA;AACA,KAAK;A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AO,EAAE;AACL9J,YAAM,EAAE;AACJ+J,mBAAW,EAAE,QADT;AAEJtE,YAAI,EAAE,QAFF;AAGJuE,YAAI,EAAE,IAHF;AAIJC,gBAAQ,EAAE;AAJN,OADH;AAOL/J,mBAAa,EAAE;AACX6J,mBAAW,EAAE,gBADF;AAEXtE,YAAI,EAAE,QAFK;AAGXuE,YAAI,EAAE,IAHK;AAIXC,gBAAQ,EAAE;AAJC,OAPV;AAaL9J,YAAM,EAAE;AACJ4J,mBAAW,EAAE,QADT;AAEJtE,YAAI,EAAE,SAFF;AAGJuE,YAAI,EAAE,IAHF;AAIJC,gBAAQ,EAAE;AAJN;AAbH,KALN;AAyBHjP,WAAO,EAAE;AAzBN,GAAP;AA2BH,CA5BM,C;;;;;;;;;;;;ACIP;AAAA;AAAO,IAAM0O,gBAAgB,GAAG,6BAAzB,C","file":"autoProcessor.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"./generated_module/src/autoProcessor.ts\");\n","export type Dictionary<T> = Record<string, T>;\n\n/** @returns the non-prototype keys of the given object */\nexport const getKeys = (obj: object): string[] => {\n /* eslint-disable-line */\n return Object.getOwnPropertyNames(obj);\n};\n\nexport const values = <T = any>(obj: { [key: string]: T }): T[] => {\n return getKeys(obj).map((key: string): T => obj[key]);\n};\n\nexport const forEach = <T>(\n obj: Dictionary<T>,\n action: (key: string, value: T) => void,\n): void => {\n getKeys(obj).forEach((key: string): void => action(key, obj[key]));\n};\n\nexport const map = <T, R>(\n obj: Dictionary<T>,\n mapper: (key: string, value: T) => R,\n): R[] => {\n return getKeys(obj).map((key: string): R => mapper(key, obj[key]));\n};\n\ntype NonNullAssertion = <T>(val: T, msg?: string) => asserts val is NonNullable<T>;\n\nexport const assertNotNull: NonNullAssertion = <T>(\n val: T,\n msg?: string,\n): asserts val is NonNullable<T> => {\n if (val == null) {\n throw new Error(msg);\n }\n};\n\nexport const toDictionary = <T, V>(\n arr: T[],\n keyMapper: (input: T) => string,\n valueMapper: (input: T) => V,\n): Dictionary<V> => {\n const result: Dictionary<V> = {};\n arr.forEach((entry) => {\n result[keyMapper(entry)] = valueMapper(entry);\n });\n return result;\n};\n","import {\n getModuleConfigFromFile,\n getDerivedData as getDerivedDataUser,\n} from \"./getUserData\";\nimport { AppModel, DerivedData } from \"./types/AutoModuleTypes\";\n\nfunction createAutoProcessor(\n getDerivedData: (dataModel: AppModel) => DerivedData,\n): (dataModel: AppModel) => DerivedData {\n const derivedDataGetter = (dataModel: AppModel): DerivedData => {\n return {\n getModuleConfig: getModuleConfigFromFile,\n ...getDerivedData(dataModel),\n };\n };\n return derivedDataGetter;\n}\n\nexport const getDerivedData = createAutoProcessor(getDerivedDataUser);\n","import { ModuleConfig } from \"@microchip/melody-automodule-interface/lib/src/ModuleConfig\";\nimport { PinsData } from \"@microchip/melody-automodule-interface/lib/src/pins\";\nimport { PinsLogic } from \"@microchip/melody-automodule-interface/lib/src/types\";\nexport { getCreatorFunctions } from \"../../src/CreatorFunctions\";\nexport { getDerivedData } from \"../../src/DerivedData\";\n\nexport const getPinsDataFromFile = (): PinsData | undefined => {\n try {\n return require(\"../../src/pinsdata.json\");\n } catch {\n return undefined;\n }\n};\n\nexport const getPinsLogicFromFile = (): PinsLogic | undefined => {\n try {\n return require(\"../../src/PinsLogic.ts\");\n } catch {\n return undefined;\n }\n};\n\nexport const getModuleConfigFromFile = (): ModuleConfig | undefined => {\n try {\n return require(\"../../src/moduleConfig.json\");\n } catch {\n return undefined;\n }\n};\n","import { pin_row } from \"@microchip/pin-standard\";\nimport { PinsData } from \"@microchip/melody-automodule-interface/lib/src/pins\";\nimport {\n AppModel,\n PinsLogic,\n} from \"@microchip/melody-automodule-interface/lib/src/types\";\nimport { getPinsDataFromFile, getPinsLogicFromFile } from \"../getUserData\";\n\nconst mockPinsLogic = (getPinsData: GetPinsData): PinsLogic => {\n const getCompletePinData = (appModel: AppModel): any => {\n return {};\n };\n const getRowData = (appModel: AppModel, rowData: pin_row): pin_row => {\n return rowData;\n };\n return {\n getCompletePinData: getCompletePinData,\n getRowData: getRowData,\n getPinsData: getPinsData,\n };\n};\n\ntype GetPinsData = typeof getPinsData;\nexport const getPinsData = (): PinsData => getPinsDataFromFile() ?? { rows: [] };\n\nexport const getPinsLogic = (): PinsLogic => {\n const pinsLogic = getPinsLogicFromFile();\n if (pinsLogic) {\n return {\n ...pinsLogic,\n getPinsData: getPinsData,\n };\n } else {\n return mockPinsLogic(getPinsData);\n }\n};\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar initializer_system_1 = require(\"./initializer-system\");\nexports.Interface = initializer_system_1.Interface;\nexports.INIT_PRIORITY = initializer_system_1.INIT_PRIORITY;\nexports.sortInitializers = initializer_system_1.sortInitializers;\n//# sourceMappingURL=index.js.map","\"use strict\";\nvar __spreadArrays = (this && this.__spreadArrays) || function () {\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\n r[k] = a[j];\n return r;\n};\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\n result[\"default\"] = mod;\n return result;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar InterfaceTypes = __importStar(require(\"@microchip/scf-interface\"));\nvar pkgJson = __importStar(require(\"../package.json\"));\nvar getInterfaceId = function () {\n return {\n name: InterfaceTypes.getInterfaceName(pkgJson),\n version: InterfaceTypes.getInterfaceVersion(pkgJson),\n };\n};\nexports.sortInitializers = function (initializers) {\n var retinitializers = __spreadArrays(initializers);\n retinitializers.sort(prioritySorter);\n return retinitializers;\n};\nvar prioritySorter = function (a, b) {\n var _a, _b, _c, _d, _e, _f, _g, _h;\n var result = 0;\n var apriority = (_b = (_a = a === null || a === void 0 ? void 0 : a.initializer) === null || _a === void 0 ? void 0 : _a.priority) !== null && _b !== void 0 ? _b : INIT_PRIORITY.DEFAULT;\n var bpriority = (_d = (_c = b === null || b === void 0 ? void 0 : b.initializer) === null || _c === void 0 ? void 0 : _c.priority) !== null && _d !== void 0 ? _d : INIT_PRIORITY.DEFAULT;\n if (apriority < bpriority) {\n result = -1;\n }\n else if (apriority > bpriority) {\n result = 1;\n }\n else {\n //same priority sort via intializer name alphabetically\n result = (_h = (_f = (_e = a === null || a === void 0 ? void 0 : a.initializer) === null || _e === void 0 ? void 0 : _e.name) === null || _f === void 0 ? void 0 : _f.localeCompare((_g = b === null || b === void 0 ? void 0 : b.initializer) === null || _g === void 0 ? void 0 : _g.name)) !== null && _h !== void 0 ? _h : 0;\n }\n return result;\n};\nvar INIT_PRIORITY;\n(function (INIT_PRIORITY) {\n INIT_PRIORITY[INIT_PRIORITY[\"START\"] = 1] = \"START\";\n INIT_PRIORITY[INIT_PRIORITY[\"PRE_PERIPHERAL\"] = 50] = \"PRE_PERIPHERAL\";\n INIT_PRIORITY[INIT_PRIORITY[\"PERIPHERAL\"] = 100] = \"PERIPHERAL\";\n INIT_PRIORITY[INIT_PRIORITY[\"POST_PERIPHERAL\"] = 150] = \"POST_PERIPHERAL\";\n INIT_PRIORITY[INIT_PRIORITY[\"DEFAULT\"] = 200] = \"DEFAULT\";\n INIT_PRIORITY[INIT_PRIORITY[\"PRE_SOFTWARE\"] = 250] = \"PRE_SOFTWARE\";\n INIT_PRIORITY[INIT_PRIORITY[\"SOFTWARE\"] = 300] = \"SOFTWARE\";\n INIT_PRIORITY[INIT_PRIORITY[\"POST_SOFTWARE\"] = 350] = \"POST_SOFTWARE\";\n INIT_PRIORITY[INIT_PRIORITY[\"END\"] = 400] = \"END\";\n})(INIT_PRIORITY = exports.INIT_PRIORITY || (exports.INIT_PRIORITY = {}));\nvar createMock = function () {\n return {\n interfaceId: getInterfaceId(),\n payload: {\n moduleName: \"MyModule\",\n },\n args: {},\n results: {\n requestId: {\n initializer: {\n name: \"mymodule_init\",\n header: {\n name: \"mymodule.h\",\n path: \"include/\",\n },\n },\n registerInit: [\n {\n name: \"OSCCON1\",\n comment: \"//Comments\",\n value: 55,\n valueAsHex: \"0x55\",\n },\n ],\n },\n },\n };\n};\nvar createPrototypeImport = function () {\n return {\n interfaceId: getInterfaceId(),\n };\n};\nvar createPrototypeExport = function () {\n return {\n interfaces: [{ interfaceId: getInterfaceId() }],\n };\n};\nexports.Interface = {\n createPrototypeExport: createPrototypeExport,\n createPrototypeImport: createPrototypeImport,\n getInterfaceId: getInterfaceId,\n createMock: createMock,\n};\n//# sourceMappingURL=initializer-system.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getTableOrder = exports.getInterruptTableView = void 0;\nvar StateHelper_1 = require(\"../manager_helper/StateHelper\");\nexports.getInterruptTableView = function (state) {\n var tables = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n tables[_i - 1] = arguments[_i];\n }\n var interruptTables = tables === null || tables === void 0 ? void 0 : tables.map(function (table) {\n if (table) {\n return {\n tableId: table.tableId,\n tableDescription: table.tableDescription,\n headers: table.headers,\n rowData: table.rowData,\n moduleIds: table.moduleIds,\n showOrderColumn: table.showOrderColumn,\n hasReorder: table.hasReorder,\n order: exports.getTableOrder(state, table),\n };\n }\n });\n return {\n interruptTables: interruptTables,\n };\n};\nexports.getTableOrder = function (state, table) {\n var _a;\n return (_a = StateHelper_1.getIntTableOrderFromState(state, table.tableId)) !== null && _a !== void 0 ? _a : Object.keys(table.rowData);\n};\n//# sourceMappingURL=InterruptTableViewHelper.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.cellUpdateAction = exports.Actions = void 0;\nexports.Actions = {\n CELL_UPDATE: \"CELL_UPDATE\",\n ROW_UP: \"ROW_UP\",\n ROW_DOWN: \"ROW_DOWN\",\n ROW_SELECT: \"ROW_SELECT\",\n ADD_ROW: \"ADD_ROW\",\n DELETE_ROW: \"DELETE_ROW\",\n};\nexports.cellUpdateAction = function (tableId, moduleId, column, rowId, cellValue) {\n return {\n type: exports.Actions.CELL_UPDATE,\n payload: {\n tableId: tableId,\n moduleId: moduleId,\n column: column,\n rowId: rowId,\n cellValue: cellValue,\n },\n };\n};\n//# sourceMappingURL=TableActions.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.reduce = void 0;\nvar TableActions_1 = require(\"./TableActions\");\nexports.reduce = function (state, action) {\n switch (action.type) {\n case TableActions_1.Actions.CELL_UPDATE:\n return CellUpdateReducer(state, action);\n default:\n return state;\n }\n};\nvar CellUpdateReducer = function (state, action) {\n var _a, _b, _c;\n var _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;\n if (action.payload && ((_d = action.payload) === null || _d === void 0 ? void 0 : _d.moduleId) && ((_e = action.payload) === null || _e === void 0 ? void 0 : _e.rowId) && ((_f = action.payload) === null || _f === void 0 ? void 0 : _f.column)) {\n return __assign(__assign({}, (state !== null && state !== void 0 ? state : {})), { interruptTables: __assign(__assign({}, ((_g = state === null || state === void 0 ? void 0 : state[\"interruptTables\"]) !== null && _g !== void 0 ? _g : {})), { data: __assign(__assign({}, ((_j = (_h = state === null || state === void 0 ? void 0 : state[\"interruptTables\"]) === null || _h === void 0 ? void 0 : _h.data) !== null && _j !== void 0 ? _j : {})), (_a = {}, _a[action.payload.moduleId] = __assign(__assign({}, ((_m = (_l = (_k = state === null || state === void 0 ? void 0 : state[\"interruptTables\"]) === null || _k === void 0 ? void 0 : _k.data) === null || _l === void 0 ? void 0 : _l[action.payload.moduleId]) !== null && _m !== void 0 ? _m : {})), (_b = {}, _b[action.payload.rowId] = __assign(__assign({}, ((_s = (_q = (_p = (_o = state === null || state === void 0 ? void 0 : state[\"interruptTables\"]) === null || _o === void 0 ? void 0 : _o.data) === null || _p === void 0 ? void 0 : _p[action.payload.moduleId]) === null || _q === void 0 ? void 0 : _q[(_r = action.payload) === null || _r === void 0 ? void 0 : _r.rowId]) !== null && _s !== void 0 ? _s : {})), (_c = {}, _c[action.payload.column] = action.payload.cellValue, _c)), _b)), _a)) }) });\n }\n};\n//# sourceMappingURL=reduce.js.map","\"use strict\";\n// export { InterruptTableHelper } from \"./InterruptTableHelper\";\n// export {\n// BaseTable,\n// BaseTableColumns,\n// BaseTableRowData,\n// InterruptData,\n// InterruptHeaderInfo,\n// ColumnTypes,\n// InterruptTableData,\n// Row,\n// } from \"./types\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.reduce = exports.getInterruptTableView = exports.cellUpdateAction = exports.Actions = exports.getIntTableOrderFromState = exports.getIntTableDataFromState = exports.getInterruptTableState = exports.InterruptManagerHelper = exports.NoMetaModule = void 0;\nvar TableCell_1 = require(\"./types/TableCell\");\nObject.defineProperty(exports, \"NoMetaModule\", { enumerable: true, get: function () { return TableCell_1.NoMetaModule; } });\nvar InterruptManagerHelper_1 = require(\"./manager_helper/InterruptManagerHelper\");\nObject.defineProperty(exports, \"InterruptManagerHelper\", { enumerable: true, get: function () { return InterruptManagerHelper_1.InterruptManagerHelper; } });\nvar StateHelper_1 = require(\"./manager_helper/StateHelper\");\nObject.defineProperty(exports, \"getInterruptTableState\", { enumerable: true, get: function () { return StateHelper_1.getInterruptTableState; } });\nObject.defineProperty(exports, \"getIntTableDataFromState\", { enumerable: true, get: function () { return StateHelper_1.getIntTableDataFromState; } });\nObject.defineProperty(exports, \"getIntTableOrderFromState\", { enumerable: true, get: function () { return StateHelper_1.getIntTableOrderFromState; } });\n// export {\n// InterruptTablesApp,\n// Props as InterruptTablesProps,\n// } from \"./InterruptTableView/InterruptTablesApp\";\nvar TableActions_1 = require(\"./InterruptTableView/TableActions\");\nObject.defineProperty(exports, \"Actions\", { enumerable: true, get: function () { return TableActions_1.Actions; } });\nObject.defineProperty(exports, \"cellUpdateAction\", { enumerable: true, get: function () { return TableActions_1.cellUpdateAction; } });\nvar InterruptTableViewHelper_1 = require(\"./InterruptTableView/InterruptTableViewHelper\");\nObject.defineProperty(exports, \"getInterruptTableView\", { enumerable: true, get: function () { return InterruptTableViewHelper_1.getInterruptTableView; } });\nvar reduce_1 = require(\"./InterruptTableView/reduce\");\nObject.defineProperty(exports, \"reduce\", { enumerable: true, get: function () { return reduce_1.reduce; } });\n//# sourceMappingURL=index.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.InterruptManagerHelper = void 0;\nvar TableCell_1 = require(\"../types/TableCell\");\nvar StateHelper_1 = require(\"./StateHelper\");\nvar InterruptManagerHelper = /** @class */ (function () {\n function InterruptManagerHelper(initTableData, state, initInterruptsData) {\n var _this = this;\n this.initInterruptsData = {};\n this.interruptTableRowData = {};\n this.interruptModuleIds = {};\n this.extraData = {};\n this.showTable = true;\n this.addInterruptHookData = function (dataKey, data, moduleId) {\n var _a;\n var rowData = {};\n Object.keys(data).forEach(function (buffKey) {\n var _a;\n var _b;\n if (_this.initTableData.headers[buffKey].show) {\n rowData = __assign(__assign({}, rowData), (_a = {}, _a[buffKey] = {\n value: data[buffKey].value,\n options: data[buffKey].options,\n actions: (_b = data[buffKey].actions) === null || _b === void 0 ? void 0 : _b.map(function (action) {\n var _a;\n action.action.payload.value =\n typeof action.action.payload.value === \"boolean\"\n ? action.action.payload.value\n ? \"true\"\n : \"false\"\n : action.action.payload.value;\n action.action.meta =\n moduleId === TableCell_1.NoMetaModule ||\n ((_a = action.action.meta) === null || _a === void 0 ? void 0 : _a.to) === TableCell_1.NoMetaModule\n ? undefined\n : action.action.meta != undefined\n ? action.action.meta\n : {\n to: moduleId,\n };\n return action;\n }),\n }, _a));\n }\n });\n _this.interruptTableRowData = __assign(__assign({}, _this.interruptTableRowData), (_a = {}, _a[dataKey] = rowData, _a));\n };\n this.getModuleIds = function () { return _this.interruptModuleIds; };\n this.initInterruptsData = initInterruptsData;\n this.initTableData = initTableData;\n this.state = state;\n }\n InterruptManagerHelper.prototype.dataMap = function (moduleId, dataToHook, rowIdMapper, dataMapper, extraDataMapper) {\n var _this = this;\n dataToHook.forEach(function (data) {\n var _a, _b;\n var _c;\n var rowId = rowIdMapper(data);\n var hookData = dataMapper(data, rowId);\n if (hookData == undefined)\n return;\n var extraData = (_c = extraDataMapper === null || extraDataMapper === void 0 ? void 0 : extraDataMapper(data, rowId)) !== null && _c !== void 0 ? _c : data;\n _this.interruptModuleIds = __assign(__assign({}, _this.interruptModuleIds), (_a = {}, _a[rowId] = moduleId, _a));\n _this.extraData = __assign(__assign({}, _this.extraData), (_b = {}, _b[rowId] = extraData, _b));\n _this.addInterruptHookData(rowId, hookData, moduleId);\n });\n return this;\n };\n InterruptManagerHelper.prototype.getRowDataElementValue = function (moduleId, colName, rowId, defaultVal) {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j;\n var tableState = StateHelper_1.getIntTableDataFromState(this.state);\n if (((_c = (_b = (_a = tableState === null || tableState === void 0 ? void 0 : tableState.data) === null || _a === void 0 ? void 0 : _a[moduleId]) === null || _b === void 0 ? void 0 : _b[rowId]) === null || _c === void 0 ? void 0 : _c[colName]) != undefined) {\n return (_f = (_e = (_d = tableState === null || tableState === void 0 ? void 0 : tableState.data) === null || _d === void 0 ? void 0 : _d[moduleId]) === null || _e === void 0 ? void 0 : _e[rowId]) === null || _f === void 0 ? void 0 : _f[colName];\n }\n else\n return defaultVal !== null && defaultVal !== void 0 ? defaultVal : (_j = (_h = (_g = this.interruptTableRowData) === null || _g === void 0 ? void 0 : _g[rowId]) === null || _h === void 0 ? void 0 : _h[colName]) === null || _j === void 0 ? void 0 : _j.value;\n };\n InterruptManagerHelper.prototype.getProcessedTableData = function () {\n var _this = this;\n var _a;\n if (this.showTable) {\n var rowData_1 = {};\n ((_a = this.order) !== null && _a !== void 0 ? _a : Object.keys(this.interruptTableRowData)).forEach(function (id) {\n var _a;\n rowData_1 = __assign(__assign({}, rowData_1), (_a = {}, _a[id] = _this.interruptTableRowData[id], _a));\n });\n return {\n tableId: this.initTableData.tableId,\n tableDescription: this.initTableData.tableDescription,\n headers: this.initTableData.headers,\n rowData: rowData_1,\n moduleIds: this.interruptModuleIds,\n hasReorder: this.initTableData.hasReorder,\n showOrderColumn: this.initTableData.showOrderColumn,\n order: this.order,\n };\n }\n };\n InterruptManagerHelper.prototype.setTableShow = function () {\n this.showTable = true;\n return this;\n };\n InterruptManagerHelper.prototype.unsetTableShow = function () {\n this.showTable = false;\n return this;\n };\n InterruptManagerHelper.prototype.getProcessedInterruptData = function () {\n var _this = this;\n var extractData = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n extractData[_i] = arguments[_i];\n }\n var myReturn = [];\n if (this.showTable) {\n (this.order ? this.order : Object.keys(this.interruptTableRowData)).forEach(function (interruptId) {\n var data = {};\n extractData === null || extractData === void 0 ? void 0 : extractData.forEach(function (dataKey) {\n var _a;\n var _b, _c, _d, _e, _f;\n data = __assign(__assign({}, data), (_a = {}, _a[dataKey] = (_d = (_c = (_b = _this.extraData) === null || _b === void 0 ? void 0 : _b[interruptId]) === null || _c === void 0 ? void 0 : _c[dataKey]) !== null && _d !== void 0 ? _d : (_f = (_e = _this.initInterruptsData) === null || _e === void 0 ? void 0 : _e[interruptId]) === null || _f === void 0 ? void 0 : _f[dataKey], _a));\n });\n myReturn.push(data);\n });\n }\n return myReturn;\n };\n InterruptManagerHelper.prototype.setOrder = function (orderMap) {\n var _this = this;\n var rowIds = Object.keys(this.interruptTableRowData);\n var storedData = {};\n rowIds.forEach(function (rowId) {\n var _a;\n var _b, _c, _d, _e;\n storedData = __assign(__assign({}, storedData), (_a = {}, _a[rowId] = __assign(__assign({}, ((_c = (_b = _this.initInterruptsData) === null || _b === void 0 ? void 0 : _b[rowId]) !== null && _c !== void 0 ? _c : {})), ((_e = (_d = _this.extraData) === null || _d === void 0 ? void 0 : _d[rowId]) !== null && _e !== void 0 ? _e : {})), _a));\n });\n var rowIdsOrdered = orderMap(rowIds, storedData);\n this.order = rowIdsOrdered;\n return this;\n };\n return InterruptManagerHelper;\n}());\nexports.InterruptManagerHelper = InterruptManagerHelper;\n//# sourceMappingURL=InterruptManagerHelper.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getIntTableDataOfModuleFromState = exports.getIntTableDataFromState = exports.getIntTableOrderFromState = exports.getInterruptTableState = void 0;\nexports.getInterruptTableState = function (state) {\n return state === null || state === void 0 ? void 0 : state[\"interruptTables\"];\n};\nexports.getIntTableOrderFromState = function (state, tableId) {\n var _a, _b;\n return (_b = (_a = exports.getInterruptTableState(state)) === null || _a === void 0 ? void 0 : _a.order) === null || _b === void 0 ? void 0 : _b[tableId];\n};\nexports.getIntTableDataFromState = function (state) {\n var _a;\n return (_a = exports.getInterruptTableState(state)) === null || _a === void 0 ? void 0 : _a.data;\n};\nexports.getIntTableDataOfModuleFromState = function (state, moduleId) {\n var _a;\n return (_a = exports.getIntTableDataFromState(state)) === null || _a === void 0 ? void 0 : _a[moduleId];\n};\n//# sourceMappingURL=StateHelper.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.NoMetaModule = void 0;\nexports.NoMetaModule = \"___NOMETA___\";\n//# sourceMappingURL=TableCell.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar interrupt_standard_1 = require(\"./interrupt-standard\");\nexports.Interface = interrupt_standard_1.Interface;\n//# sourceMappingURL=index.js.map","\"use strict\";\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\n result[\"default\"] = mod;\n return result;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar InterfaceTypes = __importStar(require(\"@microchip/scf-interface\"));\nvar pkgJson = __importStar(require(\"../package.json\"));\nexports.getInterfaceId = function () {\n return {\n name: InterfaceTypes.getInterfaceName(pkgJson),\n version: InterfaceTypes.getInterfaceVersion(pkgJson),\n };\n};\nexports.createPrototypeImport = function () {\n return {\n interfaceId: exports.getInterfaceId(),\n };\n};\nexports.createPrototypeExport = function () {\n return {\n interfaces: [{ interfaceId: exports.getInterfaceId() }],\n };\n};\nvar createMock = function () {\n return {\n interfaceId: exports.getInterfaceId(),\n payload: {},\n results: {\n requestId: {\n interruptList: [\n {\n module: \"UART1\",\n name: \"URXI\",\n isEnabled: true,\n },\n {\n module: \"UART1\",\n name: \"UTXI\",\n isEnabled: true,\n },\n ],\n interruptActions: {\n URXI: {\n isEnabled: [\n {\n validFor: true,\n action: {\n type: \"[FORM] SUBMIT\",\n payload: {\n tabId: \"main\",\n path: \"interrupt.urxi\",\n value: true,\n },\n },\n },\n {\n validFor: false,\n action: {\n type: \"[FORM] SUBMIT\",\n payload: {\n tabId: \"main\",\n path: \"interrupt.urxi\",\n value: false,\n },\n },\n },\n ],\n },\n UTXI: {\n isEnabled: [\n {\n validFor: true,\n action: {\n type: \"[FORM] SUBMIT\",\n payload: {\n tabId: \"main\",\n path: \"interrupt.utxi\",\n value: true,\n },\n },\n },\n {\n validFor: false,\n action: {\n type: \"[FORM] SUBMIT\",\n payload: {\n tabId: \"main\",\n path: \"interrupt.utxi\",\n value: false,\n },\n },\n },\n ],\n },\n },\n },\n },\n };\n};\nexports.Interface = {\n createPrototypeExport: exports.createPrototypeExport,\n createPrototypeImport: exports.createPrototypeImport,\n getInterfaceId: exports.getInterfaceId,\n createMock: createMock,\n};\n//# sourceMappingURL=interrupt-standard.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.RowPrefix = void 0;\nvar RowPrefix;\n(function (RowPrefix) {\n RowPrefix[\"Default\"] = \"defaultRow_\";\n RowPrefix[\"Dynamic\"] = \"dynamicRow_\";\n})(RowPrefix = exports.RowPrefix || (exports.RowPrefix = {}));\n//# sourceMappingURL=Tables.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.toDictionary = exports.assertNotNull = exports.map = exports.forEach = exports.values = exports.getKeys = void 0;\n/** @returns the non-prototype keys of the given object */\nvar getKeys = function (obj) {\n return Object.getOwnPropertyNames(obj);\n};\nexports.getKeys = getKeys;\n/**\n * Gets the values of a map as a list\n * @param obj\n * @returns\n */\nvar values = function (obj) {\n return (0, exports.getKeys)(obj).map(function (key) { return obj[key]; });\n};\nexports.values = values;\nvar forEach = function (obj, action) {\n (0, exports.getKeys)(obj).forEach(function (key) { return action(key, obj[key]); });\n};\nexports.forEach = forEach;\nvar map = function (obj, mapper) {\n return (0, exports.getKeys)(obj).map(function (key) { return mapper(key, obj[key]); });\n};\nexports.map = map;\nvar assertNotNull = function (val, msg) {\n if (val == null) {\n throw new Error(msg);\n }\n};\nexports.assertNotNull = assertNotNull;\nvar toDictionary = function (arr, keyMapper, valueMapper) {\n var result = {};\n arr.forEach(function (entry) {\n result[keyMapper(entry)] = valueMapper(entry);\n });\n return result;\n};\nexports.toDictionary = toDictionary;\n//# sourceMappingURL=Utils.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getFriendlyInterfaceId = exports.getModuleDefaultDescription = exports.DependencySelector = exports.getProcessedHandle = exports.getSettingOptionsIfPresent = exports.getOverrideDefaultValue = exports.getSettingDefaultIfPresent = exports.getOptionValueByName = exports.getSettingFromComponent = exports.getSettingBits = exports.getRegisterValues = exports.hasConfigBits = exports.getComboOptions = exports.getDefaultValue = exports.castComponent = void 0;\nvar CalculateRegisterValue_1 = __importDefault(require(\"@microchip/scf-device/lib/CalculateRegisterValue\"));\nvar Setting_1 = require(\"@microchip/scf-device/lib/Setting\");\nvar Arrays_1 = require(\"@microchip/scf-device/lib/util/Arrays\");\nvar Utils_1 = require(\"../Utils\");\nvar getConfigData_1 = require(\"./getConfigData\");\nvar castComponent = function (component) {\n switch (component.category) {\n case \"software\":\n return component;\n case \"import\":\n return component;\n case \"hardware\":\n return component;\n default:\n throw Error(\"Unsupported Component Type\");\n }\n};\nexports.castComponent = castComponent;\nvar getDefaultValue = function (overrideDefaultValues, component) {\n var _a;\n return ((_a = overrideDefaultValues === null || overrideDefaultValues === void 0 ? void 0 : overrideDefaultValues(component.name)) !== null && _a !== void 0 ? _a : (component.type === \"ComboBox\"\n ? component.defaultValue.value\n : component.defaultValue));\n};\nexports.getDefaultValue = getDefaultValue;\nvar getComboOptions = function (overrideOptions, component) {\n var _a, _b;\n return (_a = overrideOptions === null || overrideOptions === void 0 ? void 0 : overrideOptions(component.name)) !== null && _a !== void 0 ? _a : (_b = component === null || component === void 0 ? void 0 : component.defaultValue) === null || _b === void 0 ? void 0 : _b[\"options\"];\n};\nexports.getComboOptions = getComboOptions;\nvar hasConfigBits = function (interfaceName) {\n var _a;\n return ((_a = (0, exports.getFriendlyInterfaceId)(interfaceName)) === null || _a === void 0 ? void 0 : _a.indexOf(\"configuration_bits\")) != -1;\n};\nexports.hasConfigBits = hasConfigBits;\nvar getRegisterValues = function (model, interfaceName) {\n var _a;\n var registers = {};\n var config = (0, getConfigData_1.getConfigData)(model);\n interfaceName = (0, exports.getFriendlyInterfaceId)(interfaceName);\n (_a = config === null || config === void 0 ? void 0 : config.peripherals) === null || _a === void 0 ? void 0 : _a.forEach(function (peripheral) {\n var _a, _b, _c;\n var peripheralName = (_a = (0, exports.getFriendlyInterfaceId)(peripheral.interfaceId.name)) !== null && _a !== void 0 ? _a : \"\";\n if ((0, exports.hasConfigBits)(peripheralName))\n return;\n if ((interfaceName != undefined && peripheralName !== interfaceName) ||\n !peripheral.registers)\n return;\n (_c = (0, Utils_1.getKeys)((_b = peripheral.registers) !== null && _b !== void 0 ? _b : {})) === null || _c === void 0 ? void 0 : _c.forEach(function (regName) {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;\n var registerValue;\n var reg = (_b = (_a = model.getHardware(peripheralName)) === null || _a === void 0 ? void 0 : _a.getPeripheral().registers) === null || _b === void 0 ? void 0 : _b[regName];\n if (reg) {\n registerValue = {\n comment: \"\",\n value: 0,\n valueAsHex: \"0x00\",\n name: reg === null || reg === void 0 ? void 0 : reg.name,\n alias: (_c = reg === null || reg === void 0 ? void 0 : reg.alias) !== null && _c !== void 0 ? _c : reg === null || reg === void 0 ? void 0 : reg.name,\n settings: {},\n };\n }\n else {\n return;\n }\n var registerVal = CalculateRegisterValue_1.default.for(reg);\n var comments = [];\n (_d = peripheral.registers) === null || _d === void 0 ? void 0 : _d[regName].forEach(function (set) {\n var _a, _b, _c, _d, _e;\n var setting = (_a = reg.settings) === null || _a === void 0 ? void 0 : _a[set.setting];\n if (setting) {\n if (setting.type !== \"R\") {\n //Add Comments\n comments.push(\"\".concat(set.setting, \" \").concat(model.getComponentValue(set.name), \"; \"));\n }\n if (registerValue === null || registerValue === void 0 ? void 0 : registerValue.settings) {\n registerValue.settings[setting.alias] = (0, exports.getSettingBits)(reg, setting, (_b = model.getComponent(set.name)) === null || _b === void 0 ? void 0 : _b.value, (_c = config === null || config === void 0 ? void 0 : config.deviceType) !== null && _c !== void 0 ? _c : \"PIC\");\n }\n switch (set.type) {\n case \"ComboBox\":\n case \"boolean\":\n registerVal.withNumberValue(setting, (_e = (0, exports.getOptionValueByName)(setting, (_d = model.getComponent(set.name)) === null || _d === void 0 ? void 0 : _d.value)) !== null && _e !== void 0 ? _e : 0);\n break;\n case \"number\":\n registerVal.withNumberValue(setting, model.getComponentValue(set.name));\n break;\n case \"register\":\n case \"string\":\n registerVal.withNumberValue(setting, Number(model.getComponentValue(set.name)));\n break;\n default:\n break;\n }\n }\n });\n if (reg.settings) {\n registerValue.value = registerVal.asNumber();\n }\n else {\n registerValue.value = Number((_j = model.getComponentValue((_h = (_g = (_f = (_e = peripheral.registers) === null || _e === void 0 ? void 0 : _e[regName]) === null || _f === void 0 ? void 0 : _f[0]) === null || _g === void 0 ? void 0 : _g.name) !== null && _h !== void 0 ? _h : \"\")) !== null && _j !== void 0 ? _j : 0);\n comments.push(\"\".concat(registerValue.name, \" \").concat(registerValue.value, \"; \"));\n }\n registerValue.valueAsHex =\n \"0x\" + registerValue.value.toString(16).toUpperCase();\n registerValue.comment = sortComments(comments, reg);\n registers[(_k = reg === null || reg === void 0 ? void 0 : reg.alias) !== null && _k !== void 0 ? _k : reg.name] = registerValue;\n });\n });\n return registers;\n};\nexports.getRegisterValues = getRegisterValues;\nvar sortComments = function (comments, register) {\n comments.sort(function (a, b) {\n var _a, _b, _c, _d;\n var settingA = (_a = register.settings) === null || _a === void 0 ? void 0 : _a[(_b = a.split[\" \"]) === null || _b === void 0 ? void 0 : _b[0]];\n var settingB = (_c = register.settings) === null || _c === void 0 ? void 0 : _c[(_d = b.split(\" \")) === null || _d === void 0 ? void 0 : _d[0]];\n return Number(settingB === null || settingB === void 0 ? void 0 : settingB.mask) - Number(settingA === null || settingA === void 0 ? void 0 : settingA.mask);\n });\n return comments.join(\"\");\n};\nvar getSettingBits = function (register, setting, value, deviceType) {\n var _a, _b;\n var setValNumber = Number((_b = (_a = (0, Setting_1.getOptionByAlias)(value, setting)) === null || _a === void 0 ? void 0 : _a.value) !== null && _b !== void 0 ? _b : 0);\n var settingValue = {\n alias: setting.alias,\n name: setting.name,\n value: setValNumber !== null && setValNumber !== void 0 ? setValNumber : 0,\n valueAsHex: \"0x\" + setValNumber.toString(16).toUpperCase(),\n valueAsDescription: value,\n bitName: deviceType === \"PIC\"\n ? \"\".concat(register.name, \"bits.\").concat(setting.name)\n : \"\".concat(register.name, \".\").concat(setting.name),\n };\n return settingValue;\n};\nexports.getSettingBits = getSettingBits;\nvar getRegisterFromComponent = function (hardware, component) {\n var _a, _b, _c, _d, _e;\n var registerName = (_a = component.name\n .replace(component.setting.toLowerCase(), \"\")) === null || _a === void 0 ? void 0 : _a.toUpperCase();\n var register = (_b = hardware === null || hardware === void 0 ? void 0 : hardware.registers) === null || _b === void 0 ? void 0 : _b[registerName];\n if (register) {\n return register;\n }\n else {\n var regName = (_c = component.name\n .replace(component.setting.toLowerCase(), \"\")) === null || _c === void 0 ? void 0 : _c.toUpperCase();\n var registers = (0, Utils_1.getKeys)((_d = hardware === null || hardware === void 0 ? void 0 : hardware.registers) !== null && _d !== void 0 ? _d : {});\n for (var _i = 0, _f = registers !== null && registers !== void 0 ? registers : []; _i < _f.length; _i++) {\n var reg = _f[_i];\n var modifiedRegName = reg.replace(/_/g, \"\");\n if (regName === modifiedRegName) {\n return (_e = hardware === null || hardware === void 0 ? void 0 : hardware.registers) === null || _e === void 0 ? void 0 : _e[reg];\n }\n }\n }\n};\nvar getSettingFromComponent = function (model, component) {\n var _a;\n var config = (0, getConfigData_1.getConfigData)(model);\n var setting;\n if (model) {\n (_a = config === null || config === void 0 ? void 0 : config.peripherals) === null || _a === void 0 ? void 0 : _a.forEach(function (peripheral) {\n var _a, _b, _c;\n if (setting)\n return;\n var peripheralName = (0, exports.getFriendlyInterfaceId)(peripheral.interfaceId.name);\n var hardware = (_a = model.getHardware(peripheralName)) === null || _a === void 0 ? void 0 : _a.getPeripheral();\n var register = getRegisterFromComponent(hardware, component);\n if (register && !register.settings) {\n //No settings for this particular register. Create one\n setting = {\n alias: (_b = register.alias) !== null && _b !== void 0 ? _b : register.name,\n name: register.name,\n defaultValue: register.defaultValue,\n type: register.type,\n description: register.desc,\n porDefault: register.defaultValue,\n };\n }\n else {\n setting = (_c = register === null || register === void 0 ? void 0 : register.settings) === null || _c === void 0 ? void 0 : _c[component.setting];\n }\n });\n }\n return setting;\n};\nexports.getSettingFromComponent = getSettingFromComponent;\nvar getOptionValueByName = function (setting, optionName) {\n if (!setting)\n return undefined;\n var optionValue = setting.porDefault;\n if (setting.options) {\n setting.options.forEach(function (option) {\n if (option.name === optionName || option.description === optionName) {\n optionValue = option.value;\n }\n });\n }\n return Number(optionValue);\n};\nexports.getOptionValueByName = getOptionValueByName;\nvar getSettingDefaultIfPresent = function (component, setting, overrideDefaultValue) {\n var _a, _b;\n var defaultValue;\n if (overrideDefaultValue !== undefined) {\n return overrideDefaultValue;\n }\n if (component.overrideDefaultValue) {\n return component.overrideDefaultValue;\n }\n if (setting === null || setting === void 0 ? void 0 : setting.defaultValue) {\n var option = (0, Setting_1.getOptionByName)(setting.defaultValue, setting);\n defaultValue =\n (_b = option === null || option === void 0 ? void 0 : option[(_a = component.displayOptionSetting) !== null && _a !== void 0 ? _a : \"alias\"]) !== null && _b !== void 0 ? _b : setting.defaultValue;\n }\n return defaultValue;\n};\nexports.getSettingDefaultIfPresent = getSettingDefaultIfPresent;\nvar getOverrideDefaultValue = function (component, model) {\n var _a, _b;\n return (_b = (_a = model.getDerivedFunctions()).overrideDefaultValues) === null || _b === void 0 ? void 0 : _b.call(_a, component.name);\n};\nexports.getOverrideDefaultValue = getOverrideDefaultValue;\nvar getSettingOptionsIfPresent = function (component, setting, masterComponentValue) {\n var _a;\n var options = [\"\"];\n if (setting) {\n var filteredOptions = component.mode\n ? filterModeOptions((_a = setting.options) !== null && _a !== void 0 ? _a : [], component, masterComponentValue)\n : setting.options;\n options = (0, Arrays_1.map)(filteredOptions !== null && filteredOptions !== void 0 ? filteredOptions : [], function (option) { var _a, _b; return (_b = option[(_a = component.displayOptionSetting) !== null && _a !== void 0 ? _a : \"alias\"]) !== null && _b !== void 0 ? _b : option.alias; });\n }\n return options;\n};\nexports.getSettingOptionsIfPresent = getSettingOptionsIfPresent;\nvar filterModeOptions = function (options, component, masterComponentValue) {\n var _a, _b, _c, _d;\n if (((_a = component.mode) === null || _a === void 0 ? void 0 : _a.operation) != \"filterOptions\" || masterComponentValue == undefined)\n return options;\n //Determine mode\n var mode = (0, Arrays_1.find)((_d = (0, Utils_1.getKeys)((_c = (_b = component.mode) === null || _b === void 0 ? void 0 : _b.optionModes) !== null && _c !== void 0 ? _c : {})) !== null && _d !== void 0 ? _d : [], function (mode) {\n var _a, _b, _c, _d;\n var match = (_b = (_a = component.mode) === null || _a === void 0 ? void 0 : _a.optionModes) === null || _b === void 0 ? void 0 : _b[mode];\n if (match) {\n return ((_d = (_c = masterComponentValue === null || masterComponentValue === void 0 ? void 0 : masterComponentValue.match(match)) === null || _c === void 0 ? void 0 : _c.length) !== null && _d !== void 0 ? _d : -1) > 0;\n }\n return false;\n });\n var filteredOptions = (0, Arrays_1.filter)(options !== null && options !== void 0 ? options : [], function (option) {\n var _a, _b, _c, _d;\n if (option.mode && mode) {\n var match = (_b = (_a = component.mode) === null || _a === void 0 ? void 0 : _a.optionModes) === null || _b === void 0 ? void 0 : _b[mode];\n if (match) {\n return ((_d = (_c = option.mode.match(match)) === null || _c === void 0 ? void 0 : _c.length) !== null && _d !== void 0 ? _d : -1) > 0;\n }\n }\n return true;\n });\n return filteredOptions;\n};\nvar getProcessedHandle = function (handle, payload) {\n var _a, _b, _c;\n if (handle) {\n handle = __assign(__assign({}, handle), { label: (_c = (_b = (_a = payload === null || payload === void 0 ? void 0 : payload.moduleName) !== null && _a !== void 0 ? _a : payload === null || payload === void 0 ? void 0 : payload.name) !== null && _b !== void 0 ? _b : handle.label) !== null && _c !== void 0 ? _c : handle.providerId + \" : \" + handle.exportId });\n }\n return handle;\n};\nexports.getProcessedHandle = getProcessedHandle;\nvar DependencySelector = /** @class */ (function () {\n function DependencySelector(model, component) {\n var _this = this;\n this.noneSelection = { label: \"None\" };\n this.createOptionEntry = function (option) {\n return {\n label: _this.createOptionLabel(option.handle, option.payload),\n value: option,\n };\n };\n this.createOptionLabel = function (handle, payload) {\n var _a, _b;\n return (_b = (_a = (0, exports.getProcessedHandle)(handle, payload)) === null || _a === void 0 ? void 0 : _a.label) !== null && _b !== void 0 ? _b : \"\";\n };\n this.model = model;\n this.component = component;\n }\n DependencySelector.prototype.generateDropdownOptions = function () {\n var dropdownOptions = [];\n var thisImport = this.model.getImports()[this.component.importId];\n var options = thisImport === null || thisImport === void 0 ? void 0 : thisImport.options;\n if (this.shouldAllowUnselectDependency(thisImport, options)) {\n dropdownOptions.push(this.noneSelection);\n }\n if (options) {\n for (var option in options) {\n dropdownOptions.push(this.createOptionEntry(options[option]));\n }\n }\n return dropdownOptions;\n };\n DependencySelector.prototype.getDropdownOptionNames = function () {\n var names = [];\n this.generateDropdownOptions().forEach(function (option) { return names.push(option.label); });\n return names;\n };\n DependencySelector.prototype.shouldAllowUnselectDependency = function (thisImport, options) {\n return (thisImport != undefined &&\n thisImport.isUnassignable != false &&\n options !== undefined);\n };\n return DependencySelector;\n}());\nexports.DependencySelector = DependencySelector;\nfunction getModuleDefaultDescription() {\n //TODO: Need to refactor this so that gets it from the source.\n //Alternatively, we could get it during the automodule update process and fetch it from there...\n return undefined;\n}\nexports.getModuleDefaultDescription = getModuleDefaultDescription;\nvar getFriendlyInterfaceId = function (interfaceName) {\n interfaceName = interfaceName === null || interfaceName === void 0 ? void 0 : interfaceName.replace(/ /g, \"\").replace(/-/g, \"_\");\n return interfaceName;\n};\nexports.getFriendlyInterfaceId = getFriendlyInterfaceId;\n//# sourceMappingURL=AutoModuleHelpers.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getConfigData = void 0;\n/* eslint-disable @typescript-eslint/no-var-requires */\nvar Utils_1 = require(\"../Utils\");\nvar getConfigData = function (model) {\n var _a, _b;\n var config = (_b = model === null || model === void 0 ? void 0 : (_a = model.getDerivedData()).getModuleConfig) === null || _b === void 0 ? void 0 : _b.call(_a);\n config = ConfigBuilder.for(config)\n .withDynamicConfigData(model)\n .withDynamicComponents(model)\n .build();\n return config;\n};\nexports.getConfigData = getConfigData;\nvar ConfigBuilder = /** @class */ (function () {\n function ConfigBuilder(config) {\n var _this = this;\n this.build = function () {\n return _this.config;\n };\n this.withDynamicConfigData = function (model) {\n var _a;\n return new ConfigBuilder((_a = model === null || model === void 0 ? void 0 : model.getDerivedFunction(\"getDynamicConfigData\", _this.config)) !== null && _a !== void 0 ? _a : _this.config);\n };\n this.withDynamicComponents = function (model) {\n var _a, _b;\n var dynamicComponents = (_b = model === null || model === void 0 ? void 0 : (_a = model.getDerivedFunctions()).getDynamicComponents) === null || _b === void 0 ? void 0 : _b.call(_a);\n if (dynamicComponents) {\n var dynamicComponentMap = (0, Utils_1.toDictionary)(dynamicComponents, function (component) {\n var _a;\n _this.config.UIGroups[component.group] =\n (_a = _this.config.UIGroups[component.group]) !== null && _a !== void 0 ? _a : component.group;\n return component.name;\n }, function (component) { return component; });\n _this.config.softwareData = __assign(__assign({}, _this.config.softwareData), dynamicComponentMap);\n }\n return new ConfigBuilder(_this.config);\n };\n this.config = config;\n }\n ConfigBuilder.for = function (config) {\n if (!config)\n throw console.error(\"Cannot find ModuleConfig\");\n return new ConfigBuilder(config);\n };\n return ConfigBuilder;\n}());\n//# sourceMappingURL=getConfigData.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getDefaultInterruptActions = exports.InterruptActionsBuilder = void 0;\nvar AutoModuleHelpers_1 = require(\"../autoModule/AutoModuleHelpers\");\nvar InterruptActionsBuilder = /** @class */ (function () {\n function InterruptActionsBuilder(model) {\n var _this = this;\n this.actions = [];\n this.createActionFor = function (componentName) {\n var _a;\n _this.actions = _this.buildActions();\n _this.curComponent = componentName\n ? (_a = _this.model.getComponent(componentName)) === null || _a === void 0 ? void 0 : _a.component\n : undefined;\n _this.curComponentName = componentName;\n _this.tableRowId = undefined;\n _this.tableRowCol = undefined;\n _this.tableCellPath = undefined;\n return _this;\n };\n this.addActionIfEnabled = function (actionValue) {\n if (!_this.curComponentName || !_this.curComponent)\n return _this;\n if (!_this.isActionValueAcceptable(_this.curComponent, actionValue))\n return _this;\n var payload = {\n tabId: _this.curComponent.tabs[0],\n value: actionValue,\n };\n if (_this.curComponent.category === \"table\") {\n if (!_this.tableCellPath)\n return _this;\n payload = __assign(__assign({}, payload), { path: \"\".concat(_this.curComponent.group, \".\").concat(_this.curComponent.name, \".\").concat(_this.tableCellPath), rowId: _this.tableRowId });\n }\n else {\n payload = __assign(__assign({}, payload), { path: \"\".concat(_this.curComponent.group, \".\").concat(_this.curComponent.name) });\n }\n _this.actions.push({\n validFor: true,\n action: {\n type: \"[FORM] SUBMIT\",\n payload: payload,\n },\n });\n return _this;\n };\n this.addActionIfDisabled = function (actionValue) {\n if (!_this.curComponentName || !_this.curComponent)\n return _this;\n if (!_this.isActionValueAcceptable(_this.curComponent, actionValue))\n return _this;\n var payload = {\n tabId: _this.curComponent.tabs[0],\n value: actionValue,\n };\n if (_this.curComponent.category === \"table\") {\n if (!_this.tableCellPath)\n return _this;\n payload = __assign(__assign({}, payload), { path: \"\".concat(_this.curComponent.group, \".\").concat(_this.curComponent.name, \".\").concat(_this.tableCellPath), rowId: _this.tableRowId });\n }\n else {\n payload = __assign(__assign({}, payload), { path: \"\".concat(_this.curComponent.group, \".\").concat(_this.curComponent.name) });\n }\n _this.actions.push({\n validFor: false,\n action: {\n type: \"[FORM] SUBMIT\",\n payload: payload,\n },\n });\n return _this;\n };\n this.setPathToTableCell = function (rowIndex, colName) {\n var _a;\n if (((_a = _this.curComponent) === null || _a === void 0 ? void 0 : _a.category) !== \"table\")\n return _this;\n _this.tableRowId = rowIndex;\n _this.tableRowCol = colName;\n _this.tableCellPath = \"\".concat(rowIndex, \".\").concat(colName);\n return _this;\n };\n this.isActionValueAcceptable = function (component, actionValue) {\n var _a, _b, _c, _d, _e, _f, _g, _h;\n if (component.category === \"hardware\") {\n if (component.type === \"ComboBox\") {\n var options = (_a = (0, AutoModuleHelpers_1.getSettingFromComponent)(_this.model, component)) === null || _a === void 0 ? void 0 : _a.options;\n if (!(options === null || options === void 0 ? void 0 : options.some(function (option) {\n var _a;\n return option[(_a = component[\"displayOptionSetting\"]) !== null && _a !== void 0 ? _a : \"alias\"] ===\n actionValue;\n }))) {\n return false;\n }\n }\n else if (component.type === \"boolean\") {\n // if (actionValue !== \"enabled\" && actionValue !== \"disabled\") {\n if (actionValue !== true && actionValue !== false) {\n return false;\n }\n }\n }\n else if (component.category === \"software\") {\n if (component.type === \"ComboBox\") {\n var options = component[\"options\"];\n if (!(options === null || options === void 0 ? void 0 : options.some(function (option) { return option === actionValue; }))) {\n return false;\n }\n }\n else if (component.type === \"boolean\") {\n if (actionValue !== true && actionValue !== false) {\n return false;\n }\n }\n }\n else if (component.category === \"table\") {\n if (!_this.tableRowCol)\n return false;\n if (((_c = (_b = component.columns) === null || _b === void 0 ? void 0 : _b[_this.tableRowCol]) === null || _c === void 0 ? void 0 : _c.type) === \"ComboBox\") {\n var options = (_f = (_e = (_d = component.columns) === null || _d === void 0 ? void 0 : _d[_this.tableRowCol]) === null || _e === void 0 ? void 0 : _e.defaultValue) === null || _f === void 0 ? void 0 : _f[\"options\"];\n if (!(options === null || options === void 0 ? void 0 : options.some(function (option) { return option === actionValue; }))) {\n return false;\n }\n }\n else if (((_h = (_g = component.columns) === null || _g === void 0 ? void 0 : _g[_this.tableRowCol]) === null || _h === void 0 ? void 0 : _h.type) === \"boolean\") {\n if (actionValue !== true && actionValue !== false) {\n return false;\n }\n }\n }\n return true;\n };\n this.buildActions = function () {\n return _this.actions;\n };\n this.model = model;\n }\n InterruptActionsBuilder.createActionBuilder = function (model) {\n return new InterruptActionsBuilder(model);\n };\n return InterruptActionsBuilder;\n}());\nexports.InterruptActionsBuilder = InterruptActionsBuilder;\nfunction getDefaultInterruptActions(model, componentName) {\n if (!componentName)\n return [];\n return (InterruptActionsBuilder.createActionBuilder(model)\n .createActionFor(componentName)\n .addActionIfEnabled(true)\n .addActionIfDisabled(false)\n // .addActionIfEnabled(\"enabled\")\n // .addActionIfDisabled(\"disabled\")\n .buildActions());\n}\nexports.getDefaultInterruptActions = getDefaultInterruptActions;\n//# sourceMappingURL=InterruptActions.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.UidMapBuilder = void 0;\nvar UidMapBuilder = /** @class */ (function () {\n function UidMapBuilder() {\n this.uidMap = {};\n }\n UidMapBuilder.prototype.addDefaultRows = function (rowData) {\n var _this = this;\n rowData.forEach(function (row, rowCount) {\n var _a;\n _this.uidMap[row.uid] = (_a = row.rowId) !== null && _a !== void 0 ? _a : rowCount;\n });\n return this;\n };\n UidMapBuilder.prototype.addDynamicRows = function (tableState) {\n var _this = this;\n tableState.forEach(function (row) {\n var uid = row === null || row === void 0 ? void 0 : row.uid;\n if (uid && uid.indexOf(\"dynamicRow_\") > -1) {\n _this.incrementUidAndShift(uid, row.rowId);\n }\n });\n return this;\n };\n UidMapBuilder.prototype.removeRows = function (tableState) {\n var _this = this;\n tableState.forEach(function (row) {\n var uid = row === null || row === void 0 ? void 0 : row.uid;\n if (uid && (row === null || row === void 0 ? void 0 : row.dynamicallyRemoved)) {\n _this.uidMap[uid] = -1;\n }\n });\n return this;\n };\n UidMapBuilder.prototype.sortByValue = function () {\n var _this = this;\n var count = 0;\n var sortedUids = [];\n this.getUidKeys().forEach(function (uid) {\n var _a;\n sortedUids.push((_a = {}, _a[uid] = _this.uidMap[uid], _a));\n });\n sortedUids = sortedUids.sort(function (a, b) { return a[Object.keys(a)[0]] - b[Object.keys(b)[0]]; });\n sortedUids.forEach(function (uid) {\n var uidKey = Object.keys(uid)[0];\n if (_this.uidMap[uidKey] > -1) {\n _this.uidMap[uidKey] = count++;\n }\n });\n return this;\n };\n UidMapBuilder.prototype.create = function () {\n return this.uidMap;\n };\n UidMapBuilder.prototype.incrementUidAndShift = function (uid, rowId) {\n var _this = this;\n this.getUidKeys().forEach(function (uid) {\n if (_this.uidMap[uid] >= rowId) {\n _this.uidMap[uid]++;\n }\n });\n this.uidMap[uid] = rowId;\n };\n UidMapBuilder.prototype.getUidKeys = function () {\n return Object.keys(this.uidMap);\n };\n return UidMapBuilder;\n}());\nexports.UidMapBuilder = UidMapBuilder;\n//# sourceMappingURL=UidMapBuilder.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getHeaderStyle = exports.getCellStyle = exports.getTableUiSchema = exports.getTableActions = exports.getCellValidationInfo = exports.createTableUids = exports.overrideDefaultsAndFilterRows = exports.getValueBasedOnState = exports.getTableFormData = exports.removeRowFromTable = exports.addRowToTable = exports.addRowsToTable = exports.overrideCellValue = exports.createInitialRows = exports.getInitialTableFormData = exports.calculateColumnWidth = exports.isTableInState = exports.overrideTableDefaultsWithChanges = exports.getTableHelpers = exports.getTableComponentSchema = void 0;\nvar Tables_1 = require(\"@microchip/melody-automodule-interface/lib/src/Tables\");\nvar Arrays_1 = require(\"@microchip/scf-device/lib/util/Arrays\");\nvar UidMapBuilder_1 = require(\"./UidMapBuilder\");\nfunction getTableComponentSchema(component, viewModel) {\n var _a, _b, _c, _d;\n var tableColumns = {};\n for (var columnsKey in component.columns) {\n var rjsfType = void 0;\n if (component.columns[columnsKey].type === \"ComboBox\") {\n var colBox = component.columns[columnsKey];\n rjsfType = \"string\";\n tableColumns[columnsKey] = {\n type: rjsfType,\n title: colBox.title,\n default: getDefaultValue(viewModel.overrideDefaultValues, colBox, columnsKey, component.name),\n enum: getComboOptions(viewModel.overrideTableOptions, colBox, columnsKey, component.name),\n };\n }\n else {\n rjsfType = (_a = component === null || component === void 0 ? void 0 : component.columns[columnsKey]) === null || _a === void 0 ? void 0 : _a.type;\n tableColumns[columnsKey] = {\n type: rjsfType,\n title: component.columns[columnsKey].title,\n default: component.columns[columnsKey].defaultValue,\n };\n }\n }\n return {\n type: \"array\",\n title: (_d = (_c = (_b = viewModel.getDerivedFunction).overrideTitle) === null || _c === void 0 ? void 0 : _c.call(_b, component.name)) !== null && _d !== void 0 ? _d : component.description,\n items: {\n type: \"object\",\n properties: __assign({}, tableColumns),\n },\n };\n}\nexports.getTableComponentSchema = getTableComponentSchema;\nvar getTableHelpers = function () {\n return {\n addRowToTable: addRowToTable,\n addRowsToTable: addRowsToTable,\n calculateColumnWidth: calculateColumnWidth,\n createInitialRows: createInitialRows,\n createTableUids: createTableUids,\n getCellStyle: getCellStyle,\n getCellValidationInfo: getCellValidationInfo,\n getHeaderStyle: getHeaderStyle,\n getInitialTableFormData: getInitialTableFormData,\n getTableActions: getTableActions,\n getTableFormData: getTableFormData,\n getTableUiSchema: getTableUiSchema,\n getValueBasedOnState: getValueBasedOnState,\n isTableInState: isTableInState,\n overrideCellValue: overrideCellValue,\n overrideDefaultsAndFilterRows: overrideDefaultsAndFilterRows,\n overrideTableDefaultsWithChanges: overrideTableDefaultsWithChanges,\n removeRowFromTable: removeRowFromTable,\n createUidMapBuilder: function () { return new UidMapBuilder_1.UidMapBuilder(); },\n };\n};\nexports.getTableHelpers = getTableHelpers;\nfunction overrideTableDefaultsWithChanges(rowChanged, initialFormData, uidMap) {\n var value = __spreadArray([], initialFormData, true);\n if (Array.isArray(rowChanged)) {\n rowChanged.forEach(function (changedRow) {\n var changedUid = changedRow.uid;\n var rowChangeNum = uidMap[changedUid];\n value[rowChangeNum] = __assign(__assign({}, value[rowChangeNum]), changedRow);\n });\n }\n return value;\n}\nexports.overrideTableDefaultsWithChanges = overrideTableDefaultsWithChanges;\nfunction isTableInState(tabState, component) {\n return (tabState && tabState[component.group] && tabState[component.group][component.name]);\n}\nexports.isTableInState = isTableInState;\nfunction calculateColumnWidth(columns) {\n if (!columns) {\n return {};\n }\n var runningWidth = 0;\n var booleanFields = 0;\n var columnWidths = {};\n for (var columnName in columns) {\n if (columns[columnName].type === \"boolean\") {\n var width = 8;\n booleanFields++;\n columnWidths[columnName] = width;\n runningWidth += width;\n }\n }\n for (var columnName in columns) {\n if (columns[columnName].type !== \"boolean\") {\n var width = (100 - runningWidth) / (Object.keys(columns).length - booleanFields);\n columnWidths[columnName] = width;\n }\n }\n return columnWidths;\n}\nexports.calculateColumnWidth = calculateColumnWidth;\nfunction getInitialTableFormData(table, columnNames, model) {\n var value = [];\n var tableFormData = {};\n columnNames.forEach(function (columnName) {\n if (!tableFormData[columnName]) {\n tableFormData[columnName] = getDefaultValue(model.getDerivedFunctions().overrideTableDefaultValues, table.columns[columnName], columnName, table.name);\n }\n });\n if (!(table === null || table === void 0 ? void 0 : table.rowData)) {\n value = createInitialRows(table, tableFormData);\n }\n else {\n var rowId_1 = 0;\n table === null || table === void 0 ? void 0 : table.rowData.forEach(function (row) {\n var rowDataCols = Object.keys(row);\n columnNames.forEach(function (colName) {\n var _a;\n if (rowDataCols.indexOf(colName) === -1) {\n row = __assign(__assign({}, row), (_a = {}, _a[colName] = tableFormData[colName], _a.uid = createRowUid(Tables_1.RowPrefix.Default, rowId_1), _a));\n }\n });\n value.push(__assign(__assign({}, row), { uid: createRowUid(Tables_1.RowPrefix.Default, rowId_1), rowId: rowId_1 }));\n rowId_1++;\n });\n }\n return value;\n}\nexports.getInitialTableFormData = getInitialTableFormData;\nfunction createInitialRows(table, tableFormData) {\n var _a;\n if (tableFormData === void 0) { tableFormData = {}; }\n var value = [];\n var initialRows = (_a = table === null || table === void 0 ? void 0 : table.defaultRowNum) !== null && _a !== void 0 ? _a : 1;\n for (var i = 0; i < initialRows; i++) {\n value.push(__assign(__assign({}, tableFormData), { rowId: i, uid: createRowUid(Tables_1.RowPrefix.Default, i) }));\n }\n return value;\n}\nexports.createInitialRows = createInitialRows;\nfunction overrideCellValue(tableData, cell) {\n var modifiedTableData = __spreadArray([], tableData, true);\n modifiedTableData[cell.rowId][cell.columnName] = cell.value;\n return modifiedTableData;\n}\nexports.overrideCellValue = overrideCellValue;\nfunction addRowsToTable(tableData, columns, newRow, numberOfRows) {\n if (numberOfRows <= 0) {\n return tableData;\n }\n var value = addRowToTable(tableData, columns, __assign(__assign({}, newRow), { uid: Tables_1.RowPrefix.Dynamic + (numberOfRows - 1) }));\n return addRowsToTable(value, columns, newRow, numberOfRows - 1);\n}\nexports.addRowsToTable = addRowsToTable;\nfunction addRowToTable(tableData, columns, newRow) {\n var _a;\n var columnNames = Object.keys(columns);\n var newRowCols = Object.keys(newRow);\n var newRowId = newRow.rowId;\n var filteredTableTemp = [];\n if (tableData.length === 0) {\n filteredTableTemp.push(newRow);\n return filteredTableTemp;\n }\n if (newRowId != null) {\n columnNames.forEach(function (colName) {\n var _a;\n var _b, _c;\n var defaultColumnWidth = calculateColumnWidth(columns);\n if (newRowCols.indexOf(colName) === -1) {\n newRow = __assign(__assign({}, newRow), (_a = {}, _a[colName] = (_c = (_b = columns[colName].defaultValue) === null || _b === void 0 ? void 0 : _b[\"value\"]) !== null && _c !== void 0 ? _c : columns[colName].defaultValue, _a.columnWidth = columns[colName].columnWidth\n ? columns[colName].columnWidth + \"%\"\n : defaultColumnWidth[colName] + \"%\", _a));\n }\n });\n var tableFirstHalf = tableData.slice(0, newRowId);\n var tableSecondHalf = tableData.slice(newRowId);\n for (var i = 0; i < tableSecondHalf.length; i++) {\n var currentRowId = tableSecondHalf[i].rowId;\n tableSecondHalf[i] = __assign(__assign({}, tableSecondHalf[i]), { rowId: currentRowId + 1 });\n var actions = (_a = tableSecondHalf[i]) === null || _a === void 0 ? void 0 : _a.actions;\n if (actions) {\n tableSecondHalf[i][\"actions\"] = updateActionsRowId(actions, currentRowId + 1);\n }\n }\n tableFirstHalf.push(newRow);\n filteredTableTemp = __spreadArray(__spreadArray([], tableFirstHalf, true), tableSecondHalf, true);\n return filteredTableTemp;\n }\n return tableData;\n}\nexports.addRowToTable = addRowToTable;\nfunction removeRowFromTable(tableData, rowId) {\n var _a;\n var tableRemoved = tableData.filter(function (row) { return row.rowId !== rowId; });\n for (var i = 0; i < tableRemoved.length; i++) {\n tableRemoved[i].rowId = i;\n var actions = (_a = tableRemoved[i]) === null || _a === void 0 ? void 0 : _a.actions;\n if (actions) {\n tableRemoved[i][\"actions\"] = updateActionsRowId(actions, i);\n }\n }\n return tableRemoved;\n}\nexports.removeRowFromTable = removeRowFromTable;\nfunction getTableFormData(model, table, tab) {\n var _a;\n return ((_a = model.getDerivedFunction(table.name, table, model, tab)) !== null && _a !== void 0 ? _a : getValueBasedOnState(table, model, tab));\n}\nexports.getTableFormData = getTableFormData;\nfunction getValueBasedOnState(table, model, tab) {\n var columnNames = Object.keys(table.columns);\n var modelState = model.getState();\n var tabState = modelState ? modelState[tab] : undefined;\n var initialFormData = getInitialTableFormData(table, columnNames, model);\n if (!isTableInState(tabState, table)) {\n return initialFormData;\n }\n else {\n var rowChanged = tabState[table.group][table.name];\n var tableUids = createTableUids(table, tab, model, rowChanged);\n return overrideDefaultsAndFilterRows(rowChanged, initialFormData, table.columns, tableUids, table, tab);\n }\n}\nexports.getValueBasedOnState = getValueBasedOnState;\nfunction overrideDefaultsAndFilterRows(rowChanged, initialFormData, columns, tableUids, component, tab) {\n var modifiedForData = __spreadArray([], initialFormData, true);\n var keys = Object.keys(tableUids);\n rowChanged = rowChanged.filter(function (row) { return row != null; });\n rowChanged.forEach(function (row) {\n if (row.uid.indexOf(Tables_1.RowPrefix.Dynamic) > -1) {\n modifiedForData.push(row);\n }\n });\n var filteredModifed = [];\n keys.forEach(function (uid) {\n modifiedForData.forEach(function (row) {\n if (row.uid === uid) {\n filteredModifed[tableUids[uid]] = __assign(__assign({}, initialFormData[0]), row);\n }\n });\n });\n filteredModifed = filteredModifed.filter(function (row) { return row; });\n for (var i = 0; i < filteredModifed.length; i++) {\n if (filteredModifed[i].uid.indexOf(Tables_1.RowPrefix.Dynamic) > -1)\n continue;\n filteredModifed[i].rowId++;\n }\n var _loop_1 = function (i) {\n Object.keys(columns).forEach(function (columnName) {\n modifiedForData[i].actions = updateActionsRowId(createDefaultTableAction(component, i, columnName, tab, tableUids), i);\n });\n };\n for (var i = 0; i < modifiedForData.length; i++) {\n _loop_1(i);\n }\n return overrideTableDefaultsWithChanges(rowChanged, filteredModifed, tableUids);\n}\nexports.overrideDefaultsAndFilterRows = overrideDefaultsAndFilterRows;\nfunction createTableUids(component, tab, model, tableState) {\n var _a, _b, _c;\n var table = component;\n var dynamicTableData = model === null || model === void 0 ? void 0 : model.getDerivedFunction(component.name, component, model, tab);\n if (dynamicTableData) {\n var uidMap_1 = {};\n var rowNum_1 = 0;\n dynamicTableData.forEach(function (entry) {\n var uid = entry === null || entry === void 0 ? void 0 : entry.uid;\n if (uid !== undefined) {\n uidMap_1[uid] = rowNum_1++;\n }\n });\n return uidMap_1;\n }\n var rowData = table[\"rowData\"];\n if (!dynamicTableData && rowData) {\n var _loop_2 = function (i) {\n if (!rowData[i].uid) {\n rowData[i].uid = createRowUid(Tables_1.RowPrefix.Default, i);\n }\n rowData[i].rowId =\n (_b = (_a = (0, Arrays_1.find)(tableState !== null && tableState !== void 0 ? tableState : [], function (row) { return row.uid === (rowData === null || rowData === void 0 ? void 0 : rowData[i].uid); })) === null || _a === void 0 ? void 0 : _a.rowId) !== null && _b !== void 0 ? _b : rowData[i].rowId;\n };\n for (var i = 0; i < rowData.length; i++) {\n _loop_2(i);\n }\n }\n else {\n rowData =\n dynamicTableData !== null && dynamicTableData !== void 0 ? dynamicTableData : createInitialRows(table).map(function (row) {\n var _a, _b;\n return __assign(__assign({}, (row !== null && row !== void 0 ? row : {})), { rowId: (_b = (_a = (0, Arrays_1.find)(tableState !== null && tableState !== void 0 ? tableState : [], function (r) { return r.uid === (row === null || row === void 0 ? void 0 : row.uid); })) === null || _a === void 0 ? void 0 : _a.rowId) !== null && _b !== void 0 ? _b : row.rowId });\n });\n }\n var uidMapBuilder = (_c = model === null || model === void 0 ? void 0 : model.getTableHelpers().createUidMapBuilder()) !== null && _c !== void 0 ? _c : (0, exports.getTableHelpers)().createUidMapBuilder();\n return uidMapBuilder\n .addDefaultRows(rowData)\n .addDynamicRows(tableState !== null && tableState !== void 0 ? tableState : [])\n .removeRows(tableState !== null && tableState !== void 0 ? tableState : [])\n .sortByValue()\n .create();\n}\nexports.createTableUids = createTableUids;\nfunction getCellValidationInfo(component) {\n var table = component;\n var colInfo = [];\n var columns = table.columns;\n for (var column in columns) {\n var colData = table.columns[column];\n if (colData === null || colData === void 0 ? void 0 : colData[\"cellValidator\"]) {\n colInfo.push({\n type: colData[\"type\"],\n minValue: colData[\"cellValidator\"][\"minValue\"],\n maxValue: colData[\"cellValidator\"][\"maxValue\"],\n errMessage: colData[\"cellValidator\"][\"errorMessage\"],\n errTitle: colData[\"cellValidator\"][\"errorTitle\"],\n cValidation: colData[\"cellValidator\"][\"cValidation\"],\n cValidationErrTitle: colData[\"cellValidator\"][\"cValidationErrorTitle\"],\n cValidationErrMessage: colData[\"cellValidator\"][\"cValidationErrorMessage\"],\n });\n }\n }\n return colInfo;\n}\nexports.getCellValidationInfo = getCellValidationInfo;\nfunction getTableActions(component, tab, model, uids, rowFormData) {\n var _a, _b, _c, _d, _e;\n var table = component;\n var dynamicTableData;\n if (!rowFormData) {\n dynamicTableData = model === null || model === void 0 ? void 0 : model.getDerivedFunction(component.name, component, model, tab);\n }\n var rowData = (_b = (_a = rowFormData !== null && rowFormData !== void 0 ? rowFormData : dynamicTableData) !== null && _a !== void 0 ? _a : table[\"rowData\"]) !== null && _b !== void 0 ? _b : createInitialRows(table);\n var columnNames = Object.keys(table.columns);\n var tableActions = { table: {} };\n var rowCount = 0;\n var tableState = (_e = (_d = (_c = model === null || model === void 0 ? void 0 : model.getState()) === null || _c === void 0 ? void 0 : _c[tab]) === null || _d === void 0 ? void 0 : _d[component.group]) === null || _e === void 0 ? void 0 : _e[component.name];\n rowData.forEach(function (row) {\n columnNames.forEach(function (columnName) {\n var _a, _b, _c, _d;\n if (!tableActions[\"table\"][row.uid]) {\n tableActions[\"table\"][row.uid] = {};\n }\n var uid;\n for (var uidsKey in uids) {\n if (uids[uidsKey] === row.rowId) {\n uid = uidsKey;\n }\n }\n uid = uid !== null && uid !== void 0 ? uid : createRowUid(Tables_1.RowPrefix.Default, rowCount);\n var defaultAction = createDefaultTableAction(component, rowCount, columnName, tab, uid);\n if (tableState) {\n var ind_1 = -1;\n var filtered = tableState.filter(function (row, index) {\n ind_1 = index;\n return row.uid === uid;\n });\n if (filtered.length) {\n defaultAction = createDefaultTableAction(component, ind_1, columnName, tab, uid !== null && uid !== void 0 ? uid : createRowUid(Tables_1.RowPrefix.Default, rowCount));\n }\n }\n if (component.columns[columnName].type == \"ComboBox\") {\n defaultAction[\"payload\"] = __assign(__assign({}, defaultAction[\"payload\"]), { options: getComboOptions((_a = model === null || model === void 0 ? void 0 : model.getDerivedFunctions()) === null || _a === void 0 ? void 0 : _a.overrideTableOptions, table.columns[columnName], columnName, component.name) });\n }\n var cellAction = (_c = (_b = row.actions) === null || _b === void 0 ? void 0 : _b[columnName]) !== null && _c !== void 0 ? _c : defaultAction;\n tableActions[\"table\"][row.uid][columnName] =\n (_d = model === null || model === void 0 ? void 0 : model.getDerivedFunction(\"getActions\", table.name, cellAction)) !== null && _d !== void 0 ? _d : cellAction;\n });\n rowCount++;\n });\n var uidKeys = Object.keys(uids);\n uidKeys.forEach(function (uidKey) {\n columnNames.forEach(function (columnName) {\n if (uids[uidKey] > -1) {\n if (!tableActions[\"table\"][uidKey]) {\n tableActions[\"table\"][uidKey] = {};\n tableActions[\"table\"][uidKey][columnName] = createDefaultTableAction(table, uids[uidKey], columnName, tab, uidKey);\n }\n else if (!tableActions[\"table\"][uidKey][columnName]) {\n tableActions[\"table\"][uidKey][columnName] = createDefaultTableAction(table, uids[uidKey], columnName, tab, uidKey);\n }\n }\n });\n });\n return JSON.stringify(tableActions);\n}\nexports.getTableActions = getTableActions;\nfunction getTableUiSchema(table, columns) {\n var _a, _b;\n var tableUi = {\n tableCols: columns,\n search: table[\"isSearchable\"],\n striped: true,\n bordered: false,\n };\n if (table[\"canRemoveRows\"]) {\n tableUi = __assign(__assign({}, tableUi), { rightActions: getTableRightActions() });\n }\n if (table[\"canInsertRows\"]) {\n tableUi = __assign(__assign({}, tableUi), { leftActions: getTableLeftActions() });\n }\n if (table.canMoveRowDown) {\n tableUi = __assign(__assign({}, tableUi), { leftActions: ((_a = tableUi.leftActions) !== null && _a !== void 0 ? _a : []).concat(getTableMoveRowActions()[0]) });\n }\n if (table.canMoveRowUp) {\n tableUi = __assign(__assign({}, tableUi), { leftActions: ((_b = tableUi.leftActions) !== null && _b !== void 0 ? _b : []).concat(getTableMoveRowActions()[1]) });\n }\n return {\n \"ui:field\": \"table\",\n className: \"col-md-12 individualComponent\",\n table: __assign({}, tableUi),\n };\n}\nexports.getTableUiSchema = getTableUiSchema;\nfunction getCellStyle(isReadonly) {\n var tdStyle = {\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n };\n if (isReadonly) {\n tdStyle[\"backgroundColor\"] = \"#EEEEEE\";\n }\n return tdStyle;\n}\nexports.getCellStyle = getCellStyle;\nfunction getHeaderStyle(maxHeaderSize, displayHeadersDiagonally) {\n return displayHeadersDiagonally\n ? getDiagonalHeaderStyles(maxHeaderSize)\n : getDefaultHeaderStyles(maxHeaderSize);\n}\nexports.getHeaderStyle = getHeaderStyle;\nfunction getDiagonalHeaderStyles(maxHeaderSize) {\n var headerSizeMultiplier = 3.3;\n return {\n position: \"relative\",\n bottom: \"-7px\",\n left: \"6px\",\n transformOrigin: \"bottom left\",\n transform: \"rotate(-30deg)\",\n paddingTop: \"\".concat(headerSizeMultiplier * maxHeaderSize, \"px\"),\n };\n}\nfunction getDefaultHeaderStyles(maxHeaderSize) {\n return {\n whiteSpace: \"unset\",\n maxWidth: \"\".concat(maxHeaderSize, \"px\"),\n };\n}\nfunction createDefaultTableAction(component, row, column, tab, uid) {\n return {\n type: \"[Table] EDIT_CELL\",\n payload: {\n tabId: tab !== null && tab !== void 0 ? tab : \"main\",\n path: \"\".concat(component === null || component === void 0 ? void 0 : component.group, \".\").concat(component === null || component === void 0 ? void 0 : component.name),\n column: column,\n value: \"%v\",\n uid: uid,\n rowId: row,\n },\n };\n}\nfunction updateActionsRowId(currentActions, rowId) {\n var modifiedActions = __assign({}, currentActions);\n var columnNames = Object.keys(currentActions);\n columnNames.forEach(function (columnName) {\n var _a;\n var payload = (_a = modifiedActions[columnName]) === null || _a === void 0 ? void 0 : _a[\"payload\"];\n if (payload) {\n var path = payload[\"path\"].split(\".\");\n path[path.length - 2] = rowId;\n modifiedActions[columnName][\"payload\"][\"rowId\"] = rowId;\n modifiedActions[columnName][\"payload\"][\"path\"] = path.join(\".\");\n }\n });\n return modifiedActions;\n}\nvar getDefaultValue = function (overrideDefaultValues, component, componentName, tableName) {\n var _a;\n return ((_a = overrideDefaultValues === null || overrideDefaultValues === void 0 ? void 0 : overrideDefaultValues(tableName, componentName)) !== null && _a !== void 0 ? _a : (component.type === \"ComboBox\"\n ? component.defaultValue.value\n : component.defaultValue));\n};\nvar getComboOptions = function (overrideOptions, component, componentName, tableName) {\n var _a;\n var dynamicOptions = overrideOptions === null || overrideOptions === void 0 ? void 0 : overrideOptions(tableName, componentName);\n return dynamicOptions && dynamicOptions.length > 0\n ? dynamicOptions\n : (_a = component === null || component === void 0 ? void 0 : component.defaultValue) === null || _a === void 0 ? void 0 : _a[\"options\"];\n};\nfunction getTableLeftActions() {\n return [\n {\n dataField: \"insert-button\",\n editable: false,\n displayName: \"\",\n columnWidth: \"21px\",\n width: \"21px\",\n tdStyle: { textOverflow: \"unset\" },\n },\n ];\n}\nfunction getTableRightActions() {\n return [\n {\n dataField: \"delete-button\",\n editable: false,\n displayName: \"\",\n columnWidth: \"21px\",\n width: \"21px\",\n tdStyle: { textOverflow: \"unset\" },\n },\n ];\n}\nfunction getTableMoveRowActions() {\n return [\n {\n dataField: \"row-down-button\",\n editable: false,\n displayName: \"\",\n columnWidth: \"21px\",\n width: \"21px\",\n },\n {\n dataField: \"row-up-button\",\n editable: false,\n displayName: \"\",\n columnWidth: \"21px\",\n width: \"21px\",\n },\n ];\n}\nfunction createRowUid(prefix, postfix) {\n return prefix + postfix;\n}\n//# sourceMappingURL=tables.js.map","\"use strict\";\nvar __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.mapOptionLabels = exports.filterOptions = exports.isSingleton = exports.isUnassigned = exports.isAssigned = exports.hasOptions = exports.AlertTypes = void 0;\nvar AlertTypes;\n(function (AlertTypes) {\n AlertTypes[\"Error\"] = \"error\";\n AlertTypes[\"Warning\"] = \"warning\";\n AlertTypes[\"Hint\"] = \"hint\";\n})(AlertTypes = exports.AlertTypes || (exports.AlertTypes = {}));\n/**\n * See User-Defined Type Guards in the Typescript Handbook on Advanced Types\n * @see https://www.typescriptlang.org/docs/handbook/advanced-types.html\n */\nfunction hasOptions(dep) {\n return dep.options !== undefined;\n}\nexports.hasOptions = hasOptions;\n/**\n * See User-Defined Type Guards in the Typescript Handbook on Advanced Types\n * @see https://www.typescriptlang.org/docs/handbook/advanced-types.html\n */\nfunction isAssigned(dep) {\n return typeof dep.handle !== \"undefined\";\n}\nexports.isAssigned = isAssigned;\n/**\n * See User-Defined Type Guards in the Typescript Handbook on Advanced Types\n * @see https://www.typescriptlang.org/docs/handbook/advanced-types.html\n */\nfunction isUnassigned(dep) {\n return typeof dep.handle === \"undefined\";\n}\nexports.isUnassigned = isUnassigned;\n/**\n * Type guard function for SingletonExport\n * See User-Defined Type Guards in the Typescript Handbook on Advanced Types\n * @see https://www.typescriptlang.org/docs/handbook/advanced-types.html\n * @param resource the export to check on being a singleton\n * @deprecated No longer used. Replaced with dynamic singleton identification\n * at runtime.\n */\nfunction isSingleton(resource) {\n return typeof resource.isSingleton !== \"undefined\" && resource.isSingleton;\n}\nexports.isSingleton = isSingleton;\n/**\n * Returns a copy of `populatedImport` with all options removed which\n * cause `optionFilter` to return false.\n */\nfunction filterOptions(populatedImport, optionFilter) {\n if (populatedImport.options) {\n return __assign(__assign({}, populatedImport), { options: populatedImport.options.filter(optionFilter) });\n }\n return populatedImport;\n}\nexports.filterOptions = filterOptions;\n/**\n * Returns a copy of `populatedImport` with the options' handle labels\n * mapped according to `labelFactory`.\n */\nfunction mapOptionLabels(populatedImport, labelFactory) {\n if (populatedImport.options) {\n return __assign(__assign({}, populatedImport), { options: populatedImport.options.map(function (option) {\n return __assign(__assign({}, option), { handle: __assign(__assign({}, option.handle), { label: labelFactory(option) }) });\n }) });\n }\n return populatedImport;\n}\nexports.mapOptionLabels = mapOptionLabels;\n//# sourceMappingURL=Processor.js.map","\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar Setting_1 = require(\"./Setting\");\nvar Register_1 = require(\"./Register\");\nvar Arrays_1 = require(\"./util/Arrays\");\n/** Builder pattern */\nvar CalculateRegisterValue = /** @class */ (function () {\n function CalculateRegisterValue(register) {\n var _this = this;\n this.modifiedSettings = [];\n /** Assign a numerical value to the given `Setting`. */\n this.withNumberValue = function (setting, value) {\n if (setting === undefined) {\n throw new Error(\"Cannot assign number value to setting, setting is undefined.\");\n }\n if (!_this.getSetting(setting)) {\n throw new Error(\"Setting \".concat(setting.alias, \" is not present in Register \").concat(_this.register.name));\n }\n _this.modifiedSettings = __spreadArray(__spreadArray([], _this.modifiedSettings, true), [\n new NumberSettingValue(setting, value),\n ], false);\n return _this;\n };\n /** Assign the given `Option` to the given `Setting`. */\n this.withOption = function (setting, option) {\n if (setting === undefined) {\n throw new Error(\"Cannot assign option to setting, setting is undefined.\");\n }\n if (!_this.getSetting(setting)) {\n throw new Error(\"Setting \".concat(setting.alias, \" is not present in Register \").concat(_this.register.name));\n }\n if (!option || !_this.getOption(setting, option)) {\n throw new Error(\"Option \".concat(option === null || option === void 0 ? void 0 : option.name, \" is not present in Setting \").concat(setting.name));\n }\n _this.modifiedSettings = __spreadArray(__spreadArray([], _this.modifiedSettings, true), [\n new OptionSettingValue(setting, option),\n ], false);\n return _this;\n };\n /** Assign the `Option` matching the given alias to the given `Setting`. */\n this.withOptionAlias = function (setting, optionAlias) {\n if (setting === undefined) {\n throw new Error(\"Cannot assign option alias to setting, setting is undefined.\");\n }\n var option = (0, Setting_1.getOptionByAlias)(optionAlias, setting);\n if (option === undefined) {\n throw new Error(\"Option Alias: \\\"\".concat(optionAlias, \"\\\" not present in Setting: \\\"\").concat(setting.name, \"\\\".\"));\n }\n return _this.withOption(setting, option);\n };\n /** Assign the `Option` matching the given name to the given `Setting`. */\n this.withOptionName = function (setting, optionName) {\n if (setting === undefined) {\n throw new Error(\"Cannot assign option name to setting, setting is undefined.\");\n }\n var option = (0, Setting_1.getOptionByName)(optionName, setting);\n if (option === undefined) {\n throw new Error(\"Option Name: \\\"\".concat(optionName, \"\\\" not present in Setting: \\\"\").concat(setting.name, \"\\\".\"));\n }\n return _this.withOption(setting, option);\n };\n /** Assign the `Option` matching the given description to the given `Setting`. */\n this.withOptionDescription = function (setting, optionDescription) {\n if (setting === undefined) {\n throw new Error(\"Cannot assign option description to setting, setting is undefined.\");\n }\n var option = (0, Setting_1.getOptionByDescription)(optionDescription, setting);\n if (option === undefined) {\n throw new Error(\"Option Description: \\\"\".concat(optionDescription, \"\\\" not present in Setting: \\\"\").concat(setting.name, \"\\\".\"));\n }\n return _this.withOption(setting, option);\n };\n this.getSetting = function (setting) {\n return (0, Register_1.getSettingByAlias)(setting.alias, _this.register);\n };\n this.getOption = function (setting, option) {\n return (option === null || option === void 0 ? void 0 : option.name) ? (0, Setting_1.getOptionByName)(option.name, setting) : undefined;\n };\n this.calculate = function () {\n var registerValue = 0;\n _this.modifiedSettings.forEach(function (modifiedSetting) {\n registerValue = _this.setValue(modifiedSetting, registerValue);\n });\n var unmodifiedSettings = _this.getUnmodifiedSettings();\n unmodifiedSettings.forEach(function (unmodifiedSetting) {\n registerValue = _this.setValue(SettingValue.defaultValue(unmodifiedSetting), registerValue);\n });\n return Number(registerValue);\n };\n this.setValue = function (setting, registerValue) {\n var value = registerValue;\n value &= ~setting.getMask(); // Clear bits\n value |= setting.getShiftedValue(); // Set bits\n return value;\n };\n this.getUnmodifiedSettings = function () {\n var _a, _b;\n var modifiedSettingNames = (0, Arrays_1.map)(_this.modifiedSettings, function (setting) {\n return setting.getName();\n });\n return (0, Arrays_1.filter)((_b = (0, Arrays_1.values)((_a = _this.register.settings) !== null && _a !== void 0 ? _a : {})) !== null && _b !== void 0 ? _b : [], function (setting) { return modifiedSettingNames.indexOf(setting.name) < 0; });\n };\n /** Calculate and print the register's value as a hex string. */\n this.asHexString = function () { return CalculateRegisterValue.toHexString(_this.calculate()); };\n /** Calculate and print the register's value as a binary string. */\n this.asBinaryString = function () {\n return CalculateRegisterValue.toBinaryString(_this.calculate());\n };\n /** Calculate and print the register's value as a decimal string. */\n this.asDecimalString = function () {\n return CalculateRegisterValue.toDecimalString(_this.calculate());\n };\n /** Calculate and return the register's value as a number. */\n this.asNumber = function () { return _this.calculate(); };\n this.register = register;\n }\n /** Creates a register value calculation object for the given register. */\n CalculateRegisterValue.for = function (register) {\n return new CalculateRegisterValue(register);\n };\n /** Format the given number as a hex string value. */\n CalculateRegisterValue.toHexString = function (value) {\n if (value == null) {\n throw new Error(\"CalculateRegisterValue.toHexString() illegal argument exception. Value must not be null.\");\n }\n return \"0x\" + value.toString(16);\n };\n /** Format the given number as a binary string value. */\n CalculateRegisterValue.toBinaryString = function (value) {\n if (value == null) {\n throw new Error(\"CalculateRegisterValue.toBinaryString() illegal argument exception. Value must not be null.\");\n }\n return \"0b\" + value.toString(2);\n };\n /** Format the given number as a decimal string value. */\n CalculateRegisterValue.toDecimalString = function (value) {\n if (value == null) {\n throw new Error(\"CalculateRegisterValue.toDecimalString() illegal argument exception. Value must not be null.\");\n }\n return value.toString();\n };\n return CalculateRegisterValue;\n}());\nexports.default = CalculateRegisterValue;\nvar SettingValue = /** @class */ (function () {\n function SettingValue(setting) {\n var _this = this;\n this.getMask = function () { return Number(_this.setting.mask); };\n this.getShift = function () {\n var mask = _this.getMask();\n var shiftIndex = 0;\n while (!(mask & 0x1)) {\n mask = mask >> 1;\n shiftIndex++;\n }\n return shiftIndex;\n };\n this.getShiftedValue = function () { return _this.getValue() << _this.getShift(); };\n this.getName = function () { return _this.setting.name; };\n this.setting = setting;\n }\n SettingValue.defaultValue = function (setting) {\n var value = Number(setting.porDefault);\n return new NumberSettingValue(setting, value);\n };\n return SettingValue;\n}());\nvar NumberSettingValue = /** @class */ (function (_super) {\n __extends(NumberSettingValue, _super);\n function NumberSettingValue(setting, value) {\n var _this = _super.call(this, setting) || this;\n _this.getValue = function () { return _this.value; };\n _this.value = value;\n return _this;\n }\n return NumberSettingValue;\n}(SettingValue));\nvar OptionSettingValue = /** @class */ (function (_super) {\n __extends(OptionSettingValue, _super);\n function OptionSettingValue(setting, option) {\n var _this = _super.call(this, setting) || this;\n _this.getValue = function () { return Number(_this.option.value); };\n _this.option = option;\n return _this;\n }\n OptionSettingValue.fromDefaultValue = function (setting, value) {\n var foundValueByName = (0, Setting_1.getOptionByName)(value, setting);\n if (foundValueByName)\n return new OptionSettingValue(setting, foundValueByName);\n var foundValueByAlias = (0, Setting_1.getOptionByAlias)(value, setting);\n if (foundValueByAlias)\n return new OptionSettingValue(setting, foundValueByAlias);\n throw new Error(\"Unable to create default value '\".concat(value, \"' for setting '\").concat(setting.name, \"'.\"));\n };\n return OptionSettingValue;\n}(SettingValue));\n//# sourceMappingURL=CalculateRegisterValue.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getSettingByAlias = void 0;\nvar getSettingByAlias = function (alias, register) {\n var _a;\n return (_a = register.settings) === null || _a === void 0 ? void 0 : _a[alias];\n};\nexports.getSettingByAlias = getSettingByAlias;\n//# sourceMappingURL=Register.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getOptionDescriptions = exports.getOptionNames = exports.getOptionByDescription = exports.getOptionByName = exports.getOptionByAlias = exports.getBitRange = exports.getBitLabel = void 0;\nvar Arrays_1 = require(\"./util/Arrays\");\n/**\n * Converts a hexadecimal string to binary.\n * Any leading zeros are removed from the returned string.\n */\nvar hexToBinary = function (hex) {\n return parseInt(hex, 16).toString(2);\n};\n/**\n * Returns a string of the corresponding bit position(s).\n */\nvar getBitLabel = function (setting) {\n if (setting.mask === undefined) {\n return undefined;\n }\n var bitRange = (0, exports.getBitRange)(setting);\n if (!bitRange)\n return undefined;\n if (bitRange.high === bitRange.low) {\n return \"bit \".concat(bitRange.high);\n }\n return \"bit \".concat(bitRange.high, \"-\").concat(bitRange.low);\n};\nexports.getBitLabel = getBitLabel;\n/**\n * Converts the hexadecimal mask provided within the register setting\n * and returns an interface containing the corresponding low and high bit positions.\n */\nvar getBitRange = function (setting) {\n if (!setting.mask)\n return undefined;\n var processedHex = hexToBinary(setting.mask);\n return {\n high: processedHex.length - 1,\n low: getBitRangeLow(processedHex),\n };\n};\nexports.getBitRange = getBitRange;\nvar getOptionByAlias = function (alias, setting) {\n var _a;\n return (0, Arrays_1.find)((_a = setting === null || setting === void 0 ? void 0 : setting.options) !== null && _a !== void 0 ? _a : [], function (option) { return option.alias == alias; });\n};\nexports.getOptionByAlias = getOptionByAlias;\nvar getOptionByName = function (name, setting) {\n var _a;\n return (0, Arrays_1.find)((_a = setting === null || setting === void 0 ? void 0 : setting.options) !== null && _a !== void 0 ? _a : [], function (option) { return option.name == name; });\n};\nexports.getOptionByName = getOptionByName;\nvar getOptionByDescription = function (description, setting) {\n var _a;\n return (0, Arrays_1.find)((_a = setting.options) !== null && _a !== void 0 ? _a : [], function (option) { return option.description == description; });\n};\nexports.getOptionByDescription = getOptionByDescription;\nvar getOptionNames = function (setting) {\n var _a;\n return (0, Arrays_1.map)((_a = setting.options) !== null && _a !== void 0 ? _a : [], function (option) { return option.name; });\n};\nexports.getOptionNames = getOptionNames;\nvar getOptionDescriptions = function (setting) {\n var _a;\n return (0, Arrays_1.map)((_a = setting.options) !== null && _a !== void 0 ? _a : [], function (option) { return option.description; });\n};\nexports.getOptionDescriptions = getOptionDescriptions;\nfunction getBitRangeLow(processedHex) {\n if (processedHex.charAt(1) === \"1\") {\n var index = 1;\n while (processedHex.charAt(index) === \"1\") {\n index++;\n }\n return processedHex.length - index;\n }\n else {\n return processedHex.length - 1;\n }\n}\n//# sourceMappingURL=Setting.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.values = exports.getKeys = exports.find = exports.filter = exports.map = void 0;\nvar map = function (arr, callback) {\n var result = [];\n arr.forEach(function (value, index) {\n result[index] = callback(value);\n });\n return result;\n};\nexports.map = map;\nvar filter = function (arr, callback) {\n var result = [];\n arr.forEach(function (value) {\n if (callback(value)) {\n result.push(value);\n }\n });\n return result;\n};\nexports.filter = filter;\n/**\n * Iterates over elements of the array, returning the first element that the predicate returns truthy for.\n */\nvar find = function (arr, callback) {\n for (var i = 0; i < arr.length; i++) {\n if (callback(arr[i])) {\n return arr[i];\n }\n }\n return undefined;\n};\nexports.find = find;\n/** @returns the non-prototype keys of the given object */\nvar getKeys = function (obj) {\n if (!obj)\n return undefined;\n return Object.getOwnPropertyNames(obj);\n};\nexports.getKeys = getKeys;\nvar values = function (obj) {\n var _a;\n if (!obj)\n return undefined;\n return (_a = (0, exports.getKeys)(obj)) === null || _a === void 0 ? void 0 : _a.map(function (key) { return obj[key]; });\n};\nexports.values = values;\n//# sourceMappingURL=Arrays.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.buildSimpleApi = function (functions) {\n var api = {};\n for (var key in functions) {\n api[key] = buildFunction(functions[key]);\n }\n return api;\n};\nvar buildFunction = function (cFunction) {\n return cFunction.returns + \" \" + cFunction.name + \"(\" + buildArguments(cFunction.arguments) + \")\";\n};\nvar buildArguments = function (args) {\n if (args) {\n return args.map(function (arg) { return arg.type + \" \" + arg.name; }).join(\", \");\n }\n else {\n return \"void\";\n }\n};\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getInterfaceName = function (pkgJson) {\n var strReplace = \"@microchip/\";\n var interfaceName;\n if (pkgJson) {\n interfaceName = pkgJson[\"name\"];\n if (interfaceName) {\n interfaceName = interfaceName.replace(strReplace, \"\");\n }\n }\n if (!interfaceName) {\n throw new Error(\"Invalid Interface Name...!\");\n }\n return interfaceName;\n};\nexports.getInterfaceVersion = function (pkgJson) {\n var versionRegex = new RegExp(\"\\\\d+.\\\\d+.\\\\d+\");\n var version;\n if (pkgJson) {\n version = pkgJson[\"version\"];\n }\n if (!version && !versionRegex.test(version)) {\n throw new Error(\"Invalid Interface Version...!\");\n }\n return version;\n};\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nvar c_function_types_1 = require(\"./c-function-types\");\nexports.buildSimpleApi = c_function_types_1.buildSimpleApi;\nvar helpers_1 = require(\"./helpers\");\nexports.getInterfaceName = helpers_1.getInterfaceName;\nexports.getInterfaceVersion = helpers_1.getInterfaceVersion;\n","export class InterruptComponentNames {\n public static readonly interruptEnables = {\n INTI: \"inteIntcon\",\n INT0I: \"int0iePie0\",\n INT1I: \"int1iePie0\",\n INT2I: \"int2iePie0\",\n INT3I: \"int3iePie0\",\n };\n\n public static readonly interruptEdges = {\n INTI: \"intedgOptionReg\",\n INT0I: \"intedg0Intcon\",\n INT1I: \"intedg1Intcon\",\n INT2I: \"intedg2Intcon\",\n INT3I: \"intedg3Intcon\",\n };\n}\n\nexport class EdgeSettings {\n public static readonly edgeRegisterName = \"OPTION_REG\";\n\n public static readonly edgeSettingAlias = {\n INTI: \"INTEDG\",\n INT0I: \"INTEDG0\",\n INT1I: \"INTEDG1\",\n INT2I: \"INTEDG2\",\n INT3I: \"INTEDG3\",\n };\n}\n\nexport const EXTINT_NAME = \"EXT_INT\";\n\nexport const MACROS_NO_PRIORITY = {\n GIE_status: \"INTERRUPT_GlobalInterruptStatus()\",\n GIE_enable: \"INTERRUPT_GlobalInterruptEnable()\",\n GIE_disable: \"INTERRUPT_GlobalInterruptDisable()\",\n};\n\nexport const MACROS_WITH_PRIORITY = {\n GIE_status: {\n GIEH_status: \"INTERRUPT_GlobalInterruptHighStatus()\",\n GIEL_status: \"INTERRUPT_GlobalInterruptLowStatus()\",\n },\n GIE_enable: {\n GIEH_enable: \"INTERRUPT_GlobalInterruptHighEnable()\",\n GIEL_enable: \"INTERRUPT_GlobalInterruptLowEnable()\",\n },\n GIE_disable: {\n GIEH_disable: \"INTERRUPT_GlobalInterruptHighDisable()\",\n GIEL_disable: \"INTERRUPT_GlobalInterruptLowDisable()\",\n },\n};\n","import { CreatorFunctions } from \"@microchip/melody-automodule-interface\";\nimport { State } from \"@microchip/scf-automodule-impl/lib/creator\";\n\nexport const getCreatorFunctions = (): CreatorFunctions => {\n return {\n shouldImport: shouldImport,\n getCreatorImportArgs: getCreatorImportArgs,\n };\n};\n\nconst shouldImport = (importKey: string, state: State): boolean => {\n return true;\n};\n\nconst getCreatorImportArgs = (importKey: string, state: State): any | undefined => {\n return undefined;\n};\n","import {\n AppModel,\n DerivedData,\n DerivedFunctions,\n} from \"../generated_module/src/types/AutoModuleTypes\";\nimport * as Processor from \"@microchip/scf-common/lib/Processor\";\nimport * as interrupt_standard from \"@microchip/interrupt-standard\";\nimport { getKeys, map, toDictionary, values } from \"../generated_module/src/Utils\";\nimport { getGeneratorModel, getHeaderFiles } from \"./GeneratorModel\";\nimport { EXTINT_NAME } from \"./Constants\";\nimport * as initializer_system from \"@microchip/initializer-system\";\nimport * as initializer_main from \"@microchip/initializer-main\";\nimport * as pin_standard from \"@microchip/pin-standard/lib/pin-standard\";\nimport {\n Interrupt,\n Interrupts,\n MyComponentNames,\n MyExports,\n} from \"../generated_module/src/types\";\nimport { find } from \"@microchip/scf-device/lib/util/Arrays\";\nimport * as Constants from \"./Constants\";\nimport {\n InterruptManagerHelper,\n NoMetaModule,\n} from \"@microchip/interrupt-manager-generic\";\nimport { NO_PRIO_TABLE } from \"./types/TableTypes\";\nimport { InterruptActionsBuilder } from \"@microchip/scf-automodule-impl/lib/interrupts/InterruptActions\";\nimport { getNoPrioDefData } from \"./table_data/NoPrioTable\";\nimport {\n AutoAction,\n RowData,\n TableComponent,\n} from \"@microchip/melody-automodule-interface/lib/src/ModuleConfig\";\nimport { addRowToTable } from \"@microchip/scf-automodule-impl/lib/tables/tables\";\nimport { getPinsLogic } from \"../generated_module/src/pins/PCPHelper\";\n\nexport const getDerivedData = (dataModel: AppModel): DerivedData => {\n if (dataModel) {\n return new MyDerivedData(dataModel);\n }\n return new EmptyDerivedData();\n};\n\nclass EmptyDerivedData implements DerivedData {\n getMyFunctions = (): DerivedFunctions => {\n return {};\n };\n getModel = (): AppModel | undefined => {\n return undefined;\n };\n}\n\nclass MyDerivedData implements DerivedData {\n private dataModel: AppModel;\n private templateData: any;\n private hasPriority = false;\n private interruptStoreState: RowData[] = [];\n private noPrioInterruptHelper: InterruptManagerHelper<NO_PRIO_TABLE> | undefined;\n\n constructor(dataModel: AppModel) {\n this.dataModel = dataModel;\n this.interruptStoreState = (this.getModel().getState()?.main?.interruptTable?.[\n \"interruptStore\"\n ] ?? []) as RowData[];\n }\n\n getMyFunctions = (): DerivedFunctions => {\n return {\n templateData: this.getMyTemplateData,\n moduleName: this.getModuleName,\n alerts: this.getMyAlerts,\n isVisible: this.isVisible,\n \"interrupt-standard_payload\": this.getGeneralPayload,\n \"interrupt-standard_payloads\": this.interrupt_standard_payloads,\n initializer_system_results: this.initializer_system_results,\n initializer_main_results: this.initializer_main_results,\n pin_standard_args: this.pin_standard_args,\n isInterruptListNotEmpty: (): boolean => true,\n isPriorityEnabled: (): boolean =>\n this.getModel().isComponentValue(\"ipenIntcon\"),\n isPriorityDisabled: (): boolean =>\n !this.getModel().isComponentValue(\"ipenIntcon\"),\n\n intePie0: (): string | undefined =>\n this.getBooleanValue(this.getModel().isComponentValue(\"inti\")),\n int0iePie0: (): string | undefined =>\n this.getBooleanValue(this.getModel().isComponentValue(\"int0i\")),\n int1iePie0: (): string | undefined =>\n this.getBooleanValue(this.getModel().isComponentValue(\"int1i\")),\n int2iePie0: (): string | undefined =>\n this.getBooleanValue(this.getModel().isComponentValue(\"int2i\")),\n int3iePie0: (): string | undefined =>\n this.getBooleanValue(this.getModel().isComponentValue(\"int3i\")),\n\n noPriorityTable: this.getNoPriorityTable,\n interruptStore: this.getInterruptStore,\n\n noPrioTableVisible: this.isNoPrioTableVisible,\n prioNonVectTableVisible: this.isPrioNonVectTableVisible,\n isHidden: (): boolean => false,\n getPinsLogic: getPinsLogic,\n importName: this.friendlyImportName,\n };\n };\n\n private friendlyImportName = (importKey: string): string => {\n if (importKey === \"scf_pic8_interrupt_v3\") return \"INTERRUPT Hardware\";\n if (importKey === \"initializer_system\") return \"system.c Initialize()\";\n if (importKey === \"initializer_main\") return \"main.c Initialize()\";\n if (importKey === \"pin_standard\") return \"Pins\";\n return importKey;\n };\n\n public getModel = (): AppModel => {\n return this.dataModel;\n };\n\n private getNoPrioInterruptHelper = ():\n | InterruptManagerHelper<NO_PRIO_TABLE>\n | undefined => {\n if (this.noPrioInterruptHelper == undefined && this.isNoPrioTableVisible()) {\n this.noPrioInterruptHelper = new InterruptManagerHelper(\n getNoPrioDefData(this.getModel()),\n this.getModel().getState(),\n );\n\n this.mapNoPrioInterruptData(this.noPrioInterruptHelper);\n\n this.setNonVectorTableOrder(this.noPrioInterruptHelper, \"noPriorityTable\");\n }\n\n return this.noPrioInterruptHelper;\n };\n\n private mapNoPrioInterruptData = (\n interruptHelper: InterruptManagerHelper<NO_PRIO_TABLE>,\n ): void => {\n const interrupts = this.getModel().getInterrupts() ?? ({} as Interrupts);\n\n map(this.getInterruptResults(), (key, value) => {\n if (value) {\n interruptHelper.dataMap(\n key,\n value.interruptList ?? [],\n (hookData) =>\n `${find(\n getKeys(interrupts),\n (key) =>\n interrupts[key]?.name === hookData.name &&\n interrupts[key]?.module === hookData.module,\n )}-${key}`,\n (hookData, rowId) => {\n return {\n interruptName: {\n value: hookData.name,\n },\n module: {\n value: value.moduleName ?? hookData.module,\n },\n enable: {\n value: hookData.isEnabled,\n actions: value.interruptActions?.[\n hookData.name\n ]?.isEnabled\n ?.filter(\n (action) =>\n action.validFor !== hookData.isEnabled,\n )\n .map((action) => {\n return {\n for: action.validFor,\n action: action.action,\n };\n }),\n },\n };\n },\n (\n hookData,\n rowId,\n ): interrupt_standard.InterruptParameters | Interrupt => {\n return {\n ...hookData,\n ...(interrupts[rowId?.split(\"-\")?.[0] ?? \"\"] ?? {}),\n };\n },\n );\n }\n });\n };\n\n private setNonVectorTableOrder = (\n interruptHelper: InterruptManagerHelper,\n tableComponentName: string,\n ): void => {\n const tableState: RowData[] =\n this.getModel().getState()?.main?.interruptTable?.[tableComponentName] ?? [];\n\n interruptHelper.setOrder((rowIds) => {\n const uids = rowIds.map((rowUid, i) => {\n return {\n rowUid: rowUid,\n index: find(tableState, (row) => row.uid === rowUid)?.rowId ?? i,\n };\n });\n\n return uids\n .sort((row1, row2) => row1.index - row2.index)\n .map((row) => row.rowUid);\n });\n };\n\n private getInterruptResults = (): Processor.Dictionary<\n interrupt_standard.Results | undefined\n > => {\n let results =\n this.dataModel\n ?.getExportInterfaces()\n ?.getInterface(\"interrupt\", interrupt_standard.Interface.getInterfaceId())\n ?.results ?? {};\n\n results = {\n ...this.getExtInterruptResults(),\n ...this.getSystemInterruptsResults(),\n ...results,\n };\n\n return results;\n };\n\n private getSystemInterruptsResults = (): Processor.Dictionary<\n interrupt_standard.Results\n > => {\n const externalInterrupts = this.getExtInterruptResults()[NoMetaModule];\n const iocInterrupts = this.getIOCResults()[NoMetaModule];\n return {\n [NoMetaModule]: {\n interruptList: [\n ...(externalInterrupts.interruptList ?? []),\n ...(iocInterrupts.interruptList ?? []),\n ],\n interruptActions: {\n ...(externalInterrupts.interruptActions ?? {}),\n ...(iocInterrupts.interruptActions ?? {}),\n },\n },\n };\n };\n\n private getIOCResults = (): Processor.Dictionary<interrupt_standard.Results> => {\n const interrupts: interrupt_standard.InterruptParameters[] = [];\n let actions: interrupt_standard.Results[\"interruptActions\"] = {};\n\n map(this.getModel()?.getInterrupts() ?? {}, (id, interrupt) => {\n if (interrupt == undefined) return;\n if (interrupt.module !== \"PIN_MANAGER\") return;\n const isEnabled = this.getModel().isComponentValue(\"ioci\");\n\n interrupts.push({\n name: interrupt.name,\n module: \"PIN_MANAGER\",\n isEnabled: isEnabled,\n generateISR: isEnabled,\n isrCallback: {\n name: \"PIN_MANAGER_IOC\",\n header: {\n name: \"pins.h\",\n path: \"system/\",\n },\n },\n isHighPriority:\n (find(\n this.interruptStoreState,\n (int) => int.uid === `${id}-${NoMetaModule}`,\n )?.isHighPriority as boolean | undefined) ?? true,\n });\n\n const isEnabledActions = InterruptActionsBuilder.createActionBuilder(\n this.getModel(),\n )\n .createActionFor(\"ioci\")\n .addActionIfEnabled(true)\n .addActionIfDisabled(false)\n .buildActions();\n\n actions = {\n ...actions,\n [interrupt.name]: {\n isEnabled: isEnabledActions,\n },\n };\n });\n\n return {\n [NoMetaModule]: {\n interruptList: interrupts,\n interruptActions: actions,\n },\n };\n };\n\n private getExtInterruptResults = (): Processor.Dictionary<\n interrupt_standard.Results\n > => {\n const interrupts: interrupt_standard.InterruptParameters[] = [];\n let actions: interrupt_standard.Results[\"interruptActions\"] = {};\n\n map(this.getModel()?.getInterrupts() ?? {}, (id, interrupt) => {\n if (interrupt == undefined) return;\n if (interrupt.module !== \"EXT_INT\") return;\n const componentName = interrupt.name.toLowerCase() ?? \"\";\n const isEnabled = this.getModel()?.getComponentValue?.(componentName);\n\n interrupts.push({\n name: interrupt.name,\n module: EXTINT_NAME,\n isEnabled: isEnabled,\n isrCallback: {\n name: `${interrupt.name.replace(/I$/, \"\")}_ISR`,\n header: getHeaderFiles()[0],\n },\n generateISR: isEnabled,\n isHighPriority:\n (find(\n this.interruptStoreState,\n (int) => int.uid === `${id}-${NoMetaModule}`,\n )?.isHighPriority as boolean | undefined) ?? true,\n });\n\n const isEnabledActions = InterruptActionsBuilder.createActionBuilder(\n this.getModel(),\n )\n .createActionFor(componentName as MyComponentNames)\n .addActionIfEnabled(true)\n .addActionIfDisabled(false)\n .buildActions();\n\n actions = {\n ...actions,\n [interrupt.name]: {\n isEnabled: isEnabledActions,\n },\n };\n });\n\n return {\n [NoMetaModule]: {\n interruptList: interrupts,\n interruptActions: actions,\n },\n };\n };\n\n private getInterruptStandardRequests = (): MyExports[\"interrupt\"][\"interfaces\"][0][\"args\"] => {\n return (\n this.dataModel\n ?.getExportInterfaces()\n ?.getInterface(\"interrupt\", interrupt_standard.Interface.getInterfaceId())\n ?.args ?? {}\n );\n };\n\n private interrupt_standard_payloads = (): Processor.Dictionary<\n interrupt_standard.ProcessedPayload\n > => {\n const addressedPayload: Processor.Dictionary<interrupt_standard.ProcessedPayload> = {};\n let processedState: Processor.Dictionary<any> = {};\n\n this.interruptStoreState.forEach((rowData) => {\n const uid = rowData?.[\"uid\"] ?? \"\";\n const [, moduleId] = uid.split(\"-\");\n processedState = {\n ...processedState,\n [moduleId]: {\n ...(processedState[moduleId] ?? {}),\n [uid]: find(this.interruptStoreState, (int) => int.uid === uid),\n },\n };\n });\n\n map(processedState ?? {}, (scriptId, value) => {\n if (addressedPayload[scriptId]) {\n addressedPayload[scriptId] = {\n ...addressedPayload[scriptId],\n };\n } else {\n addressedPayload[scriptId] = {\n ...this.getGeneralPayload(),\n };\n }\n });\n\n map(this.getInterruptStandardRequests() ?? {}, (scriptId, value) => {\n if (addressedPayload[scriptId]) {\n addressedPayload[scriptId] = {\n ...addressedPayload[scriptId],\n ...this.getRequestsPayloadFor(value),\n };\n } else {\n addressedPayload[scriptId] = {\n ...this.getGeneralPayload(),\n ...this.getRequestsPayloadFor(value),\n };\n }\n });\n\n return addressedPayload;\n };\n\n private getGeneralPayload = (): interrupt_standard.ProcessedPayload => {\n return {\n isVectoredInterrupt: false,\n hasPriority: false,\n };\n };\n\n private getRequestsPayloadFor = (\n requests: interrupt_standard.Arguments | undefined,\n ): interrupt_standard.ProcessedPayload => {\n let requestsPayload: interrupt_standard.ProcessedPayload = {};\n\n if (!requests) return {};\n\n requests.forEach((request) => {\n switch (request.requestFor) {\n case \"interruptDataList\": {\n let interrupts = values(this.getModel().getInterrupts() ?? {});\n\n if (request.data.mode === \"both\") {\n null;\n } else if (request.data.mode === \"active\") {\n interrupts = [];\n } else if (request.data.mode === \"inactive\") {\n interrupts = [];\n } else {\n break;\n }\n\n if (request.data.moduleName === \"all\") {\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: (\n requestsPayload[request.requestFor] ?? []\n ).concat(interrupts),\n };\n } else if (Array.isArray(request.data.moduleName)) {\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: (\n requestsPayload[request.requestFor] ?? []\n ).concat(\n interrupts.filter(\n (interrupt) =>\n request.data.moduleName.indexOf(\n interrupt?.module,\n ) >= 0,\n ),\n ),\n };\n } else {\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: (\n requestsPayload[request.requestFor] ?? []\n ).concat(\n interrupts.filter(\n (interrupt) =>\n request.data.moduleName === interrupt?.module,\n ),\n ),\n };\n }\n\n break;\n }\n case \"interruptIdList\": {\n const interrupts = this.getModel().getInterrupts();\n let interruptIds = getKeys(interrupts ?? {});\n\n if (request.data.mode === \"both\") {\n null;\n } else if (request.data.mode === \"active\") {\n interruptIds = [];\n } else if (request.data.mode === \"inactive\") {\n interruptIds = [];\n } else {\n break;\n }\n\n if (request.data.moduleName === \"all\") {\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: (\n requestsPayload[request.requestFor] ?? []\n ).concat(interruptIds),\n };\n } else if (Array.isArray(request.data.moduleName)) {\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: (\n requestsPayload[request.requestFor] ?? []\n ).concat(\n interruptIds.filter(\n (interruptId) =>\n request.data.moduleName.indexOf(\n interrupts?.[interruptId]?.module ?? \"\",\n ) >= 0,\n ),\n ),\n };\n } else {\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: (\n requestsPayload[request.requestFor] ?? []\n ).concat(\n interruptIds.filter(\n (interruptId) =>\n request.data.moduleName ===\n interrupts?.[interruptId]?.module,\n ),\n ),\n };\n }\n\n break;\n }\n case \"componentValues\": {\n requestsPayload = {\n ...requestsPayload,\n };\n\n break;\n }\n case \"macros\": {\n let macros: interrupt_standard.ProcessedPayload[\"macros\"] = {};\n\n request.data.macroFilter?.forEach((macro) => {\n macros = {\n ...macros,\n [macro]: Constants.MACROS_NO_PRIORITY[macro ?? \"\"],\n };\n });\n\n requestsPayload = {\n ...requestsPayload,\n [request.requestFor]: {\n ...(requestsPayload[request.requestFor] ?? {}),\n ...macros,\n },\n };\n\n break;\n }\n default:\n null;\n }\n });\n\n return requestsPayload;\n };\n\n private getMyTemplateData = (): any => {\n if (this.templateData == undefined) {\n this.templateData = getGeneratorModel(\n this.getModel(),\n this.getNoPrioInterruptHelper()?.getProcessedInterruptData(\n \"name\",\n \"enable\",\n \"flag\",\n \"module\",\n \"handlerName\",\n \"isEnabled\",\n \"isHighPriority\",\n \"isrCallback\",\n \"generateISR\",\n \"priority\",\n ) ?? [],\n );\n }\n\n return this.templateData;\n };\n\n public getModuleName = (): string => {\n return \"Interrupt Manager\";\n };\n\n private getMyAlerts = (): Processor.Alert[] => {\n const alerts: Processor.Alert[] = [];\n const ppsData =\n this.getModel().getImportValue(\"pin_standard\")?.[\"pps\"]?.[\"data\"]?.[\n this.getModel()?.getPeripheralDescription()?.name ?? \"\"\n ] ?? {};\n\n if (this.getModel().isComponentValue(\"inti\") && ppsData[\"INT\"] === \"\") {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text: \"Configure a pin for EXT_INT INT\",\n });\n }\n if (this.getModel().isComponentValue(\"int0i\") && ppsData[\"INT0\"] === \"\") {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text: \"Configure a pin for EXT_INT INT0\",\n });\n }\n if (this.getModel().isComponentValue(\"int1i\") && ppsData[\"INT1\"] === \"\") {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text: \"Configure a pin for EXT_INT INT1\",\n });\n }\n if (this.getModel().isComponentValue(\"int2i\") && ppsData[\"INT2\"] === \"\") {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text: \"Configure a pin for EXT_INT INT2\",\n });\n }\n if (this.getModel().isComponentValue(\"int3i\") && ppsData[\"INT3\"] === \"\") {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text: \"Configure a pin for EXT_INT INT3\",\n });\n }\n\n const noPrioData =\n this.getNoPrioInterruptHelper()\n ?.getProcessedInterruptData(\"isEnabled\", \"module\")\n ?.filter((data) => data.isEnabled) ?? [];\n\n if (noPrioData.length > 0) {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text:\n \"Interrupts are enabled, enable Global Interrupt in your embedded application to make interrupts work.\",\n });\n\n if (\n noPrioData.filter(\n (data) =>\n data.module !== EXTINT_NAME && data.module !== \"PIN_MANAGER\",\n ).length > 0 &&\n this.getModel().getRegisterValues()?.[\"INTCON\"]?.settings?.PEIE !=\n undefined\n ) {\n alerts.push({\n type: Processor.AlertTypes.Hint,\n text:\n \"Peripheral Interrupts are enabled, enable Peripheral Interrupt in your embedded application to make peripheral interrupts work.\",\n });\n }\n }\n\n return alerts;\n };\n\n private isVisible = (componentName: MyComponentNames): boolean | undefined => {\n switch (componentName) {\n case \"inti\":\n return this.getModel().getInterrupts()?.EXT_INT_INTI != undefined;\n default:\n return undefined;\n }\n };\n\n private initializer_system_results = (): initializer_system.Results => {\n return {\n initializer: {\n name: \"INTERRUPT\" + \"_Initialize\",\n header: getHeaderFiles()[0],\n priority: initializer_system.INIT_PRIORITY.END,\n },\n };\n };\n\n private initializer_main_results = (): initializer_main.Results => {\n let initSectionMessage =\n \"// If using interrupts in PIC18 High/Low Priority Mode you need to enable the Global High and Low Interrupts \\n\" +\n \" // If using interrupts in PIC Mid-Range Compatibility Mode you need to enable the Global and Peripheral Interrupts \\n\" +\n \" // Use the following macros to: \\n\\n\";\n\n if (!this.getModel().isComponentValue(\"ipenIntcon\")) {\n initSectionMessage +=\n \" // Enable the Global Interrupts \\n\" +\n \" //INTERRUPT_GlobalInterruptEnable(); \\n\\n\" +\n \" // Disable the Global Interrupts \\n\" +\n \" //INTERRUPT_GlobalInterruptDisable(); \\n\\n\" +\n \" // Enable the Peripheral Interrupts \\n\" +\n \" //INTERRUPT_PeripheralInterruptEnable(); \\n\\n\" +\n \" // Disable the Peripheral Interrupts \\n\" +\n \" //INTERRUPT_PeripheralInterruptDisable(); \\n\";\n } else {\n initSectionMessage +=\n \" // Enable the Global High Interrupts \\n\" +\n \" //INTERRUPT_GlobalInterruptHighEnable(); \\n\\n\" +\n \" // Disable the Global High Interrupts \\n\" +\n \" //INTERRUPT_GlobalInterruptHighDisable(); \\n\\n\" +\n \" // Enable the Global Low Interrupts \\n\" +\n \" //INTERRUPT_GlobalInterruptLowEnable(); \\n\\n\" +\n \" // Disable the Global Low Interrupts \\n\" +\n \" //INTERRUPT_GlobalInterruptLowDisable(); \\n\\n\" +\n \" // Enable the Peripheral Interrupts \\n\" +\n \" //INTERRUPT_PeripheralInterruptEnable(); \\n\\n\" +\n \" // Disable the Peripheral Interrupts \\n\" +\n \" //INTERRUPT_PeripheralInterruptDisable(); \\n\";\n }\n\n return {\n initializer: {\n name: \"\",\n header: {\n name: \"interrupt.h\",\n path: \"system/\",\n },\n },\n initSection: {\n message: initSectionMessage,\n },\n };\n };\n\n private pin_standard_args = (): pin_standard.intf_args => {\n return {\n queryAdapters: [\"ioc\", \"pps\", \"analog\"],\n };\n };\n\n private getBooleanValue = (\n value: boolean | undefined,\n ): \"enabled\" | \"disabled\" | undefined => {\n if (value === true) return \"enabled\";\n else if (value === false) return \"disabled\";\n else return undefined;\n };\n\n private getNoPriorityTable = (\n table: TableComponent,\n model: AppModel,\n tab: string,\n ): RowData[] | undefined => {\n let currentTable = table.rowData ?? [];\n let i = 0;\n const initIndex = currentTable.length;\n\n map(\n this.getNoPrioInterruptHelper()?.getProcessedTableData()?.rowData ?? {},\n (uid, data) => {\n const rowData: RowData = {\n ...toDictionary(\n getKeys(data),\n (key) => key,\n (key) => data[key]?.value,\n ),\n actions: toDictionary(\n getKeys(data),\n (key) => key,\n (key) => data?.[key]?.actions?.[0]?.action as AutoAction,\n ),\n order: initIndex + i + 1,\n rowId: initIndex + i++,\n uid: uid,\n };\n\n currentTable = addRowToTable(currentTable, table.columns, rowData);\n },\n );\n\n return currentTable;\n };\n\n private getInterruptStore = (\n table: TableComponent,\n model: AppModel,\n tab: string,\n ): RowData[] | undefined => {\n const initRowData = table.rowData ?? [];\n\n return initRowData;\n };\n\n private isNoPrioTableVisible = (): boolean =>\n !this.getModel().isComponentValue(\"ipenIntcon\");\n\n private isPrioNonVectTableVisible = (): boolean =>\n this.getModel().isComponentValue(\"ipenIntcon\");\n}\n","import {\n AppModel,\n MyRegisterValues,\n} from \"../generated_module/src/types/AutoModuleTypes\";\nimport * as interrupt_standard from \"@microchip/interrupt-standard\";\nimport { HeaderFile } from \"@microchip/scf-interface\";\nimport { InterruptComponentNames, EdgeSettings, EXTINT_NAME } from \"./Constants\";\nimport { Interrupt } from \"../generated_module/src/types\";\n\nexport const getGeneratorModel = (\n model: AppModel,\n noPrioIntList: (interrupt_standard.InterruptParameters & Interrupt)[],\n): any => {\n let highInterrupts: interrupt_standard.InterruptParameters[] &\n { isPeripheralInterrupt?: boolean }[] = [];\n const lowInterrupts: interrupt_standard.InterruptParameters[] = [];\n let extIntList: (interrupt_standard.InterruptParameters & Interrupt)[] = [];\n\n const registerValues = model.getRegisterValues();\n if (!registerValues) return {};\n\n const pieAvailable = registerValues?.[\"INTCON\"]?.settings?.PEIE != undefined;\n\n highInterrupts = noPrioIntList\n .filter((interrupt) => interrupt.isEnabled)\n .map((data) => {\n return {\n ...data,\n isPeripheralInterrupt:\n data.module !== EXTINT_NAME && data.module !== \"PIN_MANAGER\",\n };\n });\n\n extIntList = extIntList.concat(\n ...noPrioIntList.filter((data) => data.module === EXTINT_NAME),\n );\n\n return {\n moduleNameLowerCase: model.getName()?.toLowerCase(),\n moduleNameUpperCase: model.getName()?.toUpperCase(),\n header: getHeaderFiles(),\n hasHighInterrupts: highInterrupts.length > 0,\n hasLowInterrupts: lowInterrupts.length > 0,\n\n highInterrupts: highInterrupts,\n lowInterrupts: lowInterrupts,\n preemptiveHigh: model.isComponentValue(\"serviceSingleIsrPerInterrupt\"),\n pieAvailable: pieAvailable,\n\n serviceSingleIsrPerInterrupt: model.isComponentValue(\n \"serviceSingleIsrPerInterrupt\",\n ),\n\n //Registers and Settings\n initRegisters: registerValues,\n ...registerValues,\n GIE: `${registerValues?.[\"INTCON\"]?.name}bits.GIE`,\n // External Interrupt\n allocatedPins: getAllocatedPins(model, extIntList, registerValues),\n vectoredInterruptEnabled: false,\n };\n};\n\nexport const getHeaderFiles = (): HeaderFile[] => {\n return [{ name: \"interrupt.h\", path: \"system/\" }];\n};\n\nexport interface AllocatedPins {\n isHighPriority: boolean | undefined;\n getIRQname: string;\n functionName?: string;\n customName: string;\n edge: string;\n SFREdgeDetectFromPin: string | undefined;\n flagName?: string;\n enableBitName?: string;\n interruptEnabled: boolean;\n}\n\nexport const getAllocatedPins = (\n model: AppModel,\n extIntList: (interrupt_standard.InterruptParameters & Interrupt)[],\n registerSettings: MyRegisterValues | undefined,\n): AllocatedPins[] => {\n const allocatedPins: AllocatedPins[] = [];\n\n extIntList.forEach((interrupt) => {\n if (interrupt && interrupt.name) {\n const interruptName = interrupt.name;\n const edge = model.getComponentValue?.(\n InterruptComponentNames.interruptEdges[interruptName],\n );\n const interruptHandlerName = interruptName.slice(0, interruptName.length - 1);\n\n allocatedPins.push({\n isHighPriority: interrupt.isHighPriority,\n getIRQname: interruptHandlerName,\n customName: `EXT_${interruptHandlerName}`,\n functionName: interruptHandlerName,\n edge: edge?.replace(/_edge$/, \"\"),\n SFREdgeDetectFromPin:\n registerSettings?.[\"OPTION_REG\"]?.settings?.[\n EdgeSettings.edgeSettingAlias[interruptName]\n ]?.bitName,\n flagName: interrupt.flag,\n enableBitName: interrupt.enable,\n interruptEnabled: interrupt.isEnabled,\n });\n }\n });\n\n return allocatedPins;\n};\n","import { AppModel } from \"../generated_module/src/types/AutoModuleTypes\";\nimport { pin_row } from \"@microchip/pin-standard\";\n\n// provide complete dynamic data for all pin rows. It overrides static pindata.json\nexport const getCompletePinData = (appModel: AppModel): any => {\n // way to programatically override the json data\n return {};\n};\n\n// overrides pin data for a particular row based on model.\nexport function getRowData(appModel: AppModel, rowData: pin_row): pin_row | undefined {\n let retRowJSONdata: pin_row | undefined;\n\n if (rowData.name === \"int\") {\n retRowJSONdata = appModel.isComponentValue(\"inti\") ? rowData : undefined;\n } else if (rowData.name === \"int0\") {\n retRowJSONdata = appModel.isComponentValue(\"int0i\") ? rowData : undefined;\n } else if (rowData.name === \"int1\") {\n retRowJSONdata = appModel.isComponentValue(\"int1i\") ? rowData : undefined;\n } else if (rowData.name === \"int2\") {\n retRowJSONdata = appModel.isComponentValue(\"int2i\") ? rowData : undefined;\n } else if (rowData.name === \"int3\") {\n retRowJSONdata = appModel.isComponentValue(\"int3i\") ? rowData : undefined;\n } else retRowJSONdata = undefined;\n\n return retRowJSONdata;\n}\n","import { AppModel } from \"../../generated_module/src/types/AutoModuleTypes\";\nimport { NO_PRIO_TABLE, NO_PRIO_TABLE_ID } from \"../types/TableTypes\";\n\nexport const getNoPrioDefData = (model: AppModel): NO_PRIO_TABLE => {\n return {\n tableId: NO_PRIO_TABLE_ID,\n tableDescription: \"Interrupt Table\",\n hasReorder: false,\n showOrderColumn: true,\n headers: {\n module: {\n description: \"Module\",\n type: \"string\",\n show: true,\n readonly: true,\n },\n interruptName: {\n description: \"Interrupt Name\",\n type: \"string\",\n show: true,\n readonly: true,\n },\n enable: {\n description: \"Enable\",\n type: \"boolean\",\n show: true,\n readonly: false,\n },\n },\n rowData: {},\n };\n};\n","import {\n ColumnTypeList,\n InterruptTableData,\n InterruptTableHelper,\n InterruptTableState,\n} from \"@microchip/interrupt-manager-generic\";\n\nexport const NO_PRIO_TABLE_ID = \"no_priority_interrupt_table\";\n\nexport interface NO_PRIO_COLTYPELIST extends ColumnTypeList {\n module: \"string\";\n interruptName: \"string\";\n enable: \"boolean\";\n}\n\nexport interface HAS_PRIO_COLTYPELIST extends NO_PRIO_COLTYPELIST {\n isHighPriority: \"boolean\";\n}\n\nexport type NO_PRIO_TABLE = InterruptTableHelper<NO_PRIO_COLTYPELIST>;\n\nexport type MyInterruptTableState = InterruptTableState<\n InterruptTableData<NO_PRIO_COLTYPELIST & HAS_PRIO_COLTYPELIST>[\"rowData\"][string]\n>;\n"],"sourceRoot":""}
|