bool uhi_cdc_open(uint8_t port, usb_cdc_line_coding_t *configuration) { // Send configuration if (!uhi_cdc_set_conf(port, configuration)) { return false; } // Send DTR if (!uhi_cdc_set_ctrl_line(port, CDC_CTRL_SIGNAL_DTE_PRESENT)) { return false; } return true; }
bool uhi_cdc_open(uint8_t port, CDCLineCoding *configuration) { // Send configuration if (!uhi_cdc_set_conf(port, configuration)) return false; // Send DTR if (!uhi_cdc_set_ctrl_line(port, CDCControlLineState_DTE_PRESENT)) return false; return true; }
void uhi_cdc_close(uint8_t port) { // Clear DTR uhi_cdc_set_ctrl_line(port, 0); }