Keil Logo


void memset (
  unsigned long start_address, /* memory start address */
  unsigned long length,        /* memory length        */
  unsigned char value          /* value to write       */

The debug function memset fills the memory specified through start address and length with the character value.


  • The order of the parameters length and value of the debug function memset are inverted compared to the standard C function memset.
Return Value


>MEMSET (0x20000, 0x1000, 'a')       /* Fill 0x20000 to 0x20FFF with 'a' */
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.