user28623: I am not that great at Arduino and C++ yet, but I'll give this a shot:
I have a char array that looks like this:
char PROGMEM bitmap[] = {0xD7,0xED,0xEF,0xFF,0xF6,0xEF,0xFE};

However, I receive this char array from a string, which is basically:
String input = "0xD7,0xED,0xEF,0xFF,0xF6,0xEF,0xFE";

How do I turn my input variable with a comma separated char array into the actual array? I need it to be fast and not use a lot of memory. I haven't been able to find a use case like this, because it's very unique.
I feel like this should be super simple to do, but I can't wrap my head around it.
Things I've tried and didn't understand that much:
1:
char delimiter[] = ",";

char* ptr = strtok_r(text, delimiter);

while (ptr != NULL) {
  Serial.println(ptr);
  ptr = strtok_r(NULL, delimiter);
}


cannot convert 'String' to 'char*' for argument '1' to 'char* strtok(char*, const char*)'

2:
char buf[4800];
text.toCharArray(buf, 4800);
char *p = buf;
char *str;
int i = 0;
char bitmap[115];
while ((str = strtok_r(p, ",", &p)) != NULL) {
  bitmap[i] = str;
  i++;
}
Serial.println(bitmap);

(the total length of my characters are 4799 and the total length of hexadecimals are 114, so I'm just trying something here)
Error: Apparently you can't use  =?
3: 
char buf[4800];
text.toCharArray(buf, 4800);
char *p = buf;
char *str;
while ((str = strtok_r(p, ",", &p)) != NULL) {
  Serial.println(str);
}

This actually prints the strings to the console, but trying to add them to a char array is still a mystery I am trying to solve right as I write this.
4:
char buf[4800];
text.toCharArray(buf, 4800);
char *p = buf;
char *str;
char *ptr;
char bitmap[115];
int i = 0;
while ((str = strtok_r(p, ",", &p)) != NULL) {
  bitmap[i] = strtol(str, &ptr, 16);
  i++;
}

Serial.println(bitmap);

I'm getting a lot closer now. strtol(str, &ptr, 16) actually gives me the right integers I need, but it seems like my Arduino crashes when I run this code. It simply reboots it. Error:

assertion "heap != NULL && "free() target pointer is outside heap areas"" failed: file "/Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/heap/./heap_caps.c", line 171, function: heap_caps_free
  abort() was called at PC 0x4011c173 on core 1


user28623: So after a lot of help and some tweaking, I finally got it to work!
String text = server.arg(0);

char buf[text.length()];
text.toCharArray(buf, text.length());
char *p = buf;
char *str;
char bitmap[960]; //960 is fixed for now, need to count amount of commas + 1
int i = 0;
while ((str = strtok_r(p, ",", &p)) != NULL) {
  bitmap[i] = strtol(str, NULL, 16);
  i++;
}

bitmap now contains all the XBM data from the GET request. I ran into some issues, causing the device to restart, because I accidentally forgot that the length of the bitmap array isn't 114 (that's the amount of horizontal pixels of the display). This caused it to overflow by a lot.
Huge thanks to jose can u c for helping me.

28623: <p>I am not that great at Arduino and C++ yet, but I'll give this a shot:</p>

<p>I have a char array that looks like this:</p>

<pre><code>char PROGMEM bitmap[] = {0xD7,0xED,0xEF,0xFF,0xF6,0xEF,0xFE};
</code></pre>

<p>However, I receive this char array from a string, which is basically:</p>

<pre><code>String input = "0xD7,0xED,0xEF,0xFF,0xF6,0xEF,0xFE";
</code></pre>

<p>How do I turn my <code>input</code> variable with a comma separated char array into the actual array? I need it to be fast and not use a lot of memory. I haven't been able to find a use case like this, because it's very unique.</p>

<p>I feel like this should be super simple to do, but I can't wrap my head around it.</p>

<p>Things I've tried and didn't understand that much:</p>

<p><strong>1:</strong></p>

<pre><code>char delimiter[] = ",";

char* ptr = strtok_r(text, delimiter);

while (ptr != NULL) {
  Serial.println(ptr);
  ptr = strtok_r(NULL, delimiter);
}
</code></pre>

<blockquote>
  <p>cannot convert 'String' to 'char*' for argument '1' to 'char* strtok(char*, const char*)'</p>
</blockquote>

<p><strong>2:</strong></p>

<pre><code>char buf[4800];
text.toCharArray(buf, 4800);
char *p = buf;
char *str;
int i = 0;
char bitmap[115];
while ((str = strtok_r(p, ",", &amp;p)) != NULL) {
  bitmap[i] = str;
  i++;
}
Serial.println(bitmap);
</code></pre>

<p>(the total length of my characters are 4799 and the total length of hexadecimals are 114, so I'm just trying something here)</p>

<p>Error: Apparently you can't use  <code>=</code>?</p>

<p><strong>3:</strong> </p>

<pre><code>char buf[4800];
text.toCharArray(buf, 4800);
char *p = buf;
char *str;
while ((str = strtok_r(p, ",", &amp;p)) != NULL) {
  Serial.println(str);
}
</code></pre>

<p>This actually prints the strings to the console, but trying to add them to a char array is still a mystery I am trying to solve right as I write this.</p>

<p><strong>4:</strong></p>

<pre><code>char buf[4800];
text.toCharArray(buf, 4800);
char *p = buf;
char *str;
char *ptr;
char bitmap[115];
int i = 0;
while ((str = strtok_r(p, ",", &amp;p)) != NULL) {
  bitmap[i] = strtol(str, &amp;ptr, 16);
  i++;
}

Serial.println(bitmap);
</code></pre>

<p>I'm getting a lot closer now. <code>strtol(str, &amp;ptr, 16)</code> actually gives me the right integers I need, but it seems like my Arduino crashes when I run this code. It simply reboots it. Error:</p>

<blockquote>
  <p>assertion "heap != NULL &amp;&amp; "free() target pointer is outside heap areas"" failed: file "/Users/ficeto/Desktop/ESP32/ESP32/esp-idf-public/components/heap/./heap_caps.c", line 171, function: heap_caps_free
  abort() was called at PC 0x4011c173 on core 1</p>
</blockquote>
 28623: <p>So after a lot of help and some tweaking, I finally got it to work!</p>

<pre><code>String text = server.arg(0);

char buf[text.length()];
text.toCharArray(buf, text.length());
char *p = buf;
char *str;
char bitmap[960]; //960 is fixed for now, need to count amount of commas + 1
int i = 0;
while ((str = strtok_r(p, ",", &amp;p)) != NULL) {
  bitmap[i] = strtol(str, NULL, 16);
  i++;
}
</code></pre>

<p><code>bitmap</code> now contains all the XBM data from the GET request. I ran into some issues, causing the device to restart, because I accidentally forgot that the length of the bitmap array isn't 114 (that's the amount of horizontal pixels of the display). This caused it to overflow by a lot.</p>

<p>Huge thanks to <a href="https://arduino.stackexchange.com/users/27653/jose-can-u-c">jose can u c</a> for helping me.</p>
