ProfinetConnector/src/profinet/profinet_cb_signal_led_ind.hpp

31 lines
1.5 KiB
C++
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#pragma once
#include "../../libs/include/pnet_api.h"
/**
* Indication to the application that the Profinet signal LED should change
* state.
*
* Use this callback to implement control of the LED.
*
* It is optional to implement this callback (but a compliant Profinet device
* must have a signal LED)
*
* No \a arep information is available, as this callback typically is triggered
* when there is no active connection.
*
* Индикация приложению о том, что сигнальный светодиод Profinet должен изменить состояние.
*
* Используйте этот обратный вызов для реализации управления светодиодом.
*
* Реализовать этот обратный вызов необязательно (но совместимое с Profinet устройство должно иметь сигнальный светодиод).
*
* Информация \a arep недоступна, так как этот обратный вызов обычно запускается при отсутствии активного соединения.
*
* @param net InOut: The p-net stack instance
* @param arg InOut: User-defined data (not used by p-net)
* @param led_state In: True if the signal LED should be on.
* @return 0 on success.
* -1 if an error occurred. Will trigger a log message.
*/
int profinet_cb_signal_led_ind (pnet_t * net, void * arg, bool led_state);