Skip to content

Commit ca430f3

Browse files
Usha GUsha G
authored andcommitted
MPAE-13691 Adding read me file
1 parent 12a7709 commit ca430f3

File tree

1 file changed

+35
-26
lines changed

1 file changed

+35
-26
lines changed

README.md

Lines changed: 35 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -2,44 +2,53 @@
22

33
[![MCHP](images/microchip.png)](https://www.microchip.com)
44

5-
# Update the title for pic16f15244-uart-i2c-bridge-i2c-client2-mplab-mcc here
5+
# UART-I2C Bridge Implementation: I2C Client(Client#2) Implementation using PIC16F15244 Microcoontroller
66

7-
<!-- This is where the introduction to the example goes, including mentioning the peripherals used -->
7+
In this code example, PIC16F15244 MCU acts as I2C client 2 device and processes periodically acquired sensor data and send data to the host device through I2C interface.Compatible PIC16F152xx family of MCUs are:PIC16F15214,PIC16F15223,PIC16F15254,PIC16F15276.
8+
9+
Refer GitHub code example [UART-I2C Bridge and I2C Host Implementation using PIC16F15244 Microcontroller](https://github.com/microchip-pic-avr-examples/pic16f15244-uart-i2c-bridge-and-i2c-host-mplab-mcc) and [UART-I2C Bridge Implementation: I2C Client(Client#1) Implementation using PIC16F15244 Microcontroller](https://github.com/microchip-pic-avr-examples/pic16f15244-uart-i2c-bridge-i2c-client1-mplab-mcc) for more details about the implementation and application.
810

911
## Related Documentation
1012

11-
<!-- Any information about an application note or tech brief can be linked here. Use unbreakable links!
12-
In addition a link to the device family landing page and relevant peripheral pages as well:
13-
- [AN3381 - Brushless DC Fan Speed Control Using Temperature Input and Tachometer Feedback](https://microchip.com/00003381/)
14-
- [PIC18F-Q10 Family Product Page](https://www.microchip.com/design-centers/8-bit/pic-mcus/device-selection/pic18f-q10-product-family) -->
13+
- [PIC16F15244 Product Family Page](https://www.microchip.com/en-us/products/microcontrollers-and-microprocessors/8-bit-mcus/pic-mcus/pic16f15244)
14+
- [PIC16F15244 Code Examples on GitHub](https://github.com/microchip-pic-avr-examples?q=pic16f15244&type=&language=&sort=)
15+
- [PIC16F15244 MCU Family Video](https://www.youtube.com/watch?v=nHLv3Th-o-s)
16+
- [PIC16F15244 MCU Product Page](https://www.microchip.com/en-us/product/PIC16F15244)
17+
- [Technical Brief - Using the MSSP in I2C Master mode](https://www.microchip.com/wwwappnotes/appnotes.aspx?appnote=en1001796)
18+
- [Technical Brief – Using the MSSP in I2C Slave mode](https://www.microchip.com/wwwappnotes/appnotes.aspx?appnote=en1001796)
19+
- [Application Note – AN3538 A Simple Water Monitoring System with I2C Communication](https://ww1.microchip.com/downloads/en/Appnotes/A-Simple-Water-Monitoring-System-with%20I2C-Communication-DS00003538A.pdf)
1520

16-
## Software Used
21+
## Description
1722

18-
<!-- All software used in this example must be listed here. Use unbreakable links!
19-
- MPLAB® X IDE 5.30 or newer [(microchip.com/mplab/mplab-x-ide)](http://www.microchip.com/mplab/mplab-x-ide)
20-
- MPLAB® XC8 2.10 or a newer compiler [(microchip.com/mplab/compilers)](http://www.microchip.com/mplab/compilers)
21-
- MPLAB® Code Configurator (MCC) 3.95.0 or newer [(microchip.com/mplab/mplab-code-configurator)](https://www.microchip.com/mplab/mplab-code-configurator)
22-
- MPLAB® Code Configurator (MCC) Device Libraries PIC10 / PIC12 / PIC16 / PIC18 MCUs [(microchip.com/mplab/mplab-code-configurator)](https://www.microchip.com/mplab/mplab-code-configurator)
23-
- Microchip PIC18F-Q Series Device Support (1.4.109) or newer [(packs.download.microchip.com/)](https://packs.download.microchip.com/) -->
23+
In this code example, the PIC16F15244 microcontroller communicate with Data Visualizer terminal window application, running on a PC, through USART interface and receive user inputs/commands. Based on the commands received from the user, the PIC16F15244 microcontroller communicates with the I2C client devices and collect the required sensors data and, transmit to PC for displaying it on the terminal window. This way, the PIC16F15244 microcontroller acts as a EUART-I2C bridge to communicate with Data Visualizer terminal window application and acts as a I2C host device to communicate with the I2C client devices.
2424

25-
- MPLAB® X IDE 6.0.0 or newer [(MPLAB® X IDE 6.0)](https://www.microchip.com/en-us/development-tools-tools-and-software/mplab-x-ide?utm_source=GitHub&utm_medium=TextLink&utm_campaign=MCU8_MMTCha_MPAE_Examples&utm_content=pic16f15244-uart-i2c-bridge-i2c-client2-mplab-mcc-github)
26-
- MPLAB® XC8 2.36.0 or newer compiler [(MPLAB® XC8 2.36)](https://www.microchip.com/en-us/development-tools-tools-and-software/mplab-xc-compilers?utm_source=GitHub&utm_medium=TextLink&utm_campaign=MCU8_MMTCha_MPAE_Examples&utm_content=pic16f15244-uart-i2c-bridge-i2c-client2-mplab-mcc-github)
25+
The code example uses two I2C clients, named as client 1 and client 2 and, they are based on PIC16F15244 microcontroller. Below Figure 1 shows the block diagram view of the application.
2726

28-
## Hardware Used
27+
<p align="center">
28+
<img width=auto height=auto src="images/block diagram.png">
29+
<br>Figure 1 : Block diagram view of the application<br>
30+
</p>
2931

30-
<!-- All hardware used in this example must be listed here. Use unbreakable links!
31-
- PIC18F47Q10 Curiosity Nano [(DM182029)](https://www.microchip.com/Developmenttools/ProductDetails/DM182029)
32-
- Curiosity Nano Base for Click boards™ [(AC164162)](https://www.microchip.com/Developmenttools/ProductDetails/AC164162)
33-
- POT Click board™ [(MIKROE-3402)](https://www.mikroe.com/pot-click) -->
32+
For the purpose of demonstration, pH sensor is interfaced to client 1 and, temperature and capacitive soil moisture sensors are interfaced to client 2. Both the clients periodically collect data from the sensors, process the acquired data and keep the data ready to transmit to Host device over I2C interface.
3433

35-
## Setup
34+
The input commands and clients I2C address information has been displayed on the terminal window of data visualizer. The user needs to enter a client device address from where the sensor data needs to be collected. If the entered client device address is correct, then the next input command, asking the user to enter sensor information from where data needs to be collected, is displayed on the terminal window. After entering the correct sensor information, the host device establishes I2C communication with the respective client device and requests to send the processed sensor data. The client device responds back to host request with the processed sensor data. Upon receiving the sensor data, the host device transmits data to data visualizer tool through UART interface, for displaying it on the terminal window. If the user entered client address or sensor input command is incorrect, then terminal window display the supplied client address or sensor information is incorrect and requests the user to re-enter details.
3635

37-
<!-- Explain how to connect hardware and set up software. Depending on complexity, step-by-step instructions and/or tables and/or images can be used -->
36+
## Software Used
37+
38+
- [MPLAB® X IDE 5.50 or newer](http://www.microchip.com/mplab/mplab-x-ide)
39+
- [MPLAB® XC8 2.20 or a newer compiler](http://www.microchip.com/mplab/compilers)
40+
- [MPLAB® Code Configurator (MCC) v5.0.3 or newer](https://www.microchip.com/mplab/mplab-code-configurator)
41+
- [MPLAB® Code Configurator (MCC) Device Libraries PIC10 / PIC12 / PIC16 / PIC18 MCU](https://www.microchip.com/mplab/mplab-code-configurator)
42+
- [Microchip PIC16F1xxxx Series Device Support (v1.8.149) or newer](https://packs.download.microchip.com/)
3843

39-
## Operation
44+
## Hardware Used
4045

41-
<!-- Explain how to operate the example. Depending on complexity, step-by-step instructions and/or tables and/or images can be used -->
46+
- Curiosity Nano Base for Click boards™[AC164162](https://www.microchip.com/en-us/development-tool/AC164162)
47+
- PIC16F15244 Curiosity Nano Evaluation Kit [EV09Z19A](https://www.microchip.com/en-us/development-tool/EV09Z19A)
48+
- SHT AN Click [MIKROE-3984](https://www.mikroe.com/sht-an-click)
49+
- PH Sensor [EC-4743](https://www.electronicscomp.com/analog-ph-sensor-kit-for-arduino?gclid=EAIaIQobChMIhfv3t-q58QIVu4NLBR2VKQGWEAYYAyABEgKhdPD_BwE)
50+
- Capacitive Soil Moisture Sensor V2.0 [EC-5092](https://www.electronicscomp.com/capacitive-soil-moisture-sensor-v2?gclid=EAIaIQobChMI3YCgheq58QIVxZVLBR1PZQKPEAQYAiABEgJW9_D_BwE)
4251

43-
## Summary
52+
## Demo Operation
4453

45-
<!-- Summarize what the example has shown -->
54+
To know about the demo operation, refer GitHub code example [UART-I2C Bridge and I2C Host Implementation using PIC16F15244 Microcontroller](https://github.com/microchip-pic-avr-examples/pic16f15244-uart-i2c-bridge-and-i2c-host-mplab-mcc)

0 commit comments

Comments
 (0)