File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -699,12 +699,16 @@ int OV7670::setFrameRate(int32_t framerate)
699699
700700int  OV7670::setVerticalFlip (bool  flip_enable)
701701{
702-   return  -1 ;
702+     uint8_t  currentRegisterValue = regRead (getID (), MVFP);
703+     uint8_t  newRegisterValue = flip_enable ? currentRegisterValue | MVFP_VFLIP : currentRegisterValue & ~MVFP_VFLIP;
704+     return  regWrite (getID (), MVFP, newRegisterValue);
703705}
704706
705707int  OV7670::setHorizontalMirror (bool  mirror_enable)
706708{
707-   return  -1 ;
709+     uint8_t  currentRegisterValue = regRead (getID (), MVFP);
710+     uint8_t  newRegisterValue = mirror_enable ? currentRegisterValue | MVFP_MIRROR : currentRegisterValue & ~MVFP_MIRROR;
711+     return  regWrite (getID (), MVFP, newRegisterValue);
708712}
709713
710714int  OV7670::setResolution (int32_t  resolution)
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments