| 
 
| 遇到一个用板子自带slider控制led灯的程序 问题是板子不知道我何时按了按钮
 程序如下int turn;
 int temp=0;
 for(turn=0;turn<10;turn++){
 if(turn>0)
 {
 sequence(turn);
 temp=TSS1_cKey0.Position;
 int h=0;
 while(h==0)
 {
 TSS_Task();
 lstpos=TSS1_cKey0.Position;
 if(lstpos!=temp)
 {
 if(TSS1_cKey0.Position>=0 && TSS1_cKey0.Position < 24)
 {
 h=1;
 RED_blk();
 }
 else if(TSS1_cKey0.Position >= 24 && TSS1_cKey0.Position< 40)
 {
 h=1;
 GREEN_blk();
 }
 else if(TSS1_cKey0.Position>= 40 && TSS1_cKey0.Position <= 64)
 {
 h=1;
 BLUE_blk();
 }
 }//if
 else
 temp=TSS1_cKey0.Position;
 }//while
 }//if
 else
 temp=TSS1_cKey0.Position;
 }//for
 
 解决了直接支付宝打款
 看完成程度给报酬
 
 | 
 |