28.3.2.6.3 Write Protect

Use the MULTIPKT bit combined with MCNT to set the maximum number of bytes the USB peripheral will write to RAM for OUT transactions. MCNT can be any number, including zero. The application code has to allocate a buffer at least as big as what MCNT is set to for the endpoint to ensure that no RAM corruption is possible. If MULIPKT and MCNT are unused, the allocated buffer has to be as large as set by BUFSIZE.

The write protect can be used to save RAM used by the application in cases where the used protocol is expected to not sending a multiple of the endpoint size.