SHARE
TWEET

4x4x4 LED Pattern 1

a guest May 6th, 2019 78 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include "HC4x4x4Cube.h"
  2.  
  3. const PROGMEM unsigned int aExample[][4] = {
  4.    
  5.   {0x1000, 0x1000, 0x1000, 0x1000},
  6.   {0x2000, 0x2000, 0x2000, 0x2000},
  7.   {0x4000, 0x4000, 0x4000, 0x4000},
  8.   {0x8000, 0x8000, 0x8000, 0x8000},
  9.   {0x0800, 0x0800, 0x0800, 0x0800},
  10.   {0x0400, 0x0400, 0x0400, 0x0400},
  11.   {0x0200, 0x0200, 0x0200, 0x0200},
  12.   {0x0100, 0x0100, 0x0100, 0x0100},
  13.   {0x0010, 0x0010, 0x0010, 0x0010},
  14.   {0x0020, 0x0020, 0x0020, 0x0020},
  15.   {0x0040, 0x0040, 0x0040, 0x0040},
  16.   {0x0080, 0x0080, 0x0080, 0x0080},
  17.   {0x0008, 0x0008, 0x0008, 0x0008},
  18.   {0x0004, 0x0004, 0x0004, 0x0004},
  19.   {0x0002, 0x0002, 0x0002, 0x0002},
  20.   {0x0001, 0x0001, 0x0001, 0x0001},
  21.   {0x0001, 0x0001, 0x0002, 0x0002},
  22.   {0x0001, 0x0002, 0x0004, 0x0008},
  23.   {0x0003, 0x000C, 0x0000, 0x0000},
  24.   {0x000F, 0x0000, 0x0000, 0x0000},
  25.   {0x00F0, 0x0000, 0x0000, 0x0000},
  26.   {0x0F00, 0x0000, 0x0000, 0x0000},
  27.   {0xF000, 0x0000, 0x0000, 0x0000},
  28.   {0x0000, 0xF000, 0x0000, 0x0000},
  29.   {0x0000, 0x0F00, 0x0000, 0x0000},
  30.   {0x0000, 0x00F0, 0x0000, 0x0000},
  31.   {0x0000, 0x000F, 0x0000, 0x0000},
  32.   {0x0000, 0x0000, 0x000F, 0x0000},
  33.   {0x0000, 0x0000, 0x00F0, 0x0000},
  34.   {0x0000, 0x0000, 0x0F00, 0x0000},
  35.   {0x0000, 0x0000, 0xF000, 0x0000},
  36.   {0x0000, 0x0000, 0x0000, 0xF000},
  37.   {0x0000, 0x0000, 0x0000, 0x0F00},
  38.   {0x0000, 0x0000, 0x0000, 0x00F0},
  39.   {0x0000, 0x0000, 0x0000, 0x000F},
  40.   {0x0000, 0x0000, 0x000C, 0x0003},
  41.   {0x0008, 0x0004, 0x0002, 0x0001},
  42.   {0x0002, 0x0002, 0x0001, 0x0001},
  43.   {0x0001, 0x0001, 0x0001, 0x0001},
  44.   {0x0010, 0x0010, 0x0010, 0x0010},
  45.   {0x0100, 0x0100, 0x0100, 0x0100},
  46.  
  47. };
  48.                      
  49. const _Pattern_info Example = {41,aExample[0]};            
  50.  
  51. #define SPEED 50
  52.  
  53. void setup()
  54. {
  55.   CubeInit();
  56. }
  57.  
  58. void loop()
  59. {
  60.   CubePlayPattern(Example, SPEED, 50);
  61. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top