Difference between revisions of "MCP23017"

From Let's Control It
Jump to navigation Jump to search
Line 1: Line 1:
 
----
 
----
[[Bestand:MCP23017DIP28.jpg|320px]]
+
[[File:MCP23017DIP28.jpg|320px]]
 
----
 
----
= Introductie =
+
= Introduction =
Het aantal outputs van een ESP-01 kan eenvoudig worden uitgebreid middels een IO Expander. We gebruiken hier de MCP23017 die 16 extra outputs geeft. Zo kun je b.v. een 16 kanaals relaisbord aansturen.
+
The number of GPIO pins on the ESP module can be expanded with a IO Expander. We will use the MCP23017 that provides 16 more outputs. This way it becomes possible to control a 16 channel relay board.
  
 
= Hardware =
 
= Hardware =
De MCP23017 moet worden aangesloten via I2C. Deze chip werkt op 3V3 volt dus kan direct op de ESP worden aangesloten.
+
The MCP23017 needs to be connected through the I2C interface. This chip is compatible with 3V3 and it can be connected to the ESP without levelshifters..
  
== Aansluitingen ==
+
== Connections ==
  
 
   MCP23017 ESP-01
 
   MCP23017 ESP-01
Line 17: Line 17:
  
 
= Software =
 
= Software =
 +
 
== ESP Easy ==
 
== ESP Easy ==
  
 
== ESP Connextio ==
 
== ESP Connextio ==
Het commando is:
+
Command:
 
  ''<nowiki>MCPWiredOut <pin nr>,<On/Off></nowiki>''
 
  ''<nowiki>MCPWiredOut <pin nr>,<On/Off></nowiki>''
  
Line 40: Line 41:
 
|}
 
|}
  
=== Voorbeeld ===
+
=== Sample ===
 
  MCPWiredOut 1,On
 
  MCPWiredOut 1,On

Revision as of 20:04, 24 August 2015


MCP23017DIP28.jpg


Introduction

The number of GPIO pins on the ESP module can be expanded with a IO Expander. We will use the MCP23017 that provides 16 more outputs. This way it becomes possible to control a 16 channel relay board.

Hardware

The MCP23017 needs to be connected through the I2C interface. This chip is compatible with 3V3 and it can be connected to the ESP without levelshifters..

Connections

 MCP23017 	ESP-01
 GND 	 	GND
 VCC    	VCC
 SDA		GPIO 0
 SCL		GPIO 2

Software

ESP Easy

ESP Connextio

Command:

MCPWiredOut <pin nr>,<On/Off>
Parameter: Beschrijving: Bereik: Opmerking:
Pin nr Output pin 1 t/m 16
On/Off Aan of Uit On/Off

Sample

MCPWiredOut 1,On