Пример #1
0
//__attribute__((constructor))
int32_t badge_setup(void)
{
printf("Start\n");
  touch_start(TPCount, TPPins, TPDischarge);
  if(!eei2cLockFlag)
  {
printf("1\n");
    eei2cLock = locknew();
    lockclr(eei2cLock);
    eei2cLockFlag = 1;
printf("1\n");
  }
  init_MMA7660FC();
printf("1\n");
  if(!st_eeInitFlag) ee_init();
printf("1\n");
  cpcog = light_start();
printf("1\n");
  cogIRcom = ircom_start(IR_IN, IR_OUT, 2400, 38500);
printf("1\n");
  screen_init(OLED_CS, OLED_DC, OLED_DAT, OLED_CLK, OLED_RST, SSD1306_SWITCHCAPVCC, TYPE_128X64);
printf("1\n");
  screen_auto(ON);
printf("1\n");
  clear();
printf("1\n");
  text_size(LARGE);
    printf("Return\n");  
return 0;
}
Пример #2
0
// Set up some global things
void Init(void)
{
  screen_auto(0);       // Set the screen not to auto-update (we want to control it)
  text_size(SMALL);     // Set the text size

  UsedShots = 0;        // No shots currently active
  FreeShots = MaxShots;
}
Пример #3
0
// Set up some global things
void Init(void)
{
  screen_auto(0);     // Set the screen not to auto-update (we want to control it)
  text_size(SMALL);   // Set the text size
}