nf_512B.h

Go to the documentation of this file.
00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 #ifndef _NF_512B_H_
00016 #define _NF_512B_H_
00017 
00018 #define  NF_TYPE_512B_KNOWN   FALSE // No static mode define by default
00019 
00022 #define  CONF_512B_F1_1    0
00023 #define  CONF_512B_F1_2    1
00024 #define  CONF_512B_F1_3    2
00025 #define  CONF_512B_F2_1    3
00026 #define  CONF_512B_F2_2    4
00027 #define  CONF_512B_F2_3    5
00028 #define  CONF_512B_F3_1    6
00029 #define  CONF_512B_F3_2    7
00030 #define  CONF_512B_F3_3    8
00031 #define  CONF_512B_F3_4    9
00032 #define  CONF_512B_F3_5    10
00033 #define  CONF_512B_F3_6    11
00034 #define  CONF_512B_F3_7    12
00035 #define  CONF_512B_F3_8    13
00036 #define  CONF_512B_F3_9    14
00037 #define  CONF_512B_F3_10   15
00038 #define  CONF_512B_F4_1    16
00039 #define  CONF_512B_F4_2    17
00040 #define  CONF_512B_F4_3    18
00041 #define  CONF_512B_F4_4    19
00042 
00043 
00044 #if (NF_AUTO_DETECT_512B==TRUE)
00045 
00046 //**********  LIST USED FOR GENERIC 512B DRIVER ************
00047 
00050 #  if (!defined _nfc_drv_c_)
00051 extern _CONST_TYPE_   St_nf_conf  nf_list_conf[];
00052 #  else
00053 _CONST_TYPE_   St_nf_conf  nf_list_conf[]=
00054 {
00055   { 1,1,0,1,1, (CLK_DFC_NFC_40MHz)>>5}  // CONF_512B_F1_1
00056 , { 1,1,0,0,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F1_2
00057 , { 1,1,0,0,0, (CLK_DFC_NFC_24MHz)>>5}  // CONF_512B_F1_3
00058 , { 2,1,0,0,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F2_1
00059 , { 2,1,0,0,0, (CLK_DFC_NFC_24MHz)>>5}  // CONF_512B_F2_2
00060 , { 2,1,0,0,0, (CLK_DFC_NFC_16MHz)>>5}  // CONF_512B_F2_3
00061 , { 2,2,0,1,1, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_1
00062 , { 2,2,0,1,0, (CLK_DFC_NFC_24MHz)>>5}  // CONF_512B_F3_2
00063 , { 2,4,0,1,1, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_3
00064 , { 2,4,0,1,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_4
00065 , { 2,4,0,1,0, (CLK_DFC_NFC_24MHz)>>5}  // CONF_512B_F3_5
00066 , { 1,2,0,1,1, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_6
00067 , { 1,2,0,1,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_7
00068 , { 1,2,0,1,0, (CLK_DFC_NFC_24MHz)>>5}  // CONF_512B_F3_8
00069 , { 1,4,0,1,1, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_9
00070 , { 1,4,0,1,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F3_10
00071 , { 0,0,0,1,1, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F4_1
00072 , { 0,0,0,0,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F4_2
00073 , { 0,0,0,1,0, (CLK_DFC_NFC_30MHz)>>5}  // CONF_512B_F4_3
00074 , { 0,0,0,1,0, (CLK_DFC_NFC_24MHz)>>5}  // CONF_512B_F4_4
00075 };
00076 #endif
00077 
00078 
00081 #  if (!defined _nfc_drv_c_)
00082 extern _CONST_TYPE_   St_nf_id    nf_list_id[];
00083 #  else
00084 _CONST_TYPE_   St_nf_id    nf_list_id[]=
00085 {
00086 //  Maker         ,ID    ,Conf               // References
00087   { M_ID_HYNIX    ,0x35  ,CONF_512B_F2_2 }   // HY27SS08561M
00088 , { M_ID_HYNIX    ,0x36  ,CONF_512B_F2_3 }   // HY27SS08121M
00089 , { M_ID_HYNIX    ,0x75  ,CONF_512B_F2_1 }   // HY27US08561M
00090 , { M_ID_HYNIX    ,0x76  ,CONF_512B_F2_1 }   // HY27US08121M
00091                                             
00092 , { M_ID_INFINEON ,0x66  ,CONF_512B_F1_1 }   // HYF31DS51280[4/5]BT[C/I]
00093                                             
00094 , { M_ID_SAMSUNG  ,0x33  ,CONF_512B_F4_4 }   // K9F2808Q0B
00095 //{ M_ID_SAMSUNG  ,0x35  ,CONF_512B_F3_6 }   // K9F5608Q0B, K9F5608R0D
00096 , { M_ID_SAMSUNG  ,0x35  ,CONF_512B_F3_8 }   // K9F5608Q0C
00097 //{ M_ID_SAMSUNG  ,0x36  ,CONF_512B_F3_9 }   // K9F1208Q0A, K9F1208Q0B
00098 , { M_ID_SAMSUNG  ,0x36  ,CONF_512B_F3_2 }   // K9K1208Q0C
00099                                             
00100 , { M_ID_SAMSUNG  ,0x73  ,CONF_512B_F4_1 }   // K9F2808U0B, K9F2808U0C
00101 //{ M_ID_SAMSUNG  ,0x75  ,CONF_512B_F3_6 }   // K9F5608D0C, K9F5608U0B, K9F5608U0C, K9F5608U0D
00102 , { M_ID_SAMSUNG  ,0x75  ,CONF_512B_F3_7 }   // K9F5608U0A
00103 , { M_ID_SAMSUNG  ,0x76  ,CONF_512B_F4_2 }   // K9F1208R0C, K9F1208U0C
00104 //{ M_ID_SAMSUNG  ,0x76  ,CONF_512B_F3_9 }   // K9F1208D0A, K9F1208D0B, K9F1208U0A, K9F1208U0B
00105 //{ M_ID_SAMSUNG  ,0x76  ,CONF_512B_F3_10}   // K9F1208U0M
00106 //{ M_ID_SAMSUNG  ,0x76  ,CONF_512B_F3_1 }   // K9K1208D0C, K9K1208U0C
00107 , { M_ID_SAMSUNG  ,0x78  ,CONF_512B_F3_5 }   // K9K1G08Q0A
00108 //{ M_ID_SAMSUNG  ,0x79  ,CONF_512B_F3_3 }   // K9K1G08U0A
00109 , { M_ID_SAMSUNG  ,0x79  ,CONF_512B_F3_4 }   // K9K1G08U0M
00110                                             
00111 , { M_ID_ST       ,0x33  ,CONF_512B_F1_3 }   // NAND128R3A
00112 , { M_ID_ST       ,0x35  ,CONF_512B_F1_3 }   // NAND256R3A
00113 , { M_ID_ST       ,0x36  ,CONF_512B_F1_3 }   // NAND512R3A
00114 , { M_ID_ST       ,0x39  ,CONF_512B_F1_3 }   // NAND01GR3A
00115 , { M_ID_ST       ,0x73  ,CONF_512B_F4_2 }   // NAND128W3A
00116 , { M_ID_ST       ,0x75  ,CONF_512B_F1_2 }   // NAND256W3A
00117 , { M_ID_ST       ,0x76  ,CONF_512B_F1_2 }   // NAND512W3A
00118 , { M_ID_ST       ,0x79  ,CONF_512B_F1_2 }   // NAND01GW3A
00119                                             
00120 , { M_ID_TOSHIBA  ,0x73  ,CONF_512B_F4_2 }   // TC58128AFT, TC58128AFTI
00121 //{ M_ID_TOSHIBA  ,0x73  ,CONF_512B_F4_3 }   // TC58DAM72A1FT00, TC58DVM72A1FT00, TC58DVM72A1FTI0
00122 , { M_ID_TOSHIBA  ,0x75  ,CONF_512B_F4_2 }   // TC58256AFT, TC58256AFTI
00123 //{ M_ID_TOSHIBA  ,0x75  ,CONF_512B_F4_3 }   // TC582562AXB, TC58DAM82A1FT00, TC58DVM82A1FT00, TC58DVM82A1FTI0, TC58DVM82A1XBJ1
00124 , { M_ID_TOSHIBA  ,0x76  ,CONF_512B_F4_2 }   // TC58512FT, TC58512FTI
00125 //{ M_ID_TOSHIBA  ,0x76  ,CONF_512B_F4_3 }   // TC58DVM92A1FT00, TC58DWM92A2XGJ5, TC58DWM92A2XGJX, TC58DVM92A1FTI0
00126 , { M_ID_TOSHIBA  ,0x79  ,CONF_512B_F4_2 }   // TH58100FT, TH58100FTI
00127 //{ M_ID_TOSHIBA  ,0x79  ,CONF_512B_F4_3 }   // TC58DVG02A1FT00, TC58DVG02A1FTI0
00128 
00129 // !! Nand FLash 512B 16 pages not supported by generic driver 512B
00130 //{ M_ID_SAMSUNG  ,0x39  ,CONF_512B_F4_1 }   // K9F6408U0C
00131 //{ M_ID_SAMSUNG  ,0xE6  ,CONF_512B_F4_1 }   // K9F6408Q0C
00132 //{ M_ID_SAMSUNG  ,0xE6  ,CONF_512B_F4_3 }   // K9F6408U0B
00133 //{ M_ID_TOSHIBA  ,0xE6  ,CONF_512B_F4_2 }   // TC58V64BFT, TC58V64BFTI
00134 };
00135 #  endif // (!defined _nfc_drv_c_)
00136 
00137 
00140 #  if (!defined _nfc_drv_c_)
00141 extern _CONST_TYPE_   St_nf_link_id_block  nf_list_link_id_block[];
00142 #  else
00143 _CONST_TYPE_   St_nf_link_id_block  nf_list_link_id_block[]=
00144 {
00145 // !! Nand FLash 512B 32 pages
00146   { 0x33   ,1 }
00147 , { 0x35   ,2 }
00148 , { 0x36   ,4 }
00149 , { 0x39   ,8 }  // Specific ST
00150 , { 0x66   ,4 }
00151 , { 0x73   ,1 }
00152 , { 0x75   ,2 }
00153 , { 0x76   ,4 }
00154 , { 0x78 ,8 }
00155 , { 0x79   ,8 }
00156 // !! Nand FLash 512B 16 pages not supported by generic driver 512B
00157 //{ 0x39 ,1 }  // Specific Samsung
00158 //{ 0xE6 ,1 }
00159 };
00160 #  endif // (!defined _nfc_drv_c_)
00161 
00162 
00163 #else    // (NF_AUTO_DETECT_512B==TRUE)
00164 
00165 
00166 //**********  LIST USED FOR SINGLE 512B DRIVER ************
00167 #  undef  NF_DEV_CONF   // In case of define by other listing (e.g. 2KB)
00168 
00169 // LIST USED FOR SINGLE 512B DRIVER with 16 pages per block                       
00170 
00171 #if    (defined NF_TYPE_K9F6408U0C)
00172 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00173 #  define NF_DEV_ID     0x39
00174 #  define NF_DEV_CONF   CONF_512B_F4_1
00175 #  define NF_N_ZONES    1
00176 #  define NF_SHIFT_BLOCK_PAGE          4  // (1<<n) size of block (16p), unit in pages
00177                         
00178 #elif  (defined NF_TYPE_K9F6408Q0C)
00179 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00180 #  define NF_DEV_ID     0xE6
00181 #  define NF_DEV_CONF   CONF_512B_F4_1
00182 #  define NF_N_ZONES    1
00183 #  define NF_SHIFT_BLOCK_PAGE          4  // (1<<n) size of block (16p), unit in pages
00184                         
00185 #elif  (defined NF_TYPE_K9F6408U0B)
00186 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00187 #  define NF_DEV_ID     0xE6
00188 #  define NF_DEV_CONF   CONF_512B_F4_3
00189 #  define NF_N_ZONES    1
00190 #  define NF_SHIFT_BLOCK_PAGE          4  // (1<<n) size of block (16p), unit in pages
00191                         
00192 #elif  (defined NF_TYPE_TC58V64BFT) || (defined NF_TYPE_TC58V64BFTI)
00193 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00194 #  define NF_DEV_ID     0xE6
00195 #  define NF_DEV_CONF   CONF_512B_F4_2
00196 #  define NF_N_ZONES    1
00197 #  define NF_SHIFT_BLOCK_PAGE          4  // (1<<n) size of block (16p), unit in pages
00198 
00199 
00200 // LIST USED FOR SINGLE 512B DRIVER with 32 pages per block
00201                       
00202 #elif  (defined NF_TYPE_HY27SS08561M)
00203 #  define NF_DEV_MAKER  M_ID_HYNIX
00204 #  define NF_DEV_ID     0x35
00205 #  define NF_DEV_CONF   CONF_512B_F2_2
00206                         
00207 #elif  (defined NF_TYPE_HY27SS08121M)
00208 #  define NF_DEV_MAKER  M_ID_HYNIX
00209 #  define NF_DEV_ID     0x36
00210 #  define NF_DEV_CONF   CONF_512B_F2_3
00211  
00212 #elif  (defined NF_TYPE_HY27US08561M)
00213 #  define NF_DEV_MAKER  M_ID_HYNIX
00214 #  define NF_DEV_ID     0x75
00215 #  define NF_DEV_CONF   CONF_512B_F2_1
00216                         
00217 #elif  (defined NF_TYPE_HY27US08121M)
00218 #  define NF_DEV_MAKER  M_ID_HYNIX
00219 #  define NF_DEV_ID     0x76
00220 #  define NF_DEV_CONF   CONF_512B_F2_1
00221                                                
00222 #elif  (defined NF_TYPE_HYF31DS51280XBT)
00223 #  define NF_DEV_MAKER  M_ID_INFINEON
00224 #  define NF_DEV_ID     0x66
00225 #  define NF_DEV_CONF   CONF_512B_F1_1
00226 
00227 #elif  (defined NF_TYPE_K9F2808Q0B)
00228 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00229 #  define NF_DEV_ID     0x33
00230 #  define NF_DEV_CONF   CONF_512B_F4_4
00231                         
00232 #elif  (defined NF_TYPE_K9F5608Q0B) || (defined NF_TYPE_K9F5608R0D)
00233 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00234 #  define NF_DEV_ID     0x35
00235 #  define NF_DEV_CONF   CONF_512B_F3_6
00236                   
00237 #elif  (defined NF_TYPE_K9F5608Q0C)
00238 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00239 #  define NF_DEV_ID     0x35
00240 #  define NF_DEV_CONF   CONF_512B_F3_8
00241                         
00242 #elif  (defined NF_TYPE_K9F1208Q0A) || (defined NF_TYPE_K9F1208Q0B)
00243 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00244 #  define NF_DEV_ID     0x36
00245 #  define NF_DEV_CONF   CONF_512B_F3_9
00246                                                
00247 #elif  (defined NF_TYPE_K9K1208Q0C)
00248 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00249 #  define NF_DEV_ID     0x36
00250 #  define NF_DEV_CONF   CONF_512B_F3_2
00251         
00252 #elif  (defined NF_TYPE_K9F2808U0B) || (defined NF_TYPE_K9F2808U0C)
00253 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00254 #  define NF_DEV_ID     0x73
00255 #  define NF_DEV_CONF   CONF_512B_F4_1
00256                       
00257 #elif  (defined NF_TYPE_K9F5608D0C) || (defined NF_TYPE_K9F5608U0B) || (defined NF_TYPE_K9F5608U0C) || (defined NF_TYPE_K9F5608U0D)
00258 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00259 #  define NF_DEV_ID     0x75
00260 #  define NF_DEV_CONF   CONF_512B_F3_6
00261                         
00262 #elif  (defined NF_TYPE_K9F5608U0A)
00263 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00264 #  define NF_DEV_ID     0x75
00265 #  define NF_DEV_CONF   CONF_512B_F3_7
00266                                                      
00267 #elif  (defined NF_TYPE_K9F1208R0C) || (defined NF_TYPE_K9F1208U0C)
00268 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00269 #  define NF_DEV_ID     0x76
00270 #  define NF_DEV_CONF   CONF_512B_F4_2
00271                    
00272 #elif  (defined NF_TYPE_K9F1208D0A) || (defined NF_TYPE_K9F1208D0B) || (defined NF_TYPE_K9F1208U0A) || (defined NF_TYPE_K9F1208U0B)
00273 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00274 #  define NF_DEV_ID     0x76
00275 #  define NF_DEV_CONF   CONF_512B_F3_9
00276                                                
00277 #elif  (defined NF_TYPE_K9F1208U0M)
00278 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00279 #  define NF_DEV_ID     0x76
00280 #  define NF_DEV_CONF   CONF_512B_F3_10
00281                         
00282 #elif  (defined NF_TYPE_K9K1208D0C) || (defined NF_TYPE_K9K1208U0C)
00283 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00284 #  define NF_DEV_ID     0x76
00285 #  define NF_DEV_CONF   CONF_512B_F3_1
00286                        
00287 #elif  (defined NF_TYPE_K9K1G08Q0A)
00288 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00289 #  define NF_DEV_ID     0x78
00290 #  define NF_DEV_CONF   CONF_512B_F3_5
00291                         
00292 #elif  (defined NF_TYPE_K9K1G08U0A)
00293 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00294 #  define NF_DEV_ID     0x79
00295 #  define NF_DEV_CONF   CONF_512B_F3_3
00296                         
00297 #elif  (defined NF_TYPE_K9K1G08U0M)
00298 #  define NF_DEV_MAKER  M_ID_SAMSUNG
00299 #  define NF_DEV_ID     0x79
00300 #  define NF_DEV_CONF   CONF_512B_F3_4
00301 
00302 #elif  (defined NF_TYPE_NAND128R3A)
00303 #  define NF_DEV_MAKER  M_ID_ST
00304 #  define NF_DEV_ID     0x33
00305 #  define NF_DEV_CONF   CONF_512B_F1_3
00306                         
00307 #elif  (defined NF_TYPE_NAND256R3A)
00308 #  define NF_DEV_MAKER  M_ID_ST
00309 #  define NF_DEV_ID     0x35
00310 #  define NF_DEV_CONF   CONF_512B_F1_3
00311                         
00312 #elif  (defined NF_TYPE_NAND512R3A)
00313 #  define NF_DEV_MAKER  M_ID_ST
00314 #  define NF_DEV_ID     0x36
00315 #  define NF_DEV_CONF   CONF_512B_F1_3
00316                         
00317 #elif  (defined NF_TYPE_NAND01GR3A)
00318 #  define NF_DEV_MAKER  M_ID_ST
00319 #  define NF_DEV_ID     0x39
00320 #  define NF_DEV_CONF   CONF_512B_F1_3
00321                         
00322 #elif  (defined NF_TYPE_NAND128W3A)
00323 #  define NF_DEV_MAKER  M_ID_ST
00324 #  define NF_DEV_ID     0x73
00325 #  define NF_DEV_CONF   CONF_512B_F4_2
00326                         
00327 #elif  (defined NF_TYPE_NAND256W3A)
00328 #  define NF_DEV_MAKER  M_ID_ST
00329 #  define NF_DEV_ID     0x75
00330 #  define NF_DEV_CONF   CONF_512B_F1_2
00331                         
00332 #elif  (defined NF_TYPE_NAND512W3A)
00333 #  define NF_DEV_MAKER  M_ID_ST
00334 #  define NF_DEV_ID     0x76
00335 #  define NF_DEV_CONF   CONF_512B_F1_2
00336                         
00337 #elif  (defined NF_TYPE_NAND01GW3A)
00338 #  define NF_DEV_MAKER  M_ID_ST
00339 #  define NF_DEV_ID     0x79
00340 #  define NF_DEV_CONF   CONF_512B_F1_2
00341                          
00342 #elif  (defined NF_TYPE_TC58128AFT) || (defined NF_TYPE_TC58128AFTI)
00343 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00344 #  define NF_DEV_ID     0x73
00345 #  define NF_DEV_CONF   CONF_512B_F4_2
00346                         
00347 #elif  (defined NF_TYPE_TC58DAM72A1FT00) || (defined NF_TYPE_TC58DVM72A1FT00) || (defined NF_TYPE_TC58DVM72A1FTI0)
00348 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00349 #  define NF_DEV_ID     0x73
00350 #  define NF_DEV_CONF   CONF_512B_F4_3
00351                                                   
00352 #elif  (defined NF_TYPE_TC58256AFT) || (defined NF_TYPE_TC58256AFTI)
00353 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00354 #  define NF_DEV_ID     0x75
00355 #  define NF_DEV_CONF   CONF_512B_F4_2
00356                      
00357 #elif  (defined NF_TYPE_TC582562AXB) || (defined NF_TYPE_TC58DAM82A1FT00) || (defined NF_TYPE_TC58DVM82A1FT00) || (defined NF_TYPE_TC58DVM82A1FTI0) || (defined NF_TYPE_TC58DVM82A1XBJ1)
00358 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00359 #  define NF_DEV_ID     0x75
00360 #  define NF_DEV_CONF   CONF_512B_F4_3
00361                                                   
00362 #elif  (defined NF_TYPE_TC58512FT) || (defined NF_TYPE_TC58512FTI)
00363 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00364 #  define NF_DEV_ID     0x76
00365 #  define NF_DEV_CONF   CONF_512B_F4_2
00366                                     
00367 #elif  (defined NF_TYPE_TC58DVM92A1FT00) || (defined NF_TYPE_TC58DVM92A1FTI0) || (defined NF_TYPE_TC58DWM92A2XGJ5) || (defined NF_TYPE_TC58DWM92A2XGJX)
00368 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00369 #  define NF_DEV_ID     0x76
00370 #  define NF_DEV_CONF   CONF_512B_F4_3
00371                                                   
00372 #elif  (defined NF_TYPE_TH58100FT) || (defined NF_TYPE_TH58100FTI)
00373 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00374 #  define NF_DEV_ID     0x79
00375 #  define NF_DEV_CONF   CONF_512B_F4_2
00376                      
00377 #elif  (defined NF_TYPE_TC58DVG02A1FT00) || (defined NF_TYPE_TC58DVG02A1FTI0)
00378 #  define NF_DEV_MAKER  M_ID_TOSHIBA
00379 #  define NF_DEV_ID     0x79
00380 #  define NF_DEV_CONF   CONF_512B_F4_3
00381 
00382 #endif
00383 
00384 
00385 #if (defined NF_DEV_CONF)
00386 
00387 #  undef  NF_TYPE_512B_KNOWN
00388 #  define NF_TYPE_512B_KNOWN  TRUE     // A static mode define
00389 
00390    // Determination of number of block
00391 #  if (!defined  NF_N_ZONES)
00392 #  if   (NF_DEV_ID == 0x33)
00393 #     define   NF_N_ZONES       1
00394 #  elif (NF_DEV_ID == 0x73)
00395 #     define   NF_N_ZONES       1
00396 #  elif (NF_DEV_ID == 0x35)
00397 #     define   NF_N_ZONES       2
00398 #  elif (NF_DEV_ID == 0x75)
00399 #     define   NF_N_ZONES       2
00400 #  elif (NF_DEV_ID == 0x36)
00401 #     define   NF_N_ZONES       4
00402 #  elif (NF_DEV_ID == 0x66)
00403 #     define   NF_N_ZONES       4
00404 #  elif (NF_DEV_ID == 0x76)
00405 #     define   NF_N_ZONES       4
00406 #  elif (NF_DEV_ID == 0x39)   // Specific ST
00407 #     define   NF_N_ZONES       8
00408 #  elif (NF_DEV_ID == 0x78)
00409 #     define   NF_N_ZONES       8
00410 #  elif (NF_DEV_ID == 0x79)
00411 #     define   NF_N_ZONES       8
00412 #  else
00413 #     error    BAD DEVICE ID of reference in nf_512B.h
00414 #  endif
00415 #  endif // (!defined  NF_N_ZONES)
00416 
00417 #  define   NF_N_BLOCKS          (NF_N_ZONES*1024L)
00418 
00419    // Determination of number of row cycles
00420 #  if   (NF_N_ZONES <= 2)
00421 #     define   NF_N_ROW_CYCLES   2
00422 #  else
00423 #     define   NF_N_ROW_CYCLES   3
00424 #  endif
00425 
00426    // Select configuration
00427 /*
00428 #  define NF_COPYBACK_CONT       // 0 = copy back not supported, N = number of    CONTINUE subdivision contraint on copyback
00429 #  define NF_COPYBACK_DISCONT    // 0 = copy back not supported, N = number of DISCONTINUE subdivision contraint on copyback
00430 #  define NF_CACHE_PROGRAM       // 1 = cache program supported, 0 = not supported
00431 #  define NF_CE_TOGGLE           // 1 = CE toggle supported, 0 = not supported - CE must be always LOW
00432 #  define NF_TIMING_READ         // mode 1: 1 cycle high, 1 cycle low for read cycle
00433                                  // mode 0: 1.5 cycle high, 0.5 cycle low for read cycle
00434 #  define CLK_DFC_NFC            // Freq max supported,  CLK_DFC_NFC_xxMHz
00435 */
00436 #  if    (NF_DEV_CONF == CONF_512B_F4_1)
00437 #     define NF_COPYBACK_CONT    0
00438 #     define NF_COPYBACK_DISCONT 0
00439 #     define NF_CACHE_PROGRAM    0
00440 #     define NF_CE_TOGGLE        1
00441 #     define NF_TIMING_READ      1
00442 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00443 #  elif  (NF_DEV_CONF == CONF_512B_F4_2)
00444 #     define NF_COPYBACK_CONT    0
00445 #     define NF_COPYBACK_DISCONT 0
00446 #     define NF_CACHE_PROGRAM    0
00447 #     define NF_CE_TOGGLE        0
00448 #     define NF_TIMING_READ      0
00449 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00450 #  elif  (NF_DEV_CONF == CONF_512B_F4_3)
00451 #     define NF_COPYBACK_CONT    0
00452 #     define NF_COPYBACK_DISCONT 0
00453 #     define NF_CACHE_PROGRAM    0
00454 #     define NF_CE_TOGGLE        1
00455 #     define NF_TIMING_READ      0
00456 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00457 #  elif  (NF_DEV_CONF == CONF_512B_F4_4)
00458 #     define NF_COPYBACK_CONT    0
00459 #     define NF_COPYBACK_DISCONT 0
00460 #     define NF_CACHE_PROGRAM    0
00461 #     define NF_CE_TOGGLE        1
00462 #     define NF_TIMING_READ      0
00463 #     define CLK_DFC_NFC         CLK_DFC_NFC_24MHz
00464 #  elif  (NF_DEV_CONF == CONF_512B_F1_1)
00465 #     define NF_COPYBACK_CONT    1
00466 #     define NF_COPYBACK_DISCONT 1
00467 #     define NF_CACHE_PROGRAM    0
00468 #     define NF_CE_TOGGLE        1
00469 #     define NF_TIMING_READ      1
00470 #     define CLK_DFC_NFC         CLK_DFC_NFC_40MHz
00471 #  elif  (NF_DEV_CONF == CONF_512B_F1_2)
00472 #     define NF_COPYBACK_CONT    1
00473 #     define NF_COPYBACK_DISCONT 1
00474 #     define NF_CACHE_PROGRAM    0
00475 #     define NF_CE_TOGGLE        0
00476 #     define NF_TIMING_READ      0
00477 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00478 #  elif  (NF_DEV_CONF == CONF_512B_F1_3)
00479 #     define NF_COPYBACK_CONT    1
00480 #     define NF_COPYBACK_DISCONT 1
00481 #     define NF_CACHE_PROGRAM    0
00482 #     define NF_CE_TOGGLE        0
00483 #     define NF_TIMING_READ      0
00484 #     define CLK_DFC_NFC         CLK_DFC_NFC_24MHz
00485 #  elif  (NF_DEV_CONF == CONF_512B_F3_6)
00486 #     define NF_COPYBACK_CONT    1
00487 #     define NF_COPYBACK_DISCONT 2
00488 #     define NF_CACHE_PROGRAM    0
00489 #     define NF_CE_TOGGLE        1
00490 #     define NF_TIMING_READ      1
00491 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00492 #  elif  (NF_DEV_CONF == CONF_512B_F3_7)
00493 #     define NF_COPYBACK_CONT    1
00494 #     define NF_COPYBACK_DISCONT 2
00495 #     define NF_CACHE_PROGRAM    0
00496 #     define NF_CE_TOGGLE        1
00497 #     define NF_TIMING_READ      0
00498 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00499 #  elif  (NF_DEV_CONF == CONF_512B_F3_8)
00500 #     define NF_COPYBACK_CONT    1
00501 #     define NF_COPYBACK_DISCONT 2
00502 #     define NF_CACHE_PROGRAM    0
00503 #     define NF_CE_TOGGLE        1
00504 #     define NF_TIMING_READ      0
00505 #     define CLK_DFC_NFC         CLK_DFC_NFC_24MHz
00506 #  elif  (NF_DEV_CONF == CONF_512B_F3_9)
00507 #     define NF_COPYBACK_CONT    1
00508 #     define NF_COPYBACK_DISCONT 4
00509 #     define NF_CACHE_PROGRAM    0
00510 #     define NF_CE_TOGGLE        1
00511 #     define NF_TIMING_READ      1
00512 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00513 #  elif  (NF_DEV_CONF == CONF_512B_F3_10)
00514 #     define NF_COPYBACK_CONT    1
00515 #     define NF_COPYBACK_DISCONT 4
00516 #     define NF_CACHE_PROGRAM    0
00517 #     define NF_CE_TOGGLE        1
00518 #     define NF_TIMING_READ      0
00519 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00520 #  elif  (NF_DEV_CONF == CONF_512B_F2_1)
00521 #     define NF_COPYBACK_CONT    2
00522 #     define NF_COPYBACK_DISCONT 1
00523 #     define NF_CACHE_PROGRAM    0
00524 #     define NF_CE_TOGGLE        0
00525 #     define NF_TIMING_READ      0
00526 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00527 #  elif  (NF_DEV_CONF == CONF_512B_F2_2)
00528 #     define NF_COPYBACK_CONT    2
00529 #     define NF_COPYBACK_DISCONT 1
00530 #     define NF_CACHE_PROGRAM    0
00531 #     define NF_CE_TOGGLE        0
00532 #     define NF_TIMING_READ      0
00533 #     define CLK_DFC_NFC         CLK_DFC_NFC_24MHz
00534 #  elif  (NF_DEV_CONF == CONF_512B_F2_3)
00535 #     define NF_COPYBACK_CONT    2
00536 #     define NF_COPYBACK_DISCONT 1
00537 #     define NF_CACHE_PROGRAM    0
00538 #     define NF_CE_TOGGLE        0
00539 #     define NF_TIMING_READ      0
00540 #     define CLK_DFC_NFC         CLK_DFC_NFC_16MHz
00541 #  elif  (NF_DEV_CONF == CONF_512B_F3_1)
00542 #     define NF_COPYBACK_CONT    2
00543 #     define NF_COPYBACK_DISCONT 2
00544 #     define NF_CACHE_PROGRAM    0
00545 #     define NF_CE_TOGGLE        1
00546 #     define NF_TIMING_READ      1
00547 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00548 #  elif  (NF_DEV_CONF == CONF_512B_F3_2)
00549 #     define NF_COPYBACK_CONT    2
00550 #     define NF_COPYBACK_DISCONT 2
00551 #     define NF_CACHE_PROGRAM    0
00552 #     define NF_CE_TOGGLE        1
00553 #     define NF_TIMING_READ      0
00554 #     define CLK_DFC_NFC         CLK_DFC_NFC_24MHz
00555 #  elif  (NF_DEV_CONF == CONF_512B_F3_3)
00556 #     define NF_COPYBACK_CONT    2
00557 #     define NF_COPYBACK_DISCONT 4
00558 #     define NF_CACHE_PROGRAM    0
00559 #     define NF_CE_TOGGLE        1
00560 #     define NF_TIMING_READ      1
00561 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00562 #  elif  (NF_DEV_CONF == CONF_512B_F3_4)
00563 #     define NF_COPYBACK_CONT    2
00564 #     define NF_COPYBACK_DISCONT 4
00565 #     define NF_CACHE_PROGRAM    0
00566 #     define NF_CE_TOGGLE        1
00567 #     define NF_TIMING_READ      0
00568 #     define CLK_DFC_NFC         CLK_DFC_NFC_30MHz
00569 #  elif  (NF_DEV_CONF == CONF_512B_F3_5)
00570 #     define NF_COPYBACK_CONT    2
00571 #     define NF_COPYBACK_DISCONT 4
00572 #     define NF_CACHE_PROGRAM    0
00573 #     define NF_CE_TOGGLE        1
00574 #     define NF_TIMING_READ      0
00575 #     define CLK_DFC_NFC         CLK_DFC_NFC_24MHz
00576 #  endif   // (defined CONF_512B_X)
00577 
00578 #endif   // (defined NF_DEV_CONF) = static mode
00579 
00580 #endif   // (NF_AUTO_DETECT_512B==TRUE)
00581 
00582 
00583 #if ((NF_AUTO_DETECT_512B == TRUE) || (NF_TYPE_512B_KNOWN == TRUE))
00584 //**** HERE A 512B driver with 32 or 16 pages by block is used in generic or single mode ****
00585 #  define NF_SHIFT_PAGE_BYTE           9  // (1<<n) size of page  (512B), unit in bytes
00586 #  if (!defined NF_SHIFT_BLOCK_PAGE)
00587 #  define NF_SHIFT_BLOCK_PAGE          5  // (1<<n) size of block (32p), unit in pages
00588 #  endif // else is define at 16p
00589 #endif
00590 
00591 #endif   // _NF_512B_H_

Generated on Fri Oct 31 14:31:24 2008 for ATMEL by  doxygen 1.5.3