• AVR Freaks

Hot!Harmony 2.0.5.2 - Dynamic USART with Buffer and Client question (or maybe Static)

Author
D4ILYD0SE
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/02/12 15:34:09
  • Location: 0
  • Status: offline
2019/08/12 12:52:25 (permalink)
0

Harmony 2.0.5.2 - Dynamic USART with Buffer and Client question (or maybe Static)

Greetings Programs!
 
I am attempting to implement USART capabilities with buffer queue support using Harmony Configure.  I plan to use 4 USART instances.  One of the things that has been slightly confusing through the Harmony Tutorials (or just not at all explained) available online is how this all works with the clients.  If I choose Static Mode then each instance will have a singular client leaving you with 4 total clients.  According to Harmony Configurator, I can choose Buffer Queue Support for Static mode. 
 
However, according to the online documentation and implementation support, it suggests Buffer Queue support is NOT provided for Static mode.  Assuming this is true, then in Dynamic mode, do I choose 4 clients or do I choose 1 client.  I am communicating with 4 separate external entities via USART, but is the client actually referring to the micro itself? 
 
Let's say I go the Dynamic route with 1 client and 4 instances.  The online documentation says to initialize your DRV_HANDLE, but in the example, they have 1 client and 1 instance.  Is the DRV_Handle the client? 
 
Hope I wasn't confusing everyone.  Here's the link to what I'm reading and following along with: Link
#1
m4l490n
Senior Member
  • Total Posts : 121
  • Reward points : 0
  • Joined: 2010/06/15 22:21:39
  • Location: 0
  • Status: offline
Re: Harmony 2.0.5.2 - Dynamic USART with Buffer and Client question (or maybe Static) 2019/08/12 16:57:57 (permalink)
0
"Clients" are different "tasks" in your firmware, or different separate "modules" that need to use one of the micro's UARTs, not different micros.
 
I recommend you to use as many instances and clients as UARTs you need. For example, if you need three UARTS, then configure the driver as "3" instances and "3" clients, otherwise, if you only define ONE client for THREE instances, you will need to be opening and closing the instance, or port, you need to use and this, in my opinion, is too much work and can lead to problems. It's better to have three instances so you open the three ports, at the same time and you don't have to be closing them to "recycle" your "DRV_HANDLE" pointer.
#2
D4ILYD0SE
New Member
  • Total Posts : 16
  • Reward points : 0
  • Joined: 2019/02/12 15:34:09
  • Location: 0
  • Status: offline
Re: Harmony 2.0.5.2 - Dynamic USART with Buffer and Client question (or maybe Static) 2019/08/12 21:27:25 (permalink)
0
This would certainly make sense with my build errors.  I shall attempt with all clients.  Thank you.  I shall also update to 2.0.6.  I believe I am actually using 2.0.2
#3
Jump to:
© 2019 APG vNext Commercial Version 4.5