Re: Task design considerations for a multilayer protocol stack
- From: ssubbarayan <ssubba@xxxxxxxxx>
- Date: Thu, 01 Nov 2007 07:54:51 -0700
On Oct 31, 3:50 pm, a...@xxxxxxxx wrote:
If I were to use a function call interface,(appl to middle layer) how
would I facilitate 2 way communication?
Incase I use a single task in middle layer wouldn't the single task in
middle layer be a bottleneck.I need a full-duplex communication
between applications, a middle layer and the interface drivers
(between each).
......... ........... ........
| app 1| | app 2| | app 3|
.......... ........... ..........
\ / \ / \ /
\ / \ / \ /
------------------------------------------
| middle layer |
------------------------------------------
\ / \ /
..\..../.. \....../....
| drv 1| | drv2 |
.......... ...........
I am trying to come with the best design possible.
Please post your valuable suggestions.
Thanks,
asm
Hi,
The entire system cannot be pure function calls as in real time you
might need reentrant code.So part of this can be calls.The
architecture I described would be like this:
Main application will run under a task.This task would access the
middle layer through direct calls.In this architecture the functions
called would be executing the context of the application task
requesting the call.From below layers if you want to pass values you
can design a function like this:
prototype:
returntype functionname(datatype a,datatype b,*datatobefilled)
In the above prototype the last parameter can be filled by the middle
layer with the data requested by the application.The first two
parameters can be the data which can be passed from application layer
to middle layer.
This architecture would be feasible provided the amount of data
exchange is less in terms of memory.Incase you need to pass more
amount of data then the architecture described below by Mr.Karthik
would work.Optionally you can choose a mix of both what I have
suggested and what Karthik has suggested.
All depends on the requirements of your application in terms of speed
and memory.
Regards,
s.subbarayan
.
- Prev by Date: Re: 5.4 Memory Fragmentation and Port of Doug Lea's Malloc
- Next by Date: Re: Update Clock
- Previous by thread: Re: Task design considerations for a multilayer protocol stack
- Next by thread: Browsing the end device list
- Index(es):
Relevant Pages
|