パンチングマシンをプログラミングで動かす!
どう動かすか
パンチングマシンの詳しい説明はYoutubeをご覧ください!
まず、プログラミングする前に動作の流れを確認します。
1. スイッチを押すとコンベアーが正転駆動
2. パンチングマシンの手前のフォトトランジスタ (明るさセンサー)の入力を受けてコンベアー停 止
3. パンチングマシンが降下
4. パンチングマシンの下にあるスイッチで降下
5. パンチングマシンが上昇
6. パンチングマシンの上にあるスイッチで停止
7 .コンベアー逆転駆動
8. フォトトランジスタの前でコンベアー停止
イメージがしやすい様に先に完成した動作を!
プログラムをパンチングマシン用に変更
いよいよパンチングマシンをプログラミングで動かします!
今回はパンチングマシンの入力・出力に合わせて
入力 ×7 出力 ×7 とします。
パート1と同様に1~7までの入力・出力に対応するプログラムを作成します。
- #include <piControlIf.h>
- #include <piControl.h>
- #include <string.h>
- #include <stdio.h>
- #include <unistd.h>
- // === 1 ===
- int i = 0;
- int iLastInputValue = 0;
- char *pchInput = NULL;
- char *pchOutput = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn = {"", 0, 0, 0};
- SPIVariable spiVariableOut = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn = {0, 0, 0};
- SPIValue sValueOut = {0, 0, 0};
- // === 2 ===
- int i2 = 0;
- int iLastInputValue2 = 0;
- char *pchInput2 = NULL;
- char *pchOutput2 = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn2 = {"", 0, 0, 0};
- SPIVariable spiVariableOut2 = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn2 = {0, 0, 0};
- SPIValue sValueOut2 = {0, 0, 0};
- //=== 3 ===
- int i3 = 0;
- int iLastInputValue3 = 0;
- char *pchInput3 = NULL;
- char *pchOutput3 = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn3 = {"", 0, 0, 0};
- SPIVariable spiVariableOut3 = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn3 = {0, 0, 0};
- SPIValue sValueOut3 = {0, 0, 0};
- // === 4 ===
- int i4 = 0;
- int iLastInputValue4 = 0;
- char *pchInput4 = NULL;
- char *pchOutput4 = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn4 = {"", 0, 0, 0};
- SPIVariable spiVariableOut4 = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn4 = {0, 0, 0};
- SPIValue sValueOut4 = {0, 0, 0};
- // === 5 ===
- int i5 = 0;
- int iLastInputValue5 = 0;
- char *pchInput5 = NULL;
- char *pchOutput5 = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn5 = {"", 0, 0, 0};
- SPIVariable spiVariableOut5 = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn5 = {0, 0, 0};
- SPIValue sValueOut5 = {0, 0, 0};
- //=== 6 ===
- int i6 = 0;
- int iLastInputValue6 = 0;
- char *pchInput6 = NULL;
- char *pchOutput6 = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn6 = {"", 0, 0, 0};
- SPIVariable spiVariableOut6 = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn6 = {0, 0, 0};
- SPIValue sValueOut6 = {0, 0, 0};
- // === 7 ===
- int i7 = 0;
- int iLastInputValue7 = 0;
- char *pchInput7 = NULL;
- char *pchOutput7 = NULL;
- // structures containing variable information: Name, Offset, Bit, Length
- SPIVariable spiVariableIn7 = {"", 0, 0, 0};
- SPIVariable spiVariableOut7 = {"", 0, 0, 0};
- // structures containing variable value: Offset, Bit, Value
- SPIValue sValueIn7 = {0, 0, 0};
- SPIValue sValueOut7 = {0, 0, 0};
そして次にそれぞれの関数の作成とプロトタイプ宣言をします。
- int IO_1(void);
- int IO_2(void);
- int IO_3(void);
- int IO_4(void);
- int IO_5(void);
- int IO_6(void);
- int IO_7(void);
- // --- 1 ---
- int IO_1(void) {
- i5 = piControlGetBitValue(&sValueIn5); // PiBridge - read input pin
- if(iLastInputValue5 != sValueIn5.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput, sValueIn.i8uValue)
- if(0 == iLastInputValue5) // and was pressed before
- { // switch light
- sValueOut.i8uValue = ~sValueOut.i8uValue;
- // PiBridge - set output pin
- i5 = piControlSetBitValue(&sValueOut);
- printf("%-32s : %s \n", pchOutput, sValueOut.i8uValue ? "On" : "Off");
- if(0 != i5)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i5);
- return -1;
- }
- }
- }
- iLastInputValue5 = sValueIn5.i8uValue; // remember last input value
- return 0;
- }
- // --- 2 ---
- int IO_2(void) {
- i2 = piControlGetBitValue(&sValueIn2); // PiBridge - read input pin
- if(iLastInputValue2 != sValueIn2.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput2, sValueIn2.i8uValue);
- if(0 == sValueIn2.i8uValue) // if button is released
- {
- if(1 == iLastInputValue2) // and was pressed before
- { // switch light
- sValueOut.i8uValue = ~sValueOut.i8uValue;
- // PiBridge - set output pin
- i2 = piControlSetBitValue(&sValueOut);
- printf("%-32s : %s \n", pchOutput,sValueOut.i8uValue ? "On" : "Off");
- sleep(0.1);
- i2 = piControlGetBitValue(&sValueIn2); // PiBridge - read input pin
- if(iLastInputValue2 != sValueIn2.i8uValue) // if button state changed
- {
- if(0 == sValueIn2.i8uValue) // if button is released
- { // show the change
- printf("%-32s : %d \n", pchInput, sValueIn2.i8uValue);
- if(1 == iLastInputValue2) // and was pressed before
- // switch light
- sValueOut3.i8uValue = ~sValueOut3.i8uValue; // PiBridge - set output pi
- i2 = piControlSetBitValue(&sValueOut3);
- printf("%-32s : %s \n", pchOutput3, sValueOut3.i8uValue ? "On" : "Off");
- if(0 != i2)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i2);
- return -1;
- }
- }
- }
- }
- IO_4();
- }
- }
- }
- iLastInputValue2 = sValueIn2.i8uValue; // remember last input value
- //printf("=== OK 2 ====");
- return 0;
- // --- 3---
- int IO_3(void) {
- i3 = piControlGetBitValue(&sValueIn3); // PiBridge - read input pin
- if(iLastInputValue3 != sValueIn3.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput3, sValueIn3.i8uValue);
- if(0 == iLastInputValue3) // and was pressed before
- { // switch light
- sValueOut4.i8uValue = ~sValueOut4.i8uValue;
- // PiBridge - set output pin
- i3 = piControlSetBitValue(&sValueOut4);
- printf("%-32s : %s \n", pchOutput4, sValueOut4.i8uValue ? "On" : "Off");
- sleep(0.5);
- // -----
- i3 = piControlGetBitValue(&sValueIn3); // PiBridge - read input pin
- if(iLastInputValue3 != sValueIn3.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput2, sValueIn2.i8uValue);
- if(0 == iLastInputValue3) // and was pressed before
- { // switch light
- sValueOut2.i8uValue = ~sValueOut2.i8uValue;
- // PiBridge - set output pin
- i3 = piControlSetBitValue(&sValueOut2);
- printf("%-32s : %s \n", pchOutput2, sValueOut2.i8uValue ? "On" : "Off");
- if(0 != i3)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i3);
- return -1;
- }
- }
- }
- }
- iLastInputValue4 = sValueIn4.i8uValue; // remember last input value
- iLastInputValue3 = sValueIn3.i8uValue; // remember last input value
- IO_5();
- }
- //printf("=== OK 2 ====");
- return 0;
- }
- // --- 4 ---
- int IO_4(void) {
- i4 = piControlGetBitValue(&sValueIn4); // PiBridge - read input pin
- if(iLastInputValue4 != sValueIn4.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput4, sValueIn4.i8uValue);
- if(0 == iLastInputValue4) // and was pressed before
- { // switch light
- sValueOut3.i8uValue = ~sValueOut3.i8uValue;
- // PiBridge - set output pin
- i4 = piControlSetBitValue(&sValueOut3);
- printf("%-32s : %s \n", pchOutput3, sValueOut3.i8uValue ? "On" : "Off");
- sleep(0.1);
- i4 = piControlGetBitValue(&sValueIn4); // PiBridge - read input pin
- if(iLastInputValue4 != sValueIn4.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput4, sValueIn4.i8uValue);
- if(0 == iLastInputValue4) // and was pressed before
- { // switch light
- sValueOut4.i8uValue = ~sValueOut4.i8uValue;
- // PiBridge - set output pin
- i4 = piControlSetBitValue(&sValueOut4);
- printf("%-32s : %s \n", pchOutput4, sValueOut4.i8uValue ? "On" : "Off");
- if(0 != i4)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i4);
- return -1;
- }
- }
- }
- }
- IO_3();
- }
- iLastInputValue4 = sValueIn4.i8uValue; // remember last input value
- return 0;
- }
- // --- 5---
- int IO_5(void) {
- i = piControlGetBitValue(&sValueIn); // PiBridge - read input pin
- if(0 != i) // handle error
- {
- fprintf(stderr, "Error: piControlGetBitValue() returned %d\n", i);
- return -1;
- }
- if(iLastInputValue != sValueIn.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput, sValueIn.i8uValue);
- if(0 == sValueIn.i8uValue) // if button is released
- {
- if(1 == iLastInputValue) // and was pressed before
- { // switch light
- sValueOut2.i8uValue = ~sValueOut2.i8uValue;
- // PiBridge - set output pin
- i = piControlSetBitValue(&sValueOut2);
- printf("%-32s : %s \n", pchOutput2, sValueOut2.i8uValue ? "On" : "Off");
- if(0 != i2)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i2);
- return -1;
- }
- }
- }
- }
- iLastInputValue = sValueIn.i8uValue; // remember last input value
- }
- // --- 6 ---
- int IO_6(void) {
- i6 = piControlGetBitValue(&sValueIn6); // PiBridge - read input pin
- if(0 != i6) // handle error
- {
- fprintf(stderr, "Error: piControlGetBitValue() returned %d\n", i6);
- return -1;
- }
- if(iLastInputValue6 != sValueIn6.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput6, sValueIn6.i8uValue);
- if(0 == sValueIn6.i8uValue) // if button is released
- {
- if(1 == iLastInputValue6) // and was pressed before
- { // switch light
- sValueOut6.i8uValue = ~sValueOut6.i8uValue;
- // PiBridge - set output pin
- i6 = piControlSetBitValue(&sValueOut6);
- printf("%-32s : %s \n", pchOutput6, sValueOut6.i8uValue ? "On" : "Off");
- if(0 != i6)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i6);
- return -1;
- }
- }
- }
- }
- iLastInputValue6 = sValueIn6.i8uValue; // remember last input value
- }
- // --- 7 ---
- int IO_7(void) {
- i7 = piControlGetBitValue(&sValueIn7); // PiBridge - read input pin
- if(0 != i7) // handle error
- {
- fprintf(stderr, "Error: piControlGetBitValue() returned %d\n", i7);
- return -1;
- }
- if(iLastInputValue7 != sValueIn7.i8uValue) // if button state changed
- { // show the change
- printf("%-32s : %d \n", pchInput7, sValueIn7.i8uValue);
- if(0 == sValueIn7.i8uValue) // if button is released
- {
- if(1 == iLastInputValue7) // and was pressed before
- { // switch light
- sValueOut7.i8uValue = ~sValueOut7.i8uValue;
- // PiBridge - set output pin
- i7 = piControlSetBitValue(&sValueOut7);
- printf("%-32s : %s \n", pchOutput7, sValueOut7.i8uValue ? "On" : "Off");
- if(0 != i7)
- {
- fprintf(stderr, "Error: piControlSetBitValue() returned %d\n", i7);
- return -1;
- }
- }
- }
- }
- iLastInputValue7 = sValueIn7.i8uValue; // remember last input value
- }
以下はメインプログラムです。
- int main(int argc, char ** argv)
- {
- pchInput = argv[1]; // PiCtory input pin for Switch
- pchOutput = argv[2]; // PiCtory output pin for Light
- pchInput2 = argv[3]; // PiCtory input pin for Switch
- pchOutput2 = argv[4]; // PiCtory output pin for Light
- pchInput3 = argv[5]; // PiCtory input pin for Switch
- pchOutput3 = argv[6]; // PiCtory output pin for Light
- pchInput4 = argv[7]; // PiCtory input pin for Switch
- pchOutput4 = argv[8]; // PiCtory output pin for Light
- pchInput5 = argv[9]; // PiCtory input pin for Switch
- pchOutput5 = argv[10]; // PiCtory output pin for Light
- pchInput6 = argv[11]; // PiCtory input pin for Switch
- pchOutput6 = argv[12]; // PiCtory output pin for Light
- pchInput7 = argv[13]; // PiCtory input pin for Switch
- pchOutput7 = argv[14]; // PiCtory output pin for Light
- strncpy(spiVariableIn.strVarName, pchInput, sizeof(spiVariableIn.strVarName));
- strncpy(spiVariableOut.strVarName, pchOutput, sizeof(spiVariableOut.strVarName));
- strncpy(spiVariableIn2.strVarName, pchInput2, sizeof(spiVariableIn2.strVarName));
- strncpy(spiVariableOut2.strVarName, pchOutput2, sizeof(spiVariableOut2.strVarName));
- strncpy(spiVariableIn3.strVarName, pchInput3, sizeof(spiVariableIn3.strVarName));
- strncpy(spiVariableOut3.strVarName, pchOutput3, sizeof(spiVariableOut3.strVarName));
- strncpy(spiVariableIn4.strVarName, pchInput4, sizeof(spiVariableIn4.strVarName));
- strncpy(spiVariableOut4.strVarName, pchOutput4, sizeof(spiVariableOut4.strVarName));
- strncpy(spiVariableIn5.strVarName, pchInput5, sizeof(spiVariableIn5.strVarName));
- strncpy(spiVariableOut5.strVarName, pchOutput5, sizeof(spiVariableOut5.strVarName));
- strncpy(spiVariableIn6.strVarName, pchInput6, sizeof(spiVariableIn6.strVarName));
- strncpy(spiVariableOut6.strVarName, pchOutput6, sizeof(spiVariableOut6.strVarName));
- strncpy(spiVariableIn7.strVarName, pchInput7, sizeof(spiVariableIn7.strVarName));
- strncpy(spiVariableOut7.strVarName, pchOutput7, sizeof(spiVariableOut7.strVarName));
-
- i = piControlGetVariableInfo(&spiVariableIn); // PiBridge - get variable info
- if(0 != i) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i, spiVariableIn.strVarName);
- return -1;
- }
-
- i2 = piControlGetVariableInfo(&spiVariableIn2); // PiBridge - get variable info
- if(0 != i2) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i2, spiVariableIn2.strVarName);
- return -1;
- }
-
- i3 = piControlGetVariableInfo(&spiVariableIn3); // PiBridge - get variable info
- if(0 != i3) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i3, spiVariableIn3.strVarName);
- return -1;
- }
-
- i4 = piControlGetVariableInfo(&spiVariableIn4); // PiBridge - get variable info
- if(0 != i4) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i4, spiVariableIn4.strVarName);
- return -1;
- }
-
- i5 = piControlGetVariableInfo(&spiVariableIn5); // PiBridge - get variable info
- if(0 != i5) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i5, spiVariableIn5.strVarName);
- return -1;
- }
-
- i6 = piControlGetVariableInfo(&spiVariableIn6); // PiBridge - get variable info
- if(0 != i6) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i6, spiVariableIn6.strVarName);
- return -1;
- }
-
- i7 = piControlGetVariableInfo(&spiVariableIn7); // PiBridge - get variable info
- if(0 != i7) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i7, spiVariableIn7.strVarName);
- return -1;
- }
- // =============================
- i = piControlGetVariableInfo(&spiVariableOut); // PiBridge - get variable info
- if(0 != i) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i, spiVariableOut.strVarName);
- return -1;
- }
-
- i2 = piControlGetVariableInfo(&spiVariableOut2); // PiBridge - get variable info
- if(0 != i2) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i2, spiVariableOut2.strVarName);
- return -1;
- }
-
- i3 = piControlGetVariableInfo(&spiVariableOut3); // PiBridge - get variable info
- if(0 != i3) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i3, spiVariableOut3.strVarName);
- return -1;
- }
- i4 = piControlGetVariableInfo(&spiVariableOut4); // PiBridge - get variable info
- if(0 != i4) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i4, spiVariableOut4.strVarName);
- return -1;
- }
-
- i5 = piControlGetVariableInfo(&spiVariableOut5); // PiBridge - get variable info
- if(0 != i5) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i5, spiVariableOut.strVarName);
- return -1;
- }
-
- i6 = piControlGetVariableInfo(&spiVariableOut6); // PiBridge - get variable info
- if(0 != i6) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i6, spiVariableOut.strVarName);
- return -1;
- }
- i7 = piControlGetVariableInfo(&spiVariableOut7); // PiBridge - get variable info
- if(0 != i7) // handle error
- {
- fprintf(stderr, "Error: piControlGetVariableInfo() returned %d for variable '%s' \n",
- i7, spiVariableOut.strVarName);
- return -1;
- }
- // =============================
- sValueIn.i16uAddress = spiVariableIn.i16uAddress;
- sValueIn.i8uBit = spiVariableIn.i8uBit;
- sValueIn.i8uValue = 0;
- sValueOut.i16uAddress = spiVariableOut.i16uAddress;
- sValueOut.i8uBit = spiVariableOut.i8uBit;
- sValueOut.i8uValue = 0;
- // --------------- 2
- sValueIn2.i16uAddress = spiVariableIn2.i16uAddress;
- sValueIn2.i8uBit = spiVariableIn2.i8uBit;
- sValueIn2.i8uValue = 0;
- sValueOut2.i16uAddress = spiVariableOut2.i16uAddress;
- sValueOut2.i8uBit = spiVariableOut2.i8uBit;
- sValueOut2.i8uValue = 0;
- // ----------------- 3
- sValueIn3.i16uAddress = spiVariableIn3.i16uAddress;
- sValueIn3.i8uBit = spiVariableIn3.i8uBit;
- sValueIn3.i8uValue = 0;
- sValueOut3.i16uAddress = spiVariableOut3.i16uAddress;
- sValueOut3.i8uBit = spiVariableOut3.i8uBit;
- sValueOut3.i8uValue = 0;
- // ------------------- 4
- sValueIn4.i16uAddress = spiVariableIn4.i16uAddress;
- sValueIn4.i8uBit = spiVariableIn4.i8uBit;
- sValueIn4.i8uValue = 0;
- sValueOut4.i16uAddress = spiVariableOut4.i16uAddress;
- sValueOut4.i8uBit = spiVariableOut4.i8uBit;
- sValueOut4.i8uValue = 0;
- // ------------------- 5
- sValueIn5.i16uAddress = spiVariableIn5.i16uAddress;
- sValueIn5.i8uBit = spiVariableIn5.i8uBit;
- sValueIn5.i8uValue = 0;
- sValueOut5.i16uAddress = spiVariableOut5.i16uAddress;
- sValueOut5.i8uBit = spiVariableOut5.i8uBit;
- sValueOut5.i8uValue = 0;
- // ------------------- 6
- sValueIn6.i16uAddress = spiVariableIn6.i16uAddress;
- sValueIn6.i8uBit = spiVariableIn6.i8uBit;
- sValueIn6.i8uValue = 0;
- sValueOut6.i16uAddress = spiVariableOut6.i16uAddress;
- sValueOut6.i8uBit = spiVariableOut6.i8uBit;
- sValueOut6.i8uValue = 0;
- // ------------------- 7
- sValueIn7.i16uAddress = spiVariableIn7.i16uAddress;
- sValueIn7.i8uBit = spiVariableIn7.i8uBit;
- sValueIn7.i8uValue = 0;
- sValueOut7.i16uAddress = spiVariableOut7.i16uAddress;
- sValueOut7.i8uBit = spiVariableOut7.i8uBit;
- sValueOut7.i8uValue = 0;
- // -----------------
- printf("%s is running waiting for switch '%s' \n", argv[0], pchInput);
- printf("%s is running waiting for switch '%s' \n", argv[1], pchInput2);
- printf("%s is running waiting for switch '%s' \n", argv[2], pchInput3);
- printf("%s is running waiting for switch '%s' \n", argv[3], pchInput4);
- printf("%s is running waiting for switch '%s' \n", argv[4], pchInput5);
- printf("%s is running waiting for switch '%s' \n", argv[5], pchInput6);
- printf("%s is running waiting for switch '%s' \n\n\n", argv[6], pchInput7);
- while(1)
- {
- IO_1();
- IO_2();
- IO_3();
- IO_4();
- IO_5();
- IO_6();
- IO_7();
- }
- return 0;
- }
コマンドラインからプログラムの実行
demoフォルダへ移動
cd demo
piTest.c をコンパイルします。
make
プログラムを実行します!
./piTest I_1 O_1 I_2 O_2 I_3 O_3 I_4 O_4 I_5 O_5 I_6 O_6 I_7 O_7
パンチングマシンをレボリューションパイで動作させることができました!
ご覧いただきありがとうございました!