.. _program_listing_file_libspookyaction_include_pn532_esp32_hsu.hpp: Program Listing for File hsu.hpp ================================ |exhale_lsh| :ref:`Return to documentation for file ` (``libspookyaction/include/pn532/esp32/hsu.hpp``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS .. code-block:: cpp // // Created by Pietro Saccardi on 21/12/2020. // #ifndef PN532_ESP32_HSU_HPP #define PN532_ESP32_HSU_HPP #include #include #include namespace pn532::esp32 { class hsu_channel final : public channel { uart_port_t _port; protected: result<> raw_send(mlab::range buffer, ms timeout) override; result<> raw_receive(mlab::range buffer, ms timeout) override; [[nodiscard]] inline comm_rx_mode raw_receive_mode() const override; bool on_send_prepare(ms timeout) override; public: bool wake() override; hsu_channel(uart_port_t port, uart_config_t config, gpio_num_t to_device_tx, gpio_num_t to_device_rx); ~hsu_channel() override; }; }// namespace pn532::esp32 namespace pn532::esp32 { comm_rx_mode hsu_channel::raw_receive_mode() const { return comm_rx_mode::stream; } }// namespace pn532::esp32 #endif//PN532_ESP32_HSU_HPP