configured for beyondtek displays

Dependents:   datalogger_ft810

Fork of FT800_3 by The Best

Revision:
3:392d2c733c68
Parent:
2:ab74a9a05970
Child:
4:363ec27cdfaa
--- a/FT_CoPro_Cmds.cpp	Sat Jan 04 13:56:38 2014 +0000
+++ b/FT_CoPro_Cmds.cpp	Fri Sep 19 15:56:15 2014 +0000
@@ -1,511 +1,511 @@
 /* mbed Library for FTDI FT800  Enbedded Video Engine "EVE"
- * based on Original Code Sample from FTDI 
+ * based on Original Code Sample from FTDI
  * ported to mbed by Peter Drescher, DC2PD 2014
  * Released under the MIT License: http://mbed.org/license/mit */
 
 #include "FT_Platform.h"
 
 
-ft_void_t FT800::Ft_Gpu_Copro_SendCmd( ft_uint32_t cmd)
-{ 
-   Ft_Gpu_Hal_Transfer32( cmd);
+ft_void_t FT800::SendCmd( ft_uint32_t cmd)
+{
+   Transfer32( cmd);
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_SendStr( const ft_char8_t *s)
+ft_void_t FT800::SendStr( const ft_char8_t *s)
 {
-  Ft_Gpu_Hal_TransferString( s);
+  TransferString( s);
 }
 
 
-ft_void_t FT800::Ft_Gpu_CoCmd_StartFunc( ft_uint16_t count)
+ft_void_t FT800::StartFunc( ft_uint16_t count)
 {
-  Ft_Gpu_Hal_CheckCmdBuffer( count);
-  Ft_Gpu_Hal_StartCmdTransfer( FT_GPU_WRITE,count);
+  CheckCmdBuffer( count);
+  StartCmdTransfer( FT_GPU_WRITE,count);
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_EndFunc( ft_uint16_t count)
+ft_void_t FT800::EndFunc( ft_uint16_t count)
 {
-  Ft_Gpu_Hal_EndTransfer( );
-  Ft_Gpu_Hal_Updatecmdfifo( count);
+  EndTransfer( );
+  Updatecmdfifo( count);
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Text( ft_int16_t x, ft_int16_t y, ft_int16_t font, ft_uint16_t options, const ft_char8_t* s)
+ft_void_t FT800::Text( ft_int16_t x, ft_int16_t y, ft_int16_t font, ft_uint16_t options, const ft_char8_t* s)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3 + strlen(s) + 1);
-  Ft_Gpu_Copro_SendCmd(  CMD_TEXT);
-  //Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(ft_uint32_t)x));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)options<<16)|(ft_uint32_t)font));
-  Ft_Gpu_CoCmd_SendStr(  s);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3 + strlen(s) + 1));  
+  StartFunc( FT_CMD_SIZE*3 + strlen(s) + 1);
+  SendCmd(  CMD_TEXT);
+  //Copro_SendCmd(  (((ft_uint32_t)y<<16)|(ft_uint32_t)x));
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)options<<16)|(ft_uint32_t)font));
+  SendStr(  s);
+  EndFunc( (FT_CMD_SIZE*3 + strlen(s) + 1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Number( ft_int16_t x, ft_int16_t y, ft_int16_t font, ft_uint16_t options, ft_int32_t n)
+ft_void_t FT800::Number( ft_int16_t x, ft_int16_t y, ft_int16_t font, ft_uint16_t options, ft_int32_t n)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);  
-  Ft_Gpu_Copro_SendCmd(  CMD_NUMBER);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)options<<16)|font));
-  Ft_Gpu_Copro_SendCmd(  n);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));  
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_NUMBER);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)options<<16)|font));
+  SendCmd(  n);
+  EndFunc( (FT_CMD_SIZE*4));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_LoadIdentity( )
+ft_void_t FT800::LoadIdentity( )
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);    
-  Ft_Gpu_Copro_SendCmd(  CMD_LOADIDENTITY);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));  
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_LOADIDENTITY);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Toggle( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t font, ft_uint16_t options, ft_uint16_t state, const ft_char8_t* s)
+ft_void_t FT800::Toggle( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t font, ft_uint16_t options, ft_uint16_t state, const ft_char8_t* s)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4 + strlen(s) + 1);     
-  Ft_Gpu_Copro_SendCmd(  CMD_TOGGLE);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)font<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)state<<16)|options));
-  Ft_Gpu_CoCmd_SendStr(  s);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4 + strlen(s) + 1));       
+  StartFunc( FT_CMD_SIZE*4 + strlen(s) + 1);
+  SendCmd(  CMD_TOGGLE);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)font<<16)|w));
+  SendCmd(  (((ft_uint32_t)state<<16)|options));
+  SendStr(  s);
+  EndFunc( (FT_CMD_SIZE*4 + strlen(s) + 1));
 }
 
 /* Error handling for val is not done, so better to always use range of 65535 in order that needle is drawn within display region */
-ft_void_t FT800::Ft_Gpu_CoCmd_Gauge( ft_int16_t x, ft_int16_t y, ft_int16_t r, ft_uint16_t options, ft_uint16_t major, ft_uint16_t minor, ft_uint16_t val, ft_uint16_t range)
+ft_void_t FT800::Gauge( ft_int16_t x, ft_int16_t y, ft_int16_t r, ft_uint16_t options, ft_uint16_t major, ft_uint16_t minor, ft_uint16_t val, ft_uint16_t range)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);       
-  Ft_Gpu_Copro_SendCmd(  CMD_GAUGE);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)options<<16)|r));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)minor<<16)|major));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)range<<16)|val));
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));         
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_GAUGE);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)options<<16)|r));
+  SendCmd(  (((ft_uint32_t)minor<<16)|major));
+  SendCmd(  (((ft_uint32_t)range<<16)|val));
+  EndFunc( (FT_CMD_SIZE*5));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_RegRead( ft_uint32_t ptr, ft_uint32_t result)
+ft_void_t FT800::RegRead( ft_uint32_t ptr, ft_uint32_t result)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);         
-  Ft_Gpu_Copro_SendCmd(  CMD_REGREAD);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  0);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3)); 
-    
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_REGREAD);
+  SendCmd(  ptr);
+  SendCmd(  0);
+  EndFunc( (FT_CMD_SIZE*3));
+
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_GetProps( ft_uint32_t ptr, ft_uint32_t w, ft_uint32_t h)
+ft_void_t FT800::GetProps( ft_uint32_t ptr, ft_uint32_t w, ft_uint32_t h)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);           
-  Ft_Gpu_Copro_SendCmd(  CMD_GETPROPS);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  w);
-  Ft_Gpu_Copro_SendCmd(  h);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));           
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_GETPROPS);
+  SendCmd(  ptr);
+  SendCmd(  w);
+  SendCmd(  h);
+  EndFunc( (FT_CMD_SIZE*4));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Memcpy( ft_uint32_t dest, ft_uint32_t src, ft_uint32_t num)
+ft_void_t FT800::Memcpy( ft_uint32_t dest, ft_uint32_t src, ft_uint32_t num)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);         
-  Ft_Gpu_Copro_SendCmd(  CMD_MEMCPY);
-  Ft_Gpu_Copro_SendCmd(  dest);
-  Ft_Gpu_Copro_SendCmd(  src);
-  Ft_Gpu_Copro_SendCmd(  num);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));           
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_MEMCPY);
+  SendCmd(  dest);
+  SendCmd(  src);
+  SendCmd(  num);
+  EndFunc( (FT_CMD_SIZE*4));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Spinner( ft_int16_t x, ft_int16_t y, ft_uint16_t style, ft_uint16_t scale)
+ft_void_t FT800::Spinner( ft_int16_t x, ft_int16_t y, ft_uint16_t style, ft_uint16_t scale)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);         
-  Ft_Gpu_Copro_SendCmd(  CMD_SPINNER);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)scale<<16)|style));
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));           
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_SPINNER);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)scale<<16)|style));
+  EndFunc( (FT_CMD_SIZE*3));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_BgColor( ft_uint32_t c)
+ft_void_t FT800::BgColor( ft_uint32_t c)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);           
-  Ft_Gpu_Copro_SendCmd(  CMD_BGCOLOR);
-  Ft_Gpu_Copro_SendCmd(  c);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));           
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_BGCOLOR);
+  SendCmd(  c);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Swap()
+ft_void_t FT800::Swap()
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);         
-  Ft_Gpu_Copro_SendCmd(  CMD_SWAP);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));         
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_SWAP);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Inflate( ft_uint32_t ptr)
+ft_void_t FT800::Inflate( ft_uint32_t ptr)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);
-  Ft_Gpu_Copro_SendCmd(  CMD_INFLATE);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));  
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_INFLATE);
+  SendCmd(  ptr);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Translate( ft_int32_t tx, ft_int32_t ty)
+ft_void_t FT800::Translate( ft_int32_t tx, ft_int32_t ty)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);  
-  Ft_Gpu_Copro_SendCmd(  CMD_TRANSLATE);
-  Ft_Gpu_Copro_SendCmd(  tx);
-  Ft_Gpu_Copro_SendCmd(  ty);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));  
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_TRANSLATE);
+  SendCmd(  tx);
+  SendCmd(  ty);
+  EndFunc( (FT_CMD_SIZE*3));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Stop()
+ft_void_t FT800::Stop()
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);    
-  Ft_Gpu_Copro_SendCmd(  CMD_STOP);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));    
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_STOP);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Slider( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_uint16_t options, ft_uint16_t val, ft_uint16_t range)
+ft_void_t FT800::Slider( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_uint16_t options, ft_uint16_t val, ft_uint16_t range)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);    
-  Ft_Gpu_Copro_SendCmd(  CMD_SLIDER);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)val<<16)|options));
-  Ft_Gpu_Copro_SendCmd(  range);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));    
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_SLIDER);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  (((ft_uint32_t)val<<16)|options));
+  SendCmd(  range);
+  EndFunc( (FT_CMD_SIZE*5));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_TouchTransform( ft_int32_t x0, ft_int32_t y0, ft_int32_t x1, ft_int32_t y1, ft_int32_t x2, ft_int32_t y2, ft_int32_t tx0, ft_int32_t ty0, ft_int32_t tx1, ft_int32_t ty1, ft_int32_t tx2, ft_int32_t ty2, ft_uint16_t result)
+ft_void_t FT800::TouchTransform( ft_int32_t x0, ft_int32_t y0, ft_int32_t x1, ft_int32_t y1, ft_int32_t x2, ft_int32_t y2, ft_int32_t tx0, ft_int32_t ty0, ft_int32_t tx1, ft_int32_t ty1, ft_int32_t tx2, ft_int32_t ty2, ft_uint16_t result)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*6*2+FT_CMD_SIZE*2);      
-  Ft_Gpu_Copro_SendCmd(  CMD_TOUCH_TRANSFORM);
-  Ft_Gpu_Copro_SendCmd(  x0);
-  Ft_Gpu_Copro_SendCmd(  y0);
-  Ft_Gpu_Copro_SendCmd(  x1);
-  Ft_Gpu_Copro_SendCmd(  y1);
-  Ft_Gpu_Copro_SendCmd(  x2);
-  Ft_Gpu_Copro_SendCmd(  y2);
-  Ft_Gpu_Copro_SendCmd(  tx0);
-  Ft_Gpu_Copro_SendCmd(  ty0);
-  Ft_Gpu_Copro_SendCmd(  tx1);
-  Ft_Gpu_Copro_SendCmd(  ty1);
-  Ft_Gpu_Copro_SendCmd(  tx2);
-  Ft_Gpu_Copro_SendCmd(  ty2);
-  Ft_Gpu_Copro_SendCmd(  result);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*6*2+FT_CMD_SIZE*2));        
+  StartFunc( FT_CMD_SIZE*6*2+FT_CMD_SIZE*2);
+  SendCmd(  CMD_TOUCH_TRANSFORM);
+  SendCmd(  x0);
+  SendCmd(  y0);
+  SendCmd(  x1);
+  SendCmd(  y1);
+  SendCmd(  x2);
+  SendCmd(  y2);
+  SendCmd(  tx0);
+  SendCmd(  ty0);
+  SendCmd(  tx1);
+  SendCmd(  ty1);
+  SendCmd(  tx2);
+  SendCmd(  ty2);
+  SendCmd(  result);
+  EndFunc( (FT_CMD_SIZE*6*2+FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Interrupt( ft_uint32_t ms)
+ft_void_t FT800::Interrupt( ft_uint32_t ms)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);        
-  Ft_Gpu_Copro_SendCmd(  CMD_INTERRUPT);
-  Ft_Gpu_Copro_SendCmd(  ms);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));          
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_INTERRUPT);
+  SendCmd(  ms);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_FgColor( ft_uint32_t c)
+ft_void_t FT800::FgColor( ft_uint32_t c)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);          
-  Ft_Gpu_Copro_SendCmd(  CMD_FGCOLOR);
-  Ft_Gpu_Copro_SendCmd(  c);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));          
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_FGCOLOR);
+  SendCmd(  c);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Rotate( ft_int32_t a)
+ft_void_t FT800::Rotate( ft_int32_t a)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);            
-  Ft_Gpu_Copro_SendCmd(  CMD_ROTATE);
-  Ft_Gpu_Copro_SendCmd(  a);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));          
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_ROTATE);
+  SendCmd(  a);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Button( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_int16_t font, ft_uint16_t options, const ft_char8_t* s)
+ft_void_t FT800::Button( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_int16_t font, ft_uint16_t options, const ft_char8_t* s)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4 + strlen(s) + 1);            
-  Ft_Gpu_Copro_SendCmd(  CMD_BUTTON);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|font));
-  Ft_Gpu_CoCmd_SendStr(  s);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4 + strlen(s) + 1));              
+  StartFunc( FT_CMD_SIZE*4 + strlen(s) + 1);
+  SendCmd(  CMD_BUTTON);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  (((ft_uint32_t)y<<16)|font));
+  SendStr(  s);
+  EndFunc( (FT_CMD_SIZE*4 + strlen(s) + 1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_MemWrite( ft_uint32_t ptr, ft_uint32_t num)
+ft_void_t FT800::MemWrite( ft_uint32_t ptr, ft_uint32_t num)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);       
-  Ft_Gpu_Copro_SendCmd(  CMD_MEMWRITE);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  num);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));       
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_MEMWRITE);
+  SendCmd(  ptr);
+  SendCmd(  num);
+  EndFunc( (FT_CMD_SIZE*3));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Scrollbar( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_uint16_t options, ft_uint16_t val, ft_uint16_t size, ft_uint16_t range)
+ft_void_t FT800::Scrollbar( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_uint16_t options, ft_uint16_t val, ft_uint16_t size, ft_uint16_t range)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);       
-  Ft_Gpu_Copro_SendCmd(  CMD_SCROLLBAR);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)val<<16)|options));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)range<<16)|size));
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));       
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_SCROLLBAR);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  (((ft_uint32_t)val<<16)|options));
+  SendCmd(  (((ft_uint32_t)range<<16)|size));
+  EndFunc( (FT_CMD_SIZE*5));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_GetMatrix( ft_int32_t a, ft_int32_t b, ft_int32_t c, ft_int32_t d, ft_int32_t e, ft_int32_t f)
+ft_void_t FT800::GetMatrix( ft_int32_t a, ft_int32_t b, ft_int32_t c, ft_int32_t d, ft_int32_t e, ft_int32_t f)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*7);       
-  Ft_Gpu_Copro_SendCmd(  CMD_GETMATRIX);
-  Ft_Gpu_Copro_SendCmd(  a);
-  Ft_Gpu_Copro_SendCmd(  b);
-  Ft_Gpu_Copro_SendCmd(  c);
-  Ft_Gpu_Copro_SendCmd(  d);
-  Ft_Gpu_Copro_SendCmd(  e);
-  Ft_Gpu_Copro_SendCmd(  f);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*7));         
+  StartFunc( FT_CMD_SIZE*7);
+  SendCmd(  CMD_GETMATRIX);
+  SendCmd(  a);
+  SendCmd(  b);
+  SendCmd(  c);
+  SendCmd(  d);
+  SendCmd(  e);
+  SendCmd(  f);
+  EndFunc( (FT_CMD_SIZE*7));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Sketch( ft_int16_t x, ft_int16_t y, ft_uint16_t w, ft_uint16_t h, ft_uint32_t ptr, ft_uint16_t format)
+ft_void_t FT800::Sketch( ft_int16_t x, ft_int16_t y, ft_uint16_t w, ft_uint16_t h, ft_uint32_t ptr, ft_uint16_t format)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);         
-  Ft_Gpu_Copro_SendCmd(  CMD_SKETCH);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  format);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));         
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_SKETCH);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  ptr);
+  SendCmd(  format);
+  EndFunc( (FT_CMD_SIZE*5));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_MemSet( ft_uint32_t ptr, ft_uint32_t value, ft_uint32_t num)
+ft_void_t FT800::MemSet( ft_uint32_t ptr, ft_uint32_t value, ft_uint32_t num)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);         
-  Ft_Gpu_Copro_SendCmd(  CMD_MEMSET);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  value);
-  Ft_Gpu_Copro_SendCmd(  num);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));         
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_MEMSET);
+  SendCmd(  ptr);
+  SendCmd(  value);
+  SendCmd(  num);
+  EndFunc( (FT_CMD_SIZE*4));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_GradColor( ft_uint32_t c)
+ft_void_t FT800::GradColor( ft_uint32_t c)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);         
-  Ft_Gpu_Copro_SendCmd(  CMD_GRADCOLOR);
-  Ft_Gpu_Copro_SendCmd(  c);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));         
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_GRADCOLOR);
+  SendCmd(  c);
+  EndFunc( (FT_CMD_SIZE*2));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_BitmapTransform( ft_int32_t x0, ft_int32_t y0, ft_int32_t x1, ft_int32_t y1, ft_int32_t x2, ft_int32_t y2, ft_int32_t tx0, ft_int32_t ty0, ft_int32_t tx1, ft_int32_t ty1, ft_int32_t tx2, ft_int32_t ty2, ft_uint16_t result)
+ft_void_t FT800::BitmapTransform( ft_int32_t x0, ft_int32_t y0, ft_int32_t x1, ft_int32_t y1, ft_int32_t x2, ft_int32_t y2, ft_int32_t tx0, ft_int32_t ty0, ft_int32_t tx1, ft_int32_t ty1, ft_int32_t tx2, ft_int32_t ty2, ft_uint16_t result)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*6*2+FT_CMD_SIZE*2);         
-  Ft_Gpu_Copro_SendCmd(  CMD_BITMAP_TRANSFORM);
-  Ft_Gpu_Copro_SendCmd(  x0);
-  Ft_Gpu_Copro_SendCmd(  y0);
-  Ft_Gpu_Copro_SendCmd(  x1);
-  Ft_Gpu_Copro_SendCmd(  y1);
-  Ft_Gpu_Copro_SendCmd(  x2);
-  Ft_Gpu_Copro_SendCmd(  y2);
-  Ft_Gpu_Copro_SendCmd(  tx0);
-  Ft_Gpu_Copro_SendCmd(  ty0);
-  Ft_Gpu_Copro_SendCmd(  tx1);
-  Ft_Gpu_Copro_SendCmd(  ty1);
-  Ft_Gpu_Copro_SendCmd(  tx2);
-  Ft_Gpu_Copro_SendCmd(  ty2);
-  Ft_Gpu_Copro_SendCmd(  result);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*6*2+FT_CMD_SIZE*2));     
+  StartFunc( FT_CMD_SIZE*6*2+FT_CMD_SIZE*2);
+  SendCmd(  CMD_BITMAP_TRANSFORM);
+  SendCmd(  x0);
+  SendCmd(  y0);
+  SendCmd(  x1);
+  SendCmd(  y1);
+  SendCmd(  x2);
+  SendCmd(  y2);
+  SendCmd(  tx0);
+  SendCmd(  ty0);
+  SendCmd(  tx1);
+  SendCmd(  ty1);
+  SendCmd(  tx2);
+  SendCmd(  ty2);
+  SendCmd(  result);
+  EndFunc( (FT_CMD_SIZE*6*2+FT_CMD_SIZE*2));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_Calibrate( ft_uint32_t result)
+ft_void_t FT800::Calibrate( ft_uint32_t result)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);     
-  Ft_Gpu_Copro_SendCmd(  CMD_CALIBRATE);
-  Ft_Gpu_Copro_SendCmd(  result);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));   
-  Ft_Gpu_Hal_WaitCmdfifo_empty( );
-  
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_CALIBRATE);
+  SendCmd(  result);
+  EndFunc( (FT_CMD_SIZE*2));
+  WaitCmdfifo_empty( );
+
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_SetFont( ft_uint32_t font, ft_uint32_t ptr)
+ft_void_t FT800::SetFont( ft_uint32_t font, ft_uint32_t ptr)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);       
-  Ft_Gpu_Copro_SendCmd(  CMD_SETFONT);
-  Ft_Gpu_Copro_SendCmd(  font);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));       
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_SETFONT);
+  SendCmd(  font);
+  SendCmd(  ptr);
+  EndFunc( (FT_CMD_SIZE*3));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_Logo(  )
+ft_void_t FT800::Logo(  )
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);       
-  Ft_Gpu_Copro_SendCmd(  CMD_LOGO);  
-  Ft_Gpu_CoCmd_EndFunc( FT_CMD_SIZE*1); 
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_LOGO);
+  EndFunc( FT_CMD_SIZE*1);
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_Append( ft_uint32_t ptr, ft_uint32_t num)
+ft_void_t FT800::Append( ft_uint32_t ptr, ft_uint32_t num)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);       
-  Ft_Gpu_Copro_SendCmd(  CMD_APPEND);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  num);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));       
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_APPEND);
+  SendCmd(  ptr);
+  SendCmd(  num);
+  EndFunc( (FT_CMD_SIZE*3));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_MemZero( ft_uint32_t ptr, ft_uint32_t num)
+ft_void_t FT800::MemZero( ft_uint32_t ptr, ft_uint32_t num)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);       
-  Ft_Gpu_Copro_SendCmd(  CMD_MEMZERO);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  num);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));       
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_MEMZERO);
+  SendCmd(  ptr);
+  SendCmd(  num);
+  EndFunc( (FT_CMD_SIZE*3));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_Scale( ft_int32_t sx, ft_int32_t sy)
+ft_void_t FT800::Scale( ft_int32_t sx, ft_int32_t sy)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);       
-  Ft_Gpu_Copro_SendCmd(  CMD_SCALE);
-  Ft_Gpu_Copro_SendCmd(  sx);
-  Ft_Gpu_Copro_SendCmd(  sy);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));       
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_SCALE);
+  SendCmd(  sx);
+  SendCmd(  sy);
+  EndFunc( (FT_CMD_SIZE*3));
 }
-ft_void_t FT800::Ft_Gpu_CoCmd_Clock( ft_int16_t x, ft_int16_t y, ft_int16_t r, ft_uint16_t options, ft_uint16_t h, ft_uint16_t m, ft_uint16_t s, ft_uint16_t ms)
+ft_void_t FT800::Clock( ft_int16_t x, ft_int16_t y, ft_int16_t r, ft_uint16_t options, ft_uint16_t h, ft_uint16_t m, ft_uint16_t s, ft_uint16_t ms)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);         
-  Ft_Gpu_Copro_SendCmd(  CMD_CLOCK);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)options<<16)|r));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)m<<16)|h));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)ms<<16)|s));
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));       
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_CLOCK);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)options<<16)|r));
+  SendCmd(  (((ft_uint32_t)m<<16)|h));
+  SendCmd(  (((ft_uint32_t)ms<<16)|s));
+  EndFunc( (FT_CMD_SIZE*5));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Gradient( ft_int16_t x0, ft_int16_t y0, ft_uint32_t rgb0, ft_int16_t x1, ft_int16_t y1, ft_uint32_t rgb1)
+ft_void_t FT800::Gradient( ft_int16_t x0, ft_int16_t y0, ft_uint32_t rgb0, ft_int16_t x1, ft_int16_t y1, ft_uint32_t rgb1)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);         
-  Ft_Gpu_Copro_SendCmd(  CMD_GRADIENT);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y0<<16)|(x0 & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  rgb0);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y1<<16)|(x1 & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  rgb1);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));         
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_GRADIENT);
+  SendCmd(  (((ft_uint32_t)y0<<16)|(x0 & 0xffff)));
+  SendCmd(  rgb0);
+  SendCmd(  (((ft_uint32_t)y1<<16)|(x1 & 0xffff)));
+  SendCmd(  rgb1);
+  EndFunc( (FT_CMD_SIZE*5));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_SetMatrix(  )
+ft_void_t FT800::SetMatrix(  )
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);         
-  Ft_Gpu_Copro_SendCmd(  CMD_SETMATRIX);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));         
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_SETMATRIX);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Track( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_int16_t tag)
+ft_void_t FT800::Track( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_int16_t tag)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);         
-  Ft_Gpu_Copro_SendCmd(  CMD_TRACK);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  tag);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));       
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_TRACK);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  tag);
+  EndFunc( (FT_CMD_SIZE*4));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_GetPtr( ft_uint32_t result)
+ft_void_t FT800::GetPtr( ft_uint32_t result)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);         
-  Ft_Gpu_Copro_SendCmd(  CMD_GETPTR);
-  Ft_Gpu_Copro_SendCmd(  result);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));         
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_GETPTR);
+  SendCmd(  result);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Progress( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_uint16_t options, ft_uint16_t val, ft_uint16_t range)
+ft_void_t FT800::Progress( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_uint16_t options, ft_uint16_t val, ft_uint16_t range)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*5);         
-  Ft_Gpu_Copro_SendCmd(  CMD_PROGRESS);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)val<<16)|options));
-  Ft_Gpu_Copro_SendCmd(  range);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*5));         
+  StartFunc( FT_CMD_SIZE*5);
+  SendCmd(  CMD_PROGRESS);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  (((ft_uint32_t)val<<16)|options));
+  SendCmd(  range);
+  EndFunc( (FT_CMD_SIZE*5));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_ColdStart(  )
+ft_void_t FT800::ColdStart(  )
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);       
-  Ft_Gpu_Copro_SendCmd(  CMD_COLDSTART);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));       
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_COLDSTART);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Keys( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_int16_t font, ft_uint16_t options, const ft_char8_t* s)
+ft_void_t FT800::Keys( ft_int16_t x, ft_int16_t y, ft_int16_t w, ft_int16_t h, ft_int16_t font, ft_uint16_t options, const ft_char8_t* s)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4 + strlen(s) + 1);         
-  Ft_Gpu_Copro_SendCmd(  CMD_KEYS);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)h<<16)|w));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)options<<16)|font));
-  Ft_Gpu_CoCmd_SendStr(  s);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4 + strlen(s) + 1));           
+  StartFunc( FT_CMD_SIZE*4 + strlen(s) + 1);
+  SendCmd(  CMD_KEYS);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)h<<16)|w));
+  SendCmd(  (((ft_uint32_t)options<<16)|font));
+  SendStr(  s);
+  EndFunc( (FT_CMD_SIZE*4 + strlen(s) + 1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Dial( ft_int16_t x, ft_int16_t y, ft_int16_t r, ft_uint16_t options, ft_uint16_t val)
+ft_void_t FT800::Dial( ft_int16_t x, ft_int16_t y, ft_int16_t r, ft_uint16_t options, ft_uint16_t val)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);           
-  Ft_Gpu_Copro_SendCmd(  CMD_DIAL);
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
-  Ft_Gpu_Copro_SendCmd(  (((ft_uint32_t)options<<16)|r));
-  Ft_Gpu_Copro_SendCmd(  val);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));           
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_DIAL);
+  SendCmd(  (((ft_uint32_t)y<<16)|(x & 0xffff)));
+  SendCmd(  (((ft_uint32_t)options<<16)|r));
+  SendCmd(  val);
+  EndFunc( (FT_CMD_SIZE*4));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_LoadImage( ft_uint32_t ptr, ft_uint32_t options)
+ft_void_t FT800::LoadImage( ft_uint32_t ptr, ft_uint32_t options)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*3);           
-  Ft_Gpu_Copro_SendCmd(  CMD_LOADIMAGE);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  options);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*3));           
+  StartFunc( FT_CMD_SIZE*3);
+  SendCmd(  CMD_LOADIMAGE);
+  SendCmd(  ptr);
+  SendCmd(  options);
+  EndFunc( (FT_CMD_SIZE*3));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Dlstart(  )
+ft_void_t FT800::Dlstart(  )
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);           
-  Ft_Gpu_Copro_SendCmd(  CMD_DLSTART);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));             
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_DLSTART);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_Snapshot( ft_uint32_t ptr)
+ft_void_t FT800::Snapshot( ft_uint32_t ptr)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*2);             
-  Ft_Gpu_Copro_SendCmd(  CMD_SNAPSHOT);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*2));             
+  StartFunc( FT_CMD_SIZE*2);
+  SendCmd(  CMD_SNAPSHOT);
+  SendCmd(  ptr);
+  EndFunc( (FT_CMD_SIZE*2));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_ScreenSaver(  )
+ft_void_t FT800::ScreenSaver(  )
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*1);             
-  Ft_Gpu_Copro_SendCmd(  CMD_SCREENSAVER);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*1));             
+  StartFunc( FT_CMD_SIZE*1);
+  SendCmd(  CMD_SCREENSAVER);
+  EndFunc( (FT_CMD_SIZE*1));
 }
 
-ft_void_t FT800::Ft_Gpu_CoCmd_MemCrc( ft_uint32_t ptr, ft_uint32_t num, ft_uint32_t result)
+ft_void_t FT800::MemCrc( ft_uint32_t ptr, ft_uint32_t num, ft_uint32_t result)
 {
-  Ft_Gpu_CoCmd_StartFunc( FT_CMD_SIZE*4);             
-  Ft_Gpu_Copro_SendCmd(  CMD_MEMCRC);
-  Ft_Gpu_Copro_SendCmd(  ptr);
-  Ft_Gpu_Copro_SendCmd(  num);
-  Ft_Gpu_Copro_SendCmd(  result);
-  Ft_Gpu_CoCmd_EndFunc( (FT_CMD_SIZE*4));             
+  StartFunc( FT_CMD_SIZE*4);
+  SendCmd(  CMD_MEMCRC);
+  SendCmd(  ptr);
+  SendCmd(  num);
+  SendCmd(  result);
+  EndFunc( (FT_CMD_SIZE*4));
 }
 
 
-ft_void_t FT800::Ft_App_WrCoCmd_Buffer(ft_uint32_t cmd)
+ft_void_t FT800::WrCoCmd_Buffer(ft_uint32_t cmd)
 {
-   Ft_Gpu_Hal_WrCmd32(cmd);
+   WrCmd32(cmd);
    /* Increment the command index */
-   Ft_CmdBuffer_Index += FT_CMD_SIZE;  
+   CmdBuffer_Index += FT_CMD_SIZE;
 }
 
-ft_void_t FT800::Ft_App_WrDlCmd_Buffer(ft_uint32_t cmd)
+ft_void_t FT800::WrDlCmd_Buffer(ft_uint32_t cmd)
 {
-   Ft_Gpu_Hal_Wr32((RAM_DL+Ft_DlBuffer_Index),cmd);
+   Wr32((RAM_DL+DlBuffer_Index),cmd);
    /* Increment the command index */
-   Ft_DlBuffer_Index += FT_CMD_SIZE;  
+   DlBuffer_Index += FT_CMD_SIZE;
 }
 
-ft_void_t FT800::Ft_App_Flush_DL_Buffer()
+ft_void_t FT800::Flush_DL_Buffer()
 {
-   Ft_DlBuffer_Index = 0;
-   
+   DlBuffer_Index = 0;
+
 }
 
-ft_void_t FT800::Ft_App_Flush_Co_Buffer()
+ft_void_t FT800::Flush_Co_Buffer()
 {
-   Ft_CmdBuffer_Index = 0;
+   CmdBuffer_Index = 0;
 }
 
 
 /* API to check the status of previous DLSWAP and perform DLSWAP of new DL */
 /* Check for the status of previous DLSWAP and if still not done wait for few ms and check again */
-ft_void_t FT800::GPU_DLSwap(ft_uint8_t DL_Swap_Type)
+ft_void_t FT800::DLSwap(ft_uint8_t DL_Swap_Type)
 {
     ft_uint8_t Swap_Type = DLSWAP_FRAME,Swap_Done = DLSWAP_FRAME;
 
@@ -515,18 +515,18 @@
     }
 
     /* Perform a new DL swap */
-    Ft_Gpu_Hal_Wr8(REG_DLSWAP,Swap_Type);
+    Wr8(REG_DLSWAP,Swap_Type);
 
     /* Wait till the swap is done */
     while(Swap_Done)
     {
-        Swap_Done = Ft_Gpu_Hal_Rd8(REG_DLSWAP);
+        Swap_Done = Rd8(REG_DLSWAP);
 
         if(DLSWAP_DONE != Swap_Done)
         {
-            Ft_Gpu_Hal_Sleep(10);//wait for 10ms
+            Sleep(10);//wait for 10ms
         }
-    }   
+    }
 }