X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=include%2FCECExportsC.h;h=8d91fe26ad9010d964a061c45694a84e28c7eba6;hb=a58d63d2a7101b189d99e5976d23d53b0599d3d8;hp=6fa4dbeebc6115f991a65040a4770d68d56c9bbf;hpb=6dfe921375b746dab058c1f1c3a8263fbd409d3d;p=deb_libcec.git diff --git a/include/CECExportsC.h b/include/CECExportsC.h index 6fa4dbe..8d91fe2 100644 --- a/include/CECExportsC.h +++ b/include/CECExportsC.h @@ -52,12 +52,6 @@ extern DECLSPEC bool cec_init(const char *strDeviceName, CEC::cec_logical_addres extern DECLSPEC bool cec_init(const char *strDeviceName, cec_logical_address iLogicalAddress = CECDEVICE_PLAYBACKDEVICE1, int iPhysicalAddress = CEC_DEFAULT_PHYSICAL_ADDRESS); #endif -/*! - * @brief Close the CEC adapter connection. - * @return True when the device was closed, false otherwise. - */ -extern DECLSPEC bool cec_close(void); - /*! * @brief Open a connection to the CEC adapter. * @param strPort The path to the port. @@ -66,6 +60,12 @@ extern DECLSPEC bool cec_close(void); */ extern DECLSPEC bool cec_open(const char *strPort, int iTimeout); +/*! + * @brief Close the connection to the CEC adapter. + * @param iTimeout Timeout in ms + */ +extern DECLSPEC bool cec_close(int iTimeout); + /*! * @brief Ping the CEC adapter. * @return True when the ping was succesful, false otherwise. @@ -145,6 +145,17 @@ extern DECLSPEC bool cec_get_next_keypress(CEC::cec_keypress *key); extern DECLSPEC bool cec_get_next_keypress(cec_keypress *key); #endif +/*! + * @brief Get the next CEC command that was received by the adapter. + * @param action The next command. + * @return True when a command was passed, false otherwise. + */ +#ifdef __cplusplus +extern DECLSPEC bool cec_get_next_command(CEC::cec_command *command); +#else +extern DECLSPEC bool cec_get_next_command(cec_command *command); +#endif + /*! * @brief Transmit a frame on the CEC line. * @param data The frame to send.