void boardtest() { // while(K1 == 0)OSTimeDly(10) ; while(K1 == 1)OSTimeDly(10) ; //TF CheckMode() ; while(K1 == 0)OSTimeDly(10) ; while(K1 == 1)OSTimeDly(10) ; //rst OSTimeDly(100) ; TfMode() ; OSTimeDly(100) ; while(K1 == 0){OSTimeDly(100); } while(K1 == 1){UsbInfoDispose();OSTimeDly(10) ; } //rst CheckMode() ; OSTimeDly(200) ; DspRst() ; while(1){ if(K9 == 0 ){Light_Init(); TOP_W = 0 ; TOP_IR850= 0 ; TOP_IR940 = 0 ; LEFT_W = 0 ; RIGHT_W = 0 ; LEFT_IR850 = 0 ; RIGHT_IR850 = 0 ; BOT_W = 0 ; BOT_IR = 0 ; RIGHT_UV = 0 ; LEFT_UV = 0 ; } if(K2 == 0 ){Light_Init(); TOP_IR850= 0 ;} if(K3 == 0 ){Light_Init(); TOP_IR940 = 0 ; } if(K4 == 0 ){Light_Init(); LEFT_W = 0 ; RIGHT_W = 0 ; } if(K5 == 0 ){Light_Init(); TOP_IR940 = 0 ;TOP_IR850= 0 ; ;} OSTimeDly(1); if(K6 == 0 ){Light_Init(); LEFT_IR850 = 0 ; RIGHT_IR850 = 0 ; } OSTimeDly(1); if(K7 == 0 ){Light_Init(); BOT_W = 0 ;BOT_IR = 0 ;} OSTimeDly(1); if(K8 == 0 ){Light_Init(); RIGHT_UV = 0 ;LEFT_UV = 0 ; } OSTimeDly(1); if(K1 == 0 ){Light_Init();break ;} OSTimeDly(1); OSTimeDly(10); } CheckMode() ; OSTimeDly(300); while(K1 == 0)OSTimeDly(10) ; while(K1 == 1)OSTimeDly(10) ; PhotographOne() ; OSTimeDly(300) ; while(K1 == 0)OSTimeDly(10) ; while(K1 == 1)OSTimeDly(10) ; ViewMode(); OSTimeDly(100) ; while(K1 == 0)OSTimeDly(10) ; while(K1 == 1)OSTimeDly(10) ; //PhotoDelOne() ; Select_Send_LONG(0x24); OSTimeDly(100) ; while(K1 == 0)OSTimeDly(10) ; while(K1 == 1)OSTimeDly(10) ; CheckMode() ; OSTimeDly(100); PccamMode() ; OSTimeDly(300) ; while(K1 == 0)OSTimeDly(10) ; while(K1 == 1){UsbInfoDispose();OSTimeDly(10) ; } CheckMode() ; }
GLvoid GLWindow::ResizeGLScene(GLsizei width, GLsizei height) { if (0 == height) { height = 1; // 防止被0除 } m_width = width; m_height = height; glViewport(0, 0, (GLsizei)width, (GLsizei)height); ViewMode(); // 设置显示模式 }
void VoxCad::SetupTensileWindow(void) { TensileDockWidget = new QDockWidget(this); TensileDockWidget->setAllowedAreas(Qt::LeftDockWidgetArea | Qt::RightDockWidgetArea); TensileDlg = new Dlg_Tensile(&MainEnv, PhysicsDockWidget); TensileDockWidget->setWidget(TensileDlg); TensileDockWidget->setWindowTitle("Tensile Testing"); TensileDockWidget->setVisible(false); connect(TensileDlg, SIGNAL(DoneTensileTesting()), this, SLOT(ViewMode())); connect(&TensileDlg->Tester, SIGNAL(StartExternalGLUpdate(int)), GLWindow, SLOT(StartAutoRedraw(int))); connect(&TensileDlg->Tester, SIGNAL(StopExternalGLUpdate()), GLWindow, SLOT(StopAutoRedraw())); addDockWidget(Qt::RightDockWidgetArea, TensileDockWidget); }
void KeyInfoDispose() { //按键检测处理 System.Key.Value = KeyScan() ; System.Key.Keylong = &Keylong ; if(!System.Key.Value) { // 处理休眠操作 if(System.Key.NoKeyTime == 180) { if(System.Dsp.Mode == CHECK_MODE||VIEW_MODE) { System.Dsp.Mode = SLEEP_MODE ; Light_Init() ; // SHOW_SCREEN(0xE8, " "); } } else if ((System.Key.NoKeyTime == 300)&&(System.Dsp.Mode == SLEEP_MODE)) { System.Dsp.Mode = SLEEP_MODE ; // SHOW_SCREEN(0xE8, "Power Saving Mode"); SHOW_SCREENW(0xE8, WcharToChar(L"节电模式") ); OSTimeDly(200); //必须有 } } else { // GR_DBG_PRINTF("keylong is %d OK it is %d\n\n",*System.Key.Keylong,Keylong); // 处理唤醒操作 System.Key.NoKeyTime = 0 ; if(System.Dsp.Mode == SLEEP_MODE) { CheckMode(); OSTimeDly(200) ; } //处理按键操作 switch(System.Key.Value) { case 1 :// 顶白光 { if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { switch(System.Dsp.Mode) { case VIEW_MODE: CheckMode(); break ; default :break ; } Photo_SignAndCount(); } }break ; case 2 :// check: 850 940 770 闪烁 长按:进入PCCAM { }break ; case 3 ://check: 紫外-激光 长按:进入校正 { if(*System.Key.Keylong)// 进入校正功能 { if(System.Dsp.Mode == CHECK_MODE) { PriorExposure(); } } else { if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { switch(System.Dsp.Mode) { case VIEW_MODE: CheckMode(); break ; default :break ; } if((System.Dsp.Mode ==PCCAM_MODE)||(System.Dsp.Mode ==CHECK_MODE)) { Photo_SignAndChk(); } } // PhotoMvRight() ; } }break ; case 4 ://check : sensor1 sensor2 sensor3 ,长按:608 { }break ; case 5 ://check: 左白光 右白光 左红外, 右红外 view:翻页 放大 { // PhotoDelAll(); if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { switch(System.Dsp.Mode) { case PCCAM_MODE : case CHECK_MODE : { ViewMode() ; }break; case VIEW_MODE : { if(*System.Key.Keylong) { CheckMode(); } else { ViewMode_F1() ; } }break; default :break ; } } }break ; case 6 ://check: 底白光,底红外 view :右边翻页 { if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { switch(System.Dsp.Mode) { case PCCAM_MODE : case CHECK_MODE : { }break; case VIEW_MODE : { ViewMode_F2() ; }break; default :break ; } } }break ; case 7 ://view--check ; { if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { switch(System.Dsp.Mode) { case PCCAM_MODE : case CHECK_MODE : { C608_On() ; }break; case VIEW_MODE : { ViewMode_F3() ; }break; default :break ; } } }break ; case 8 ://check:短按单拍,长按8连拍 ,view 长按删除,短按确认 { if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { if(*System.Key.Keylong)// 进入校正功能 { } else { switch(System.Dsp.Mode) { case PCCAM_MODE : case CHECK_MODE : { // CheckMode(); if( System.Local_SignOutCount_Flag == 0 ) { System.Local_SignOutCount_Flag = 1 ; } Local_SignOutCount = 0 ; ShowLeftBtmNum(); }break; case VIEW_MODE : { ViewMode_F4() ; }break; default :break ; } } } }break ; case 9 ://check: 短按连拍,长按修改密码 // view:自动回放 { if(System.Led.Statu == C608_PWR_ON) { CheckMode(); OSTimeDly(100) ; } else { ViewMode() ; PhotoDelAll(); CheckMode(); } }break ; default : break ; } } }