Date
1 - 3 of 3
Sequences to perform when software crashes / is closed
Cornelius Claussen
Hi,
do you have access to the DC power supply source code as well? As an additional measure to what Anton suggested you could implement a shutdown on communication loss in the DC power supply itself, that would also include other error cases such as physical cable disconnection etc. Most power supplies we worked with require some heartbeat message to keep the communication alive.
best
Cornelius
Am Mi., 1. Feb. 2023 um 15:05 Uhr schrieb Anton Wöllert via lists.lfenergy.org <anton.woellert=pionix.de@...>:
Dear Davide,right now, there is unfortunately no "teardown" of EVerest at all. But if you write your own module, you could try to register your own signal handler for that module which in turn could do some clean-up/teardown for you (see https://en.wikipedia.org/wiki/C_signal_handling).It is on our backlog to implement a proper shutdown for the modules, but this might take some time until done.Best,AntonAm Mi., 1. Feb. 2023 um 14:28 Uhr schrieb Davide Marzona <davidemarzona@...>:Hello,recently I implemented my own protocol to comunicate with a DC power supply in C++. I tested it by simulating the other modules and connecting only the power supply. In certain cases, some other module had exeprienced some errors and the whole software crashed. I noticed that in these cases, if the power suppply has been enabled, there's no funciotnality that is able to turn it off, I have to manually connetct to it and disable the output.My question is if there is some way to define some sequencences in module/interface code that shall be performed when software crashes or simply is closed by the user. My idea is that as like ev-cli creates module init and ready functions, if there is some way to create a function like close where the methods needed to safelly close the module are collected.
Thank you,D. Marzona
Anton Wöllert
Dear Davide,
right now, there is unfortunately no "teardown" of EVerest at all. But if you write your own module, you could try to register your own signal handler for that module which in turn could do some clean-up/teardown for you (see https://en.wikipedia.org/wiki/C_signal_handling).
It is on our backlog to implement a proper shutdown for the modules, but this might take some time until done.
Best,
Anton
Am Mi., 1. Feb. 2023 um 14:28 Uhr schrieb Davide Marzona <davidemarzona@...>:
Hello,recently I implemented my own protocol to comunicate with a DC power supply in C++. I tested it by simulating the other modules and connecting only the power supply. In certain cases, some other module had exeprienced some errors and the whole software crashed. I noticed that in these cases, if the power suppply has been enabled, there's no funciotnality that is able to turn it off, I have to manually connetct to it and disable the output.My question is if there is some way to define some sequencences in module/interface code that shall be performed when software crashes or simply is closed by the user. My idea is that as like ev-cli creates module init and ready functions, if there is some way to create a function like close where the methods needed to safelly close the module are collected.
Thank you,D. Marzona
Davide Marzona
Hello,
recently I implemented my own protocol to comunicate with a DC power supply in C++. I tested it by simulating the other modules and connecting only the power supply. In certain cases, some other module had exeprienced some errors and the whole software crashed.
I noticed that in these cases, if the power suppply has been enabled, there's no funciotnality that is able to turn it off, I have to manually connetct to it and disable the output.
My question is if there is some way to define some sequencences in module/interface code that shall be performed when software crashes or simply is closed by the user. My idea is that as like ev-cli creates module
init and ready functions, if there is some way to create a function like
close where the methods needed to safelly close the module are collected.
Thank you,
D. Marzona