@@ -684,10 +684,10 @@ const uint8_t *USBEndpointTester::configuration_desc(uint8_t index)
684
684
}
685
685
}
686
686
687
- void USBEndpointTester::_cb_bulk_out (usb_ep_t endpoint )
687
+ void USBEndpointTester::_cb_bulk_out ()
688
688
{
689
689
_cnt_cb_bulk_out++;
690
- uint32_t rx_size = read_finish (endpoint );
690
+ uint32_t rx_size = read_finish (_endpoints[EP_BULK_OUT] );
691
691
692
692
if (_abort_transfer_test == false ) {
693
693
// Send data back to host using the IN endpoint.
@@ -699,15 +699,15 @@ void USBEndpointTester::_cb_bulk_out(usb_ep_t endpoint)
699
699
_num_packets_bulk_out_abort++;
700
700
read_start (_endpoints[EP_BULK_OUT], _endpoint_buffs[EP_BULK_OUT], (*_endpoint_configs)[EP_BULK_OUT].max_packet );
701
701
if (_num_packets_bulk_out_abort == NUM_PACKETS_UNTIL_ABORT) {
702
- endpoint_abort (endpoint );
702
+ endpoint_abort (_endpoints[EP_BULK_OUT] );
703
703
}
704
704
}
705
705
}
706
706
707
- void USBEndpointTester::_cb_bulk_in (usb_ep_t endpoint )
707
+ void USBEndpointTester::_cb_bulk_in ()
708
708
{
709
709
_cnt_cb_bulk_in++;
710
- write_finish (endpoint );
710
+ write_finish (_endpoints[EP_BULK_IN] );
711
711
712
712
if (_abort_transfer_test == false ) {
713
713
// Receive more data from the host using the OUT endpoint.
@@ -721,15 +721,15 @@ void USBEndpointTester::_cb_bulk_in(usb_ep_t endpoint)
721
721
memset (_endpoint_buffs[EP_BULK_IN], _num_packets_bulk_in_abort, (*_endpoint_configs)[EP_BULK_IN].max_packet );
722
722
write_start (_endpoints[EP_BULK_IN], _endpoint_buffs[EP_BULK_IN], (*_endpoint_configs)[EP_BULK_IN].max_packet );
723
723
if (_num_packets_bulk_in_abort == NUM_PACKETS_UNTIL_ABORT) {
724
- endpoint_abort (endpoint );
724
+ endpoint_abort (_endpoints[EP_BULK_IN] );
725
725
}
726
726
}
727
727
}
728
728
729
- void USBEndpointTester::_cb_int_out (usb_ep_t endpoint )
729
+ void USBEndpointTester::_cb_int_out ()
730
730
{
731
731
_cnt_cb_int_out++;
732
- uint32_t rx_size = read_finish (endpoint );
732
+ uint32_t rx_size = read_finish (_endpoints[EP_INT_OUT] );
733
733
if (_abort_transfer_test == false ) {
734
734
// Send data back to host using the IN endpoint.
735
735
memset (_endpoint_buffs[EP_INT_IN], 0 , (*_endpoint_configs)[EP_INT_IN].max_packet );
@@ -740,15 +740,15 @@ void USBEndpointTester::_cb_int_out(usb_ep_t endpoint)
740
740
_num_packets_int_out_abort++;
741
741
read_start (_endpoints[EP_INT_OUT], _endpoint_buffs[EP_INT_OUT], (*_endpoint_configs)[EP_INT_OUT].max_packet );
742
742
if (_num_packets_int_out_abort == NUM_PACKETS_UNTIL_ABORT) {
743
- endpoint_abort (endpoint );
743
+ endpoint_abort (_endpoints[EP_INT_OUT] );
744
744
}
745
745
}
746
746
}
747
747
748
- void USBEndpointTester::_cb_int_in (usb_ep_t endpoint )
748
+ void USBEndpointTester::_cb_int_in ()
749
749
{
750
750
_cnt_cb_int_in++;
751
- write_finish (endpoint );
751
+ write_finish (_endpoints[EP_INT_IN] );
752
752
if (_abort_transfer_test == false ) {
753
753
// Receive more data from the host using the OUT endpoint.
754
754
read_start (_endpoints[EP_INT_OUT], _endpoint_buffs[EP_INT_OUT], (*_endpoint_configs)[EP_INT_OUT].max_packet );
@@ -761,25 +761,25 @@ void USBEndpointTester::_cb_int_in(usb_ep_t endpoint)
761
761
memset (_endpoint_buffs[EP_INT_IN], _num_packets_int_in_abort, (*_endpoint_configs)[EP_INT_IN].max_packet );
762
762
write_start (_endpoints[EP_INT_IN], _endpoint_buffs[EP_INT_IN], (*_endpoint_configs)[EP_INT_IN].max_packet );
763
763
if (_num_packets_int_in_abort == NUM_PACKETS_UNTIL_ABORT) {
764
- endpoint_abort (endpoint );
764
+ endpoint_abort (_endpoints[EP_INT_IN] );
765
765
}
766
766
}
767
767
}
768
768
769
- void USBEndpointTester::_cb_iso_out (usb_ep_t endpoint )
769
+ void USBEndpointTester::_cb_iso_out ()
770
770
{
771
771
_cnt_cb_iso_out++;
772
- uint32_t rx_size = read_finish (endpoint );
772
+ uint32_t rx_size = read_finish (_endpoints[EP_ISO_OUT] );
773
773
// Send data back to host using the IN endpoint.
774
774
memset (_endpoint_buffs[EP_ISO_IN], 0 , (*_endpoint_configs)[EP_ISO_IN].max_packet );
775
775
memcpy (_endpoint_buffs[EP_ISO_IN], _endpoint_buffs[EP_ISO_OUT], rx_size);
776
776
write_start (_endpoints[EP_ISO_IN], _endpoint_buffs[EP_ISO_IN], rx_size);
777
777
}
778
778
779
- void USBEndpointTester::_cb_iso_in (usb_ep_t endpoint )
779
+ void USBEndpointTester::_cb_iso_in ()
780
780
{
781
781
_cnt_cb_iso_in++;
782
- write_finish (endpoint );
782
+ write_finish (_endpoints[EP_ISO_IN] );
783
783
// Receive more data from the host using the OUT endpoint.
784
784
read_start (_endpoints[EP_ISO_OUT], _endpoint_buffs[EP_ISO_OUT], (*_endpoint_configs)[EP_ISO_OUT].max_packet );
785
785
}
0 commit comments