Skip to content

Commit aba730f

Browse files
committed
MPAE-19444 updated versions, I2C Host Ex v1.0.0, etc
1 parent 31f2333 commit aba730f

File tree

9 files changed

+66
-65
lines changed

9 files changed

+66
-65
lines changed

README.md

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ The [I<sup>2</sup>C Proximity Sensor example](https://onlinedocs.microchip.com/v
1818

1919
This example demonstrates how to read the value of the VCNL4200 proximity sensor on the Curiosity Nano Explorer, with the Data Streamer Visualization Output selected. Every 100 ms, an LED and a Debug I/O pin are toggled, after a 100 ms delay.
2020

21-
In the MCC Melody Data Streamer library configruation, the appropriately typed variables are added to the Data Streamer table.
21+
In the MCC Melody Data Streamer library configuration, the appropriately typed variables are added to the Data Streamer table.
2222

2323
![alt text](images/pic18f57q43-i2c-proximity-sensor-polled-datastreamerTable_uartPins.png)
2424

2525

26-
The below image of the MPLAB Data Visualizer shows the application running, where the variable configured in the Data Streamer Table have been imported as a Variable Streamer in the [MPLAB® Data Visualizer](https://www.microchip.com/en-us/tools-resources/debug/mplab-data-visualizer "MPLAB® Data Visualizer"), via a generated .ds (data streamer file).
26+
The below image of the MPLAB Data Visualizer shows the application running, where the variable configured in the Data Streamer Table have been imported as a Variable Streamer in the [MPLAB® Data Visualizer](https://www.microchip.com/en-us/tools-resources/debug/mplab-data-visualizer "MPLAB® Data Visualizer"), via a generated `.ds` (data streamer file).
2727
![alt text](images/pic18f57q43-i2c-proximity-sensor-dataStreamer.png)
2828

2929
The following is a block diagram view of the application, as seen in the [MCC Melody Builder](https://onlinedocs.microchip.com/v2/keyword-lookup?keyword=MCC.MELODY.BUILDER&version=latest&redirect=true "MCC Melody Builder").
@@ -37,23 +37,24 @@ Example Components are a tight integration of learning material directly into MC
3737
## Related Documentation
3838

3939
- [MCC Melody I<sup>2</sup>C Example Component (for the Curiosity Nano Explorer)](https://onlinedocs.microchip.com/v2/keyword-lookup?keyword=I2C.HOST.EXAMPLE.COMPONENT&version=latest&redirect=true "MCC Melody I<sup>2</sup>C Example Component for the Curiosity Nano Explorer")
40-
- [MCC Melody Design Patterns for Control Flow](https://onlinedocs.microchip.com/v2/keyword-lookup?keyword=I2C.HOST.EXAMPLE.COMPONENT&version=latest&redirect=true "MCC Melody I<sup>2</sup>C Example Component for the Curiosity Nano Explorer")
40+
- [MCC Melody Design Patterns for Control Flow](https://onlinedocs.microchip.com/g/GUID-7CE1AEE9-2487-4E7B-B26B-93A577BA154E "MCC Melody Design Patterns for Control Flow")
4141

4242
- [Curiosity Nano Explorer User Guide](https://ww1.microchip.com/downloads/aemDocuments/documents/MCU08/ProductDocuments/UserGuides/PIC18F57Q43-Curiosity-Nano-HW-UserGuide-DS40002186B.pdf "Curiosity Nano Explorer Users Guide")
4343

4444
- [PIC18F57Q43 Data Sheet](https://ww1.microchip.com/downloads/aemDocuments/documents/MCU08/ProductDocuments/DataSheets/PIC18F27-47-57Q43-Data-Sheet-40002147F.pdf "PIC18F57Q43 Data Sheet")
4545

4646
## Software Used
47-
- MPLAB® X IDE 6.25.0 or newer [(MPLAB® X IDE 6.25.0)](https://www.microchip.com/en-us/development-tools-tools-and-software/mplab-x-ide)
48-
- MPLAB® XC8 3.00.0 or newer [(MPLAB® XC8 3.00.0)](https://www.microchip.com/en-us/tools-resources/develop/mplab-xc-compilers/xc8)
47+
- [MPLAB® X IDE](https://www.microchip.com/en-us/development-tools-tools-and-software/mplab-x-ide) 6.25.0 or newer
48+
- [MPLAB® XC8](https://www.microchip.com/en-us/tools-resources/develop/mplab-xc-compilers/xc8) 3.00.0 or newer
4949

50-
- MPLAB® Code Configurator (MCC) Plug-in Version 5.6 or newer (*Tools>Plugins>Installed*, search: "MCC")
51-
- MPLAB Data Visualizer Plug-in Version 1.4.1926 or newer (*Tools>Plugins>Installed*, search: "Data Visualizer")
50+
- [MPLAB® Code Configurator](https://www.microchip.com/en-us/tools-resources/configure/mplab-code-configurator) (MCC) Plug-in Version 5.6.2 or newer (*Tools>Plugins>Installed*, search: "MCC")
51+
- [MPLAB Data Visualizer](https://www.microchip.com/en-us/tools-resources/debug/mplab-data-visualizer) Plug-in Version 1.4.1926 or newer (*Tools>Plugins>Installed*, search: "Data Visualizer")
5252
- MCC Melody I2C_Host Example Component for the Curiosity Nano Explorer 1.0.0 or newer
53-
- MCC Core 5.8.0 or newer
54-
- MCC Melody Core 2.9.0 or newer
53+
- MCC Core 5.8.2 or newer
54+
- SPA Host 1.0.0 or newer
55+
- MCC Melody Core 2.9.1 or newer
5556

56-
Open the MCC Content Manager to verify the MCC Core and MCC Melody Core versions.
57+
Open the MCC Content Manager ![CM_icon](images/Icon-MPLAB-CM24.png) to verify the MCC Core and MCC Melody Core versions.
5758

5859
![alt text](images/MCC_Core_ContentLibrary_Versions_SPA.png)
5960

-163 Bytes
Loading

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,4 +116,4 @@ int main(void)
116116
IO_LED_Toggle();
117117
IO_Debug_Toggle();
118118
}
119-
}
119+
}

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/mcc-manifest-autosave.yml

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,31 @@
22

33
manifest_file_version: 1.0.0
44
project: pic18f57q43-i2c-proximity-sensor-polled-data-streamer
5-
creation_date: 2025-05-05T12:23:32.412+02:00[Europe/Berlin]
5+
creation_date: 2025-06-17T10:53:23.876+02:00[Europe/Berlin]
66
operating_system: Windows 11
77
mcc_mode: IDE
88
mcc_mode_version: v6.25
99
device_name: PIC18F57Q43
1010
compiler: XC8 3.00
11-
mcc_version: 5.6.0-rc.f
12-
mcc_core_version: 5.8.0-rc.f
13-
content_manager_version: 6.0.0-rc.d
11+
mcc_version: 5.6.2
12+
mcc_core_version: 5.8.2
13+
content_manager_version: 6.0.1
1414
is_mcc_offline: false
15-
is_using_prerelease_versions: true
16-
mcc_content_registries: https://registry.npmjs.org/,https://artifacts.microchip.com/artifactory/api/npm/npm/
17-
device_library: {library_class: com.microchip.mcc.melody.Library, name: Melody, version: 2.9.0-rc.1}
15+
is_using_prerelease_versions: false
16+
mcc_content_registries: https://registry.npmjs.org/
17+
device_library: {library_class: com.microchip.mcc.melody.Library, name: Melody, version: 2.9.1}
1818
packs: {name: N/A, version: N/A}
1919
modules:
20-
- {name: '@mchp-mcc/data-streamer-driver', type: MELODY, version: 2.0.2-dev.1}
20+
- {name: '@mchp-mcc/data-streamer-driver', type: MELODY, version: 2.0.1}
2121
- {name: '@mchp-mcc/delay-blocking-driver', type: MELODY, version: 3.2.0}
22-
- {name: '@mchp-mcc/example-i2c-host', type: MELODY, version: 1.0.0}
23-
- {name: '@mchp-mcc/i2c-host-driver', type: MELODY, version: 1.1.0-dev.1}
22+
- {name: '@mchp-mcc/example-i2c-host', type: MELODY, version: 1.0.0-rc.4}
23+
- {name: '@mchp-mcc/i2c-host-driver', type: MELODY, version: 1.0.5}
2424
- {name: '@mchp-mcc/main-manager', type: MELODY, version: 3.1.2}
25-
- {name: '@mchp-mcc/pic-8bit', type: MELODY, version: 5.29.2-dev.1}
25+
- {name: '@mchp-mcc/melody', type: CLASSIC, version: 2.9.1}
26+
- {name: '@mchp-mcc/pic-8bit', type: MELODY, version: 5.29.1}
2627
- {name: '@mchp-mcc/pic18-configuration-bits-v1', type: MELODY, version: 5.3.5}
2728
- {name: '@mchp-mcc/pic18-pin-manager', type: MELODY, version: 3.7.1}
28-
- {name: '@mchp-mcc/pin-content-processor', type: MELODY, version: 3.9.1-feat.6}
29+
- {name: '@mchp-mcc/pin-content-processor', type: MELODY, version: 3.10.0}
2930
- {name: '@mchp-mcc/scf-pic8-i2c-v1', type: MELODY, version: 6.1.4}
3031
- {name: '@mchp-mcc/scf-pic8-interrupt-v1', type: MELODY, version: 5.2.11}
3132
- {name: '@mchp-mcc/scf-pic8-osc-v1', type: MELODY, version: 4.4.0}

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/mcc-manifest-generated-success.yml

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,31 @@
22

33
manifest_file_version: 1.0.0
44
project: pic18f57q43-i2c-proximity-sensor-polled-data-streamer
5-
creation_date: 2025-05-05T12:02:46.301+02:00[Europe/Berlin]
5+
creation_date: 2025-06-17T10:53:23.859+02:00[Europe/Berlin]
66
operating_system: Windows 11
77
mcc_mode: IDE
88
mcc_mode_version: v6.25
99
device_name: PIC18F57Q43
1010
compiler: XC8 3.00
11-
mcc_version: 5.6.0-rc.f
12-
mcc_core_version: 5.8.0-rc.f
13-
content_manager_version: 6.0.0-rc.d
11+
mcc_version: 5.6.2
12+
mcc_core_version: 5.8.2
13+
content_manager_version: 6.0.1
1414
is_mcc_offline: false
15-
is_using_prerelease_versions: true
16-
mcc_content_registries: https://registry.npmjs.org/,https://artifacts.microchip.com/artifactory/api/npm/npm/
17-
device_library: {library_class: com.microchip.mcc.melody.Library, name: Melody, version: 2.9.0-rc.1}
15+
is_using_prerelease_versions: false
16+
mcc_content_registries: https://registry.npmjs.org/
17+
device_library: {library_class: com.microchip.mcc.melody.Library, name: Melody, version: 2.9.1}
1818
packs: {name: N/A, version: N/A}
1919
modules:
20-
- {name: '@mchp-mcc/data-streamer-driver', type: MELODY, version: 2.0.2-dev.1}
20+
- {name: '@mchp-mcc/data-streamer-driver', type: MELODY, version: 2.0.1}
2121
- {name: '@mchp-mcc/delay-blocking-driver', type: MELODY, version: 3.2.0}
22-
- {name: '@mchp-mcc/example-i2c-host', type: MELODY, version: 1.0.0}
23-
- {name: '@mchp-mcc/i2c-host-driver', type: MELODY, version: 1.1.0-dev.1}
22+
- {name: '@mchp-mcc/example-i2c-host', type: MELODY, version: 1.0.0-rc.4}
23+
- {name: '@mchp-mcc/i2c-host-driver', type: MELODY, version: 1.0.5}
2424
- {name: '@mchp-mcc/main-manager', type: MELODY, version: 3.1.2}
25-
- {name: '@mchp-mcc/pic-8bit', type: MELODY, version: 5.29.2-dev.1}
25+
- {name: '@mchp-mcc/melody', type: CLASSIC, version: 2.9.1}
26+
- {name: '@mchp-mcc/pic-8bit', type: MELODY, version: 5.29.1}
2627
- {name: '@mchp-mcc/pic18-configuration-bits-v1', type: MELODY, version: 5.3.5}
2728
- {name: '@mchp-mcc/pic18-pin-manager', type: MELODY, version: 3.7.1}
28-
- {name: '@mchp-mcc/pin-content-processor', type: MELODY, version: 3.9.1-feat.6}
29+
- {name: '@mchp-mcc/pin-content-processor', type: MELODY, version: 3.10.0}
2930
- {name: '@mchp-mcc/scf-pic8-i2c-v1', type: MELODY, version: 6.1.4}
3031
- {name: '@mchp-mcc/scf-pic8-interrupt-v1', type: MELODY, version: 5.2.11}
3132
- {name: '@mchp-mcc/scf-pic8-osc-v1', type: MELODY, version: 4.4.0}

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/mcc_generated_files/data_streamer/data_streamer.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
/**
23
* DATASTREAMER Generated Driver API Header File.
34
*
@@ -33,9 +34,8 @@
3334
#ifndef DATA_STREAMER_H
3435
#define DATA_STREAMER_H
3536

36-
#include <stddef.h>
37+
#include <stdio.h>
3738
#include <stdint.h>
38-
#include "data_streamer_comms.h"
3939

4040
/**
4141
* @def Data Streamer Start Byte Macro.
@@ -120,4 +120,4 @@ void DataStreamer_PackageSet(void * customStructHandler, size_t customlength);
120120
#endif /* DATA_STREAMER_H */
121121
/**
122122
End of File
123-
*/
123+
*/

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/mcc_generated_files/data_streamer/src/data_streamer.c

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@
3131
*/
3232

3333
#include "../data_streamer.h"
34+
#include "../../uart/uart1.h"
35+
36+
static const uart_drv_interface_t *DS_UART = &UART1;
37+
3438

3539
struct DATA_STREAMER_STRUCT DataStreamer;
3640
struct PACKAGE_STRUCT DATA_STREAMER_PACKAGE;
@@ -40,21 +44,22 @@ void DataStreamer_Initialize(void)
4044
DataStreamer_PackageSet(&DataStreamer, sizeof (DataStreamer));
4145
}
4246

47+
static void DataStreamer_VariableWrite(char var)
48+
{
49+
while (!(DS_UART->IsTxReady()));
50+
DS_UART->Write(var);
51+
};
52+
4353
void DataStreamer_FrameSend(void * package, size_t length)
4454
{
45-
/* cppcheck-suppress misra-c2012-11.5 */
4655
char * dp = package;
4756
DataStreamer_VariableWrite(DATA_STREAMER_START_BYTE);
48-
size_t counter = length;
49-
while (counter > 0U)
57+
while (length--)
5058
{
5159
DataStreamer_VariableWrite(*dp++);
52-
counter--;
5360
}
5461
DataStreamer_VariableWrite(DATA_STREAMER_END_BYTE);
55-
while (DataStreamer_IsTxDone() == false)
56-
{
57-
}
62+
while (!(DS_UART->IsTxDone()));
5863
};
5964

6065
void DataStreamer_PackageSet(void * customStructHandler, size_t customlength)

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/nbproject/configurations.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
<logicalFolder name="data_streamer"
1111
displayName="data_streamer"
1212
projectFiles="true">
13-
<itemPath>mcc_generated_files/data_streamer/data_streamer_comms.h</itemPath>
1413
<itemPath>mcc_generated_files/data_streamer/data_streamer.h</itemPath>
1514
</logicalFolder>
1615
<logicalFolder name="i2c_host" displayName="i2c_host" projectFiles="true">
@@ -56,7 +55,6 @@
5655
displayName="data_streamer"
5756
projectFiles="true">
5857
<logicalFolder name="src" displayName="src" projectFiles="true">
59-
<itemPath>mcc_generated_files/data_streamer/src/data_streamer_comms.c</itemPath>
6058
<itemPath>mcc_generated_files/data_streamer/src/data_streamer.c</itemPath>
6159
</logicalFolder>
6260
<itemPath>mcc_generated_files/data_streamer/data_streamer.ds</itemPath>

pic18f57q43-i2c-proximity-sensor-polled-data-streamer.X/pic18f57q43-i2c-proximity-sensor-polled-data-streamer.mc3

Lines changed: 13 additions & 18 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)