Paso 1: Se trata de la conexión y el código
int A = 22;int B = 23; int C = 24; int D = 25; int E = 26; int F = 27; int G = 28; int H = 29; int I = 30; int J = 31; int K = 32; int L = 33; int M = 34; int N = 35; int O = 36; int P = 37; int Q = 38; int R = 39; int S = 40; int T = 41; int U = 42; int V = 43; int W = 44; int X = 45; int Y = 46; int Z = 47; int AA = 48; int AB = 49; int AC = 50; int AD = 51; int AE = 52; int AF = 53;int i = 0; int incomingByte[32];void setup() { Serial.begin(9600); pinMode(A, OUTPUT); pinMode(B, OUTPUT); pinMode(C, OUTPUT); pinMode(D, OUTPUT); pinMode(E, OUTPUT); pinMode(F, OUTPUT); pinMode(G, OUTPUT); pinMode(H, OUTPUT); pinMode(I, OUTPUT); pinMode(J, OUTPUT); pinMode(K, OUTPUT); pinMode(L, OUTPUT); pinMode(M, OUTPUT); pinMode(N, OUTPUT); pinMode(O, OUTPUT); pinMode(P, OUTPUT); pinMode(Q, OUTPUT); pinMode(R, OUTPUT); pinMode(S, OUTPUT); pinMode(T, OUTPUT); pinMode(U, OUTPUT); pinMode(V, OUTPUT); pinMode(W, OUTPUT); pinMode(X, OUTPUT); pinMode(Y, OUTPUT); pinMode(Z, OUTPUT); pinMode(AA, OUTPUT); pinMode(AB, OUTPUT); pinMode(AC, OUTPUT); pinMode(AD, OUTPUT); pinMode(AE, OUTPUT); pinMode(AF, OUTPUT); }void loop() { if (Serial.available() >= 32) { for (int i=0; i<32;i++) { incomingByte[i] = Serial.read(); } // Arduino pins digitalWrite(A, incomingByte[0]); // Pin 2 digitalWrite(B, incomingByte[1]); // Pin 3 digitalWrite(C, incomingByte[2]); // Pin 4 digitalWrite(D, incomingByte[3]); // Pin 5 digitalWrite(E, incomingByte[4]); // Pin 6 digitalWrite(F, incomingByte[5]); // Pin 7 digitalWrite(G, incomingByte[6]); // Pin 8 digitalWrite(H, incomingByte[7]); // Pin 9 digitalWrite(I, incomingByte[8]); // Pin 10 digitalWrite(J, incomingByte[9]); // Pin 11 digitalWrite(K, incomingByte[10]); // Pin 12 digitalWrite(L, incomingByte[11]); // Pin 13 digitalWrite(M, incomingByte[12]); // Pin A0 digitalWrite(N, incomingByte[13]); // Pin A1 digitalWrite(O, incomingByte[14]); // Pin A2 digitalWrite(P, incomingByte[15]); digitalWrite(Q, incomingByte[16]); digitalWrite(R, incomingByte[17]); digitalWrite(S, incomingByte[18]); digitalWrite(T, incomingByte[19]); digitalWrite(U, incomingByte[20]); digitalWrite(V, incomingByte[21]); digitalWrite(W, incomingByte[22]); digitalWrite(X, incomingByte[23]); digitalWrite(Y, incomingByte[24]); digitalWrite(Z, incomingByte[25]); digitalWrite(AA, incomingByte[26]); digitalWrite(AB, incomingByte[27]); digitalWrite(AC, incomingByte[28]); digitalWrite(AD, incomingByte[29]); digitalWrite(AE, incomingByte[30]); digitalWrite(AF, incomingByte[31]); } }