• AVR Freaks

Helpful ReplyHot!Harmony 3, missing functions after core 3.7.1 update

Author
Jon_S
New Member
  • Total Posts : 21
  • Reward points : 0
  • Joined: 2019/12/03 04:51:40
  • Location: 0
  • Status: offline
2020/05/22 04:14:16 (permalink)
0

Harmony 3, missing functions after core 3.7.1 update

I've just updated and I now have missing functions causing a build failure, does anyone know how to persuade it to generate properly? Part is a PIC32MZ1024EFM064.
I've tried the obvious (remove the modules in MHC, generate, re-add the modules, generate) without success.
 
In Initialization.c:
 
const SYS_CONSOLE_UART_PLIB_INTERFACE sysConsole0UARTPlibAPI =
{
    .read = (SYS_CONSOLE_UART_PLIB_READ)UART2_Read,
 .readCountGet = (SYS_CONSOLE_UART_PLIB_READ_COUNT_GET)UART2_ReadCountGet,
 .readFreeBufferCountGet = (SYS_CONSOLE_UART_PLIB_READ_FREE_BUFFFER_COUNT_GET)UART2_ReadFreeBufferCountGet,
    .write = (SYS_CONSOLE_UART_PLIB_WRITE)UART2_Write,
 .writeCountGet = (SYS_CONSOLE_UART_PLIB_WRITE_COUNT_GET)UART2_WriteCountGet,
 .writeFreeBufferCountGet = (SYS_CONSOLE_UART_PLIB_WRITE_FREE_BUFFER_COUNT_GET)UART2_WriteFreeBufferCountGet,
};

 
UART2_ReadFreeBufferCountGet and UART2_WriteFreeBufferCountGet no-longer exist in the plib_uart files.
 
This one may be a design decision, and something I wasn't supposed to be using, but
CORETIMER_DelayUs ( uint32_t delay_us) has vanished from plib_coretimer.
 
Edit:
 
CORETIMER_CompareSet
CORETIMER_CounterGet
 
Are missing too, which is also causing build errors in Initialisation.c.
post edited by Jon_S - 2020/05/22 05:02:13
#1
arpananand
Super Member
  • Total Posts : 488
  • Reward points : 0
  • Joined: 2009/11/18 04:35:42
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 05:22:52 (permalink) ☄ Helpfulby Jon_S 2020/05/22 05:35:38
0
for coretimer, you seem to have enabled periodic interrupt. for that mode those APIs are not supported. if you change the mode, then APIs will be generated. 
#2
arpananand
Super Member
  • Total Posts : 488
  • Reward points : 0
  • Joined: 2009/11/18 04:35:42
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 05:25:30 (permalink) ☄ Helpfulby Jon_S 2020/05/22 06:02:10
0
and the mentioned UART APIs are available in ring buffer mode only. so enable that in UART PLIB configuration.
 
#3
Jon_S
New Member
  • Total Posts : 21
  • Reward points : 0
  • Joined: 2019/12/03 04:51:40
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 05:37:13 (permalink)
0
arpananand
for coretimer, you seem to have enabled periodic interrupt. for that mode those APIs are not supported. if you change the mode, then APIs will be generated. 

 
Thank you, those errors have stopped.

arpananand
and the mentioned UART APIs are available in ring buffer mode only. so enable that in UART PLIB configuration.


Can I ask how I do that? I can't seem to find where that is configured.
#4
vgandhi
Junior Member
  • Total Posts : 27
  • Reward points : 0
  • Joined: 2016/10/24 21:28:35
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 06:01:07 (permalink)
0
You will need to get the latest version of the CSP package v3.7.1 and the dev_packs v3.7.1 as well. The UART PLIB has been updated and now optionally supports ring buffer mode (MHC configurable). The console system service is now updated to make use of the ring buffer mode of the UART PLIB. When the console system service is connected to the UART PLIB in the MHC project graph, the ring buffer mode of the UART PLIB should get enabled automatically. Also, note that there are changes to the SYS Console API signatures depending on which APIs you have been using in your application. You can refer the demo applications on console system service here -
https://github.com/Microchip-MPLAB-Harmony/core/tree/master/apps/system/console_debug/sys_console_debug_uart_read_write/firmware
For backward compatibility, the SYS_CONSOLE_PRINT(), SYS_CONSOLE_MESSAGE(), SYS_DEBUG_PRINT() and SYS_DEBUG_MESSAGE() APIs do not have any API or behavior change. More details can be found in the console and debug system service documentation available under the core/doc folder.
 
 
#5
Jon_S
New Member
  • Total Posts : 21
  • Reward points : 0
  • Joined: 2019/12/03 04:51:40
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 06:35:07 (permalink)
0
vgandhi
You will need to get the latest version of the CSP package v3.7.1 and the dev_packs v3.7.1 as well.



Thank you. I have CSP v3.7.1 but the HCM says dev_packs v3.7.0 is the latest (that seems to match GitHub). I have tried removing and re-downloading them anyway. All the modules in the config manager show as "Up to date".
 
There is no ring buffer options under the MHC property page for the UART PLIB modules. And I still have build errors in the MH generated code.
 
 
vgandhi
Also, note that there are changes to the SYS Console API signatures depending on which APIs you have been using in your application.



Thank you for the heads-up. I have been using the un-changed ones. But I'll read that documentation.
 
 
post edited by Jon_S - 2020/05/22 06:36:29
#6
Jon_S
New Member
  • Total Posts : 21
  • Reward points : 0
  • Joined: 2019/12/03 04:51:40
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 06:43:59 (permalink)
0
Ok, If I load any of the UART example projects then the ring buffer options DO exist.
 
How can I adjust my project so those options are present too?
post edited by Jon_S - 2020/05/22 06:46:23
#7
vgandhi
Junior Member
  • Total Posts : 27
  • Reward points : 0
  • Joined: 2016/10/24 21:28:35
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 06:47:05 (permalink)
0
Sorry my bad. The dev_packs package will be v3.7.0. 
Please look at the example applications available here ..
https://github.com/Microchip-MPLAB-Harmony/core/tree/master/apps/system/console_debug/sys_console_debug_uart_read_write/firmware
#8
vgandhi
Junior Member
  • Total Posts : 27
  • Reward points : 0
  • Joined: 2016/10/24 21:28:35
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 06:48:21 (permalink)
0
Can you post a snapshot of the project graph? Are there more than one module connected to the UART PLIB?
 
#9
Jon_S
New Member
  • Total Posts : 21
  • Reward points : 0
  • Joined: 2019/12/03 04:51:40
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 07:04:00 (permalink)
0
After I opened the example project the options are now appearing in my project too. I had my project open with no ring buffer options shown (and build errors), closed MPLAB, opened the example project in the framework folder, closed MPLAB, opened my project again and suddenly had the new options (and the errors are gone). I did not have the Content Manager open at any time during that process, just the Configurator.
 
There are a few modules connected to the PLIB, I've attached an image.
 
Very peculiar. Does opening a 'newer' project clear a cache, or something similar.
 
 

Attached Image(s)

#10
vgandhi
Junior Member
  • Total Posts : 27
  • Reward points : 0
  • Joined: 2016/10/24 21:28:35
  • Location: 0
  • Status: offline
Re: Harmony 3, missing functions after core 3.7.1 update 2020/05/22 07:48:15 (permalink)
5 (1)
Glad you are able to proceed. The project graph looks fine. There is only console system service connected to the UART Plib, which is fine.
#11
Jump to:
© 2020 APG vNext Commercial Version 4.5