Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
2つの変数(inとin2)を取り、それらをまとめたいと思います。次に例を示します。
in = 1; in2 = 3; pin = in.in2; // I want this to set pin to 13
arduino IDEは、inはクラスではないと言っているので、これを実現するためにどの構文を使用しますか?
編集:私はそれを行うための別の方法を考え出しました、あなたはただ取ることができますin。10を掛けて、プラスpinの合計に設定しますinin2
in
pin
in2
これを試してみてください。私はCで書きましたが、要点はわかります。2 つの項目を文字列に変換し、連結して整数として解析します。
pin = int.Parse((string)in + (string)in2);