您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

class_base_block_driver.html 15KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  5. <meta http-equiv="X-UA-Compatible" content="IE=9"/>
  6. <meta name="generator" content="Doxygen 1.8.10"/>
  7. <title>SdFat: BaseBlockDriver Class Reference</title>
  8. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  9. <script type="text/javascript" src="jquery.js"></script>
  10. <script type="text/javascript" src="dynsections.js"></script>
  11. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  12. <script type="text/javascript" src="search/searchdata.js"></script>
  13. <script type="text/javascript" src="search/search.js"></script>
  14. <script type="text/javascript">
  15. $(document).ready(function() { init_search(); });
  16. </script>
  17. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  18. </head>
  19. <body>
  20. <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
  21. <div id="titlearea">
  22. <table cellspacing="0" cellpadding="0">
  23. <tbody>
  24. <tr style="height: 56px;">
  25. <td id="projectalign" style="padding-left: 0.5em;">
  26. <div id="projectname">SdFat
  27. </div>
  28. </td>
  29. </tr>
  30. </tbody>
  31. </table>
  32. </div>
  33. <!-- end header part -->
  34. <!-- Generated by Doxygen 1.8.10 -->
  35. <script type="text/javascript">
  36. var searchBox = new SearchBox("searchBox", "search",false,'Search');
  37. </script>
  38. <div id="navrow1" class="tabs">
  39. <ul class="tablist">
  40. <li><a href="index.html"><span>Main&#160;Page</span></a></li>
  41. <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
  42. <li><a href="files.html"><span>Files</span></a></li>
  43. <li>
  44. <div id="MSearchBox" class="MSearchBoxInactive">
  45. <span class="left">
  46. <img id="MSearchSelect" src="search/mag_sel.png"
  47. onmouseover="return searchBox.OnSearchSelectShow()"
  48. onmouseout="return searchBox.OnSearchSelectHide()"
  49. alt=""/>
  50. <input type="text" id="MSearchField" value="Search" accesskey="S"
  51. onfocus="searchBox.OnSearchFieldFocus(true)"
  52. onblur="searchBox.OnSearchFieldFocus(false)"
  53. onkeyup="searchBox.OnSearchFieldChange(event)"/>
  54. </span><span class="right">
  55. <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
  56. </span>
  57. </div>
  58. </li>
  59. </ul>
  60. </div>
  61. <div id="navrow2" class="tabs2">
  62. <ul class="tablist">
  63. <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
  64. <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
  65. <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
  66. </ul>
  67. </div>
  68. <!-- window showing the filter options -->
  69. <div id="MSearchSelectWindow"
  70. onmouseover="return searchBox.OnSearchSelectShow()"
  71. onmouseout="return searchBox.OnSearchSelectHide()"
  72. onkeydown="return searchBox.OnSearchSelectKey(event)">
  73. </div>
  74. <!-- iframe showing the search results (closed by default) -->
  75. <div id="MSearchResultsWindow">
  76. <iframe src="javascript:void(0)" frameborder="0"
  77. name="MSearchResults" id="MSearchResults">
  78. </iframe>
  79. </div>
  80. </div><!-- top -->
  81. <div class="header">
  82. <div class="summary">
  83. <a href="#pub-methods">Public Member Functions</a> &#124;
  84. <a href="class_base_block_driver-members.html">List of all members</a> </div>
  85. <div class="headertitle">
  86. <div class="title">BaseBlockDriver Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div> </div>
  87. </div><!--header-->
  88. <div class="contents">
  89. <p>Base block driver.
  90. <a href="class_base_block_driver.html#details">More...</a></p>
  91. <p><code>#include &lt;BaseBlockDriver.h&gt;</code></p>
  92. <div class="dynheader">
  93. Inheritance diagram for BaseBlockDriver:</div>
  94. <div class="dyncontent">
  95. <div class="center"><img src="class_base_block_driver__inherit__graph.png" border="0" usemap="#_base_block_driver_inherit__map" alt="Inheritance graph"/></div>
  96. <map name="_base_block_driver_inherit__map" id="_base_block_driver_inherit__map">
  97. <area shape="rect" id="node2" href="class_sdio_card.html" title="Raw SDIO access to SD and SDHC flash memory cards. " alt="" coords="27,80,101,107"/>
  98. </map>
  99. <center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>
  100. <table class="memberdecls">
  101. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
  102. Public Member Functions</h2></td></tr>
  103. <tr class="memitem:a16bb3305f3130253dd7ab6e19aa1b524"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_base_block_driver.html#a16bb3305f3130253dd7ab6e19aa1b524">readBlock</a> (uint32_t block, uint8_t *dst)=0</td></tr>
  104. <tr class="separator:a16bb3305f3130253dd7ab6e19aa1b524"><td class="memSeparator" colspan="2">&#160;</td></tr>
  105. <tr class="memitem:a3a029a2d02fc7cbdd7c15c8d622565c4"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_base_block_driver.html#a3a029a2d02fc7cbdd7c15c8d622565c4">readBlocks</a> (uint32_t block, uint8_t *dst, size_t nb)=0</td></tr>
  106. <tr class="separator:a3a029a2d02fc7cbdd7c15c8d622565c4"><td class="memSeparator" colspan="2">&#160;</td></tr>
  107. <tr class="memitem:a5361ff2658d7654bf00b97c54c6aa2aa"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_base_block_driver.html#a5361ff2658d7654bf00b97c54c6aa2aa">syncBlocks</a> ()=0</td></tr>
  108. <tr class="separator:a5361ff2658d7654bf00b97c54c6aa2aa"><td class="memSeparator" colspan="2">&#160;</td></tr>
  109. <tr class="memitem:a87df3db1b400286883661525441d39fa"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_base_block_driver.html#a87df3db1b400286883661525441d39fa">writeBlock</a> (uint32_t block, const uint8_t *src)=0</td></tr>
  110. <tr class="separator:a87df3db1b400286883661525441d39fa"><td class="memSeparator" colspan="2">&#160;</td></tr>
  111. <tr class="memitem:a3d6520b21252ebfb17b0cac0b87689b1"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_base_block_driver.html#a3d6520b21252ebfb17b0cac0b87689b1">writeBlocks</a> (uint32_t block, const uint8_t *src, size_t nb)=0</td></tr>
  112. <tr class="separator:a3d6520b21252ebfb17b0cac0b87689b1"><td class="memSeparator" colspan="2">&#160;</td></tr>
  113. </table>
  114. <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
  115. <div class="textblock"><p>Base block driver. </p>
  116. </div><h2 class="groupheader">Member Function Documentation</h2>
  117. <a class="anchor" id="a16bb3305f3130253dd7ab6e19aa1b524"></a>
  118. <div class="memitem">
  119. <div class="memproto">
  120. <table class="mlabels">
  121. <tr>
  122. <td class="mlabels-left">
  123. <table class="memname">
  124. <tr>
  125. <td class="memname">virtual bool BaseBlockDriver::readBlock </td>
  126. <td>(</td>
  127. <td class="paramtype">uint32_t&#160;</td>
  128. <td class="paramname"><em>block</em>, </td>
  129. </tr>
  130. <tr>
  131. <td class="paramkey"></td>
  132. <td></td>
  133. <td class="paramtype">uint8_t *&#160;</td>
  134. <td class="paramname"><em>dst</em>&#160;</td>
  135. </tr>
  136. <tr>
  137. <td></td>
  138. <td>)</td>
  139. <td></td><td></td>
  140. </tr>
  141. </table>
  142. </td>
  143. <td class="mlabels-right">
  144. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  145. </tr>
  146. </table>
  147. </div><div class="memdoc">
  148. <p>Read a 512 byte block from an SD card.</p>
  149. <dl class="params"><dt>Parameters</dt><dd>
  150. <table class="params">
  151. <tr><td class="paramdir">[in]</td><td class="paramname">block</td><td>Logical block to be read. </td></tr>
  152. <tr><td class="paramdir">[out]</td><td class="paramname">dst</td><td>Pointer to the location that will receive the data. </td></tr>
  153. </table>
  154. </dd>
  155. </dl>
  156. <dl class="section return"><dt>Returns</dt><dd>The value true is returned for success and the value false is returned for failure. </dd></dl>
  157. <p>Implemented in <a class="el" href="class_sdio_card.html#ac94605c428fa9258106835cceec470d8">SdioCard</a>.</p>
  158. </div>
  159. </div>
  160. <a class="anchor" id="a3a029a2d02fc7cbdd7c15c8d622565c4"></a>
  161. <div class="memitem">
  162. <div class="memproto">
  163. <table class="mlabels">
  164. <tr>
  165. <td class="mlabels-left">
  166. <table class="memname">
  167. <tr>
  168. <td class="memname">virtual bool BaseBlockDriver::readBlocks </td>
  169. <td>(</td>
  170. <td class="paramtype">uint32_t&#160;</td>
  171. <td class="paramname"><em>block</em>, </td>
  172. </tr>
  173. <tr>
  174. <td class="paramkey"></td>
  175. <td></td>
  176. <td class="paramtype">uint8_t *&#160;</td>
  177. <td class="paramname"><em>dst</em>, </td>
  178. </tr>
  179. <tr>
  180. <td class="paramkey"></td>
  181. <td></td>
  182. <td class="paramtype">size_t&#160;</td>
  183. <td class="paramname"><em>nb</em>&#160;</td>
  184. </tr>
  185. <tr>
  186. <td></td>
  187. <td>)</td>
  188. <td></td><td></td>
  189. </tr>
  190. </table>
  191. </td>
  192. <td class="mlabels-right">
  193. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  194. </tr>
  195. </table>
  196. </div><div class="memdoc">
  197. <p>Read multiple 512 byte blocks from an SD card.</p>
  198. <dl class="params"><dt>Parameters</dt><dd>
  199. <table class="params">
  200. <tr><td class="paramdir">[in]</td><td class="paramname">block</td><td>Logical block to be read. </td></tr>
  201. <tr><td class="paramdir">[in]</td><td class="paramname">nb</td><td>Number of blocks to be read. </td></tr>
  202. <tr><td class="paramdir">[out]</td><td class="paramname">dst</td><td>Pointer to the location that will receive the data. </td></tr>
  203. </table>
  204. </dd>
  205. </dl>
  206. <dl class="section return"><dt>Returns</dt><dd>The value true is returned for success and the value false is returned for failure. </dd></dl>
  207. <p>Implemented in <a class="el" href="class_sdio_card.html#a7de36d26a01dc39b7dc122c54ee03b12">SdioCard</a>.</p>
  208. </div>
  209. </div>
  210. <a class="anchor" id="a5361ff2658d7654bf00b97c54c6aa2aa"></a>
  211. <div class="memitem">
  212. <div class="memproto">
  213. <table class="mlabels">
  214. <tr>
  215. <td class="mlabels-left">
  216. <table class="memname">
  217. <tr>
  218. <td class="memname">virtual bool BaseBlockDriver::syncBlocks </td>
  219. <td>(</td>
  220. <td class="paramname"></td><td>)</td>
  221. <td></td>
  222. </tr>
  223. </table>
  224. </td>
  225. <td class="mlabels-right">
  226. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  227. </tr>
  228. </table>
  229. </div><div class="memdoc">
  230. <p>End multi-block transfer and go to idle state. </p><dl class="section return"><dt>Returns</dt><dd>The value true is returned for success and the value false is returned for failure. </dd></dl>
  231. <p>Implemented in <a class="el" href="class_sdio_card.html#affcd36a5c3a42042fe24716671f06632">SdioCard</a>.</p>
  232. </div>
  233. </div>
  234. <a class="anchor" id="a87df3db1b400286883661525441d39fa"></a>
  235. <div class="memitem">
  236. <div class="memproto">
  237. <table class="mlabels">
  238. <tr>
  239. <td class="mlabels-left">
  240. <table class="memname">
  241. <tr>
  242. <td class="memname">virtual bool BaseBlockDriver::writeBlock </td>
  243. <td>(</td>
  244. <td class="paramtype">uint32_t&#160;</td>
  245. <td class="paramname"><em>block</em>, </td>
  246. </tr>
  247. <tr>
  248. <td class="paramkey"></td>
  249. <td></td>
  250. <td class="paramtype">const uint8_t *&#160;</td>
  251. <td class="paramname"><em>src</em>&#160;</td>
  252. </tr>
  253. <tr>
  254. <td></td>
  255. <td>)</td>
  256. <td></td><td></td>
  257. </tr>
  258. </table>
  259. </td>
  260. <td class="mlabels-right">
  261. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  262. </tr>
  263. </table>
  264. </div><div class="memdoc">
  265. <p>Writes a 512 byte block to an SD card.</p>
  266. <dl class="params"><dt>Parameters</dt><dd>
  267. <table class="params">
  268. <tr><td class="paramdir">[in]</td><td class="paramname">block</td><td>Logical block to be written. </td></tr>
  269. <tr><td class="paramdir">[in]</td><td class="paramname">src</td><td>Pointer to the location of the data to be written. </td></tr>
  270. </table>
  271. </dd>
  272. </dl>
  273. <dl class="section return"><dt>Returns</dt><dd>The value true is returned for success and the value false is returned for failure. </dd></dl>
  274. <p>Implemented in <a class="el" href="class_sdio_card.html#ae53e5f72ddf9ace3f47774d968e064ed">SdioCard</a>.</p>
  275. </div>
  276. </div>
  277. <a class="anchor" id="a3d6520b21252ebfb17b0cac0b87689b1"></a>
  278. <div class="memitem">
  279. <div class="memproto">
  280. <table class="mlabels">
  281. <tr>
  282. <td class="mlabels-left">
  283. <table class="memname">
  284. <tr>
  285. <td class="memname">virtual bool BaseBlockDriver::writeBlocks </td>
  286. <td>(</td>
  287. <td class="paramtype">uint32_t&#160;</td>
  288. <td class="paramname"><em>block</em>, </td>
  289. </tr>
  290. <tr>
  291. <td class="paramkey"></td>
  292. <td></td>
  293. <td class="paramtype">const uint8_t *&#160;</td>
  294. <td class="paramname"><em>src</em>, </td>
  295. </tr>
  296. <tr>
  297. <td class="paramkey"></td>
  298. <td></td>
  299. <td class="paramtype">size_t&#160;</td>
  300. <td class="paramname"><em>nb</em>&#160;</td>
  301. </tr>
  302. <tr>
  303. <td></td>
  304. <td>)</td>
  305. <td></td><td></td>
  306. </tr>
  307. </table>
  308. </td>
  309. <td class="mlabels-right">
  310. <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
  311. </tr>
  312. </table>
  313. </div><div class="memdoc">
  314. <p>Write multiple 512 byte blocks to an SD card.</p>
  315. <dl class="params"><dt>Parameters</dt><dd>
  316. <table class="params">
  317. <tr><td class="paramdir">[in]</td><td class="paramname">block</td><td>Logical block to be written. </td></tr>
  318. <tr><td class="paramdir">[in]</td><td class="paramname">nb</td><td>Number of blocks to be written. </td></tr>
  319. <tr><td class="paramdir">[in]</td><td class="paramname">src</td><td>Pointer to the location of the data to be written. </td></tr>
  320. </table>
  321. </dd>
  322. </dl>
  323. <dl class="section return"><dt>Returns</dt><dd>The value true is returned for success and the value false is returned for failure. </dd></dl>
  324. <p>Implemented in <a class="el" href="class_sdio_card.html#a8b811f875497e90e75fbe6c2d41d89cb">SdioCard</a>.</p>
  325. </div>
  326. </div>
  327. <hr/>The documentation for this class was generated from the following file:<ul>
  328. <li>Arduino/libraries/SdFat/src/FatLib/BaseBlockDriver.h</li>
  329. </ul>
  330. </div><!-- contents -->
  331. <!-- start footer part -->
  332. <hr class="footer"/><address class="footer"><small>
  333. Generated on Mon Sep 5 2016 10:18:52 for SdFat by &#160;<a href="http://www.doxygen.org/index.html">
  334. <img class="footer" src="doxygen.png" alt="doxygen"/>
  335. </a> 1.8.10
  336. </small></address>
  337. </body>
  338. </html>