//STM32F103C8T6 programm today (main programm) Akku Atomizer V1.5 rev. Beta (must be working quickly, montag one week holidays an need better portable vaping device.. // case is so constructed that the dongle port can be connected for updating).. (same working on table atomizer with little changes) #include #include #include #include #define OLED_RESET 4 Adafruit_SSD1306 display(OLED_RESET); #define NUMFLAKES 80 #define NUMFLAKES2 80 #define NUMFLAKES3 80 #define NUMFLAKES4 80 #define NUMFLAKES5 80 #define NUMFLAKES6 500 #define NUMFLAKES7 500 #define XPOS 0 #define YPOS 1 #define DELTAY 2 #define LOGO16_GLCD_HEIGHT 16 #define LOGO16_GLCD_WIDTH 16 const unsigned char PROGMEM cat [] = { 0xF8, 0x00, 0x00, 0x78, // ##### #### 0xCC, 0x00, 0x01, 0xBC, // ## ## ## #### 0xB3, 0x00, 0x06, 0x24, // # ## ## ## # # 0x99, 0x80, 0x0C, 0xC4, // # ## ## ## ## # 0x8C, 0xC0, 0x31, 0x84, // # ## ## ## ## # 0x84, 0x60, 0x21, 0x04, // # # ## # # # 0x84, 0x20, 0x02, 0x08, // # # # # # 0x84, 0x00, 0x02, 0x08, // # # # # 0x80, 0x00, 0x00, 0x18, // # ## 0xC3, 0x80, 0x0C, 0x10, // ## ### ## # 0x44, 0x40, 0x12, 0x10, // # # # # # # 0x4C, 0x40, 0x31, 0x20, // # ## # ## # # 0x08, 0x60, 0x21, 0x20, // # ## # # # 0x08, 0x20, 0x41, 0x00, // # # # # 0x08, 0x20, 0x41, 0x00, // # # # # 0x00, 0x00, 0x00, 0x00, // 0x00, 0x00, 0x00, 0x00, // 0x07, 0x06, 0x00, 0x00, // ### ## 0x18, 0xCF, 0x0F, 0x80, // ## ## #### ##### 0x61, 0xE6, 0x3C, 0x60, // ## #### ## #### ## 0x86, 0x12, 0x43, 0x10, // # ## # # # ## # 0x18, 0x00, 0x00, 0x80, // ## # 0x20, 0x40, 0x20, 0x40, // # # # # 0x00, 0x84, 0x10, 0x00, // # # # 0x00, 0x8E, 0x20, 0x00, // # ### # 0x00, 0x71, 0xC0, 0x00, // ### ### }; const unsigned char PROGMEM cat2 [] = { 0x3E, 0x00, 0x01, 0xA0, // ##### ## # 0x72, 0x00, 0x02, 0x14, // ### # # # # 0x41, 0x80, 0x0C, 0xC4, // # ## ## ## # 0x4C, 0xC0, 0x11, 0x84, // # ## ## # ## # 0xC4, 0x40, 0x21, 0x04, // ## # # # # # 0x84, 0x20, 0x02, 0x04, // # # # # # 0x84, 0x00, 0x00, 0x04, // # # # 0x83, 0xC0, 0x02, 0x0C, // # #### # ## 0x87, 0xE0, 0x1E, 0x08, // # ###### #### # 0x45, 0xC0, 0x3E, 0x18, // # # ### ##### ## 0x4D, 0xC0, 0x3F, 0x10, // # ## ### ###### # 0x08, 0xA0, 0x27, 0x10, // # # # # ### # 0x00, 0x20, 0x61, 0x30, // # ## # ## 0x0F, 0xC0, 0x71, 0x00, // ###### ### # 0x08, 0x20, 0x1F, 0x00, // # # ##### 0x00, 0x00, 0x03, 0x00, // ## 0x00, 0x06, 0x00, 0x00, // ## 0x15, 0x0F, 0x05, 0x80, // # # # #### # ## 0x60, 0xE7, 0x38, 0x60, // ## ### ### ### ## 0x43, 0x02, 0x42, 0x00, // # ## # # # 0x48, 0x00, 0x00, 0x80, // # # # 0x98, 0x60, 0x60, 0x40, // # ## ## ## # 0x10, 0xC4, 0x30, 0x00, // # ## # ## 0x20, 0x8E, 0x30, 0x00, // # # ### ## 0x00, 0xFB, 0xE0, 0x00, // ##### ##### }; const unsigned char PROGMEM cat3 [] = { 0x1F, 0x00, 0x01, 0xF4, // ##### ##### # 0x36, 0xE0, 0x05, 0x3C, // ## ## ### # # #### 0x23, 0x20, 0x00, 0x64, // # ## # ## # 0x40, 0x98, 0x00, 0x44, // # # ## # # 0x40, 0x48, 0x01, 0x80, // # # # ## 0x40, 0x00, 0x00, 0x04, // # # 0x43, 0xE0, 0x0A, 0x04, // # ##### # # # 0x43, 0xF0, 0x1E, 0x04, // # ###### #### # 0x4E, 0xF0, 0x39, 0x84, // # ### #### ### ## # 0x4B, 0xE0, 0x37, 0x80, // # # ##### ## #### 0x05, 0xF0, 0x2F, 0x8C, // # ##### # ##### ## 0x0F, 0xD0, 0x3B, 0x80, // ###### # ### ### 0x08, 0xF0, 0x27, 0x90, // # #### # #### # 0x08, 0x00, 0x20, 0xA0, // # # # # 0x07, 0xE0, 0x3B, 0x80, // ###### ### ### 0x07, 0x04, 0x00, 0x00, // ### # 0x00, 0x06, 0x00, 0x00, // ## 0x1B, 0x0F, 0x8F, 0x80, // ## ## ##### ##### 0x60, 0xA7, 0x34, 0x60, // ## # # ### ## # ## 0x45, 0x00, 0x03, 0x10, // # # # ## # 0x48, 0x02, 0x00, 0x80, // # # # # 0x98, 0x10, 0x40, 0x40, // # ## # # # 0x10, 0x17, 0x40, 0x00, // # # ### # 0x00, 0x1D, 0xC0, 0x00, // ### ### }; const unsigned char PROGMEM nyan1 [] = { 0x07, 0xE0, 0x00, 0x79, 0xFF, 0xFF, 0xE0, 0x00, // ###### #### #################### 0x1C, 0x38, 0x03, 0xCE, 0x00, 0x00, 0x10, 0x00, // ### ### #### ### # 0xF0, 0x0F, 0x1E, 0x04, 0x00, 0x00, 0x08, 0x00, // #### #### #### # # 0x00, 0x01, 0xF0, 0x04, 0x03, 0x00, 0x08, 0x00, // ##### # ## # 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x00, 0x11, 0x8B, 0x00, // # # ## # ## 0x0F, 0xF8, 0x07, 0xF4, 0x00, 0x39, 0x8B, 0x80, // ######### ####### # ### ## # ### 0x38, 0x0C, 0x0C, 0x1C, 0x00, 0x6C, 0x0C, 0xC0, // ### ## ## ### ## ## ## ## 0xE0, 0x07, 0x1B, 0xC4, 0x02, 0x62, 0x08, 0xC0, // ### ### ## #### # # ## # # ## 0x00, 0x01, 0xE2, 0x64, 0xC0, 0x61, 0xF0, 0xC0, // #### # ## # ## ## ##### ## 0x00, 0x00, 0x03, 0x3C, 0xC0, 0x60, 0x00, 0xC0, // ## #### ## ## ## 0x00, 0x00, 0x01, 0x0C, 0x00, 0x80, 0x00, 0x20, // # ## # # 0x00, 0x00, 0x01, 0x8C, 0x00, 0x87, 0x07, 0x20, // ## ## # ### ### # 0x00, 0x00, 0x00, 0xC5, 0xC0, 0x85, 0x05, 0x20, // ## # ### # # # # # # 0x0F, 0xF0, 0x00, 0x7C, 0x00, 0x84, 0x74, 0x20, // ######## ##### # # ### # # 0x18, 0x38, 0x03, 0xFC, 0x04, 0xB0, 0x21, 0xA0, // ## ### ######## # # ## # ## # 0xF0, 0x0E, 0x0E, 0x04, 0x20, 0xB1, 0x25, 0xA0, // #### ### ### # # # ## # # # ## # 0x00, 0x03, 0xF8, 0x04, 0x00, 0x61, 0xFC, 0xC0, // ####### # ## ####### ## 0x00, 0x00, 0x00, 0x0E, 0x00, 0x10, 0x01, 0x00, // ### # # 0x00, 0x00, 0x00, 0x11, 0xFF, 0xFF, 0xFE, 0x00, // # ######################## 0x0F, 0xE0, 0x00, 0x33, 0x24, 0x11, 0xA4, 0x00, // ####### ## ## # # # ## # # 0x38, 0x3C, 0x07, 0xF3, 0x24, 0x19, 0xA4, 0x00, // ### #### ####### ## # # ## ## # # 0xE0, 0x07, 0x0C, 0x3E, 0x38, 0x0F, 0x98, 0x00, // ### ### ## ##### ### ##### ## 0x00, 0x01, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, // ###### }; const unsigned char PROGMEM nyan2 [] = { 0x00, 0x00, 0x00, 0x01, 0xFF, 0xFF, 0xE0, 0x00, // #################### 0x1F, 0xF8, 0x03, 0xFE, 0x00, 0x00, 0x10, 0x00, // ########## ######### # 0xF0, 0x0F, 0xFE, 0x04, 0x00, 0x00, 0x08, 0x00, // #### ########### # # 0x00, 0x00, 0x00, 0x04, 0x01, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x00, 0x3D, 0x89, 0xC0, // # #### ## # ### 0x00, 0x00, 0x00, 0x04, 0x00, 0x3D, 0x89, 0xC0, // # #### ## # ### 0x00, 0x00, 0x00, 0x04, 0x00, 0x22, 0x0A, 0x20, // # # # # # # 0x1F, 0xF8, 0x07, 0xFC, 0x02, 0x21, 0x8C, 0x20, // ########## ######### # # ## ## # 0xF0, 0x0F, 0xFD, 0x84, 0x40, 0x20, 0x78, 0x20, // #### ########## ## # # # #### # 0x00, 0x00, 0x02, 0x44, 0x00, 0x20, 0x00, 0x20, // # # # # # 0x00, 0x00, 0x02, 0x64, 0x01, 0x60, 0x00, 0x10, // # ## # # ## # 0x00, 0x00, 0x02, 0x7C, 0x01, 0x40, 0x00, 0x10, // # ##### # # # 0x00, 0x00, 0x01, 0x04, 0xC0, 0x40, 0x81, 0x10, // # # ## # # # # 0x00, 0x00, 0x00, 0xC4, 0x00, 0x41, 0x8B, 0x10, // ## # # ## # ## # 0x1F, 0xF8, 0x01, 0xFC, 0x04, 0x4C, 0x00, 0x70, // ########## ####### # # ## ### 0xF8, 0x0F, 0xFF, 0x04, 0x20, 0x6C, 0x92, 0x70, // ##### ############ # # ## ## # # # ### 0x00, 0x00, 0x00, 0x04, 0x00, 0x30, 0xFE, 0x20, // # ## ####### # 0x00, 0x00, 0x00, 0x06, 0x00, 0x10, 0x00, 0xC0, // ## # ## 0x00, 0x00, 0x00, 0x09, 0xFF, 0xFF, 0xFF, 0x00, // # ######################### 0x00, 0x00, 0x00, 0x09, 0x44, 0x08, 0x62, 0x00, // # # # # # ## # 0x3F, 0xFC, 0x07, 0xF9, 0x64, 0x0C, 0x72, 0x00, // ############ ######## # ## # ## ### # 0xE0, 0x07, 0xFC, 0x0E, 0x3C, 0x03, 0xCE, 0x00, // ### ######### ### #### #### ### }; const unsigned char PROGMEM nyan3 [] = { 0xC0, 0x1F, 0xF0, 0x01, 0xFF, 0xFF, 0xE0, 0x00, // ## ######### #################### 0x7F, 0xF0, 0x1F, 0xFE, 0x00, 0x00, 0x10, 0x00, // ########### ############ # 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x08, 0x00, // # # 0x00, 0x00, 0x00, 0x04, 0x01, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x08, 0x00, // # # # 0xE0, 0x1F, 0xF0, 0x04, 0x00, 0x1D, 0x89, 0xC0, // ### ######### # ### ## # ### 0x3F, 0xF0, 0x1F, 0xFC, 0x00, 0x22, 0x0A, 0x20, // ########## ########### # # # # # 0x00, 0x00, 0x00, 0x04, 0x02, 0x21, 0x8C, 0x20, // # # # ## ## # 0x00, 0x00, 0x00, 0x04, 0x00, 0x20, 0x78, 0x20, // # # #### # 0x00, 0x00, 0x00, 0x04, 0x00, 0x20, 0x00, 0x20, // # # # 0x00, 0x00, 0x00, 0x04, 0x00, 0x20, 0x00, 0x20, // # # # 0x00, 0x00, 0x00, 0x0C, 0x01, 0x21, 0x83, 0x10, // ## # # ## ## # 0x00, 0x00, 0x00, 0xFC, 0xE0, 0x22, 0x85, 0x10, // ###### ### # # # # # # 0x00, 0x1F, 0xF3, 0x04, 0x00, 0x22, 0x95, 0x10, // ######### ## # # # # # # # # 0x00, 0x30, 0x1A, 0x3C, 0x04, 0x3C, 0x00, 0x70, // ## ## # #### # #### ### 0x7F, 0xF0, 0x0F, 0xFC, 0x20, 0x3C, 0x92, 0x70, // ########### ########## # #### # # # ### 0xC0, 0x00, 0x03, 0xF4, 0x20, 0x70, 0xFE, 0x20, // ## ###### # # ### ####### # 0x00, 0x00, 0x00, 0x06, 0x00, 0x10, 0x00, 0xC0, // ## # ## 0x00, 0x00, 0x00, 0x05, 0xFF, 0xFF, 0xFF, 0x00, // # ######################### 0xF0, 0x3F, 0xF8, 0x05, 0xFF, 0xFF, 0xFF, 0x00, // #### ########### # ######################### 0x1F, 0xE0, 0x0F, 0xFC, 0xC2, 0x02, 0x29, 0x00, // ######## ########## ## # # # # # 0x00, 0x00, 0x00, 0x07, 0x1E, 0x01, 0xE7, 0x00, // ### #### #### ### }; const unsigned char PROGMEM nyan4 [] = { 0x00, 0x0F, 0xE0, 0x00, 0x00, 0x00, 0x00, 0x00, // ####### 0xC0, 0x18, 0x30, 0x01, 0xFF, 0xFF, 0xE0, 0x00, // ## ## ## #################### 0x70, 0x70, 0x1C, 0x1E, 0x00, 0x00, 0x10, 0x00, // ### ### ### #### # 0x1F, 0xC0, 0x07, 0x74, 0x00, 0x05, 0x08, 0x00, // ####### ### ### # # # # 0x00, 0x00, 0x01, 0xC4, 0x01, 0x07, 0x08, 0x00, // ### # # ### # 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x08, 0x00, // # # # 0x00, 0x0F, 0xE0, 0x04, 0x20, 0x00, 0x08, 0x00, // ####### # # # 0xC0, 0x18, 0x30, 0x04, 0x00, 0x3C, 0x09, 0xC0, // ## ## ## # #### # ### 0x70, 0x70, 0x1C, 0x1C, 0x00, 0x22, 0x0A, 0x20, // ### ### ### ### # # # # # 0x1F, 0xC0, 0x07, 0xF4, 0x3A, 0x21, 0x8C, 0x20, // ####### ####### # ### # # ## ## # 0x00, 0x00, 0x00, 0x04, 0x30, 0x20, 0x78, 0x20, // # ## # #### # 0x00, 0x00, 0x00, 0x04, 0x00, 0x20, 0x00, 0x20, // # # # 0x00, 0x00, 0x00, 0x04, 0x00, 0x20, 0x00, 0x20, // # # # 0x00, 0x00, 0x00, 0x7C, 0x01, 0x63, 0x81, 0x10, // ##### # ## ### # # 0x00, 0x07, 0xC0, 0xC4, 0xC0, 0x63, 0x93, 0x90, // ##### ## # ## ## ### # ### # 0xC0, 0x1C, 0x71, 0x84, 0x00, 0x62, 0x9A, 0x90, // ## ### ### ## # ## # # ## # # # 0x70, 0x70, 0x1F, 0x7C, 0x04, 0x7A, 0x00, 0x70, // ### ### ##### ##### # #### # ### 0x1F, 0xC0, 0x02, 0x44, 0x20, 0x7C, 0x92, 0xF0, // ####### # # # # ##### # # # #### 0x00, 0x00, 0x03, 0xC4, 0x20, 0x60, 0xFE, 0x20, // #### # # ## ####### # 0x00, 0x00, 0x01, 0x86, 0x00, 0x10, 0x00, 0xC0, // ## ## # ## 0x00, 0x0F, 0xE0, 0x09, 0xFF, 0xFF, 0xFF, 0x00, // ####### # ######################### 0xE0, 0x38, 0x78, 0x09, 0xFF, 0xFF, 0xFF, 0x00, // ### ### #### # ######################### 0x38, 0xE0, 0x0E, 0x19, 0x24, 0x0C, 0x52, 0x00, // ### ### ### ## # # # ## # # # 0x0F, 0x80, 0x03, 0xEE, 0x1C, 0x03, 0xCE, 0x00, // ##### ##### ### ### #### ### }; const unsigned char PROGMEM nyan5 [] = { 0x00, 0x00, 0x00, 0x01, 0xFF, 0xFF, 0xE0, 0x00, // #################### 0xF0, 0x0F, 0xFE, 0x02, 0x00, 0x00, 0x10, 0x00, // #### ########### # # 0x1F, 0xFC, 0x03, 0xFC, 0x00, 0x00, 0x08, 0x00, // ########### ######## # 0x00, 0x00, 0x00, 0x04, 0x03, 0x00, 0x08, 0x00, // # ## # 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x20, 0x03, 0x88, 0x00, // # # ### # 0x00, 0x00, 0x07, 0xFC, 0x00, 0x31, 0x8B, 0x00, // ######### ## ## # ## 0xF0, 0x07, 0xFC, 0x04, 0x00, 0x4C, 0x0C, 0xC0, // #### ######### # # ## ## ## 0x1F, 0xFC, 0x07, 0xFC, 0x62, 0x42, 0x08, 0xC0, // ########### ######### ## # # # # ## 0x00, 0x00, 0x07, 0xC4, 0x60, 0x41, 0xF0, 0xC0, // ##### # ## # ##### ## 0x00, 0x00, 0x0C, 0x7C, 0x00, 0x40, 0x00, 0xC0, // ## ##### # ## 0x00, 0x00, 0x0C, 0x7C, 0x00, 0x40, 0x00, 0xC0, // ## ##### # ## 0x00, 0x00, 0x0F, 0x0C, 0x01, 0x80, 0x00, 0x20, // #### ## ## # 0x00, 0x00, 0x01, 0xF4, 0xC0, 0x8E, 0x27, 0x20, // ##### # ## # ### # ### # 0x00, 0x00, 0x00, 0x3C, 0x00, 0x8A, 0x35, 0x20, // #### # # # ## # # # 0x00, 0x00, 0x00, 0x04, 0x04, 0xB0, 0x00, 0xE0, // # # # ## ### 0x00, 0x00, 0x03, 0xFC, 0x20, 0xB2, 0x45, 0xE0, // ######## # # ## # # # #### 0xF8, 0x0F, 0xFE, 0x0C, 0x20, 0x43, 0xFC, 0xC0, // ##### ########### ## # # ######## ## 0x0F, 0xF8, 0x00, 0x3E, 0x00, 0x20, 0x01, 0x00, // ######### ##### # # 0x00, 0x00, 0x00, 0x43, 0xFF, 0xFF, 0xFE, 0x00, // # ######################### 0x00, 0x00, 0x07, 0xC3, 0xFF, 0xFF, 0xFE, 0x00, // ##### ######################### 0xE0, 0x07, 0xFC, 0x45, 0x10, 0x12, 0x48, 0x00, // ### ######### # # # # # # # # 0x3F, 0xFC, 0x07, 0xF8, 0xE0, 0x1E, 0x38, 0x00, // ############ ######## ### #### ### }; const unsigned char PROGMEM nyan6 [] = { 0x3F, 0xF8, 0x03, 0xFF, 0xFF, 0xFF, 0xE0, 0x00, // ########### ############################# 0xF0, 0x0F, 0xFE, 0x02, 0x00, 0x00, 0x10, 0x00, // #### ########### # # 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x08, 0x00, // # # 0x00, 0x00, 0x00, 0x04, 0x01, 0x00, 0x08, 0x00, // # # # 0x00, 0x00, 0x00, 0x04, 0x60, 0x30, 0x0B, 0x00, // # ## ## # ## 0x00, 0x00, 0x00, 0x04, 0x60, 0x31, 0x8B, 0x00, // # ## ## ## # ## 0x3F, 0xFC, 0x03, 0xFC, 0x00, 0x4D, 0x8C, 0xC0, // ############ ######## # ## ## ## ## 0xF0, 0x07, 0xFE, 0x04, 0x00, 0x42, 0x08, 0xC0, // #### ########## # # # # ## 0x00, 0x00, 0x01, 0xC4, 0x06, 0x41, 0xF0, 0xC0, // ### # ## # ##### ## 0x00, 0x00, 0x02, 0x44, 0x00, 0x40, 0x00, 0xC0, // # # # # ## 0x00, 0x00, 0x02, 0x7C, 0x00, 0x80, 0x00, 0x20, // # ##### # # 0x00, 0x00, 0x02, 0x7C, 0x00, 0x87, 0x07, 0x20, // # ##### # ### ### # 0x00, 0x00, 0x03, 0x04, 0x01, 0x8D, 0x05, 0x20, // ## # ## ## # # # # 0x00, 0x00, 0x01, 0xC4, 0xC0, 0x89, 0x35, 0x20, // ### # ## # # # ## # # # 0x1F, 0xF8, 0x03, 0xFC, 0x44, 0xB0, 0x00, 0xE0, // ########## ######## # # # ## ### 0xF0, 0x0F, 0xFE, 0xC4, 0x04, 0xB2, 0x25, 0xE0, // #### ########### ## # # # ## # # # #### 0x00, 0x00, 0x00, 0x04, 0x20, 0x43, 0xFC, 0xC0, // # # # ######## ## 0x00, 0x00, 0x00, 0x0C, 0x20, 0x60, 0x01, 0x00, // ## # ## # 0x00, 0x00, 0x00, 0x36, 0x00, 0x1F, 0xFE, 0x00, // ## ## ############ 0x00, 0x00, 0x00, 0x43, 0xFF, 0xFF, 0xE8, 0x00, // # ##################### # 0x1F, 0xFC, 0x07, 0xC3, 0xFF, 0xFF, 0xE8, 0x00, // ########### ##### ##################### # 0xF0, 0x07, 0xFC, 0x45, 0x10, 0x12, 0x48, 0x00, // #### ######### # # # # # # # # 0x00, 0x00, 0x00, 0x79, 0xE0, 0x1C, 0x38, 0x00, // #### #### ### ### }; const unsigned char PROGMEM star1 [] = { 0x80, // # }; const unsigned char PROGMEM star2 [] = { 0x40, // # 0xA0, // # # 0x40, // # }; const unsigned char PROGMEM star3 [] = { 0x40, // # 0xA0, // # # 0x40, // # }; const unsigned char PROGMEM star4 [] = { 0x10, // # 0x10, // # 0x00, // 0xD6, // ## # ## 0x00, // 0x10, // # 0x10, // # }; const unsigned char PROGMEM star5 [] = { 0x10, // # 0x44, // # # 0x00, // 0x82, // # # 0x00, // 0x44, // # # 0x10, // # }; const unsigned char PROGMEM star6 [] = { 0x20, // # 0x00, // 0x88, // # # 0x00, // 0x20, // # }; #if (SSD1306_LCDHEIGHT != 64) #error("Height incorrect, please fix Adafruit_SSD1306.h!"); #endif //i/os--------- #define rechts PB12 #define links PB13 #define slinks PB15 #define srechts PB14 #define tisch PA8 #define grun PA9 #define rot PA10 #define blau PA2 #define heat PA1 #define temp PB0 #define test PB1 #define blauu PA3 //end i/os void setup() { pinMode(rechts, INPUT); pinMode(links, INPUT); pinMode(slinks, INPUT); pinMode(srechts, INPUT); pinMode(tisch, INPUT); pinMode(blau, OUTPUT); pinMode(rot, OUTPUT); pinMode(grun, OUTPUT); pinMode(heat, OUTPUT); Serial.begin(9600); display.begin(SSD1306_SWITCHCAPVCC, 0x3C); // initialize with the I2C addr 0x3D (for the 128x64) display.clearDisplay(); } int clinks = 0; int prozi =0; int woo = 80; int wooo = 0; int woooo = 0; int wis = 0; int bb = 0; int rr = 0; int gg = 0; int clicklinks =0; int clickrechts =0; int drucklinks =0; int druckrechts =0; int auftisch =0; int sets =1; int sets1 =0; int sets2 =25; int sets3 =50; int sets4 =75; int sets5 =100; int barb = 21; int count0 =10; int count1 =0; int count2 =0; int count3 =0; int count4 =0; int count5 =0; int count6 =0; int count7 =5; int count8 =0; int dutyaus = 0; int dutytime = 0; int watt1 = 0; int watt2 =0; int boost =0; int nyanon =0; int standy =0; int nyancounter =0; int catcounter =0; int cattz = 0; long fcount = micros(); int tempy = 0; int gcount =0; int rcount =0; int bcount =0; int cofcount=1; int concount=1; int standymode; int standydelay; int lamp =0; int cpcounter=0; int cp2=0; int rheiz=0; void loop() { sw(); clinks = digitalRead(links); if (rr == 0) { digitalWrite(rot, LOW);} if (rr == 1) { digitalWrite(rot, HIGH);} if (bb == 0) { digitalWrite(blau, LOW);} if (bb == 1) { digitalWrite(blau, HIGH);} if (gg == 0) { digitalWrite(grun, LOW);} if (gg == 1) { digitalWrite(grun, HIGH);} if (digitalRead(links) == HIGH) { clicklinks =2;} if (digitalRead(links) == LOW) { clicklinks =0;} if (digitalRead(rechts) == HIGH) { clickrechts =2;} if (digitalRead(rechts) == LOW) { clickrechts =0;} if (digitalRead(slinks) == HIGH) { drucklinks =2;} if (digitalRead(slinks) == LOW) { drucklinks =0;} if (digitalRead(srechts) == HIGH) { druckrechts =2;} if (digitalRead(srechts) == LOW) { druckrechts =0;} if (digitalRead(tisch) == HIGH) { auftisch =2;} if (digitalRead(tisch) == LOW) { auftisch =0;} display.fillRect(0, 37, 128, 7, BLACK); //if (auftisch ==0) {count8=1; } //llllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllll //if(auftisch ==0) { count7++; } //capacitiv entstör if (clicklinks == 0) { digitalWrite(heat, LOW ); if (cpcounter <=50) {count8=0; cpcounter++; staty(); standy=1;} if (cpcounter ==51 && (drucklinks ==2 | druckrechts ==2 | clickrechts ==2 | auftisch == 2)) {cpcounter=0;} //akkudampfe if (cpcounter ==51 && drucklinks ==0 && druckrechts ==0 && clickrechts ==0 && auftisch == 0) {cpcounter++; count8=1; standydelay=0; count7=0;}} if (count8 == 1) {standart(); //if (lamp == 0) {noc(); standydelay++; if (standydelay >=300) {auftisch =2; standydelay =0;} if (auftisch ==2 && lamp ==0) { if (standymode == 0) { count7 = 0; count8 =2; standy =1; nyan(cat, 64, 128); } //nyancat ohne led if (standymode == 1) { count7 = 0; count8 =2; standy =1; nyan(cat, 64, 128); } //nyancat mit led if (standymode == 2) { count7 = 0; count8 =3; standy =1; cats(cat, 64, 128); } //katzen if (standymode == 3) { count7 = 0; count8 =3; standy =1; cats(cat, 64, 128); } //katzen mit led if (standymode == 4) { count7 = 0; count8 =4; standy =1; schnee(); } //rauschen } if (standymode == 5) {standymode =0;} // settuings if (count0 > 1 ) { count0--; } if (count0 <= 1 && clickrechts == 2) {sets++; count0 =10;} if (count3 > 1 ) { count3--;} if (sets == 0) {sw(); prozi =sets1; wooo =0; bar(); if (drucklinks ==2 && prozi <= 98 && count3 <= 1) {sw(); sets1++; pfl(); count3 =10; setc(); standymode++;} if (druckrechts ==2 && prozi > 0 && count3 <= 1) {sw(); sets1--; pfr(); count3 =10; setc(); }} if (sets == 1) {sw(); prozi = sets2; wooo =24; bar(); if (drucklinks ==2 && prozi <= 98 && count3 <= 1) {sw(); sets2++; pfl(); count3 =5; setc();} if (druckrechts ==2 && prozi > 10 && count3 <= 1) {sw(); sets2--; pfr(); count3 =5; setc();}} if (sets == 2) {sw(); prozi = sets3; wooo =48; bar(); if (drucklinks ==2 && prozi <= 98 && count3 <= 1) {sw(); sets3++; pfl(); count3 =5; setc();} if (druckrechts ==2 && prozi > 10 && count3 <= 1) {sw(); sets3--; pfr(); count3 =5; setc();}} if (sets == 3) {sw(); prozi = sets4; wooo =72; bar(); if (drucklinks ==2 && prozi <= 98 && count3 <= 1) {sw(); sets4++; pfl(); count3 =5; setc();} if (druckrechts ==2 && prozi > 10 && count3 <= 1) {sw(); sets4--; pfr(); count3 =5; setc();}} if (sets == 4) {sw(); prozi = sets5; wooo =96; bar(); if (drucklinks ==2 && prozi < 100 && count3 <= 1) {sw(); sets5++; pfl(); bar(); count3 =2; setc();} if (druckrechts ==2 && prozi > 10 && count3 <= 1) {sw(); sets5--; pfr(); count3 =2; setc();}} if (sets == 5) {sets =0;} if (drucklinks ==0 && lamp ==0) {noc();} //taschenlampe /* if (sets ==0 && sets1 <= 10 && druckrechts ==2) {lamp =0;} if (sets ==0 && sets1 >= 11 && sets1 <= 15 && druckrechts ==2) {lamp =1;} if (lamp ==1 && sets1 == 11) { rr=1; } if (lamp ==1 && sets1 == 12) { bb=1; } if (lamp ==1 && sets1 == 13) { gg=1; } if (lamp ==1 && sets1 == 14) { rr=1; bb=1; } if (lamp ==1 && sets1 == 15) { gg=1; bb=1; } if (sets ==0 && sets1 >= 16 && druckrechts ==2) {lamp ==0;} */ //blitzsingle if (drucklinks ==2) {rcount++; concount=1; cofcount=1; standydelay =0;} if (druckrechts ==2) {gcount++;concount=1; cofcount=1; standydelay =0;} if (clickrechts ==2) {bcount++;concount=1; cofcount=1; standydelay =0;} if (auftisch ==2) {bcount++;} //akudampfe only if (rcount >=1 && rcount <=(concount +1)) {rcount++; rr=1;} if (rcount >=(concount+2) && rcount <=(concount+cofcount +3)) {rcount++; rr=0;} if (rcount >=(concount+cofcount +4)) {rcount=0;} if (bcount >=1 && bcount <=(concount +1)) {bcount++; bb=1;} if (bcount >=(concount+2) && bcount <=(concount+cofcount +3)) {bcount++; bb=0;} if (bcount >=(concount+cofcount +4)) {bcount=0;} if (gcount >=1 && gcount <=(concount +1)) {gcount++; gg=1;} if (gcount >=(concount+2) && gcount <=(concount+cofcount +3)) {gcount++; gg=0;} if (gcount >=(concount+cofcount +4)) {gcount=0;} //heizen+blink if (clicklinks == 0) {count2 =0;} if (count2 <= 31 && clicklinks ==2) {count2++; count4++;} display.fillRect(prozi / 0.875, 38, 14, 5, WHITE); display.setTextSize(4); if (prozi >= 0 && prozi < 10) {woo = 80;} if (prozi == 100) {woo = 34;} if (prozi < 100 && prozi > 9) {woo = 56;} display.setCursor(woo,3); display.setTextColor(WHITE); display.println(prozi); display.setTextSize(1); display.setCursor(0,8); cattz++; if (cattz == 1) {display.fillRect(0, 0, 30, 26, BLACK); display.drawBitmap(0,0, cat,30, 26, WHITE);} if (cattz == 5) {display.fillRect(0, 0, 30, 26, BLACK); display.drawBitmap(0,0+1, cat2,30, 25, WHITE);} if (cattz == 9) {display.fillRect(0, 0, 30, 26, BLACK); display.drawBitmap(0,0+2, cat3,30, 24, WHITE);} if (cattz == 13) {display.fillRect(0, 0, 30, 26, BLACK); display.drawBitmap(0,0+1, cat2,30, 25, WHITE);} if (cattz >= 17) {cattz = 0;} //tempy = analogRead(test); //tempy = analogRead(temp) /42; //if (tempy >= 0 && tempy <= 9) { display.setCursor(0,27); display.print("0"); display.print(tempy); display.print(" C"); } //tischonly //if (tempy >= 10 && tempy <= 99) { display.setCursor(0,27); display.print(tempy); display.print(" C"); } //tisch only //blinkheiz if (clicklinks == 0) { digitalWrite(heat, LOW ); count5 =0; display.setTextColor(WHITE); display.setCursor(0,27); display.print(standymode); display.display(); display.setTextColor(BLACK); display.setCursor(0,27); display.print(standymode); //if (cp2 ==0) {cp2=1;count8=0;} } if (clicklinks == 2 && lamp ==0) { //count8 =0; cpcounter=0; dampf(); count2++; if (count2 == 1 | count2 == 5 | count2 == 10 | count2 == 15 | count2 == 20) { if (rheiz ==0) {digitalWrite(grun, HIGH);}} if (count2 == 3 | count2 == 8 | count2 == 13 | count2 == 18 | count2 == 23) { digitalWrite(grun, LOW);} if (count2 == 25 | count2 == 30 | count2 == 35 | count2 == 40 | count2 == 45) { if (rheiz ==0) {digitalWrite(blau, HIGH);}} if (count2 == 28 | count2 == 33 | count2 == 38 | count2 == 43 | count2 == 48) { digitalWrite(blau, LOW);} if (count2 >= 50) {count2 =0; digitalWrite(grun, LOW); digitalWrite(blau, LOW); } } } } //endloop //platzsparfunktionenhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh void dampf(void){ count5++; if (prozi <= 29) { boost =30;} if (prozi >= 30) boost = (100 - prozi); if (count5 >= (boost + 2)) {dutyaus = ((100 - prozi ))* (1000 / watt1); dutytime =100000 /watt1; } // prozi * 6;} //watt1 0-100 watt2 * if (count5 <= boost) {rheiz=1; digitalWrite(heat, HIGH );} proziact(); if ((micros()-fcount) >= dutyaus) { rheiz=1; digitalWrite(heat, HIGH );} if ((micros()-fcount) >= dutytime) { fcount = micros(); digitalWrite(heat, LOW ); count6++; } if (count6 >=2) { rheiz=0; count6 = 0; digitalWrite(rot, LOW);} if (rheiz == 1) {digitalWrite(rot, HIGH);} } void proziact(void) { count7++; if ((prozi >= 4) && (prozi % 2) == 0) { watt1 = 2; } else {watt1 = 1;} if (count7 >= 200){ digitalWrite(heat, LOW ); display.display(); count7 = 0;} } void bar(void){ display.fillRect(0, 53, 128, 11, BLACK); display.setTextColor(WHITE); display.setTextSize(1); display.setCursor(2,55); if (sets1 <=8) {display.print(" ");} display.print(sets1); display.print("% "); display.print(sets2); display.print("% "); display.print(sets3); display.print("% "); display.print(sets4); if (sets5 <=99) {display.print("% ");} if (sets5 == 100) { display.print("% ");} display.print(sets5); display.print("% "); if (prozi >= 100 && sets ==4) {barb =27; } if (prozi <=99) {barb =21;} if (sets == 4 && prozi <= 99) {wooo = 102;} display.drawRect(wooo, 53, barb, 11, WHITE); } void pfl(void){ display.setTextSize(1); display.setTextColor(WHITE); display.setCursor(prozi / 0.875 +8,37); display.println("->"); } void pfr(void){ display.setTextSize(1); display.setTextColor(WHITE); display.setCursor(prozi / 0.875 -6,37); display.println("<-"); } void sw(void) { display.fillRect(34, 1, 68, 32, BLACK); display.fillRect(0, 27, 30, 8, BLACK); } void setc(void) { //count8 =0; if (prozi >= 80) { digitalWrite(rot, HIGH); } if (prozi <= 79) { digitalWrite(rot, LOW); } if (prozi >= 90) { digitalWrite(blau, HIGH); } if (prozi <= 89) { digitalWrite(blau, LOW); } if (prozi <= 49) { digitalWrite(grun, HIGH); } if (prozi >= 50) { digitalWrite(grun, LOW); } } void noc(void) { if (count8 == 3) { digitalWrite(blau, LOW); digitalWrite(grun, LOW); digitalWrite(rot, LOW); } } int cats1 =16; int cats22 = 30; int cats3 =0; int cats4 =0; int cats5 =0; int cats6 =0; int xpos1 =20; int ypos1 =20; int schneecount =0; void cats(const uint8_t *bitmap, uint8_t w, uint8_t h) { uint8_t iconsb[NUMFLAKES][26]; uint8_t icons[NUMFLAKES2][26]; // initialize for (uint8_t f=0; f< 8; f++) { icons[f][xpos1] = random(0,92); iconsb[f][ypos1] = random(0,36); } while (count8 ==3) { // catcounter++; // if (catcounter == 400) { schneecount=0; count8 =4; noc(); schnee();} // if (digitalRead(tisch) == LOW) {count8 =1; noc();} //maus if (digitalRead(links) == HIGH) {count8 =1; noc();} //akku for (uint8_t f=0; f< cats1; f++) { icons[f][xpos1] += random(2,8); cats4 = random(20,96); if ( icons[f][xpos1] < cats4 && (iconsb[f][ypos1]) < 40 ) { iconsb[f][ypos1] += random(1,4); } if ( icons[f][xpos1] > cats4 && (iconsb[f][ypos1]) > -30 ) { iconsb[f][ypos1] -= random(1,2); } if (icons[f][xpos1] > 250) { icons[f][xpos1] = random(0,92); iconsb[f][ypos1] = random(0,40); } cats5++; if (cats5 == 1) { display.drawBitmap(icons[f][xpos1] -cats22, iconsb[f][ypos1] -cats3, cat,30, 26, WHITE);} if (cats5 == 5) { display.drawBitmap(icons[f][xpos1] -cats22, (iconsb[f][ypos1] -cats3)+1, cat2,30, 25, WHITE);} // if (cats5 == 10) { display.drawBitmap(icons[f][xpos1] -cats22, (iconsb[f][ypos1] -cats3)+2, cat3,30, 24, WHITE);} // if (cats5 == 7) { display.drawBitmap(icons[f][xpos1] -cats22, (iconsb[f][ypos1] -cats3)+1, cat2,30, 25, WHITE);} if (cats5 >= 14) {cats5 = 0;} } display.display(); delay(10); display.fillRect(0, 0, 128, 64, BLACK); } } int nyans1 =4; int cats33 =5; int nyansc1 =0; int nyanc1 =0; int nyanc2 =0; int nyanc3 =0; int nyand1 =0; int nyand2 =0; int cats2 =128; int stary1 = 7; int stary2 = 0; int starc1 = 0; int stars1 = 15; int starposy =0; int starposx =135; int nyanposy =0; int nyanposx =0; int g = 0; int f1 = 0; //String = void nyan(const uint8_t *bitmap, uint8_t w, uint8_t h) { uint8_t nyanis[NUMFLAKES3][16]; uint8_t nyanis2[NUMFLAKES4][16]; uint8_t starys[NUMFLAKES5][28]; // initialize for (uint8_t f1=0; f1< nyans1; f1++) { nyanis2[f1][nyanposx] = random(0,168); nyanis[f1][nyanposy] = random(0,54); } for (uint8_t g=0; g< stars1; g++) { starys[g][starposy] = random (0,61); starys[g][starposx] = random (135,300); } while (count8 ==2) { // nyancounter++; // if (nyancounter >701 ) {catcounter =0; count8 =3; noc(); cats(cat, 64, 128); } //dauernyans2 maus if (digitalRead(links) == HIGH) {count8 =1; noc();} //akku //if (digitalRead(tisch) == LOW) {count8 =1; noc();} //maus if (nyancounter <700) { //dauernyans if((nyanc3 % 10) == 0) { digitalWrite(heat, LOW ); } if (standymode == 1) {nyanstandby();} for (uint8_t g=0; g< stars1; g++) { starc1++; starys[g][starposx] *= 0.97; starys[g][starposx] -= random(3,8); if (starys[g][starposx] < 7) { starys[g][starposx] = random(135,250) ; starys[g][starposy] = random(0,61); } if (starc1 == 1) { display.drawBitmap((starys[g][starposx] -stary1) +3, (starys[g][starposy]) + 3, star1,1, 1, WHITE); } if (starc1 == 2) { display.drawBitmap((starys[g][starposx] -stary1) +2, (starys[g][starposy]) + 2, star2,3, 3, WHITE); } if (starc1 == 3) { display.drawBitmap((starys[g][starposx] -stary1) +2, (starys[g][starposy])+ 2, star3,3, 3, WHITE); } if (starc1 == 4) { display.drawBitmap((starys[g][starposx] -stary1) , (starys[g][starposy]) , star4,7, 7, WHITE); } if (starc1 == 5) { display.drawBitmap((starys[g][starposx] -stary1) , (starys[g][starposy]), star5,7, 7, WHITE); } if (starc1 == 6) { display.drawBitmap((starys[g][starposx] -stary1) +2, (starys[g][starposy]) +2, star6,5, 5, WHITE); } if (starc1 == 7) { starc1 = 1; } } for (uint8_t f1=0; f1< nyans1; f1++) { if (nyanis2[f1][nyanposx] < 160) {nyanis2[f1][nyanposx] /= 1.125; nyanis2[f1][nyanposx] += random(14,21);} if (nyanis2[f1][nyanposx] > 157) {nyanis2[f1][nyanposx] *= 1.02; nyanis2[f1][nyanposx] += random(1,3);} if (nyanis2[f1][nyanposx] > 249) {nyanis[f1][nyanposy] = random(0,54);} nyanc2++; if (nyanc2 == 1) { display.drawBitmap((nyanis2[f1][nyanposx] -cats2), nyanis[f1][nyanposy] -cats33, nyan1,60, 23, WHITE); } if (nyanc2 == 2) { display.drawBitmap((nyanis2[f1][nyanposx] -cats2), nyanis[f1][nyanposy] -cats33, nyan2,60, 23, WHITE); } if (nyanc2 == 3) { display.drawBitmap((nyanis2[f1][nyanposx] -cats2), nyanis[f1][nyanposy] -cats33, nyan3,60, 23, WHITE); } if (nyanc2 == 4) { display.drawBitmap((nyanis2[f1][nyanposx] -cats2), nyanis[f1][nyanposy] -cats33, nyan4,60, 23, WHITE); } if (nyanc2 == 5) { display.drawBitmap((nyanis2[f1][nyanposx] -cats2), nyanis[f1][nyanposy] -cats33, nyan5,60, 23, WHITE); } if (nyanc2 == 6) { display.drawBitmap((nyanis2[f1][nyanposx] -cats2), nyanis[f1][nyanposy] -cats33, nyan6,60, 23, WHITE); } if (nyanc2 >= 7) {nyanc2 = 1;} } display.display(); } delay(10); display.fillRect(0, 0, 128, 64, BLACK); } } void nyanstandby(void) { if (rr == 0) { digitalWrite(rot, LOW);} if (rr == 1) { digitalWrite(rot, HIGH);} if (bb == 0) { digitalWrite(blau, LOW);} if (bb == 1) { digitalWrite(blau, HIGH);} if (gg == 0) { digitalWrite(grun, LOW);} if (gg == 1) { digitalWrite(grun, HIGH);} nyanc3++; if (nyanc3 == 10) {bb=1;} if (nyanc3 == 11) {bb=0;} if (nyanc3 == 60) {bb=1; rr=1;} if (nyanc3 == 61) {bb=0; rr=0;} if (nyanc3 == 104) {gg=1; bb=1;} if (nyanc3 == 105) {gg=0; bb=0;} if (nyanc3 == 167) {rr=1;} if (nyanc3 == 168) {rr=0;} if (nyanc3 == 216) {gg=1; rr=1;} if (nyanc3 == 217) {gg=0; rr=0;} if (nyanc3 == 300) {nyanc3=0;} } int q =0; int x =0; int schneezahl =4096; int schneezahl2 =1; int menge =20; int menge1 =0; int achsex =0; int achsey =0; void schnee(void) { while (count8 ==4) { // schneecount++; // if (schneecount == 100) { nyancounter=0; count8 =2; noc(); nyan(cat, 64, 128);} // if (digitalRead(tisch) == LOW) {count8 =1; noc();} //maus if (digitalRead(links) == HIGH) {count8 =1; noc();} //akku if (menge1 <=5) { if (schneezahl2 ==1) { for (uint8_t x1=0; x1< 64; x1++) { for (uint8_t q1=0; q1< menge; q1++) { achsex =random(0,128); if ((achsex % 2) == 0 && (achsey % 2) ==0) { display.drawPixel(achsex, achsey, WHITE); } if ((achsex % 2) == 1 && (achsey % 2) ==1) { display.drawPixel(achsex, achsey, WHITE); } } achsey++; if (achsey >= 64) {achsey = 0;}} } if (schneezahl2 ==2) { for (uint8_t x1=0; x1< 64; x1++) { for (uint8_t q1=0; q1< menge; q1++) { achsex =random(0,128); if ((achsex % 2) == 1 && (achsey % 2) ==0) { display.drawPixel(achsex, achsey, WHITE); } if ((achsex % 2) == 1 && (achsey % 2) ==1) { display.drawPixel(achsex, achsey, WHITE); } } achsey++; if (achsey >= 64) {achsey = 0;}} } display.display(); delay(0); display.fillRect(0, 0, 128, 64, BLACK); schneezahl2++; if (schneezahl2== 3) {schneezahl2 = 1;} menge1++; if (menge <= 100){menge += random(0,3);}} if (menge1 >= 3) {menge = random(1,80); menge1 =0;} } } void standart(void) { if (standy == 1 ) { delay(1); digitalWrite(heat, LOW ); standy = 2; // display.clearDisplay(); // text display unverändertes display.fillRect(0, 0, 128, 64, BLACK); display.setTextSize(1); display.setTextColor(WHITE); display.setCursor(0,0); // display.println("Power"); display.drawRect(32, 0, 96, 34, WHITE); //ramen x,y,w,h display.setTextColor(WHITE); display.setTextSize(4); display.setCursor(103,3); display.println("%"); //display.println(0xDEADBEEF, HEX); display.setTextSize(1); display.setTextColor(WHITE); display.setCursor(0,45); display.println("0%^^^^^^^50%^^^^^100%"); display.display(); } } void staty(void) { display.fillRect(0, 0, 128, 64, BLACK); noc(); display.drawRect(0, 0, 128, 24, WHITE); display.fillRect(2, 2, (cpcounter / 0.4) , 20, WHITE); display.setTextSize(1); display.setTextColor(WHITE); display.setCursor(0,26); display.println("reloading capavitive"); display.setCursor(18,34); // display.print(random(0,(cpcounter*2))); display.print((400 -(cpcounter*8))); display.print((400 -(cpcounter*8))); display.print(" -> "); // display.print(random(0,(cpcounter*2))); display.print((cpcounter*8)); display.print((cpcounter*8)); // display.print(random(0,(cpcounter*2))); // display.print(random(0,(cpcounter*2))); display.setTextSize(2); display.setCursor(14,48); display.println(",,,^.^,,,"); display.display(); delay(8); } /* * MEOW! STM32 program (main actions) * by marderchen =^.^= working fine but currently uses 32/65Kbyte cach from STM32F103C8T6 so enough place for bitmapsdata, better font,...) * do what you want! * ___ * _.-| | / |\__/,| (`\ { | | -- |^ ^ |__ _) ) "-.|___| \ _.( Y ) ` / .--'-`-. _((_ `^--' /__< \ ....-+|______|__.-||__)`-' (((/ (((/ CATS are awesome! */