Code snippet:

#include "esp_system.h"
#include "math.h"

void app_main(void)
{
  int random = esp_random();
}