diff --git a/group__spi.html b/group__spi.html index 17c9bf2..8aea987 100644 --- a/group__spi.html +++ b/group__spi.html @@ -103,10 +103,6 @@ <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="enum-members" name="enum-members"></a> Enumerations</h2></td></tr> -<tr class="memitem:gac4b206a51636d91c5cffcbcee458c3cb" id="r_gac4b206a51636d91c5cffcbcee458c3cb"><td class="memItemLeft" align="right" valign="top"><a id="gac4b206a51636d91c5cffcbcee458c3cb" name="gac4b206a51636d91c5cffcbcee458c3cb"></a>enum  </td><td class="memItemRight" valign="bottom"><b>spi_mode_t</b> { <b>SPI_MODE_PERIPHERAL</b> = 2 -, <b>SPI_MODE_CONTROLLER</b> = 3 - }</td></tr> -<tr class="separator:gac4b206a51636d91c5cffcbcee458c3cb"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ga6a59b1c0553025b0573e017528952890" id="r_ga6a59b1c0553025b0573e017528952890"><td class="memItemLeft" align="right" valign="top"><a id="ga6a59b1c0553025b0573e017528952890" name="ga6a59b1c0553025b0573e017528952890"></a>enum  </td><td class="memItemRight" valign="bottom"><b>spi_dopo_t</b> { <b>SPI_DOPO_0_SCK_1</b> = 0 , <b>SPI_DOPO_2_SCK_3</b> , <b>SPI_DOPO_3_SCK_1</b> @@ -126,23 +122,23 @@ </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="func-members" name="func-members"></a> Functions</h2></td></tr> -<tr class="memitem:ga48ef10ade34f68b96d36dee03ebc4415" id="r_ga48ef10ade34f68b96d36dee03ebc4415"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415">spi_init</a> (spi_mode_t mode, uint32_t baud)</td></tr> -<tr class="memdesc:ga48ef10ade34f68b96d36dee03ebc4415"><td class="mdescLeft"> </td><td class="mdescRight">Initializes the SPI peripheral for a board with a defined SPI_SERCOM. <br /></td></tr> -<tr class="separator:ga48ef10ade34f68b96d36dee03ebc4415"><td class="memSeparator" colspan="2"> </td></tr> +<tr class="memitem:gaa2b2013ee668e73a427b2a99da1ca47a" id="r_gaa2b2013ee668e73a427b2a99da1ca47a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a">spi_init</a> (uint32_t baud)</td></tr> +<tr class="memdesc:gaa2b2013ee668e73a427b2a99da1ca47a"><td class="mdescLeft"> </td><td class="mdescRight">Initializes the SPI SERCOM as a controller for a board with a defined SPI_SERCOM. <br /></td></tr> +<tr class="separator:gaa2b2013ee668e73a427b2a99da1ca47a"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ga72cf41d2f19954fefd27f681d6b39532" id="r_ga72cf41d2f19954fefd27f681d6b39532"><td class="memItemLeft" align="right" valign="top"><a id="ga72cf41d2f19954fefd27f681d6b39532" name="ga72cf41d2f19954fefd27f681d6b39532"></a> void </td><td class="memItemRight" valign="bottom"><b>spi_enable</b> (void)</td></tr> -<tr class="memdesc:ga72cf41d2f19954fefd27f681d6b39532"><td class="mdescLeft"> </td><td class="mdescRight">Enables the SPI peripheral for a board with a defined SPI_SERCOM. <br /></td></tr> +<tr class="memdesc:ga72cf41d2f19954fefd27f681d6b39532"><td class="mdescLeft"> </td><td class="mdescRight">Enables the SPI SERCOM for a board with a defined SPI_SERCOM. <br /></td></tr> <tr class="separator:ga72cf41d2f19954fefd27f681d6b39532"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ga50084189a01c481aebe4e4d1e1968910" id="r_ga50084189a01c481aebe4e4d1e1968910"><td class="memItemLeft" align="right" valign="top">uint8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__spi.html#ga50084189a01c481aebe4e4d1e1968910">spi_transfer</a> (uint8_t data)</td></tr> <tr class="memdesc:ga50084189a01c481aebe4e4d1e1968910"><td class="mdescLeft"> </td><td class="mdescRight">Transfers a byte over SPI for a board with a defined SPI_SERCOM. <br /></td></tr> <tr class="separator:ga50084189a01c481aebe4e4d1e1968910"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:gaa8d2d6d1632faf9abbe03c3ed90d54d4" id="r_gaa8d2d6d1632faf9abbe03c3ed90d54d4"><td class="memItemLeft" align="right" valign="top"><a id="gaa8d2d6d1632faf9abbe03c3ed90d54d4" name="gaa8d2d6d1632faf9abbe03c3ed90d54d4"></a> void </td><td class="memItemRight" valign="bottom"><b>spi_disable</b> (void)</td></tr> -<tr class="memdesc:gaa8d2d6d1632faf9abbe03c3ed90d54d4"><td class="mdescLeft"> </td><td class="mdescRight">Disables the SPI peripheral for a board with a defined SPI_SERCOM. <br /></td></tr> +<tr class="memdesc:gaa8d2d6d1632faf9abbe03c3ed90d54d4"><td class="mdescLeft"> </td><td class="mdescRight">Disables the SPI SERCOM for a board with a defined SPI_SERCOM. <br /></td></tr> <tr class="separator:gaa8d2d6d1632faf9abbe03c3ed90d54d4"><td class="memSeparator" colspan="2"> </td></tr> -<tr class="memitem:gaee8eaa5f597d774c4fc4a6f7d6d08305" id="r_gaee8eaa5f597d774c4fc4a6f7d6d08305"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305">spi_init_instance</a> (uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud)</td></tr> -<tr class="memdesc:gaee8eaa5f597d774c4fc4a6f7d6d08305"><td class="mdescLeft"> </td><td class="mdescRight">Initializes a specific SERCOM instance for SPI. <br /></td></tr> -<tr class="separator:gaee8eaa5f597d774c4fc4a6f7d6d08305"><td class="memSeparator" colspan="2"> </td></tr> +<tr class="memitem:ga236f4397be3ed06d5158e8dbfe387a29" id="r_ga236f4397be3ed06d5158e8dbfe387a29"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29">spi_init_instance</a> (uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud)</td></tr> +<tr class="memdesc:ga236f4397be3ed06d5158e8dbfe387a29"><td class="mdescLeft"> </td><td class="mdescRight">Initializes a specific SERCOM instance as an SPI controller. <br /></td></tr> +<tr class="separator:ga236f4397be3ed06d5158e8dbfe387a29"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ga8f1915874847b4564ab22039f2b8762f" id="r_ga8f1915874847b4564ab22039f2b8762f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__spi.html#ga8f1915874847b4564ab22039f2b8762f">spi_enable_instance</a> (uint8_t sercom)</td></tr> <tr class="memdesc:ga8f1915874847b4564ab22039f2b8762f"><td class="mdescLeft"> </td><td class="mdescRight">Enables a specific SERCOM instance for SPI. <br /></td></tr> <tr class="separator:ga8f1915874847b4564ab22039f2b8762f"><td class="memSeparator" colspan="2"> </td></tr> @@ -155,6 +151,7 @@ </table> <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> <p>The SPI peripheral is used for synchronous serial communication with other devices. </p> +<p>Gossamer's SPI implementation only supports SPI controller mode, not peripheral mode. Your DOPO pin in this case is COPI/MOSI, and your DIPO pin is CIPO/MISO. </p> <h2 class="groupheader">Function Documentation</h2> <a id="ga3856b233dc7584708ab420d41c4816fe" name="ga3856b233dc7584708ab420d41c4816fe"></a> <h2 class="memtitle"><span class="permalink"><a href="#ga3856b233dc7584708ab420d41c4816fe">◆ </a></span>spi_disable_instance()</h2> @@ -208,8 +205,8 @@ <h2 class="memtitle"><span class="permalink"><a href="#ga8f1915874847b4564ab2203 </div> </div> -<a id="ga48ef10ade34f68b96d36dee03ebc4415" name="ga48ef10ade34f68b96d36dee03ebc4415"></a> -<h2 class="memtitle"><span class="permalink"><a href="#ga48ef10ade34f68b96d36dee03ebc4415">◆ </a></span>spi_init()</h2> +<a id="gaa2b2013ee668e73a427b2a99da1ca47a" name="gaa2b2013ee668e73a427b2a99da1ca47a"></a> +<h2 class="memtitle"><span class="permalink"><a href="#gaa2b2013ee668e73a427b2a99da1ca47a">◆ </a></span>spi_init()</h2> <div class="memitem"> <div class="memproto"> @@ -217,37 +214,25 @@ <h2 class="memtitle"><span class="permalink"><a href="#ga48ef10ade34f68b96d36dee <tr> <td class="memname">void spi_init </td> <td>(</td> - <td class="paramtype">spi_mode_t </td> - <td class="paramname"><em>mode</em>, </td> - </tr> - <tr> - <td class="paramkey"></td> - <td></td> <td class="paramtype">uint32_t </td> - <td class="paramname"><em>baud</em> </td> - </tr> - <tr> + <td class="paramname"><em>baud</em></td><td>)</td> <td></td> - <td>)</td> - <td></td><td></td> </tr> </table> </div><div class="memdoc"> -<p>Initializes the SPI peripheral for a board with a defined SPI_SERCOM. </p> +<p>Initializes the SPI SERCOM as a controller for a board with a defined SPI_SERCOM. </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> - <tr><td class="paramname">mode</td><td>SPI_MODE_CONTROLLER or SPI_MODE_PERIPHERAL </td></tr> <tr><td class="paramname">baud</td><td>The desired baud rate </td></tr> </table> </dd> </dl> -<dl class="section warning"><dt>Warning</dt><dd>SPI_MODE_PERIPHERAL is untested! </dd></dl> </div> </div> -<a id="gaee8eaa5f597d774c4fc4a6f7d6d08305" name="gaee8eaa5f597d774c4fc4a6f7d6d08305"></a> -<h2 class="memtitle"><span class="permalink"><a href="#gaee8eaa5f597d774c4fc4a6f7d6d08305">◆ </a></span>spi_init_instance()</h2> +<a id="ga236f4397be3ed06d5158e8dbfe387a29" name="ga236f4397be3ed06d5158e8dbfe387a29"></a> +<h2 class="memtitle"><span class="permalink"><a href="#ga236f4397be3ed06d5158e8dbfe387a29">◆ </a></span>spi_init_instance()</h2> <div class="memitem"> <div class="memproto"> @@ -270,12 +255,6 @@ <h2 class="memtitle"><span class="permalink"><a href="#gaee8eaa5f597d774c4fc4a6f <td class="paramtype">spi_dipo_t </td> <td class="paramname"><em>dipo</em>, </td> </tr> - <tr> - <td class="paramkey"></td> - <td></td> - <td class="paramtype">spi_mode_t </td> - <td class="paramname"><em>mode</em>, </td> - </tr> <tr> <td class="paramkey"></td> <td></td> @@ -290,7 +269,7 @@ <h2 class="memtitle"><span class="permalink"><a href="#gaee8eaa5f597d774c4fc4a6f </table> </div><div class="memdoc"> -<p>Initializes a specific SERCOM instance for SPI. </p> +<p>Initializes a specific SERCOM instance as an SPI controller. </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">sercom</td><td>The SERCOM instance to initialize. </td></tr> @@ -308,12 +287,10 @@ <h2 class="memtitle"><span class="permalink"><a href="#gaee8eaa5f597d774c4fc4a6f <dl class="section see"><dt>See also</dt><dd>spi_dipo_t </dd></dl> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> - <tr><td class="paramname">mode</td><td>SPI_MODE_CONTROLLER or SPI_MODE_PERIPHERAL </td></tr> <tr><td class="paramname">baud</td><td>The desired baud rate </td></tr> </table> </dd> </dl> -<dl class="section warning"><dt>Warning</dt><dd>SPI_MODE_PERIPHERAL is untested! </dd></dl> </div> </div> diff --git a/group__spi.js b/group__spi.js index 3c1a153..4d9f216 100644 --- a/group__spi.js +++ b/group__spi.js @@ -4,8 +4,8 @@ var group__spi = [ "spi_disable_instance", "group__spi.html#ga3856b233dc7584708ab420d41c4816fe", null ], [ "spi_enable", "group__spi.html#ga72cf41d2f19954fefd27f681d6b39532", null ], [ "spi_enable_instance", "group__spi.html#ga8f1915874847b4564ab22039f2b8762f", null ], - [ "spi_init", "group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415", null ], - [ "spi_init_instance", "group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305", null ], + [ "spi_init", "group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a", null ], + [ "spi_init_instance", "group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29", null ], [ "spi_transfer", "group__spi.html#ga50084189a01c481aebe4e4d1e1968910", null ], [ "spi_transfer_instance", "group__spi.html#ga03d51191e1fb189fcddf1087999d58a2", null ] ]; \ No newline at end of file diff --git a/navtreeindex0.js b/navtreeindex0.js index 22421f7..fbb7067 100644 --- a/navtreeindex0.js +++ b/navtreeindex0.js @@ -126,13 +126,13 @@ var NAVTREEINDEX0 = "group__slcd.html#gafa6a244c0634d7009cb70b4fe9c2bd54":[1,11,12], "group__spi.html":[1,12], "group__spi.html#ga03d51191e1fb189fcddf1087999d58a2":[1,12,7], +"group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29":[1,12,5], "group__spi.html#ga3856b233dc7584708ab420d41c4816fe":[1,12,1], -"group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415":[1,12,4], "group__spi.html#ga50084189a01c481aebe4e4d1e1968910":[1,12,6], "group__spi.html#ga72cf41d2f19954fefd27f681d6b39532":[1,12,2], "group__spi.html#ga8f1915874847b4564ab22039f2b8762f":[1,12,3], +"group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a":[1,12,4], "group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4":[1,12,0], -"group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305":[1,12,5], "group__system.html":[1,13], "group__system.html#ga436af75ad5caf82faa3497787abf4321":[1,13,1], "group__system.html#ga4f33e5a16dba970fa7064ea27287fcba":[1,13,3], diff --git a/search/all_e.js b/search/all_e.js index 57b0936..6260615 100644 --- a/search/all_e.js +++ b/search/all_e.js @@ -54,8 +54,8 @@ var searchData= ['spi_5fdisable_5finstance_51',['spi_disable_instance',['../group__spi.html#ga3856b233dc7584708ab420d41c4816fe',1,'spi_disable_instance(uint8_t sercom): spi.c'],['../group__spi.html#ga3856b233dc7584708ab420d41c4816fe',1,'spi_disable_instance(uint8_t sercom): spi.c']]], ['spi_5fenable_52',['spi_enable',['../group__spi.html#ga72cf41d2f19954fefd27f681d6b39532',1,'spi.h']]], ['spi_5fenable_5finstance_53',['spi_enable_instance',['../group__spi.html#ga8f1915874847b4564ab22039f2b8762f',1,'spi_enable_instance(uint8_t sercom): spi.c'],['../group__spi.html#ga8f1915874847b4564ab22039f2b8762f',1,'spi_enable_instance(uint8_t sercom): spi.c']]], - ['spi_5finit_54',['spi_init',['../group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415',1,'spi.h']]], - ['spi_5finit_5finstance_55',['spi_init_instance',['../group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud): spi.c'],['../group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud): spi.c']]], + ['spi_5finit_54',['spi_init',['../group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a',1,'spi.h']]], + ['spi_5finit_5finstance_55',['spi_init_instance',['../group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud): spi.c'],['../group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud): spi.c']]], ['spi_5ftransfer_56',['spi_transfer',['../group__spi.html#ga50084189a01c481aebe4e4d1e1968910',1,'spi.h']]], ['spi_5ftransfer_5finstance_57',['spi_transfer_instance',['../group__spi.html#ga03d51191e1fb189fcddf1087999d58a2',1,'spi_transfer_instance(uint8_t sercom, uint8_t data): spi.c'],['../group__spi.html#ga03d51191e1fb189fcddf1087999d58a2',1,'spi_transfer_instance(uint8_t sercom, uint8_t data): spi.c']]], ['state_20and_20future_20plans_58',['Current state and future plans',['../md__r_e_a_d_m_e.html#autotoc_md7',1,'']]], diff --git a/search/functions_9.js b/search/functions_9.js index 9a0ea5e..3254538 100644 --- a/search/functions_9.js +++ b/search/functions_9.js @@ -20,8 +20,8 @@ var searchData= ['spi_5fdisable_5finstance_17',['spi_disable_instance',['../group__spi.html#ga3856b233dc7584708ab420d41c4816fe',1,'spi_disable_instance(uint8_t sercom): spi.c'],['../group__spi.html#ga3856b233dc7584708ab420d41c4816fe',1,'spi_disable_instance(uint8_t sercom): spi.c']]], ['spi_5fenable_18',['spi_enable',['../group__spi.html#ga72cf41d2f19954fefd27f681d6b39532',1,'spi.h']]], ['spi_5fenable_5finstance_19',['spi_enable_instance',['../group__spi.html#ga8f1915874847b4564ab22039f2b8762f',1,'spi_enable_instance(uint8_t sercom): spi.c'],['../group__spi.html#ga8f1915874847b4564ab22039f2b8762f',1,'spi_enable_instance(uint8_t sercom): spi.c']]], - ['spi_5finit_20',['spi_init',['../group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415',1,'spi.h']]], - ['spi_5finit_5finstance_21',['spi_init_instance',['../group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud): spi.c'],['../group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud): spi.c']]], + ['spi_5finit_20',['spi_init',['../group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a',1,'spi.h']]], + ['spi_5finit_5finstance_21',['spi_init_instance',['../group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud): spi.c'],['../group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29',1,'spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud): spi.c']]], ['spi_5ftransfer_22',['spi_transfer',['../group__spi.html#ga50084189a01c481aebe4e4d1e1968910',1,'spi.h']]], ['spi_5ftransfer_5finstance_23',['spi_transfer_instance',['../group__spi.html#ga03d51191e1fb189fcddf1087999d58a2',1,'spi_transfer_instance(uint8_t sercom, uint8_t data): spi.c'],['../group__spi.html#ga03d51191e1fb189fcddf1087999d58a2',1,'spi_transfer_instance(uint8_t sercom, uint8_t data): spi.c']]], ['sys_5finit_24',['sys_init',['../group__system.html#gaf411a8bc6b7ed4b0af9114e10c959448',1,'system.h']]] diff --git a/spi_8h_source.html b/spi_8h_source.html index d5b1e93..a4c83e5 100644 --- a/spi_8h_source.html +++ b/spi_8h_source.html @@ -114,50 +114,45 @@ <div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="preprocessor">#include <stdbool.h></span></div> <div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="preprocessor">#include <stddef.h></span></div> <div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> </div> -<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span><span class="keyword">typedef</span> <span class="keyword">enum</span> {</div> -<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> SPI_MODE_PERIPHERAL = 2,</div> -<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> SPI_MODE_CONTROLLER = 3,</div> -<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span>} spi_mode_t;</div> -<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> </div> -<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span><span class="keyword">typedef</span> <span class="keyword">enum</span> {</div> -<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> SPI_DOPO_0_SCK_1 = 0,</div> -<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> SPI_DOPO_2_SCK_3,</div> -<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> SPI_DOPO_3_SCK_1,</div> -<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> SPI_DOPO_0_SCK_3,</div> -<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span>} spi_dopo_t;</div> -<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> </div> -<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span><span class="keyword">typedef</span> <span class="keyword">enum</span> {</div> -<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> SPI_DIPO_0 = 0,</div> -<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> SPI_DIPO_1,</div> -<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> SPI_DIPO_2,</div> -<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> SPI_DIPO_3,</div> -<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> SPI_DIPO_NONE = 0xff</div> -<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span>} spi_dipo_t;</div> -<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> </div> -<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"><a class="line" href="group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415"> 48</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415">spi_init</a>(spi_mode_t mode, uint32_t baud);</div> +<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="keyword">typedef</span> <span class="keyword">enum</span> {</div> +<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> SPI_DOPO_0_SCK_1 = 0,</div> +<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> SPI_DOPO_2_SCK_3,</div> +<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> SPI_DOPO_3_SCK_1,</div> +<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> SPI_DOPO_0_SCK_3,</div> +<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span>} spi_dopo_t;</div> +<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> </div> +<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span><span class="keyword">typedef</span> <span class="keyword">enum</span> {</div> +<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> SPI_DIPO_0 = 0,</div> +<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> SPI_DIPO_1,</div> +<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> SPI_DIPO_2,</div> +<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> SPI_DIPO_3,</div> +<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> SPI_DIPO_NONE = 0xff</div> +<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span>} spi_dipo_t;</div> +<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> </div> +<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"><a class="line" href="group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a"> 43</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a">spi_init</a>(uint32_t baud);</div> +<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> </div> +<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"><a class="line" href="group__spi.html#ga72cf41d2f19954fefd27f681d6b39532"> 48</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga72cf41d2f19954fefd27f681d6b39532">spi_enable</a>(<span class="keywordtype">void</span>);</div> <div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> </div> -<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"><a class="line" href="group__spi.html#ga72cf41d2f19954fefd27f681d6b39532"> 53</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga72cf41d2f19954fefd27f681d6b39532">spi_enable</a>(<span class="keywordtype">void</span>);</div> -<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> </div> -<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"><a class="line" href="group__spi.html#ga50084189a01c481aebe4e4d1e1968910"> 60</a></span>uint8_t <a class="code hl_function" href="group__spi.html#ga50084189a01c481aebe4e4d1e1968910">spi_transfer</a>(uint8_t data);</div> +<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"><a class="line" href="group__spi.html#ga50084189a01c481aebe4e4d1e1968910"> 55</a></span>uint8_t <a class="code hl_function" href="group__spi.html#ga50084189a01c481aebe4e4d1e1968910">spi_transfer</a>(uint8_t data);</div> +<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span> </div> +<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"><a class="line" href="group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4"> 60</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4">spi_disable</a>(<span class="keywordtype">void</span>);</div> <div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> </div> -<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"><a class="line" href="group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4"> 65</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4">spi_disable</a>(<span class="keywordtype">void</span>);</div> -<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"> 66</span> </div> -<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305">spi_init_instance</a>(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud);</div> -<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> </div> -<div class="line"><a id="l00082" name="l00082"></a><span class="lineno"> 82</span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga8f1915874847b4564ab22039f2b8762f">spi_enable_instance</a>(uint8_t sercom);</div> -<div class="line"><a id="l00083" name="l00083"></a><span class="lineno"> 83</span> </div> -<div class="line"><a id="l00090" name="l00090"></a><span class="lineno"> 90</span>uint8_t <a class="code hl_function" href="group__spi.html#ga03d51191e1fb189fcddf1087999d58a2">spi_transfer_instance</a>(uint8_t sercom, uint8_t data);</div> -<div class="line"><a id="l00091" name="l00091"></a><span class="lineno"> 91</span> </div> -<div class="line"><a id="l00096" name="l00096"></a><span class="lineno"> 96</span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga3856b233dc7584708ab420d41c4816fe">spi_disable_instance</a>(uint8_t sercom);</div> -<div class="line"><a id="l00097" name="l00097"></a><span class="lineno"> 97</span> </div> +<div class="line"><a id="l00069" name="l00069"></a><span class="lineno"> 69</span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29">spi_init_instance</a>(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud);</div> +<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span> </div> +<div class="line"><a id="l00075" name="l00075"></a><span class="lineno"> 75</span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga8f1915874847b4564ab22039f2b8762f">spi_enable_instance</a>(uint8_t sercom);</div> +<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span> </div> +<div class="line"><a id="l00083" name="l00083"></a><span class="lineno"> 83</span>uint8_t <a class="code hl_function" href="group__spi.html#ga03d51191e1fb189fcddf1087999d58a2">spi_transfer_instance</a>(uint8_t sercom, uint8_t data);</div> +<div class="line"><a id="l00084" name="l00084"></a><span class="lineno"> 84</span> </div> +<div class="line"><a id="l00089" name="l00089"></a><span class="lineno"> 89</span><span class="keywordtype">void</span> <a class="code hl_function" href="group__spi.html#ga3856b233dc7584708ab420d41c4816fe">spi_disable_instance</a>(uint8_t sercom);</div> +<div class="line"><a id="l00090" name="l00090"></a><span class="lineno"> 90</span> </div> <div class="ttc" id="agroup__spi_html_ga03d51191e1fb189fcddf1087999d58a2"><div class="ttname"><a href="group__spi.html#ga03d51191e1fb189fcddf1087999d58a2">spi_transfer_instance</a></div><div class="ttdeci">uint8_t spi_transfer_instance(uint8_t sercom, uint8_t data)</div><div class="ttdoc">Transfers a byte over SPI.</div><div class="ttdef"><b>Definition</b> spi.c:70</div></div> +<div class="ttc" id="agroup__spi_html_ga236f4397be3ed06d5158e8dbfe387a29"><div class="ttname"><a href="group__spi.html#ga236f4397be3ed06d5158e8dbfe387a29">spi_init_instance</a></div><div class="ttdeci">void spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, uint32_t baud)</div><div class="ttdoc">Initializes a specific SERCOM instance as an SPI controller.</div><div class="ttdef"><b>Definition</b> spi.c:35</div></div> <div class="ttc" id="agroup__spi_html_ga3856b233dc7584708ab420d41c4816fe"><div class="ttname"><a href="group__spi.html#ga3856b233dc7584708ab420d41c4816fe">spi_disable_instance</a></div><div class="ttdeci">void spi_disable_instance(uint8_t sercom)</div><div class="ttdoc">Disables a specific SERCOM instance for SPI.</div><div class="ttdef"><b>Definition</b> spi.c:80</div></div> -<div class="ttc" id="agroup__spi_html_ga48ef10ade34f68b96d36dee03ebc4415"><div class="ttname"><a href="group__spi.html#ga48ef10ade34f68b96d36dee03ebc4415">spi_init</a></div><div class="ttdeci">void spi_init(spi_mode_t mode, uint32_t baud)</div><div class="ttdoc">Initializes the SPI peripheral for a board with a defined SPI_SERCOM.</div></div> <div class="ttc" id="agroup__spi_html_ga50084189a01c481aebe4e4d1e1968910"><div class="ttname"><a href="group__spi.html#ga50084189a01c481aebe4e4d1e1968910">spi_transfer</a></div><div class="ttdeci">uint8_t spi_transfer(uint8_t data)</div><div class="ttdoc">Transfers a byte over SPI for a board with a defined SPI_SERCOM.</div></div> -<div class="ttc" id="agroup__spi_html_ga72cf41d2f19954fefd27f681d6b39532"><div class="ttname"><a href="group__spi.html#ga72cf41d2f19954fefd27f681d6b39532">spi_enable</a></div><div class="ttdeci">void spi_enable(void)</div><div class="ttdoc">Enables the SPI peripheral for a board with a defined SPI_SERCOM.</div></div> +<div class="ttc" id="agroup__spi_html_ga72cf41d2f19954fefd27f681d6b39532"><div class="ttname"><a href="group__spi.html#ga72cf41d2f19954fefd27f681d6b39532">spi_enable</a></div><div class="ttdeci">void spi_enable(void)</div><div class="ttdoc">Enables the SPI SERCOM for a board with a defined SPI_SERCOM.</div></div> <div class="ttc" id="agroup__spi_html_ga8f1915874847b4564ab22039f2b8762f"><div class="ttname"><a href="group__spi.html#ga8f1915874847b4564ab22039f2b8762f">spi_enable_instance</a></div><div class="ttdeci">void spi_enable_instance(uint8_t sercom)</div><div class="ttdoc">Enables a specific SERCOM instance for SPI.</div><div class="ttdef"><b>Definition</b> spi.c:66</div></div> -<div class="ttc" id="agroup__spi_html_gaa8d2d6d1632faf9abbe03c3ed90d54d4"><div class="ttname"><a href="group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4">spi_disable</a></div><div class="ttdeci">void spi_disable(void)</div><div class="ttdoc">Disables the SPI peripheral for a board with a defined SPI_SERCOM.</div></div> -<div class="ttc" id="agroup__spi_html_gaee8eaa5f597d774c4fc4a6f7d6d08305"><div class="ttname"><a href="group__spi.html#gaee8eaa5f597d774c4fc4a6f7d6d08305">spi_init_instance</a></div><div class="ttdeci">void spi_init_instance(uint8_t sercom, spi_dopo_t dopo, spi_dipo_t dipo, spi_mode_t mode, uint32_t baud)</div><div class="ttdoc">Initializes a specific SERCOM instance for SPI.</div><div class="ttdef"><b>Definition</b> spi.c:35</div></div> +<div class="ttc" id="agroup__spi_html_gaa2b2013ee668e73a427b2a99da1ca47a"><div class="ttname"><a href="group__spi.html#gaa2b2013ee668e73a427b2a99da1ca47a">spi_init</a></div><div class="ttdeci">void spi_init(uint32_t baud)</div><div class="ttdoc">Initializes the SPI SERCOM as a controller for a board with a defined SPI_SERCOM.</div></div> +<div class="ttc" id="agroup__spi_html_gaa8d2d6d1632faf9abbe03c3ed90d54d4"><div class="ttname"><a href="group__spi.html#gaa8d2d6d1632faf9abbe03c3ed90d54d4">spi_disable</a></div><div class="ttdeci">void spi_disable(void)</div><div class="ttdoc">Disables the SPI SERCOM for a board with a defined SPI_SERCOM.</div></div> </div><!-- fragment --></div><!-- contents --> </div><!-- doc-content --> <!-- start footer part -->