It’s all a bit complicated, I guess.
You are right, pulse_attach() works with the dispatch layer and need not be
related to a resource manager, although this is all irrelevant, as I don’t
need to do a pulse_attach to get the pulses. When I setup the dispatcher, I
do:
msg_attr.flags = MSG_FLAG_DEFAULT_FUNC; <— Get all messages,
even pulses, which are not being handled
msg_attr.nparts_max = 1;
msg_attr.msg_max_size = itsRcvBufferSize;
if( -1 == message_attach( itsDispatcherPtr, &msg_attr, 0, 0,
&DispatchMsgHandler, this ) )
…
…
…
Any pulse which are not handled via a seperate pulse_attach() will be sent
to the DispatchMsgHandler function, as this is the DEFAULT function to call
when no handlers are found.
I’ve figured out what is causing the missing pulses, but not why. See
attach example. If you comment out the name_attach(), you will get the
PULSE_CODE_DISCONNECT pulse. Leave it in and you won’t. Why is this? Bug?
“Rennie Allen” <rallen@csical.com> wrote in message
news:42D3EB98.5010103@csical.com…
Richard Doucet wrote:
I believe pulse_attach() is only valid if you are a resource manager;
this
application is not.
pulse_attach is valid if you are using the dispatch layer (upon which the
resmgr layer is built).
You are calling dispatch_block() are you not ?
I’ve tried it anyways and still no pulse…
If you don’t call dispatch_block(), then you won’t.
I guess I don’t understand what you are doing.
Rennie
begin 666 TestNotifications.c
M(VEN8VQU9&4@/’-T9&QI8BYH/@T*(VEN8VQU9&4@/’-T9&EO+F@^#0HC:6YC
M;‘5D92 <WES+VYE=71R:6YO+F@^#0HC:6YC;‘5D92 <‘1H<F5A9"YH/@T*
M(VEN8VQU9&4@/’-Y<R]D:7-P871C:"YH/@T*(VEN8VQU9&4@/&5R<FYO+F@^
M#0HC:6YC;‘5D92 <’)O8V5S<RYH/@T*#0ID:7-P871C:%]T("H@7V1I<W!A
M=&-H7V-R96%T92AI;G0@8VAI9"P@:6YT(&1F;&%G<RD[#0H-“FEN=”!$:7-P
M871C:$US9TAA;F1L97(@&UE<W-A9V5?8V]N=&5X=%]TB!C=’ L(&EN="!C
M;V1E+"!U;G-I9VYE9"!F;&%G<RP@=F]I9" J:&%N9&QE0T>PT*“7-T<G5C
M=”!?<‘5L<V4)G @/2 H<W1R=6-T(%]P=6QS92 J2!C=’ M/FUS9SL-"@T*
M"7-W:71C:"@@<"T^8V]D92 I#0H)>PT*“6-A<V4@7U!53%-%7T-/1$5?5$A2
M14%$1$5!5$@Z#0H)“7!R:6YT9B@@(E1H<F5A9”!D:65<;B(@3L-"@D)8G)E
M86L[#0H)8V%S92!?4%5,4T5?0T]$15]$25-#3TY.14-4.@T"0EP<FEN=&8H
M(”)$25-#3TY.14-47&XB("D[#0H)"6)R96%K.PT*"6-A<V4@7U!53%-%7T-/
M1$5?0T])1$1%051(.@T*“0EP<FEN=&8H(”)#3TE$($1%051(7&XB("D[#0H)
M"6)R96%K.PT*“61E9F%U;'0Z#0H)“7!R:6YT9B@@(D=O=”!U;FMO=VX@<'5L
M<V5<;B(@3L-"@D)37-G4F5P;'DH(&-T<"T^<F-V:60L(# L(# L(# @3L-
M"@D)8G)E86L[#0H)?0T"7)E='5R;B P.PT?0T*#0IV;VED(”!F=6YC=&EO
M;B@@:6YT(’!I9"P@:6YT(&-H:60@0T>PT*“6EN= D)8V]I9#L-”@T*#0IP
M<FEN=&8H(")#3VYN96-T:6YG(‘1O(’!I9" E9"!C:&ED(“5D7&XB+”!P:60L
M(&-H:60@3L-"@EC;VED(#T@0V]N;F5C=$%T=&%C:"@@,“P@<&ED+”!C:&ED
M+"!?3E1/7U-)1$5?0TA!3DY%3"P@," I.PT"0T*“6EF*” M,2 A/2!C;VED
M(“D-”@E[#0H)“7!R:6YT9B@@(E-E;F1I;F<N+EQN(B I.PT*“0D-”@D)37-G
M4V5N9”@@8V]I9"P@(D%L;&\B+" U+"!.54Q,+" P(“D[#0H)“0T*“0ES;&5E
M<”@@,B I.PT*+R)“4-O;FYE8W1$971A8V@H(&-O:60@3L-"@D)#0H)?0T
M"7!R:6YT9B@@(E1E<FUI;F%T:6YG+BXN7&XB(“D[#0H)97AI=”@@,” I.PT*
M?0T*#0II;G0@;6%I;BAI;G0@87)G8RP@8VAA<B J87)G=EM=2 -"GL-"B @
M(’!T:’)E861?871T<E]T( EA='1R.PT(” @9&ES<&%T8VA?= D)“2ID<W [
M#0H@(”!D:7-P871C:%]C;VYT97AT7W0@F-T<#L-"@EM97-S86=E7V%T=’)?
M= EM<V=?871T<CL-"@EI;G0)“0D)8VAI9#L-”@EI;G0)"0D)<&ED(#T@9V5T
M<&ED"D[#0H-”@EC:&ED(#T@0VAA;FYE;$-R96%T92@@7TY43U]#2$9?1$E3
M0T].3D5#5" I.PT*#0H):68H(“TQ(#T](&-H:60@0T"7L-”@D)<’)I;G1F
M*" B17)R;W(L(&-H:60@/3T@+3%<;B(@3L-"@D)97AI="@@," I.PT"7T-
M"@T*“61S<” ](%]D:7-P871C:%]C<F5A=&4H(&-H:60L(# @3L-"@T"2\O
M($1O(&UE<W-A9V4@871T86-H(‘1O(’)E8V5I=F4@;65S<V%G97,@9G)O;2!D
M:7-P871C:&5R#0H);65M<V5T*" F;7-G7V%T=’(L(# L(’-I>F5O9B@@;7-G
M7V%T=’(@2 I.PT"6US9U]A='1R+F9L86=S(#T@35-‘7T9,04=?1$5&055,
M5%]&54Y#.PT*“6US9U]A='1R+FYP87)T<U]M87@@/2 Q.PT*“6US9U]A='1R
M+FUS9U]M87A?<VEZ92 ](#(P-#@[#0H-“B @(”!I9B@@+3$@/3T@;65S<V%G
M95]A='1A8V@H(&1S<“P@)FUS9U]A='1R+” P+” P+” F1&ES<&%T8VA-<V=(
M86YD;&5R+" P(“D@2 -“B @(”![#0H@(" @"65X:70H("TQ(“D[#0H@(” @
M?0T"0T*“6EF*” P(”$](&1S<" I#0H)>PT*"0T*“0EI9B@@,” ]/2!F;W)K
M*"D@0T"0E[#0H)“0EF=6YC=&EO;B@@<&ED+”!C:&ED("D[#0H)“7T-”@D)
M96QS90T*"0E["0T*"0D);F%M95]A=‘1A8V@H(&1S<“P@(E1%4U0B+” P("D[
M#0H)"0T*"0D)8W1P(#T@9&ES<&%T8VA?8V]N=&5X=%]A;&QO8R@@9’-P(“D[
M#0H)“0D-”@D)(” @(’=H:6QE*" Q(“D-”@D)(" @(‘L-"@D)“0EI9B@@8W1P
M(#T@9&ES<&%T8VA?8FQO8VLH(&-T<” I("D@#0H)"0D)>PT*"0D)“0ED:7-P
M871C:%]H86YD;&5R*”!C=’ @3L-"@D)“0E]#0H)“2 @(”!]#0H)“7T-”@E]
@#0H-”@ER971U<FX@15A)5%]354-#15-3.PT?0T*#0H
end