Doubs building the ADD package

Micael Karlberg micael.karlberg@REDACTED
Fri Oct 31 15:09:19 CET 2003


Hi,

There is two problems:
      1) The LocalRemoteDescriptor.propGrps is not a list 
         of PropertyParm. It's actually a list of PropertyGroup, 
	 which is a list of PropertyParm. In our case it means, 
	 you should write e.g. [[PropGrps1]] (I am gessing that 
	 your cre_LocalRemoteDescriptor function does not wrap this).
      2) In the PropertyParm record, the name part is a string, e.g. "v",
         and the value part is a list of length 1 of a string, e.g. ["0"].
	 So, using your function this would mean: cre_PropertyParm("v", ["0"])

Suggestion for cre_PropertyParm:

cre_PropertyParm(Name, Value) when list(Name), list(Value) ->
   #'PropertyParm'{name = Name, value = [Value]}.

Regards,
	/BMK

mwilligs@REDACTED writes:
 > I wanna do this
 > 
 > ...
 > Local {
 > v=0
 > c=in IP4 $
 > m=audio $ RTP/AVP 4
 > }
 > ...
 > what wrong in de line "PropGrps1=cre_PropertyParm(v,"0")" because in this
 > line the error jump
 > 
 > cre_PropertyParm(Name,Value)->
 > 	#'PropertyParm'{name=Name,value=Value}.
 > 
 > 
 > 
 > ...
 > 	PropGrps3=cre_PropertyParm(m,"audio $ RTP/AVP"),
 > 	PropGrps2=cre_PropertyParm(c,"IN IP4 $"),
 > 	PropGrps1=cre_PropertyParm(v,"0"),
 > 	LRD1	= cre_LocalRemoteDescriptor([PropGrps1]),%%%here fail, I proved with
 > 0 insteaded of "0"
 > 	%
 > 	%for introducing more propgrps it's like this :
 > 	%	LRD1	=
 > cre_LocalRemoteDescriptor([PropGrps1,PropGrps2,PropGrps3]),%%%here fail
 > 
 > 	%LRD1	= cre_LocalRemoteDescriptor([]),%that work
 > 
 > 	%that work
 > 	LCD1   	= cre_LocalControlDescriptor(sendRecv),
 > 	SP3	= cre_StreamParms({remoteDescriptor, LRD1}),
 > 	SP2	= cre_StreamParms({localDescriptor, LRD1}),
 > 	SP1    	= cre_StreamParms({localControlDescriptor, LCD1}),
 > 	MEDIA1	= cre_MediaDescriptor(oneStream,SP3),
 > 	ADD1	= cre_Ammrequest(?A4444, mediaDescriptor, MEDIA1),
 > 	CR1	= cre_commandReq({addReq, ADD1}),
 > 	AR	= cre_actionReq(?megaco_choose, [CR1]).
 > ...

-- 
Micael Karlberg          Ericsson AB, Älvsjö Sweden
Tel:  +46 8 727 5668     EAB/UHK/KD - OTP Product Development
ECN:  851 5668           Mail: micael.karlberg@REDACTED
Fax:  +46 8 727 5775    



More information about the erlang-questions mailing list