fix pingstate for highspeed bulk out transfer
temp implementation of msc host --> can issue inquiry command
This commit is contained in:
@@ -117,6 +117,16 @@ tusb_descriptor_endpoint_t const desc_ept_bulk_in =
|
||||
.bInterval = 0
|
||||
};
|
||||
|
||||
tusb_descriptor_endpoint_t const desc_ept_bulk_out =
|
||||
{
|
||||
.bLength = sizeof(tusb_descriptor_endpoint_t),
|
||||
.bDescriptorType = TUSB_DESC_TYPE_ENDPOINT,
|
||||
.bEndpointAddress = 0x01,
|
||||
.bmAttributes = { .xfer = TUSB_XFER_BULK },
|
||||
.wMaxPacketSize = 512,
|
||||
.bInterval = 0
|
||||
};
|
||||
|
||||
void verify_bulk_open_qhd(ehci_qhd_t *p_qhd, tusb_descriptor_endpoint_t const * desc_endpoint, uint8_t class_code)
|
||||
{
|
||||
verify_open_qhd(p_qhd, desc_endpoint->bEndpointAddress, desc_endpoint->wMaxPacketSize.size);
|
||||
@@ -159,6 +169,18 @@ void test_open_bulk_qhd_data(void)
|
||||
TEST_ASSERT_EQUAL(EHCI_QUEUE_ELEMENT_QHD, async_head->next.type);
|
||||
}
|
||||
|
||||
void test_open_bulk_hs_out_pingstate(void)
|
||||
{
|
||||
ehci_qhd_t *p_qhd;
|
||||
pipe_handle_t pipe_hdl;
|
||||
|
||||
//------------- Code Under TEST -------------//
|
||||
pipe_hdl = hcd_pipe_open(dev_addr, &desc_ept_bulk_out, TUSB_CLASS_MSC);
|
||||
|
||||
p_qhd = &ehci_data.device[ pipe_hdl.dev_addr-1 ].qhd[ pipe_hdl.index ];
|
||||
TEST_ASSERT(p_qhd->qtd_overlay.pingstate_err);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// PIPE CLOSE
|
||||
//--------------------------------------------------------------------+
|
||||
|
||||
@@ -155,7 +155,6 @@ void test_bulk_xfer_hs_ping_out(void)
|
||||
TEST_ASSERT_STATUS( hcd_pipe_xfer(pipe_hdl, xfer_data, sizeof(xfer_data), true) );
|
||||
|
||||
ehci_qtd_t* p_qtd = p_qhd->p_qtd_list_head;
|
||||
TEST_ASSERT(p_qtd->pingstate_err);
|
||||
}
|
||||
|
||||
void test_bulk_xfer(void)
|
||||
|
||||
Reference in New Issue
Block a user