{"id":41281,"date":"2021-03-15T16:27:17","date_gmt":"2021-03-15T08:27:17","guid":{"rendered":"\/blog\/?p=41281"},"modified":"2021-03-15T16:27:20","modified_gmt":"2021-03-15T08:27:20","slug":"how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer","status":"publish","type":"post","link":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/","title":{"rendered":"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer"},"content":{"rendered":"\n<p>In this article, I\u2019m going to take you through all you need to know about using an I2C Multiplexer. We&#8217;ll be covering the following:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>What is the I2C Communication Protocol?<\/li><li>Why use an I2C Multiplexer?<\/li><li>How does an I2C Multiplexer work?<\/li><li>How to use an I2C Multiplexer with Arduino<\/li><\/ul>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img fetchpriority=\"high\" decoding=\"async\" width=\"1030\" height=\"601\" src=\"https:\/\/blog.seeedstudio.com\/wp-content\/uploads\/2021\/03\/Week-8-8-1030x601.png\" alt=\"\" class=\"wp-image-41372\" srcset=\"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1030x601.png 1030w, https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-300x175.png 300w, https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-768x448.png 768w, https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1536x896.png 1536w, https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-2048x1195.png 2048w, https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1024x597.png 1024w\" sizes=\"(max-width: 1030px) 100vw, 1030px\" \/><\/figure><\/div>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Recap: What is I2C?<\/strong><\/h2>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>I2C, pronounced I-squared-C, stands for inter-integrated circuit. I2C is a flexible multi-master, multi-slave serial communication protocol that combines the best features of SPI (Serial Peripheral Interface) and UART (Universal Asynchronous Receiver \/ Transmitter).<\/p>\n\n\n\n<p>Compared to UART, I2C is able to support faster and more simultaneous connections with peripheral devices. At the same time, it tackles the weaknesses of SPI by still only requiring two wires and allowing for multi-master interfaces.<\/p>\n\n\n\n<p>As a result, I2C is a very popular communication protocol that is in many hardware modules. For example, here are some popular Grove modules that use I2C communication.<\/p>\n\n\n\n<div style=\"height:10px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<ul class=\"wp-block-list\"><li><a href=\"https:\/\/www.seeedstudio.com\/Grove-I2C-Motor-Driver-with-L298.html\">Grove &#8211; I2C Motor Driver with L298<\/a><\/li><li><a href=\"https:\/\/www.seeedstudio.com\/Grove-AHT20-I2C-Industrial-grade-temperature-and-humidity-sensor-p-4497.html\">Grove &#8211; AHT20 I2C Industrial Grade Temperature and Humidity Sensor<\/a><\/li><li><a href=\"https:\/\/www.seeedstudio.com\/Grove-I2C-Color-Sensor-V2.html\">Grove &#8211; I2C Color Sensor V2<\/a><\/li><\/ul>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>To read more in depth about I2C, be sure to read our <a href=\"https:\/\/www.seeedstudio.com\/blog\/2019\/09\/26\/i2c-communication-interface-and-protocol-with-diagrams\/\">I2C Communication Guide<\/a>.<\/p>\n\n\n\n<p>If you\u2019re confused about the differences between I2C and other protocols like UART and SPI, you\u2019ll also benefit from reading <a href=\"https:\/\/www.seeedstudio.com\/blog\/2019\/09\/25\/uart-vs-i2c-vs-spi-communication-protocols-and-uses\/\">this article<\/a>, where we explain the differences between each of the communication protocols and their uses.&nbsp;<\/p>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Why use an I2C Multiplexer? &#8211; I2C Addressing<\/strong><\/h2>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>Since I2C allows for a single controller (master) to communicate with multiple peripherals (slaves), there must be some way to identify which peripheral each message is meant for. In I2C, this is done through addressing. Each device that uses I2C has an I2C address.<\/p>\n\n\n\n<div style=\"height:25px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter is-resized\"><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/xRwh-L-QatheDrzuPC0BYB5hl0SR_ctewHS8pcId-vWRfkb1h-uBJQHZSWX1unMqbmdhiroX_nk06arVUOKV0btHqXf4K6qj3ChGg6s0ehV1tPGKJbKe9LH1fxlNM-NsLg008ThF\" alt=\"\" width=\"600\"\/><figcaption>Source: CircuitBasics<\/figcaption><\/figure><\/div>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>The controller sends the address of the peripheral that it wants to communicate with to every connected peripheral device. Each peripheral then compares the received address to its own, sending an acknowledgement bit back to the controller if there is a match. Otherwise, the message is ignored. Following this, data is sent from the controller to the peripheral, which is once again acknowledged.<\/p>\n\n\n\n<p>That sounds nice and straightforward, but what happens when we want to use two I2C modules in the same system? Most I2C devices have a fixed address, so if you want to use more than one of the same device, you\u2019re going to run into an addressing conflict.<\/p>\n\n\n\n<p>That\u2019s where the multiplexer comes in!<\/p>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>How does an I2C Multiplexer work?<\/strong><\/h2>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>As a direct example to today\u2019s guide, we\u2019re going to look at the <a href=\"https:\/\/www.seeedstudio.com\/Grove-8-Channel-I2C-Hub-TCA9548A-p-4398.html\">TCA9548A-based Grove 8-Channel I2C Hub<\/a>. Grove is a standardised, modular prototyping system that makes hardware and electronics more accessible by removing the need for complicated wiring or solder. To date, Grove has over 300+ compatible modules, allowing anyone to get into building any kind of project easily.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter is-resized\"><img decoding=\"async\" src=\"https:\/\/lh3.googleusercontent.com\/RSwmF3cZ9Fb5g5Gy_ksJU7QCj0N8QiiZkztaeZWq7uKuX5hhtGRd09BPOelI2oNyrmm6jbk3BRPiY6ttCRo6xs1tepMfNkzOn2b4pRYYyElSyv5nFsZlHvU39d3lBQ7pP3VBo7bF\" alt=\"\" width=\"400\"\/><\/figure><\/div>\n\n\n\n<p>The Grove 8-Channel I2C Hub uses the TCA9548A I2C Multiplexer Chip. As the name suggests, it can interface with 8 different channels.<\/p>\n\n\n\n<p>The hub itself has an I2C address of 0x70. But by writing data to this address, we can select which channel we want to open or close on the fly. When we plug in devices with conflicting I2C addresses, we can simply adjust the desired channels prior to transmitting data as usual. In doing so, we ensure that there is technically only one \u2018active\u2019 device at a given I2C address, hence eliminating the conflict.<\/p>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Using an I2C Multiplexer with the Arduino IDE<\/strong><\/h2>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>Fortunately, like all Grove modules, the Grove 8-Channel I2C Hub comes with an Arduino software library that allows you to interface with it quickly and conveniently with any Arduino-compatible microcontroller. Let\u2019s take a look at how we can control the hub to interface with multiple modules that have conflicting I2C addresses.<\/p>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p><strong>Step 1: <\/strong>Download &amp; Install the <span style=\"text-decoration: underline;\"><a href=\"https:\/\/files.seeedstudio.com\/products\/103020293\/document\/Grove_8Channel_I2C_Hub_test_library.zip\">Grove 8 Channel I2C Hub Library<\/a><\/span>.<\/p>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p><strong>Step 2:<\/strong> Include the Following Code in Your Arduino Sketch.<\/p>\n\n\n\n<div style=\"height:10px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<pre class=\"wp-block-code\"><code>#include \"TCA9548A.h\"\n\/\/ if you use the software I2C to drive, you can uncomment define SOFTWAREWIRE in TCA9548A.h. \n#ifdef SOFTWAREWIRE\n  #include &lt;SoftwareWIRE.h&gt;\n  SoftwareWire myWIRE(3, 2);\n  TCA9548A&lt;SoftwareWire&gt; TCA;\n  #define WIRE myWIRE\n#else   \n  #include &lt;Wire.h&gt;\n  TCA9548A&lt;TwoWire&gt; TCA;\n  #define WIRE Wire\n#endif<\/code><\/pre>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p><strong>Step 3: <\/strong>Open the Connection to the TCA Multiplexer on the Grove Hub in Setup().<\/p>\n\n\n\n<div style=\"height:10px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<pre class=\"wp-block-code\"><code>TCA.begin(WIRE);<\/code><\/pre>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p><strong>Step 4: <\/strong>Write the code!<\/p>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>Let\u2019s say we want to use two of the Grove &#8211; AHT20 I2C Temperature and Humidity Sensor that have an I2C address of 0x38, plugged in at ports 0 and 1. To make things easier, let\u2019s first also include the Grove library for the AHT20 sensor, which can be downloaded <a href=\"https:\/\/s3-us-west-2.amazonaws.com\/files.seeedstudio.com\/products\/101990644\/document\/ATH20_Arduino_Library.zip\">here<\/a>.<\/p>\n\n\n\n<div style=\"height:10px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<pre class=\"wp-block-code\"><code>#include \"AHT20.h\"<\/code><\/pre>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>Also initialise each sensor separately, taking care to open and close the corresponding channels.<\/p>\n\n\n\n<div style=\"height:10px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<pre class=\"wp-block-code\"><code>TCA.openChannel(TCA_CHANNEL_0);\nAHT.begin();\nTCA.closeChannel(TCA_CHANNEL_0);\nTCA.openChannel(TCA_CHANNEL_1);\nAHT.begin();\nTCA.closeChannel(TCA_CHANNEL_1);<\/code><\/pre>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>As you might guess, retrieving the readings from each sensor can be done in a similar way. The resulting code reads and prints out the temperature and humidity readings from each sensor consecutively to the serial monitor. Naturally, you can easily extend this method to use any other kind of Grove I2C sensors with conflicting addresses!<\/p>\n\n\n\n<div style=\"height:10px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<pre class=\"wp-block-code\"><code>void loop()\n{\n    float humi1, temp1, humi2, temp2;\n \n    \/\/ First AHT20 Sensor\n    TCA.openChannel(TCA_CHANNEL_0);\n    int ret1 = AHT.getSensor(&amp;humi1, &amp;temp1);\n\n    if(ret1)     \/\/ GET DATA FROM AHT20 1 OK\n    {\n        Serial.print(\"humidity: \");\n        Serial.print(humi1*100);\n        Serial.print(\"%\\t temerature: \");\n        Serial.println(temp1);\n    }\n    else\n    {\n        Serial.println(\"GET DATA FROM AHT20 1 FAIL\");\n    }\n\n    TCA.closeChannel(TCA_CHANNEL_0);\n    \n    \/\/ Second AHT20 Sensor\n    TCA.openChannel(TCA_CHANNEL_1);\n    int ret2 = AHT.getSensor(&amp;humi2, &amp;temp2);\n\n    if(ret2)     \/\/ GET DATA FROM AHT20 2 OK\n    {\n        Serial.print(\"humidity: \");\n        Serial.print(humi2*100);\n        Serial.print(\"%\\t temerature: \");\n        Serial.println(temp2);\n    }\n    else\n    {\n        Serial.println(\"GET DATA FROM AHT20 2 FAIL\");\n    }\n\n    TCA.closeChannel(TCA_CHANNEL_1);\n \n    delay(100);\n}<\/code><\/pre>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Summary<\/strong><\/h2>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>This concludes our tutorial on I2C multiplexers! As you can see, with the <a href=\"http:\/\/TCA9548A-based Grove 8-Channel I2C Hub\">Grove 8-Channel I2C Multiplexer<\/a> and some additional lines of code, we can not only resolve I2C address conflicts but also make use of multiple sensors with the same I2C address easily!<\/p>\n\n\n\n<p>If you\u2019re simply looking for an I2C hub <em>without multiplexing capabilities<\/em>, the <a href=\"https:\/\/www.seeedstudio.com\/Grove-I2C-Hub-6-Port-p-4349.html\">Grove I2C Hub (6 Port)<\/a> or <a href=\"https:\/\/www.seeedstudio.com\/Grove-I2C-Hub.html\">Grove I2C Hub<\/a> with 4 ports may suit your needs better.<\/p>\n\n\n\n<p>Are you in the market for an Arduino board? Check out our <a href=\"https:\/\/www.seeedstudio.com\/blog\/2020\/02\/20\/arduino-boards-selection-guide\/\">Arduino Buying Guide<\/a> for a comprehensive coverage and comparison! Alternatively, kindly visit the <a href=\"https:\/\/www.seeedstudio.com\/category\/Grove-c-1003.html\">Seeed Online Store<\/a> to explore more Grove modules.<\/p>\n\n\n\n<div style=\"height:15px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p>If you simply want to learn more about communication protocols, don\u2019t forget to read our other guides below.<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><a href=\"https:\/\/www.seeedstudio.com\/blog\/2019\/09\/26\/i2c-communication-interface-and-protocol-with-diagrams\/\">I2C Communication \u2013 All about I\u00b2C with Diagrams<\/a><\/li><li><a href=\"https:\/\/www.seeedstudio.com\/blog\/2019\/09\/25\/uart-vs-i2c-vs-spi-communication-protocols-and-uses\/\">UART vs I2C vs SPI \u2013 Communication Protocols and Uses<\/a><\/li><\/ul>\n\n\n\n<div style=\"height:40px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n","protected":false},"excerpt":{"rendered":"<p>In this article, I\u2019m going to take you through all you need to know about<\/p>\n","protected":false},"author":3537,"featured_media":41373,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_lmt_disableupdate":"","_lmt_disable":"","_price":"","_stock":"","_tribe_ticket_header":"","_tribe_default_ticket_provider":"","_tribe_ticket_capacity":"0","_ticket_start_date":"","_ticket_end_date":"","_tribe_ticket_show_description":"","_tribe_ticket_show_not_going":false,"_tribe_ticket_use_global_stock":"","_tribe_ticket_global_stock_level":"","_global_stock_mode":"","_global_stock_cap":"","_tribe_rsvp_for_event":"","_tribe_ticket_going_count":"","_tribe_ticket_not_going_count":"","_tribe_tickets_list":"[]","_tribe_ticket_has_attendee_info_fields":false,"iawp_total_views":0,"footnotes":""},"categories":[1],"tags":[1645,1647,1651,1659,472],"class_list":["post-41281","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-news","tag-i2c","tag-i2c-communication","tag-i2c-communication-protocol","tag-i2c-interface","tag-tutorial"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.0 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer - Latest News from Seeed Studio<\/title>\n<meta name=\"description\" content=\"I2C features the best of both SPI and UART protocols. Learn about how an I2C multiplexer can conveniently resolve I2C addressing conflicts in your project!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer - Latest News from Seeed Studio\" \/>\n<meta property=\"og:description\" content=\"I2C features the best of both SPI and UART protocols. Learn about how an I2C multiplexer can conveniently resolve I2C addressing conflicts in your project!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/\" \/>\n<meta property=\"og:site_name\" content=\"Latest News from Seeed Studio\" \/>\n<meta property=\"article:published_time\" content=\"2021-03-15T08:27:17+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-03-15T08:27:20+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png\" \/>\n\t<meta property=\"og:image:width\" content=\"3000\" \/>\n\t<meta property=\"og:image:height\" content=\"1750\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Jonathan Tan\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jonathan Tan\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/\",\"url\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/\",\"name\":\"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer - Latest News from Seeed Studio\",\"isPartOf\":{\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png\",\"datePublished\":\"2021-03-15T08:27:17+00:00\",\"dateModified\":\"2021-03-15T08:27:20+00:00\",\"author\":{\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/#\/schema\/person\/61e29862da8741ee517eacd92f4cd094\"},\"description\":\"I2C features the best of both SPI and UART protocols. Learn about how an I2C multiplexer can conveniently resolve I2C addressing conflicts in your project!\",\"breadcrumb\":{\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#primaryimage\",\"url\":\"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png\",\"contentUrl\":\"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png\",\"width\":3000,\"height\":1750},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.seeedstudio.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/#website\",\"url\":\"https:\/\/www.seeedstudio.com\/blog\/\",\"name\":\"Latest News from Seeed Studio\",\"description\":\"Emerging IoT, AI and Autonomous Applications on the Edge\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.seeedstudio.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/#\/schema\/person\/61e29862da8741ee517eacd92f4cd094\",\"name\":\"Jonathan Tan\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.seeedstudio.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/d8dd1a4a7882386e8818e110c9322897?s=96&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/d8dd1a4a7882386e8818e110c9322897?s=96&r=g\",\"caption\":\"Jonathan Tan\"},\"url\":\"https:\/\/www.seeedstudio.com\/blog\/author\/jonathan-tan\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer - Latest News from Seeed Studio","description":"I2C features the best of both SPI and UART protocols. Learn about how an I2C multiplexer can conveniently resolve I2C addressing conflicts in your project!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/","og_locale":"en_US","og_type":"article","og_title":"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer - Latest News from Seeed Studio","og_description":"I2C features the best of both SPI and UART protocols. Learn about how an I2C multiplexer can conveniently resolve I2C addressing conflicts in your project!","og_url":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/","og_site_name":"Latest News from Seeed Studio","article_published_time":"2021-03-15T08:27:17+00:00","article_modified_time":"2021-03-15T08:27:20+00:00","og_image":[{"width":3000,"height":1750,"url":"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png","type":"image\/png"}],"author":"Jonathan Tan","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Jonathan Tan","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/","url":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/","name":"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer - Latest News from Seeed Studio","isPartOf":{"@id":"https:\/\/www.seeedstudio.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#primaryimage"},"image":{"@id":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#primaryimage"},"thumbnailUrl":"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png","datePublished":"2021-03-15T08:27:17+00:00","dateModified":"2021-03-15T08:27:20+00:00","author":{"@id":"https:\/\/www.seeedstudio.com\/blog\/#\/schema\/person\/61e29862da8741ee517eacd92f4cd094"},"description":"I2C features the best of both SPI and UART protocols. Learn about how an I2C multiplexer can conveniently resolve I2C addressing conflicts in your project!","breadcrumb":{"@id":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#primaryimage","url":"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png","contentUrl":"https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png","width":3000,"height":1750},{"@type":"BreadcrumbList","@id":"https:\/\/www.seeedstudio.com\/blog\/2021\/03\/15\/how-to-connect-multiple-i2c-sensors-with-the-tca9548a-i2c-multiplexer\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.seeedstudio.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Connect Multiple I2C Sensors with the TCA9548A I2C Multiplexer"}]},{"@type":"WebSite","@id":"https:\/\/www.seeedstudio.com\/blog\/#website","url":"https:\/\/www.seeedstudio.com\/blog\/","name":"Latest News from Seeed Studio","description":"Emerging IoT, AI and Autonomous Applications on the Edge","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.seeedstudio.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.seeedstudio.com\/blog\/#\/schema\/person\/61e29862da8741ee517eacd92f4cd094","name":"Jonathan Tan","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.seeedstudio.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/d8dd1a4a7882386e8818e110c9322897?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d8dd1a4a7882386e8818e110c9322897?s=96&r=g","caption":"Jonathan Tan"},"url":"https:\/\/www.seeedstudio.com\/blog\/author\/jonathan-tan\/"}]}},"modified_by":"Jonathan Tan","views":19773,"featured_image_urls":{"full":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png",3000,1750,false],"thumbnail":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-80x80.png",80,80,true],"medium":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-300x175.png",300,175,true],"medium_large":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-768x448.png",640,373,true],"large":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-1030x601.png",640,373,true],"1536x1536":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-1536x896.png",1536,896,true],"2048x2048":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-2048x1195.png",2048,1195,true],"visody_icon":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1.png",32,19,false],"magazine-7-slider-full":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-1536x1020.png",1536,1020,true],"magazine-7-slider-center":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-936x897.png",936,897,true],"magazine-7-featured":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-1024x597.png",1024,597,true],"magazine-7-medium":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-720x380.png",720,380,true],"magazine-7-medium-square":["https:\/\/www.seeedstudio.com\/blog\/wp-content\/uploads\/2021\/03\/Week-8-8-1-675x450.png",675,450,true]},"author_info":{"display_name":"Jonathan Tan","author_link":"https:\/\/www.seeedstudio.com\/blog\/author\/jonathan-tan\/"},"category_info":"<a href=\"https:\/\/www.seeedstudio.com\/blog\/category\/news\/\" rel=\"category tag\">News<\/a>","tag_info":"News","comment_count":"0","_links":{"self":[{"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/posts\/41281","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/users\/3537"}],"replies":[{"embeddable":true,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/comments?post=41281"}],"version-history":[{"count":16,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/posts\/41281\/revisions"}],"predecessor-version":[{"id":41374,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/posts\/41281\/revisions\/41374"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/media\/41373"}],"wp:attachment":[{"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/media?parent=41281"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/categories?post=41281"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.seeedstudio.com\/blog\/wp-json\/wp\/v2\/tags?post=41281"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}