Skip to content

Commit caf72a1

Browse files
author
Priyanka Tamhankar
committed
MCU8_TEJ-960 M8BTL-2809 applied suggested chnages to ReadMe.md
1 parent 0fb78ab commit caf72a1

File tree

1 file changed

+69
-67
lines changed

1 file changed

+69
-67
lines changed

README.md

Lines changed: 69 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -2,144 +2,145 @@
22

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

5-
# Getting Started with the 8-Bit MDFU Client for PIC18F56Q24 (MPLAB X)
5+
# Getting Started With the 8-bit MDFU Client for PIC18F56Q24 Using MPLAB® X
66

7-
This repository provides the MPLAB® X projects needed to configure some basic MDFU bootloader solutions for the PIC18F56Q24 Curiosity Nano Evaluation Board using code generated from the MPLAB® Code Configurator (MCC).
7+
This is an example on how to use the MPLAB Code Configurator (MCC) generated code for configuring some basic Microchip Device Firmware Update (MDFU) bootloader solutions for the PIC18F56Q24 Curiosity Nano Evaluation Board.
88

99
The Microchip Device Firmware Update (MDFU) is a device firmware update ecosystem that uses a device agnostic host application to update the application firmware. The application image that is loaded into the host follows a custom file format that includes the device and application-specific parameters needed to perform the update. This repository provides the basic starting point to configure and customize the MCC Melody 8-Bit MDFU Client library on the PIC18F56Q24 Curiosity Nano development board and also provides instructions for running the examples.
1010

1111
---
1212
## Related Documentation
1313

14-
- [PIC18F56Q24 Family Product Page](https://www.microchip.com/en-us/product/PIC18F56Q24)
15-
- [8-Bit MDFU Client Getting Started](https://onlinedocs.microchip.com/oxy/GUID-67539092-2179-43C1-8600-118A85E49693-en-US-2/index.html)
16-
- [8-Bit MDFU Client v1.0.0-beta.1 Release Note](https://onlinedocs.microchip.com/oxy/GUID-9CE46BA1-9CDF-4B9C-9C73-4793B27ED320-en-US-2/index.html)
17-
- [8-Bit MDFU Client v1.0.0-beta.1 API Documentation](https://onlinedocs.microchip.com/oxy/GUID-01EC9542-92FF-436D-91FB-7CBEEE66D701-en-US-2/index.html)
14+
[PIC18F56Q24 Family Product Page](https://www.microchip.com/en-us/product/PIC18F56Q24) <br>
15+
[8-Bit MDFU Client Getting Started](https://onlinedocs.microchip.com/oxy/GUID-67539092-2179-43C1-8600-118A85E49693-en-US-2/index.html) <br>
16+
[8-Bit MDFU Client v1.0.0-beta.1 Release Note](https://onlinedocs.microchip.com/oxy/GUID-9CE46BA1-9CDF-4B9C-9C73-4793B27ED320-en-US-2/index.html) <br>
17+
[8-Bit MDFU Client v1.0.0-beta.1 API Documentation](https://onlinedocs.microchip.com/oxy/GUID-01EC9542-92FF-436D-91FB-7CBEEE66D701-en-US-2/index.html) <br>
1818

1919
---
2020
## Software Used
2121

22-
- MPLAB® X IDE 6.15.0 [(MPLAB® X IDE 6.15)](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=pic16f18446-cnano-8bit-mdfu-client-mplab-mcc-github)
23-
- MPLAB® XC8 2.45.0 [(MPLAB® XC8 2.45)](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=pic16f18446-cnano-8bit-mdfu-client-mplab-mcc-github)
24-
- MPLAB® Code Configurator (MCC) 5.4.1 [(microchip.com/mplab/mplab-code-configurator)](https://www.microchip.com/mplab/mplab-code-configurator)
25-
- 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)
26-
- Python 3.8 or later [(Python)](https://www.python.org/downloads/)
27-
- pyfwimagebuilder v1.0.1.14 [(pyfwimagebuilder)](https://pypi.org/project/pyfwimagebuilder/)
28-
- pymdfu v1.0.1.5 [(pymdfu)](https://pypi.org/project/pymdfu/)
22+
MPLAB® X IDE 6.15.0 [(MPLAB® X IDE 6.15)](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=pic16f18446-cnano-8bit-mdfu-client-mplab-mcc-github)<br>
23+
MPLAB® XC8 2.45.0 [(MPLAB® XC8 2.45)](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=pic16f18446-cnano-8bit-mdfu-client-mplab-mcc-github)<br>
24+
MPLAB® Code Configurator (MCC) 5.4.1 [(microchip.com/mplab/mplab-code-configurator)](https://www.microchip.com/mplab/mplab-code-configurator)<br>
25+
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)<br>
26+
Python 3.8 or later [(Python)](https://www.python.org/downloads/)<br>
27+
pyfwimagebuilder v1.0.1.14 [(pyfwimagebuilder)](https://pypi.org/project/pyfwimagebuilder/)<br>
28+
pymdfu v1.0.1.5 [(pymdfu)](https://pypi.org/project/pymdfu/)<br>
2929

3030
---
3131
## Hardware Used
3232

3333
- PIC18F56Q24 Curiosity Nano [(EV01E86A)](https://www.microchip.com/en-us/development-tool/ev01e86a)
3434

35-
[![PIC18F56Q24_CNano](images\230928-mcu8-photo-ev01e86a-front-transparent.png)](images\230928-mcu8-photo-ev01e86a-front-transparent.png)
35+
[![PIC18F56Q24_CNano](images\230928-mcu8-photo-ev01e86a-front-transparent.PNG)](images\230928-mcu8-photo-ev01e86a-front-transparent.PNG)
3636

3737
---
3838
## Setup
3939

40-
The following project setup steps have been followed for each example project pair. If something goes wrong in running these examples, validate that the settings in your project are consistent with the options seen in this section.
40+
The following project setup is the same for all the example project pairs. If something goes wrong while running these examples, confirm that the settings in the projects are consistent with the options seen in this section.
4141

4242
### Client Setup
4343
[![mdfu-builder](images\ProjectConfigurationOverview.PNG)](images\ProjectConfigurationOverview.PNG)
4444

4545
**Configuration Bits**
46-
- External Oscillator Selection bits: **Oscillator not enabled**
47-
- Reset Oscillator Selection bits: **HFINTOSC with HFFRQ = 64MHz and CDIV = 1:1 **
46+
- External Oscillator Selection bits: Oscillator not enabled
47+
- Reset Oscillator Selection bits: HFINTOSC with HFFRQ = 64 MHz and CDIV = 1:1
4848

4949
[![CFG](images\ConfigBitsSetup.PNG)](images\ConfigBitsSetup.PNG)
5050

5151
**Clock Control**
52-
- Clock Source: **HFINTOSC**
53-
- HF Internal Clock: **8_MHz**
54-
- Clock Divider: **1**
52+
- Clock Source: HFINTOSC
53+
- HF Internal Clock: 8_MHz
54+
- Clock Divider: 1
5555

5656
[![CLK](images\ClockSetup.PNG)](images\ClockSetup.PNG)
5757

5858
**NVM**
59-
- Generate Flash APIs: **Enabled**
60-
- Generate EEPROM APIs: **Enabled**
61-
- Generate Device ID APIs: **Enabled**
59+
- Generate Flash APIs: Enabled
60+
- Generate EEPROM APIs: Enabled
61+
- Generate Device ID APIs: Enabled
6262

6363
[![NVM](images\NVMSetup.PNG)](images\NVMSetup.PNG)
6464

6565
**UART**
66-
- Custom Name: **UART2**
67-
- Requested Baudrate: **9600**
68-
- Calculated Baudrate: **9615**
69-
- Baud Rate Error (%): **0.16**
70-
- Parity: **None**
71-
- Data Size: **8**
72-
- Stop Bits: **1**
73-
- Flow Control Mode: **None**
74-
- Redirect Printf to UART: **Disabled**
75-
- Interrupt Driven: **Disabled**
66+
- Custom Name: UART2
67+
- Requested Baudrate: 9600
68+
- Calculated Baudrate: 9615
69+
- Baud Rate Error (%): 0.16
70+
- Parity: None
71+
- Data Size: 8
72+
- Stop Bits: 1
73+
- Flow Control Mode: None
74+
- Redirect Printf to UART: Disabled
75+
- Interrupt Driven: Disabled
7676

7777
[![UART](images\UARTDriverSetup.PNG)](images\UARTDriverSetup.PNG)
7878

7979
**UART PLIB**
80-
- Actual Baud Rate: **9615.385**
81-
- Enable Receive: **Enabled**
82-
- Receive/Transmit Polarity: **Non-Inverted**
83-
- Enable UART: **Enabled**
84-
- Enable Transmit: **Enabled**
80+
- Actual Baud Rate: 9615.385
81+
- Enable Receive: Enabled
82+
- Receive/Transmit Polarity: Non-Inverted
83+
- Enable UART: Enable
84+
- Enable Transmit: Enabled
8585

8686
[![UART_PLIB](images\UARTPLIBSetup.PNG)](images\UARTPLIBSetup.PNG)
8787

8888
**UART Pins**
89-
- UART TX: **RB5**
90-
- UART RX: **RB4**
89+
- UART TX: RB5
90+
- UART RX: RB4
9191

9292
[![UART_Pins](images\UARTPortsSetup.PNG)](images\UARTPortsSetup.PNG)
9393

9494
**8-Bit MDFU Client**
95-
- Communication Protocol: **UART**
96-
- Application Start Address: **Different for each project based on the verification selected**
97-
- Device ID: **0x7920**
98-
- I/O Pin Indicator: **Enabled**
99-
- I/O Pin Entry: **Enabled**
100-
- Memory Verification: **Assigned Based on Example Project Naming Convention**
95+
- Communication Protocol: UART
96+
- Application Start Address: Different for each project based on the verification selected
97+
- Device ID: 0x7920
98+
- I/O Pin Indicator: Enabled
99+
- I/O Pin Entry: Enabled
100+
- Memory Verification: Assigned Based on Example Project Naming Convention
101101

102102
*Example for CRC32 Verification*
103103

104104
[![MDFU](images\MDFUClientSetup.PNG)](images\MDFUClientSetup.PNG)
105105

106106
**8-Bit MDFU Client I/O**
107-
- BOOT INDICATE: **RF2**
108-
- BOOT ENTRY: **RF3**
107+
- BOOT INDICATE: RF2
108+
- BOOT ENTRY: RF3
109109

110110
[![IO-Pins](images\IOPortSetup.PNG)](images\IOPortSetup.PNG)
111-
- BOOT INDICATE: **Start High**
112-
- BOOT ENTRY: **Weak Pullup**
111+
- BOOT INDICATE: Start High
112+
- BOOT ENTRY: Weak Pullup
113113

114114
[![IO-Settings](images\IOPinsSetup.PNG)](images\IOPinsSetup.PNG)
115115

116116
**8-Bit MDFU Client Project Properties**
117-
- ROM Ranges: **This option is configured based on the start address of the application.**
118-
- For example, if the application starts at 0x2000 then this value will reflect as `0-1FFF`.
117+
- ROM Ranges: This option is configured based on the start address of the application
118+
- For example, if the application starts at 0x2000 then this value will reflect as `0-1FFF`
119119

120120
[![IO-Settings](images\MemoryModelSettings.PNG)](images\MemoryModelSettings.PNG)
121121

122122
---
123123
### Application Setup
124124
[![app-builder](images\AppConfigurationOverview.PNG)](images\AppConfigurationOverview.PNG)
125125

126-
**IO Pins**
127-
- GPIO Output: **RF2**
126+
**I/O Pins**
127+
- GPIO Output: RF2
128128

129129
[![app_io](images\AppPortSetup.PNG)](images\AppPortSetup.PNG)
130-
- Custom Name: **LED**
130+
- Custom Name: LED
131131

132132
[![app_io_settings](images\LEDSetup.PNG)](images\LEDSetup.PNG)
133133

134134
**Project Properties**
135135

136136
Linker Additional Options
137-
- Codeoffset: **0x<APP_START> = 0x2000**
138-
- Checksum: **Dependant on the verification scheme**
139-
*Check the table below to understand how the CRC32 option must be configured in the application projects*
137+
- Codeoffset: 0x<APP_START> = 0x2000
138+
- Checksum: Dependant on the verification scheme
140139

141140
[![app_offset](images\AppOffset.PNG)](images\AppOffset.PNG)
142141

142+
Note:*Check the table below to understand how the CRC32 option must be configured in the application projects*
143+
143144
|Verification Scheme | Checksum Setting |
144145
|---- |---- |
145146
|Reset Vector | N/A |
@@ -149,16 +150,16 @@ Linker Additional Options
149150
|CRC-32 | C00-3FFB@3FFC,width=-4,algorithm=-5,offset=FFFFFFFF,polynomial=04C11DB7,code=3F |
150151

151152
Fill Flash Memory
152-
- Which area to fill: **Provide Range to fill**
153-
- How to fill it: **Constant or incremental value**
154-
- Sequence: **0xFFFF**
155-
- Increment/Decrement: **No Incrementing**
156-
- Memory address range: **0x<APP_START>:0x<FLASH_END> = 0x2000:0xFFFF**
153+
- Which area to fill: Provide Range to fill
154+
- How to fill it: Constant or incremental value
155+
- Sequence: 0xFFFF
156+
- Increment/Decrement: No Incrementing
157+
- Memory address range: 0x<APP_START>:0x<FLASH_END> = 0x2000:0xFFFF
157158

158159
[![app_fill](images\AppFill.PNG)](images\AppFill.PNG)
159160

160161
## Operation
161-
In this section, we will walkthrough how to run the examples that are housed in this repository. For this example walkthrough we will execute the CRC32 verification example and update the device flash memory with the crc32 application image to demonstrate a successful device firmware update (DFU).
162+
In this section, we will walkthrough how to run the examples in this repository. This example shows how to execute the CRC32 verification example and update the device flash memory with the CRC32 application image to demonstrate a successful device firmware update (DFU).
162163

163164
**8-Bit MDFU Client Operation**
164165

@@ -178,9 +179,10 @@ In this section, we will walkthrough how to run the examples that are housed in
178179

179180
[![ProgramMDFU](images\ProgramMDFU.PNG)](images\ProgramMDFU.PNG)
180181

181-
**Bootloader Operation after initial programming**
182+
**Bootloader Operation After Initial Programming**
183+
184+
After the initial programming, the LED must be on.
182185

183-
After initial programming, the LED should be held on.
184186
[![MDFU_BootMode](images\PIC18F56Q24_BootMode.png)](images\PIC18F56Q24_BootMode.png)
185187

186188
**Application Operation**
@@ -198,7 +200,7 @@ Right click, then select Clean and Build
198200

199201
[![CleanBuild_App](images\CleanAndBuildApp.png)](images\CleanAndBuildApp.png)
200202

201-
4. Build the Application Image File using **pyfwimagebuilder**
203+
4. Build the Application Image File using **pyfwimagebuilder**.
202204

203205
*Hint: The configuration TOML file is generated by the MDFU Client project*
204206

0 commit comments

Comments
 (0)