@mchp-mcc/scf-pic8-pwm-v2 4.2.12 → 4.2.13
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 +3 -15
- package/Readme.md +3 -15
- package/output/autoCreator.js +59 -4
- package/output/autoCreator.js.map +1 -1
- package/output/autoProcessor.js +59 -4
- package/output/autoProcessor.js.map +1 -1
- package/output/creator.js +59 -4
- package/output/creator.js.map +1 -1
- package/output/processor.js +59 -4
- package/output/processor.js.map +1 -1
- package/output/pwm-v2.c.ftl +7 -7
- package/output/pwm-v2.h.ftl +1 -1
- package/package.json +5 -5
package/output/autoProcessor.js
CHANGED
|
@@ -3015,6 +3015,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
3015
3015
|
/* harmony import */ var _microchip_scf_validators_lib__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_microchip_scf_validators_lib__WEBPACK_IMPORTED_MODULE_6__);
|
|
3016
3016
|
/* harmony import */ var _microchip_pins_interface_lib_types__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @microchip/pins-interface/lib/types */ "./node_modules/@microchip/pins-interface/lib/types.js");
|
|
3017
3017
|
/* harmony import */ var _microchip_pins_interface_lib_types__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_microchip_pins_interface_lib_types__WEBPACK_IMPORTED_MODULE_7__);
|
|
3018
|
+
/* harmony import */ var _generated_module_src_Utils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../generated_module/src/Utils */ "./generated_module/src/Utils.ts");
|
|
3018
3019
|
function _createForOfIteratorHelper(o) { if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
3019
3020
|
|
|
3020
3021
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
@@ -3033,6 +3034,10 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
3033
3034
|
|
|
3034
3035
|
|
|
3035
3036
|
|
|
3037
|
+
|
|
3038
|
+
var INTERFACE_ID = _interfaces_pwm_general_parameters__WEBPACK_IMPORTED_MODULE_2__["Interface"].getInterfaceId();
|
|
3039
|
+
var INTERFACE_KEY = "pwm_general"; // Defined in moduleConfig.json file
|
|
3040
|
+
|
|
3036
3041
|
var getDerivedData = function getDerivedData(dataModel) {
|
|
3037
3042
|
if (dataModel) {
|
|
3038
3043
|
return new MyDerivedData(dataModel);
|
|
@@ -3090,6 +3095,8 @@ var MyDerivedData = function MyDerivedData(dataModel) {
|
|
|
3090
3095
|
initializer_system_results: _this.initializer_system_results,
|
|
3091
3096
|
dutyCycleValidator: _this.dutyCycleValidator,
|
|
3092
3097
|
componentName: _this.componentName,
|
|
3098
|
+
pwmenPwmcon: _this.getPWMEnable,
|
|
3099
|
+
getMyProcessedArgValue: _this.getMyProcessedArgValue,
|
|
3093
3100
|
pwmdcValue: function pwmdcValue() {
|
|
3094
3101
|
return _this.getPwmCalculator().getCCPRValue();
|
|
3095
3102
|
},
|
|
@@ -3120,10 +3127,55 @@ var MyDerivedData = function MyDerivedData(dataModel) {
|
|
|
3120
3127
|
importName: _this.friendlyImportName,
|
|
3121
3128
|
componentNameValidator: _this.componentNameValidator,
|
|
3122
3129
|
getCustomUiErrors: _this.getCustomUiErrors,
|
|
3123
|
-
pins_interface_args: _this.getPinsinterfaceArgs
|
|
3130
|
+
pins_interface_args: _this.getPinsinterfaceArgs,
|
|
3131
|
+
getmodifiedRegisterValues: _this.getmodifiedRegisterValues
|
|
3124
3132
|
};
|
|
3125
3133
|
});
|
|
3126
3134
|
|
|
3135
|
+
_defineProperty(this, "getmodifiedRegisterValues", function () {
|
|
3136
|
+
var _this$getModel;
|
|
3137
|
+
|
|
3138
|
+
var registerValues = (_this$getModel = _this.getModel()) === null || _this$getModel === void 0 ? void 0 : _this$getModel.getRegisterValues();
|
|
3139
|
+
var modifiedValues = {};
|
|
3140
|
+
|
|
3141
|
+
if (registerValues) {
|
|
3142
|
+
Object(_generated_module_src_Utils__WEBPACK_IMPORTED_MODULE_8__["values"])(registerValues).forEach(function (register) {
|
|
3143
|
+
if (register.por !== register.valueAsHex) {
|
|
3144
|
+
modifiedValues[register.name] = register.valueAsHex;
|
|
3145
|
+
}
|
|
3146
|
+
});
|
|
3147
|
+
return modifiedValues;
|
|
3148
|
+
}
|
|
3149
|
+
|
|
3150
|
+
return undefined;
|
|
3151
|
+
});
|
|
3152
|
+
|
|
3153
|
+
_defineProperty(this, "getMyProcessedArgValue", function () {
|
|
3154
|
+
var _this$dataModel, _this$dataModel$getEx;
|
|
3155
|
+
|
|
3156
|
+
var args;
|
|
3157
|
+
var exportData = (_this$dataModel = _this.dataModel) === null || _this$dataModel === void 0 ? void 0 : (_this$dataModel$getEx = _this$dataModel.getExportInterfaces()) === null || _this$dataModel$getEx === void 0 ? void 0 : _this$dataModel$getEx.getInterface(INTERFACE_KEY, INTERFACE_ID);
|
|
3158
|
+
|
|
3159
|
+
if (exportData && exportData.args) {
|
|
3160
|
+
var moduleId = Object.keys(exportData.args)[0];
|
|
3161
|
+
args = exportData.args[moduleId];
|
|
3162
|
+
}
|
|
3163
|
+
|
|
3164
|
+
return args;
|
|
3165
|
+
});
|
|
3166
|
+
|
|
3167
|
+
_defineProperty(this, "getPWMEnable", function () {
|
|
3168
|
+
var _this$getMyProcessedA;
|
|
3169
|
+
|
|
3170
|
+
var status = (_this$getMyProcessedA = _this.getMyProcessedArgValue()) === null || _this$getMyProcessedA === void 0 ? void 0 : _this$getMyProcessedA.moduleEnable;
|
|
3171
|
+
|
|
3172
|
+
if (status !== undefined) {
|
|
3173
|
+
return status ? "enabled" : "disabled";
|
|
3174
|
+
}
|
|
3175
|
+
|
|
3176
|
+
return status;
|
|
3177
|
+
});
|
|
3178
|
+
|
|
3127
3179
|
_defineProperty(this, "friendlyImportName", function (importKey) {
|
|
3128
3180
|
if (importKey === "scf_pic8_pwm_v2") return "PWM Hardware";
|
|
3129
3181
|
if (importKey === "osc_clocks") return "Oscillator Clock";
|
|
@@ -3338,7 +3390,8 @@ var MyDerivedData = function MyDerivedData(dataModel) {
|
|
|
3338
3390
|
isdriverisr: false,
|
|
3339
3391
|
ispwmi_enabled: false,
|
|
3340
3392
|
ispwmpi_enabled: false,
|
|
3341
|
-
moduleName: _this.dataModel.getName()
|
|
3393
|
+
moduleName: _this.dataModel.getName(),
|
|
3394
|
+
modifiedRegisterList: _this.getmodifiedRegisterValues()
|
|
3342
3395
|
};
|
|
3343
3396
|
});
|
|
3344
3397
|
|
|
@@ -3795,7 +3848,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
3795
3848
|
/* harmony import */ var _microchip_scf_interface__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @microchip/scf-interface */ "./node_modules/@microchip/scf-interface/lib/index.js");
|
|
3796
3849
|
/* harmony import */ var _microchip_scf_interface__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_microchip_scf_interface__WEBPACK_IMPORTED_MODULE_0__);
|
|
3797
3850
|
|
|
3798
|
-
/** The arguments to be provided to the implementation. */
|
|
3799
3851
|
|
|
3800
3852
|
var getInterfaceId = function getInterfaceId() {
|
|
3801
3853
|
return {
|
|
@@ -3829,7 +3881,10 @@ var createMock = function createMock() {
|
|
|
3829
3881
|
},
|
|
3830
3882
|
args: {
|
|
3831
3883
|
requestId: {
|
|
3832
|
-
customName: "MyModule"
|
|
3884
|
+
customName: "MyModule",
|
|
3885
|
+
moduleEnable: true,
|
|
3886
|
+
clockSource: "",
|
|
3887
|
+
clbBle: {}
|
|
3833
3888
|
}
|
|
3834
3889
|
}
|
|
3835
3890
|
};
|