rename to hcd_edpt_open()
This commit is contained in:
		| @@ -313,7 +313,7 @@ bool hcd_setup_send(uint8_t rhport, uint8_t dev_addr, uint8_t const setup_packet | ||||
| //--------------------------------------------------------------------+ | ||||
| // BULK/INT/ISO PIPE API | ||||
| //--------------------------------------------------------------------+ | ||||
| bool hcd_pipe_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_endpoint_t const * ep_desc) | ||||
| bool hcd_edpt_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_endpoint_t const * ep_desc) | ||||
| { | ||||
|   // TODO not support ISO yet | ||||
|   TU_ASSERT (ep_desc->bmAttributes.xfer != TUSB_XFER_ISOCHRONOUS); | ||||
|   | ||||
| @@ -128,15 +128,15 @@ void hcd_event_xfer_complete(uint8_t dev_addr, uint8_t ep_addr, xfer_result_t ev | ||||
| //--------------------------------------------------------------------+ | ||||
| // Endpoints API | ||||
| //--------------------------------------------------------------------+ | ||||
| bool hcd_edpt_close(uint8_t rhport, uint8_t dev_addr, uint8_t ep_addr); | ||||
| bool hcd_setup_send(uint8_t rhport, uint8_t dev_addr, uint8_t const setup_packet[8]); | ||||
| bool hcd_edpt_xfer(uint8_t rhport, uint8_t dev_addr, uint8_t ep_addr, uint8_t * buffer, uint16_t buflen); | ||||
| bool hcd_edpt_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_endpoint_t const * ep_desc); | ||||
|  | ||||
| bool hcd_edpt_close(uint8_t rhport, uint8_t dev_addr, uint8_t ep_addr); | ||||
| bool hcd_edpt_xfer(uint8_t rhport, uint8_t dev_addr, uint8_t ep_addr, uint8_t * buffer, uint16_t buflen); | ||||
| //--------------------------------------------------------------------+ | ||||
| // PIPE API | ||||
| //--------------------------------------------------------------------+ | ||||
| // TODO control xfer should be used via usbh layer | ||||
| bool hcd_pipe_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_endpoint_t const * ep_desc); | ||||
| bool hcd_pipe_queue_xfer(uint8_t dev_addr, uint8_t ep_addr, uint8_t buffer[], uint16_t total_bytes); // only queue, not transferring yet | ||||
| bool hcd_pipe_xfer(uint8_t dev_addr, uint8_t ep_addr, uint8_t buffer[], uint16_t total_bytes, bool int_on_complete); | ||||
| bool hcd_pipe_close(uint8_t rhport, uint8_t dev_addr, uint8_t ep_addr); // TODO remove | ||||
|   | ||||
| @@ -168,7 +168,7 @@ bool hub_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_interface_t const *p_i | ||||
|   TU_ASSERT(TUSB_DESC_ENDPOINT == ep_desc->bDescriptorType); | ||||
|   TU_ASSERT(TUSB_XFER_INTERRUPT == ep_desc->bmAttributes.xfer); | ||||
|    | ||||
|   TU_ASSERT(hcd_pipe_open(rhport, dev_addr, ep_desc)); | ||||
|   TU_ASSERT(hcd_edpt_open(rhport, dev_addr, ep_desc)); | ||||
|  | ||||
|   hub_data[dev_addr-1].itf_num = p_interface_desc->bInterfaceNumber; | ||||
|   hub_data[dev_addr-1].ep_status = ep_desc->bEndpointAddress; | ||||
|   | ||||
| @@ -481,7 +481,7 @@ static void ed_list_remove(ohci_ed_t * p_head, ohci_ed_t * p_ed) | ||||
|   p_ed->used      = 0; // free ED | ||||
| } | ||||
|  | ||||
| pipe_handle_t hcd_pipe_open(uint8_t dev_addr, tusb_desc_endpoint_t const * p_endpoint_desc, uint8_t class_code) | ||||
| pipe_handle_t hcd_edpt_open(uint8_t dev_addr, tusb_desc_endpoint_t const * p_endpoint_desc, uint8_t class_code) | ||||
| { | ||||
|   pipe_handle_t const null_handle = { .dev_addr = 0, .xfer_type = 0, .index = 0 }; | ||||
|  | ||||
|   | ||||
| @@ -236,7 +236,7 @@ tusb_error_t usbh_pipe_control_open(uint8_t dev_addr, uint8_t max_packet_size) | ||||
|     .bInterval        = 0 | ||||
|   }; | ||||
|  | ||||
|   hcd_pipe_open(_usbh_devices[dev_addr].rhport, dev_addr, &ep0_desc); | ||||
|   hcd_edpt_open(_usbh_devices[dev_addr].rhport, dev_addr, &ep0_desc); | ||||
|  | ||||
|   return TUSB_ERROR_NONE; | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 hathach
					hathach