| 336 | } |
| 337 | |
| 338 | static void cmd_bulk_write_test(struct any_frame* f) |
| 339 | { |
| 340 | uint8_t buffer[64]; |
| 341 | |
| 342 | wait_until_writeable(FLUXENGINE_DATA_IN_EP_NUM); |
| 343 | for (int x=0; x<64; x++) |
| 344 | { |
| 345 | CyWdtClear(); |
| 346 | for (int y=0; y<256; y++) |
| 347 | { |
| 348 | for (unsigned z=0; z<sizeof(buffer); z++) |
| 349 | buffer[z] = x+y+z; |
| 350 | |
| 351 | wait_until_writeable(FLUXENGINE_DATA_IN_EP_NUM); |
| 352 | USBFS_LoadInEP(FLUXENGINE_DATA_IN_EP_NUM, buffer, sizeof(buffer)); |
| 353 | } |
| 354 | } |
| 355 | |
| 356 | DECLARE_REPLY_FRAME(struct any_frame, F_FRAME_BULK_WRITE_TEST_REPLY); |
| 357 | send_reply(&r); |
| 358 | } |
| 359 | |
| 360 | static void cmd_bulk_read_test(struct any_frame* f) |
| 361 | { |
no test coverage detected