找回密碼
 立即注冊

QQ登錄

只需一步,快速開始

搜索
查看: 2945|回復(fù): 0
打印 上一主題 下一主題
收起左側(cè)

BASCOM-AVR利用AVR-DOS庫讀寫SD卡

[復(fù)制鏈接]
跳轉(zhuǎn)到指定樓層
樓主
ID:696930 發(fā)表于 2020-9-14 11:11 | 只看該作者 回帖獎勵 |倒序瀏覽 |閱讀模式
試驗了用BASCOM讀寫SD卡,完全可以把SD卡當(dāng)作磁盤來操作,與VB/QB語法兼容,編程非常簡單。

  AVR-DOS介紹
  Features:
           ·  Read and writeASCII-Files
·  Read and writeBinary-Files
·  Drivers available forCompact Flash Cards, Hard disk, MMC, SD etc.
·  Completly integrated inBASCOM-AVR Compiler
·  QB/VB compatible syntax
·  Completly written inAVR-Assembler (fast and compact)
  It workswith:
           ·  DOS-FAT16 and FAT32 formatted partitions
·  Files in Root directory and sub directories
·  Short DOS File names (8.3)
·  Sector Size of 512 Bytes(nearly all CF-Cards and HD)
·  Linear sector addressing(LBA-Mode). (all newer CF-Cards and HD). C/H/S-Mode of old HD is not supported.
  
  Please note: AVR-DOS is only free for noncommercial use. For commercial use, or when you are interested in ASM-Code andcomplete documentation please check Licensedirectives

  Functions:
  Hereis a list of all in BASCOM-AVR integrated statements, which uses AVR-DOSfunctionality.

  Disk/Directory:
            ·  InitFileSystem (<Partition#>)
·  DiskSize
·  DiskFree
·  Kill <FileName>
·  Dir ([ <FileName>])
·  FileLen ([ <FileName> ])
·  FileDateTime ([ <FileName>])
·  FileDate ([ <FileName>])
·  FileTime ([ <FileName>])
·  GetAttr ([ <FileName>])   
·  Name<OldFileName>As <NewFileName>   
·  ChDir<PathName>])   
·  MkDir<PathName>])   
·  RmDir<PathName>])   
  File create, open, read, write, close:
           ·  FreeFile
·  Open <FileName> ForInput/Output/Append/Binary as #<File#>
·  Close <File#>
·  Flush [<File#>]
·  Print #<File#>,Variable1; Variable2; …
·  Write #<File#>,Variable1, Variable2, …
·  Input #<File#>,Variable1, Variable2, …
·  Line Input #<File#>,StringVariable
·  Get #<File#>,<Variable> [,<Position>]
·  Put #<File#>,<Variable> [,<Position>]
·  Seek #<File#>[,<New Position>]
  Infos about opened files:
            ·  EOF (#<File#>)
·  LOC (#<File#>)
·  LOF (#<File#>)
·  FileAttr (#<File#>)
  Others:
            ·  Bload <FileName>,<SRAM-Address>
·  Bsave <FileName>,<SRAM-Address>, <Length>

CONFIG_AVR-DOS.zip

3.23 KB, 下載次數(shù): 4, 下載積分: 黑幣 -5

Config_MMC.zip

1.61 KB, 下載次數(shù): 4, 下載積分: 黑幣 -5

SD-M32.zip

1.21 KB, 下載次數(shù): 5, 下載積分: 黑幣 -5

評分

參與人數(shù) 1黑幣 +50 收起 理由
admin + 50 共享資料的黑幣獎勵!

查看全部評分

分享到:  QQ好友和群QQ好友和群 QQ空間QQ空間 騰訊微博騰訊微博 騰訊朋友騰訊朋友
收藏收藏1 分享淘帖 頂 踩
回復(fù)

使用道具 舉報

您需要登錄后才可以回帖 登錄 | 立即注冊

本版積分規(guī)則

手機版|小黑屋|51黑電子論壇 |51黑電子論壇6群 QQ 管理員QQ:125739409;技術(shù)交流QQ群281945664

Powered by 單片機教程網(wǎng)

快速回復(fù) 返回頂部 返回列表