Skip to content

Commit

Permalink
Adding start and stop transaction powermeter cmds to the DCSupplySimu…
Browse files Browse the repository at this point in the history
…lator module

Signed-off-by: Sebastian Lukas <[email protected]>
Signed-off-by: pietfried <[email protected]>
  • Loading branch information
SebaLukas committed Apr 8, 2024
1 parent f2548ee commit 10c3157
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions modules/simulation/JsDCSupplySimulator/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,15 @@ boot_module(async ({
connector_current = -settings_connector_max_import_current;
}
});

setup.provides.powermeter.register.stop_transaction((mod, args) => ({
status: 'NOT_SUPPORTED',
error: 'DcSupplySimulator does not support stop transaction request.',
}));

setup.provides.powermeter.register.start_transaction((mod, args) => ({
status: 'OK',
}));
}).then((mod) => {
setInterval(() => {
mod.provides.main.publish.voltage_current({
Expand Down

0 comments on commit 10c3157

Please sign in to comment.