LoginSignup
1
2

More than 5 years have passed since last update.

Arduboyメモ

Posted at

簡単なリファレンス

文字列

String mes = String("hogehoge");

数値→文字列

int count = 0;
String countStr = String(count);

ハード

arduboy.pressed(B_BUTTON)
で日本で言うAボタンの位置のボタン押が取れる

Sprite

loopの外でスプライトを定義

PROGMEM const unsigned char playerWalkLeftB[] = {
    0b00000000,
    0b10000100,
    0b11001000,
    0b00111111,
    0b00111111,
    0b01000100,
    0b11001100,
    0b00000000
};

loop内でdrawする

arduboy.drawBitmap(8, 8, playerWalkLeftB, 8, 8, 1);

arduboy.drawBitmap(x位置, y位置, sprite配列, width, height, カラー);

カラーは1が白、0が黒
大きさによって崩れることがあるので、その時は代わりにdrawSlowXYBitmapを使うと治ったりする。

1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2