Convert Serial.read() input into a unsigned int array.

Hello,

I'm new to Arduino and I'm sorry if my question is too basic. I have an Arduino Uno with an infrared led and I would like to send some IR raw codes to an air conditioner through the Serial.read().

These codes needs to be an unsigned int array like this:

unsigned int powerOff[200] = {4350,4450,450,1700,450,650,450,1700,450,1700,500,600,450,600,500,1700,450,600,500,600,450,1700,500,600,450,600,500,1700,450,1700,450,650,450,1650,500,1750,450,600,450,1700,500,1700,450,1700,500,1700,450,1700,500,1700,450,600,500,1700,450,600,500,600,450,600,450,650,450,600,450,650,450,600,450,650,450,600,450,600,500,600,450,600,500,600,450,600,500,1700,450,1700,500,1700,450,1700,450,1750,450,1700,450,1700,500,1700,450,5300,4350,4450,450,1700,450,650,450,1700,450,1700,500,600,450,600,500,1700,450,600,500,600,450,1700,500,600,450,600,500,1700,450,1700,500,600,450,1700,450,1750,450,600,450,1700,500,1700,450,1700,500,1700,450,1700,500,1700,450,600,500,1700,450,600,500,600,450,600,500,600,450,600,450,650,450,600,450,650,450,600,450,650,450,600,450,600,500,600,450,600,500,1700,450,1700,500,1700,450,1700,500,1700,450,1700,450,1750,450,1700,450};

I'm looking for a way to convert an serial input like 4350,4450,450,1700,450,650... or 4350 4450 450 1700 450 650... into this unsigned int array.

Could someone guide me to do this?

Thanks and best regards.

Daniel

Could someone guide me to do this?

What part are you having trouble with? Where IS your code?