⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sd.lst

📁 SD卡上的FAT32文件系统源代码,能够在任何单片机上使用
💻 LST
字号:
C51 COMPILER V8.05a   SD                                                                   04/23/2008 12:43:23 PAGE 1   


C51 COMPILER V8.05a, COMPILATION OF MODULE SD
OBJECT MODULE PLACED IN sd.OBJ
COMPILER INVOKED BY: C:\Keil\C51\BIN\C51.EXE sd.c LARGE BROWSE DEBUG OBJECTEXTEND

line level    source

   1          #include <reg51.h>
   2          #include <string.h>
   3          #include <stdio.h>
   4          #include <math.h>
   5          #include <uart.h>
*** WARNING C280 IN LINE 122 OF UART.H: 'temp': unreferenced local variable
   6          #include <fat32.h>
*** WARNING C280 IN LINE 231 OF FAT32.H: 'DirName': unreferenced local variable
*** WARNING C182 IN LINE 295 OF FAT32.H: pointer to different objects
   7          //#include <sd.h>
   8          /*
   9          struct FAT32_Init_Arg
  10          {
  11           unsigned char BPB_Sector_No;
  12           unsigned long Total_Size;
  13           unsigned long FirstDirClust;   //first directory cluster
  14           unsigned long FirstDataSector; // The first sector number of data
  15           unsigned int  BytesPerSector;  // Bytes per sector
  16           unsigned int  FATsectors;              // The amount sector a FAT occupied
  17           unsigned int  SectorsPerClust; // Sector per cluster
  18           unsigned long FirstFATSector;  // The first FAT sector
  19           unsigned long FirstDirSector;  // The first Dir sector
  20           unsigned long RootDirSectors;  // The sector number a Root dir occupied 
  21           unsigned long RootDirCount;    // The count of directory in root dir
  22          };
  23          */
  24          void main()
  25          {
  26   1       delay(10000);
  27   1       UART_Init();
  28   1       send_s("yahoo!!!");
  29   1       MMC_Init();
  30   1       delay(10000);
  31   1       MMC_get_volume_info();
  32   1       FAT32_Init(&Init_Arg);
  33   1       Printf("BPB_Sector_No",Init_Arg.BPB_Sector_No);
  34   1       Printf("Total_Size"   ,Init_Arg.Total_Size   );
  35   1       Printf("FirstDirClust",Init_Arg.FirstDirClust); 
  36   1       Printf("FirstDataSector",Init_Arg.FirstDataSector); 
  37   1       Printf("BytesPerSector",Init_Arg.BytesPerSector); 
  38   1       Printf("FATsectors",Init_Arg.FATsectors); 
  39   1       Printf("SectorsPerClust",Init_Arg.SectorsPerClust);
  40   1       Printf("FirstFATSector",Init_Arg.FirstFATSector); 
  41   1       Printf("FirstDirSector",Init_Arg.FirstDirSector); 
  42   1       //Printf("RootDirSectors",Init_Arg.RootDirSectors); 
  43   1       //Printf("RootDirCount",Init_Arg.RootDirCount);
  44   1       Printf("FAT32_OpenFile",(FAT32_OpenFile("\\TEST.TXT"))->FileSize);
  45   1       FAT32_ReadFile(&FileInfo);
  46   1       while(1);
  47   1      }


MODULE INFORMATION:   STATIC OVERLAYABLE
   CODE SIZE        =   6444    ----
   CONSTANT SIZE    =    691    ----
C51 COMPILER V8.05a   SD                                                                   04/23/2008 12:43:23 PAGE 2   

   XDATA SIZE       =    695     352
   PDATA SIZE       =   ----    ----
   DATA SIZE        =   ----    ----
   IDATA SIZE       =   ----    ----
   BIT SIZE         =   ----    ----
END OF MODULE INFORMATION.


C51 COMPILATION COMPLETE.  3 WARNING(S),  0 ERROR(S)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -