{"id":5327,"date":"2026-08-30T15:20:53","date_gmt":"2026-08-30T06:20:53","guid":{"rendered":"https:\/\/donguri3.net\/server-tech\/rp2350-sd-card-read-write-adapter-reuse-2\/"},"modified":"2026-08-30T15:20:55","modified_gmt":"2026-08-30T06:20:55","slug":"rp2350-sd-card-read-write-adapter-reuse","status":"publish","type":"post","link":"https:\/\/donguri3.net\/en\/diy-repair\/electronics-microcontroller\/rp2350-sd-card-read-write-adapter-reuse\/","title":{"rendered":"\u3010RP2350\u3011No SD Card Module Required! Read and Write Data by Reusing a Spare Conversion Adapter"},"content":{"rendered":"<p>Following our setup of the RP2350 board last time, today we&#8217;ll take on the challenge of reading and writing data to an SD card.<\/p>\n<p><a href=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/01\/IMG_2815_fix2.jpg\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-2602\" src=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/01\/IMG_2815_fix2.jpg\" alt=\"RP2350 Development Board Module For Raspberry PI Dual Core 16MB\" width=\"549\" height=\"412\" srcset=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/01\/IMG_2815_fix2.jpg 549w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/01\/IMG_2815_fix2-300x225.jpg 300w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/01\/IMG_2815_fix2-530x398.jpg 530w\" sizes=\"(max-width: 549px) 100vw, 549px\" \/><\/a><\/p>\n<p>While an SD card is essential for recording sensor data and saving configuration files, you typically purchase a dedicated connection module to use one. However, if you have any leftover &#8220;SD card conversion adapters&#8221; that come with MicroSD card purchases, you can modify one and use it as a slot.<\/p>\n<p>In this post, I&#8217;ve compiled the steps for reading and writing data with the RP2350 using a spare adapter at hand, without buying an extra dedicated module. I&#8217;ll also share my personal soldering tips for wiring heat-sensitive plastic adapters without ruining them.<\/p>\n<h2>First, Verify Operation with a Commercial Module<\/h2>\n<p>If you jump straight into testing a homemade slot and it doesn&#8217;t work, it&#8217;s impossible to isolate whether the issue lies in the wiring or the program. First, I ran a communication test with the RP2350 using a commercially available SD card module I had on hand.<\/p>\n<p><a href=\"https:\/\/www.amazon.co.jp\/Youmile-%E3%82%AB%E3%83%BC%E3%83%89%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB%E3%83%9E%E3%82%A4%E3%82%AF%E3%83%AD-%E3%82%AB%E3%83%BC%E3%83%89%E3%82%A2%E3%83%80%E3%83%97%E3%82%BF%E3%83%AA%E3%83%BC%E3%83%AB%E3%83%BC%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB-%E3%82%A4%E3%82%B3%E3%83%B3%E3%83%86%E3%83%BC%E3%83%95%E3%82%A7%E3%82%A4%E3%83%B3%E3%82%B9%E3%83%AC%E3%83%99%E3%83%AB%E5%A4%89%E6%8F%9B%E3%83%81%E3%83%83%E3%83%97%E4%BB%98%E3%81%8D-Arduino\/dp\/B0C6KB34GZ?__mk_ja_JP=%E3%82%AB%E3%82%BF%E3%82%AB%E3%83%8A&amp;crid=2PW8Y13T3GS8D&amp;dib=eyJ2IjoiMSJ9.m8SM4sR8QfB275k0RUy78Vq3b9wL593ElB33-QqBB33NElkBqk4kqXGxQFqLabLiiI_e5HxbO6mAMQqKC5yKr9NMnHv7blUipth8DAQS90DAjnlCNTAufu1EdIrWASXQLLVGXshww9bz6-i6Ey1ujxhhyUoWNXS9sxCxPN9GOqndOkjdOFhF4ZYgA_8eniaDJS-pBOr6G38iW6_G-yAMj2wxSUYpayb6jqgk3toBt4olqjsjmKUN7EQ95UUC4s5Q82zEVfw3iLlJT1QXBfA4G6E_q9Kk3RyrkLRcA60Tquc.p3v0QlKBzLtNpjcpIgAAZ4u8H1jDLXZbk8usMnakLoM&amp;dib_tag=se&amp;keywords=10%E5%80%8BSD%E3%82%AB%E3%83%BC%E3%83%89%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%AB%E3%83%9E%E3%82%A4%E3%82%AF%E3%83%ADSD+SDHC+TF%E3%82%AB%E3%83%BC%E3%83%89%E3%82%A2%E3%83%80%E3%83%97%E3%82%BF%E3%83%AA%E3%83%BC%E3%83%80%E3%83%BC%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB+SPI%E3%82%A4%E3%82%B3%E3%83%B3%E3%83%86%E3%83%95%E3%82%A7%E3%82%A4%E3%82%B3%E3%83%AC%E3%83%99%E3%83%AB%E5%A4%89%E6%8F%9B%E3%83%81%E3%83%83%E3%83%97%E4%BB%98%E3%81%8D%E3%83%94%E3%83%B3%E3%83%98%E3%83%83%E3%83%80%E3%83%BC%E4%BB%98%E3%81%8Dfor+Arduino%E7%94%A8&amp;qid=1769690438&amp;sprefix=10%E5%80%8Bsd%E3%82%AB%E3%83%BC%E3%83%89%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%AB%E3%83%9E%E3%82%A4%E3%82%AF%E3%83%ADsd+sdhc+tf%E3%82%AB%E3%83%BC%E3%83%89%E3%82%A2%E3%83%80%E3%83%97%E3%82%BF%E3%83%AA%E3%83%BC%E3%83%80%E3%83%BC%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB+spi%E3%82%A4%E3%82%B3%E3%83%B3%E3%83%86%E3%83%95%E3%82%A7%E3%82%A4%E3%82%B9%E3%83%AC%E3%83%99%E3%83%AB%E5%A4%89%E6%8F%9B%E3%83%81%E3%83%83%E3%83%97%E4%BB%98%E3%81%8D%E3%83%94%E3%83%B3%E3%83%83%E3%83%80%E3%83%BC%E4%BB%98%E3%81%8Dfor+arduino%E7%94%A8%2Caps%2C191&amp;sr=8-1&amp;linkCode=sl1&amp;tag=nando09e-22&amp;linkId=769d5a20b8fd598d01cdd55395ff20c7&amp;language=ja_JP&amp;ref_=as_li_ss_tl\" data-blogcard=\"1\">https:\/\/www.amazon.co.jp\/Youmile-%E3%82%AB%E3%83%BC%E3%83%89%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB%E3%83%9E%E3%82%A4%E3%82%AF%E3%83%AD-%E3%82%AB%E3%83%BC%E3%83%89%E3%82%A2%E3%83%80%E3%83%97%E3%82%BF%E3%83%AA%E3%83%BC%E3%83%AB%E3%83%BC%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%BC%E3%83%AB-%E3%82%A4%E3%82%B3%E3%83%B3%E3%83%86%E3%83%95%E3%82%A7%E3%82%A4%E3%82%B3%E3%83%AC%E3%83%99%E3%83%AB%E5%A4%89%E6%8F%9B%E3%83%81%E3%83%83%E3%83%97%E4%BB%98%E3%81%8D-Arduino\/dp\/B0C6KB34GZ?__mk_ja_JP=%E3%82%AB%E3%82%BF%E3%82%AB%E3%83%8A&amp;crid=2PW8Y13T3GS8D&amp;dib=eyJ2IjoiMSJ9.m8SM4sR8QfB275k0RUy78Vq3b9wL593ElB33-QqBB33NElkBqk4kqXGxQFqLabLiiI_e5HxbO6mAMQqKC5yKr9NMnHv7blUipth8DAQS90DAjnlCNTAufu1EdIrWASXQLLVGXshww9bz6-i6Ey1ujxhhyUoWNXS9sxCxPN9GOqndOkjdOFhF4ZYgA_8eniaDJS-pBOr6G38iW6_G-yAMj2wxSUYpayb6jqgk3toBt4olqjsjmKUN7EQ95UUC4s5Q82zEVfw3iLlJT1QXBfA4G6E_q9Kk3RyrkLRcA60Tquc.p3v0QlKBzLtNpjcpIgAAZ4u8H1jDLXZbk8usMnakLoM&amp;dib_tag=se&amp;keywords=10%E5%80%8BSD%E3%82%AB%E3%83%BC%E3%83%89%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%AB%E3%83%9E%E3%82%A4%E3%82%AF%E3%83%ADSD+SDHC+TF%E3%82%AB%E3%83%BC%E3%83%89%E3%82%A2%E3%83%80%E3%83%97%E3%82%BF%E3%83%AA%E3%83%BC%E3%83%80%E3%83%BC%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%AB+SPI%E3%82%A4%E3%82%B3%E3%83%B3%E3%83%86%E3%83%95%E3%82%A7%E3%82%A4%E3%82%B3%E3%83%AC%E3%83%99%E3%83%AB%E5%A4%89%E6%8F%9B%E3%83%81%E3%83%83%E3%83%97%E4%BB%98%E3%81%8D%E3%83%94%E3%83%B3%E3%83%83%E3%83%80%E3%83%BC%E4%BB%98%E3%81%8Dfor+Arduino%E7%94%A8&amp;qid=1769690438&amp;sprefix=10%E5%80%8Bsd%E3%82%AB%E3%83%BC%E3%83%89%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%AB%E3%83%9E%E3%82%A4%E3%82%AF%E3%83%ADsd+sdhc+tf%E3%82%AB%E3%83%BC%E3%83%89%E3%82%A2%E3%83%80%E3%83%97%E3%82%BF%E3%83%AA%E3%83%BC%E3%83%80%E3%83%BC%E3%83%A2%E3%82%B8%E3%83%A5%E3%83%AB+spi%E3%82%A4%E3%82%B3%E3%83%B3%E3%83%86%E3%83%95%E3%82%A7%E3%82%A4%E3%82%B3%E3%83%AC%E3%83%99%E3%83%AB%E5%A4%89%E6%8F%9B%E3%83%81%E3%83%83%E3%83%97%E4%BB%98%E3%81%8D%E3%83%94%E3%83%B3%E3%83%83%E3%83%80%E3%83%BC%E4%BB%98%E3%81%8Dfor+arduino%E7%94%A8%2Caps%2C191&amp;sr=8-1&amp;linkCode=sl1&amp;tag=nando09e-22&amp;linkId=769d5a20b8fd598d01cdd55395ff20c7&amp;language=ja_JP&amp;ref_=as_li_ss_tl<\/a><\/p>\n<p>While this is a reassuring design featuring a 3.3V\/5V level shifting chip, the RP2350 (3.3V) can operate even with a direct connection.<\/p>\n<h2>Introducing the &#8220;SdFat&#8221; Library<\/h2>\n<p>Before running tests, install the library for handling SD cards in the Arduino IDE. This time, we will use <span data-path-to-node=\"4,3,0,0\">SdFat<\/span>, which is highly functional and works great with the RP2350.<\/p>\n<ol>\n<li>Open the Arduino IDE menu and go to &#8220;Tools&#8221; -&gt; &#8220;Manage Libraries&#8230;&#8221;.<\/li>\n<li>Search for <span data-path-to-node=\"5,1,1,0\">SdFat<\/span> and install it.<\/li>\n<\/ol>\n<p>I performed a read\/write test using this library and confirmed that it works properly. Great, now the microcontroller and software setup are complete.<\/p>\n<h2>Attempting Direct Soldering to the Conversion Adapter<\/h2>\n<p>Now, this is where the real work begins. The terminals of the conversion adapter are gold-plated, making it easy for solder to adhere&#8230; or so you&#8217;d think, but the base is made of heat-sensitive plastic. If you hesitate, heat will conduct and deform the inside, making it impossible to insert an SD card.<\/p>\n<p>While the conventional wisdom has been to &#8220;solder with a dummy SD card inserted to prevent deformation,&#8221; I solved this using the power of tools and chemistry.<\/p>\n<p>Nando Kobo Style: The Secret to Soldering Without Melting<br \/>The key to success is &#8220;minimizing the time heat is conducted to an absolute minimum.&#8221; To achieve this, I used the following tool.<\/p>\n<p><a href=\"https:\/\/amzn.to\/43GJCuB\" blogcard=\"1\">https:\/\/amzn.to\/3LJns5I<\/a><\/p>\n<p>Using a toothpick or similar tool, dab just a small amount of this onto the tips of the adapter&#8217;s terminals.<\/p>\n<p><a href=\"https:\/\/amzn.to\/43GJCuB\" blogcard=\"1\">https:\/\/amzn.to\/3LJns5I<\/a><\/p>\n<p>Since there are no wires in the way, your hands won&#8217;t slip, allowing you to hit the exact target spot in one go.<\/p>\n<h3 data-path-to-node=\"25\"><b data-path-to-node=\"25\" data-index-in-node=\"0\">[Procedure]<\/b><\/h3>\n<ol>\n<li data-path-to-node=\"26,0,0\">Apply paste to the tips of the terminals.<br \/>\n<a href=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825.jpg\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-2630\" src=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825.jpg\" alt=\"Applying Flux\" width=\"604\" height=\"806\" srcset=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825.jpg 604w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825-225x300.jpg 225w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825-397x530.jpg 397w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825-423x565.jpg 423w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825-532x710.jpg 532w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2825-543x725.jpg 543w\" sizes=\"(max-width: 604px) 100vw, 604px\" \/><\/a><\/li>\n<li data-path-to-node=\"26,1,0\">Pre-tin the soldering iron tip with a little solder.<\/li>\n<li data-path-to-node=\"26,2,0\">Briefly touch the iron to the pasted area. <b data-path-to-node=\"26,2,0\" data-index-in-node=\"24\">The required time is 0.5 seconds!<\/b><\/li>\n<li data-path-to-node=\"26,3,0\">Thanks to the effect of the paste, the solder flows smoothly onto the terminal instantly.<\/li>\n<\/ol>\n<p>With this method, the job finishes before heat can conduct to the plastic part (the base), preventing deformation even without inserting a dummy card. &#8220;Soldering is about speed, not temperature.&#8221; This was the moment I truly realized that.<\/p>\n<p><a href=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820.jpg\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-2626\" src=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820.jpg\" alt=\"Soldering\" width=\"604\" height=\"806\" srcset=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820.jpg 604w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820-225x300.jpg 225w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820-397x530.jpg 397w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820-423x565.jpg 423w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820-532x710.jpg 532w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2820-543x725.jpg 543w\" sizes=\"(max-width: 604px) 100vw, 604px\" \/><\/a><\/p>\n<h2>Wiring and Program<\/h2>\n<p>Connect the completed &#8220;DIY SD slot&#8221; to the RP2350.<\/p>\n<p>[Wiring Diagram] (*Pin assignment with the terminal side facing you and the corner notch of the adapter in the upper left)<\/p>\n<table data-path-to-node=\"9\">\n<thead>\n<tr>\n<td><strong>Adapter Terminal (from left)<\/strong><\/td>\n<td><strong>Signal Name (SPI)<\/strong><\/td>\n<td><strong>RP2040-Zero<\/strong><\/td>\n<td><strong>Role<\/strong><\/td>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><span data-path-to-node=\"9,1,0,0\"><b data-path-to-node=\"9,1,0,0\" data-index-in-node=\"0\">Pin 9 (Far Left)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,1,1,0\">DAT2<\/span><\/td>\n<td><span data-path-to-node=\"9,1,2,0\"><b data-path-to-node=\"9,1,2,0\" data-index-in-node=\"0\">(Not Connected)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,1,3,0\">Not used in SPI<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,2,0,0\"><b data-path-to-node=\"9,2,0,0\" data-index-in-node=\"0\">Pin 1 (2nd)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,2,1,0\"><b data-path-to-node=\"9,2,1,0\" data-index-in-node=\"0\">CS<\/b> \/ DAT3<\/span><\/td>\n<td><span data-path-to-node=\"9,2,2,0\"><b data-path-to-node=\"9,2,2,0\" data-index-in-node=\"0\">GP 5<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,2,3,0\"><b data-path-to-node=\"9,2,3,0\" data-index-in-node=\"0\">Chip Select<\/b> (Selecting communication partner)<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,3,0,0\"><b data-path-to-node=\"9,3,0,0\" data-index-in-node=\"0\">Pin 2 (3rd)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,3,1,0\"><b data-path-to-node=\"9,3,1,0\" data-index-in-node=\"0\">MOSI<\/b> \/ CMD<\/span><\/td>\n<td><span data-path-to-node=\"9,3,2,0\"><b data-path-to-node=\"9,3,2,0\" data-index-in-node=\"0\">GP 7<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,3,3,0\"><b data-path-to-node=\"9,3,3,0\" data-index-in-node=\"0\">Data Transmit<\/b> (Microcontroller -&gt; SD)<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,4,0,0\"><b data-path-to-node=\"9,4,0,0\" data-index-in-node=\"0\">Pin 3 (4th)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,4,1,0\">VSS1 (GND)<\/span><\/td>\n<td><span data-path-to-node=\"9,4,2,0\"><b data-path-to-node=\"9,4,2,0\" data-index-in-node=\"0\">GND<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,4,3,0\">Ground *1<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,5,0,0\"><b data-path-to-node=\"9,5,0,0\" data-index-in-node=\"0\">Pin 4 (5th)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,5,1,0\">VDD<\/span><\/td>\n<td><span data-path-to-node=\"9,5,2,0\"><b data-path-to-node=\"9,5,2,0\" data-index-in-node=\"0\">3V3<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,5,3,0\">Power Supply (3.3V)<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,6,0,0\"><b data-path-to-node=\"9,6,0,0\" data-index-in-node=\"0\">Pin 5 (6th)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,6,1,0\"><b data-path-to-node=\"9,6,1,0\" data-index-in-node=\"0\">SCK<\/b> \/ CLK<\/span><\/td>\n<td><span data-path-to-node=\"9,6,2,0\"><b data-path-to-node=\"9,6,2,0\" data-index-in-node=\"0\">GP 6<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,6,3,0\"><b data-path-to-node=\"9,6,3,0\" data-index-in-node=\"0\">Clock<\/b> (Communication timing)<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,7,0,0\"><b data-path-to-node=\"9,7,0,0\" data-index-in-node=\"0\">Pin 6 (7th)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,7,1,0\">VSS2 (GND)<\/span><\/td>\n<td><span data-path-to-node=\"9,7,2,0\"><b data-path-to-node=\"9,7,2,0\" data-index-in-node=\"0\">GND<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,7,3,0\">Ground *1<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,8,0,0\"><b data-path-to-node=\"9,8,0,0\" data-index-in-node=\"0\">Pin 7 (8th)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,8,1,0\"><b data-path-to-node=\"9,8,1,0\" data-index-in-node=\"0\">MISO<\/b> \/ DAT0<\/span><\/td>\n<td><span data-path-to-node=\"9,8,2,0\"><b data-path-to-node=\"9,8,2,0\" data-index-in-node=\"0\">GP 4<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,8,3,0\"><b data-path-to-node=\"9,8,3,0\" data-index-in-node=\"0\">Data Receive<\/b> (SD -&gt; Microcontroller)<\/span><\/td>\n<\/tr>\n<tr>\n<td><span data-path-to-node=\"9,9,0,0\"><b data-path-to-node=\"9,9,0,0\" data-index-in-node=\"0\">Pin 8 (Far Right)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,9,1,0\">DAT1<\/span><\/td>\n<td><span data-path-to-node=\"9,9,2,0\"><b data-path-to-node=\"9,9,2,0\" data-index-in-node=\"0\">(Not Connected)<\/b><\/span><\/td>\n<td><span data-path-to-node=\"9,9,3,0\">Not used in SPI<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><a href=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969.jpg\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-2629\" src=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969.jpg\" alt=\"Connection\" width=\"553\" height=\"559\" srcset=\"https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969.jpg 553w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969-297x300.jpg 297w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969-75x75.jpg 75w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969-100x100.jpg 100w, https:\/\/donguri3.net\/wp-content\/uploads\/2026\/02\/IMG_2823-e1769694497969-524x530.jpg 524w\" sizes=\"(max-width: 553px) 100vw, 553px\" \/><\/a><\/p>\n<h3>Test Program<\/h3>\n<p>We use the same code verified in Step 1. *Note: When using the SdFat library, use the class name SdFile instead of File.<\/p>\n<p>#include &amp;lt;SPI.h&amp;gt;<br \/>\n#include &amp;quot;SdFat.h&amp;quot;<\/p>\n<p>\/\/ &#8212; Pin configuration (RP2350 \/ Pico 2) &#8212;<br \/>\n\/\/ Uses the same pin layout as the RP2040<br \/>\nconst int PIN_MISO = 4;<br \/>\nconst int PIN_CS = 5;<br \/>\nconst int PIN_SCK = 6;<br \/>\nconst int PIN_MOSI = 7;<\/p>\n<p>\/\/ SdFat configuration<br \/>\nSdFat sd;<br \/>\nSdFile myFile;<\/p>\n<p>void setup() {<br \/>\nSerial.begin(115200);<\/p>\n<p>\/\/ Wait for serial connection<br \/>\nwhile (!Serial) { yield(); }<br \/>\ndelay(1000);<\/p>\n<p>Serial.println(&amp;quot;<br \/>\n&#8212; RP2350 (Pico 2) SPI SD Card Test &#8212;&amp;quot;);<\/p>\n<p>\/\/ Display chip information (useful for blog screenshots)<br \/>\nSerial.print(&amp;quot;Board Target: &amp;quot;);<br \/>\n#if defined(ARDUINO_ARCH_RP2040)<br \/>\nSerial.println(&amp;quot;RP2040 \/ RP2350 Architecture&amp;quot;);<br \/>\n#else<br \/>\nSerial.println(&amp;quot;Unknown Architecture&amp;quot;);<br \/>\n#endif<\/p>\n<p>\/\/ 1. SPI pin assignment (This function is also valid on the RP2350)<br \/>\nSPI.setRX(PIN_MISO);<br \/>\nSPI.setTX(PIN_MOSI);<br \/>\nSPI.setSCK(PIN_SCK);<\/p>\n<p>Serial.println(&amp;quot;Initializing SD card&#8230;&amp;quot;);<\/p>\n<p>\/\/ 2. SD card initialization<br \/>\n\/\/ The RP2350 is fast, but let&#8217;s test connection at a stable 16MHz first<br \/>\nif (!sd.begin(PIN_CS, SD_SCK_MHZ(16))) {<br \/>\nSerial.println(&amp;quot;Error: SD card initialization failed.&amp;quot;);<br \/>\nSerial.println(&amp;quot;- Check wiring?&amp;quot;);<br \/>\nSerial.println(&amp;quot;- Check format (FAT32)?&amp;quot;);<br \/>\nsd.initErrorHalt(&amp;amp;Serial);<br \/>\nreturn;<br \/>\n}<br \/>\nSerial.println(&amp;quot;Success: SD card initialized!&amp;quot;);<\/p>\n<p>\/\/ &#8212; Write test &#8212;<br \/>\nSerial.print(&amp;quot;Writing test.txt&#8230; &amp;quot;);<\/p>\n<p>if (!myFile.open(&amp;quot;test_rp2350.txt&amp;quot;, O_RDWR | O_CREAT | O_APPEND)) {<br \/>\nSerial.println(&amp;quot;Error: Failed to open file for writing.&amp;quot;);<br \/>\nreturn;<br \/>\n}<\/p>\n<p>\/\/ Record that the write is coming from the RP2350<br \/>\nmyFile.println(&amp;quot;Hello from RP2350 (Pico 2)! SPI write test successful.&amp;quot;);<br \/>\nmyFile.close();<br \/>\nSerial.println(&amp;quot;Done.&amp;quot;);<\/p>\n<p>\/\/ &#8212; Read test &#8212;<br \/>\nSerial.println(&amp;quot;Reading test.txt content:&amp;quot;);<br \/>\nSerial.println(&amp;quot;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-&amp;quot;);<\/p>\n<p>if (!myFile.open(&amp;quot;test_rp2350.txt&amp;quot;, O_READ)) {<br \/>\nSerial.println(&amp;quot;Error: Failed to open file for reading.&amp;quot;);<br \/>\nreturn;<br \/>\n}<\/p>\n<p>while (myFile.available()) {<br \/>\nSerial.write(myFile.read());<br \/>\n}<br \/>\nmyFile.close();<\/p>\n<p>Serial.println(&amp;quot;<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-&amp;quot;);<br \/>\nSerial.println(&amp;quot;Test Complete.&amp;quot;);<br \/>\n}<\/p>\n<p>void loop() {<br \/>\n\/\/ Do nothing<br \/>\n}<\/p>\n<h2>Investing in Tools Leads to DIY Success<\/h2>\n<p>Buying a cheap SD module for a few hundred yen is also a valid approach, but utilizing a conversion adapter you have on hand gives you the advantage of freely deciding the layout and orientation of the slot. Above all, I gained valuable experience knowing that &#8220;with the right flux, even difficult soldering jobs can be finished in an instant.&#8221;<\/p>\n<p>This establishes an environment for reading and writing large volumes of data. Next time, I&#8217;ll try high-speed reading and writing using PIO SDIO with this SD card adapter.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Following our setup of the RP2350 board last time, today we&#8217;ll take on the challenge of reading and writ [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":2635,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_locale":"en_US","_original_post":"https:\/\/donguri3.net\/?p=2620","footnotes":""},"categories":[1163],"tags":[9,52,262,1053,1059,325,274,278,270],"class_list":["post-5327","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-electronics-microcontroller","tag-diy","tag-https","tag-rp2040-zero","tag-rp2350","tag-sd","tag-325","tag-274","tag-278","tag-270","en-US"],"_links":{"self":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts\/5327","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/comments?post=5327"}],"version-history":[{"count":1,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts\/5327\/revisions"}],"predecessor-version":[{"id":5331,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts\/5327\/revisions\/5331"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/media\/2635"}],"wp:attachment":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/media?parent=5327"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/categories?post=5327"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/tags?post=5327"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}