RX test is now done using packet-aligned buffers.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10166 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
ece0fcd51e
commit
b898a2ee31
|
@ -34,8 +34,8 @@
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
|
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
|
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.FORMAT" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?><contentList><content id="DAINTMSK-otgp-usb_lld_pump-(format)" val="4"/></contentList>"/>
|
<stringAttribute key="org.eclipse.cdt.launch.FORMAT" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?><contentList><content id="DAINTMSK-otgp-usb_lld_pump-(format)" val="4"/></contentList>"/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.GLOBAL_VARIABLES" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <globalVariableList/> "/>
|
<stringAttribute key="org.eclipse.cdt.launch.GLOBAL_VARIABLES" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <globalVariableList/> "/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList> <memoryBlockExpressionItem> <expression text="0x20000f88"/> </memoryBlockExpressionItem> </memoryBlockExpressionList> "/>
|
<stringAttribute key="org.eclipse.cdt.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList> <memoryBlockExpressionItem> <expression text="0x20000f88"/> </memoryBlockExpressionItem> </memoryBlockExpressionList> "/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="./build/ch.elf"/>
|
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="./build/ch.elf"/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="STM32F7xx-USB_RAW"/>
|
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="STM32F7xx-USB_RAW"/>
|
||||||
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="true"/>
|
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="true"/>
|
||||||
|
|
|
@ -34,8 +34,8 @@
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
|
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
|
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.FORMAT" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?><contentList><content id="r3-(format)" val="4"/><content id="vt_delta-null-chVTDoSetI-(format)" val="4"/></contentList>"/>
|
<stringAttribute key="org.eclipse.cdt.launch.FORMAT" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?><contentList><content id="r3-(format)" val="4"/><content id="vt_delta-null-chVTDoSetI-(format)" val="4"/></contentList>"/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.GLOBAL_VARIABLES" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <globalVariableList/> "/>
|
<stringAttribute key="org.eclipse.cdt.launch.GLOBAL_VARIABLES" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <globalVariableList/> "/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList> <memoryBlockExpressionItem> <expression text="0x20010744"/> </memoryBlockExpressionItem> </memoryBlockExpressionList> "/>
|
<stringAttribute key="org.eclipse.cdt.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList> <memoryBlockExpressionItem> <expression text="0x20010744"/> </memoryBlockExpressionItem> </memoryBlockExpressionList> "/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="./build/ch.elf"/>
|
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="./build/ch.elf"/>
|
||||||
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="STM32F7xx-USB_RAW"/>
|
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="STM32F7xx-USB_RAW"/>
|
||||||
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="true"/>
|
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="true"/>
|
||||||
|
|
|
@ -40,7 +40,7 @@ static const uint8_t txbuf[] =
|
||||||
"0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef"
|
"0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef"
|
||||||
"0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef";
|
"0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef";
|
||||||
|
|
||||||
static uint8_t rxbuf[1024];
|
static uint8_t rxbuf[1024 + 1];
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* USB writer. This thread writes data to the USB at maximum rate.
|
* USB writer. This thread writes data to the USB at maximum rate.
|
||||||
|
@ -54,7 +54,7 @@ static THD_FUNCTION(Writer, arg) {
|
||||||
chRegSetThreadName("writer");
|
chRegSetThreadName("writer");
|
||||||
while (true) {
|
while (true) {
|
||||||
msg_t msg = usbTransmit(&USBD2, USBD2_DATA_REQUEST_EP,
|
msg_t msg = usbTransmit(&USBD2, USBD2_DATA_REQUEST_EP,
|
||||||
txbuf, sizeof (txbuf) - 1);
|
txbuf, sizeof (txbuf));
|
||||||
if (msg == MSG_RESET)
|
if (msg == MSG_RESET)
|
||||||
chThdSleepMilliseconds(500);
|
chThdSleepMilliseconds(500);
|
||||||
}
|
}
|
||||||
|
@ -72,7 +72,7 @@ static THD_FUNCTION(Reader, arg) {
|
||||||
chRegSetThreadName("reader");
|
chRegSetThreadName("reader");
|
||||||
while (true) {
|
while (true) {
|
||||||
msg_t msg = usbReceive(&USBD2, USBD2_DATA_AVAILABLE_EP,
|
msg_t msg = usbReceive(&USBD2, USBD2_DATA_AVAILABLE_EP,
|
||||||
rxbuf, sizeof (rxbuf) - 1);
|
rxbuf, sizeof (rxbuf));
|
||||||
if (msg == MSG_RESET)
|
if (msg == MSG_RESET)
|
||||||
chThdSleepMilliseconds(500);
|
chThdSleepMilliseconds(500);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue