home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
HTPC Projects
Hardware
TV-Cards
DVB S/S2 cards on legacy PCI interface.
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Sebastiii" data-source="post: 1198563" data-attributes="member: 60104"><p>Maybe we can invert code ?</p><p></p><p>[code]//set the DisEqC parameters</p><p> if (_conditionalAccess != null)</p><p> {</p><p> //int hr2 = ((IMediaControl)_graphBuilder).Pause();</p><p> _diseqCsucceded = _conditionalAccess.SendDiseqcCommand(_parameters, dvbsChannel);</p><p> //hr2 = ((IMediaControl)_graphBuilder).Run();</p><p></p><p> //move diseqc motor to correct satellite</p><p> if (dvbsChannel != null && dvbsChannel.SatelliteIndex > 0 && _conditionalAccess.DiSEqCMotor != null)</p><p> {</p><p> _conditionalAccess.DiSEqCMotor.GotoPosition((byte)dvbsChannel.SatelliteIndex);</p><p> }</p><p> }</p><p>[/code]</p><p></p><p>to </p><p></p><p>[code]//set the DisEqC parameters</p><p> if (_conditionalAccess != null)</p><p> {</p><p> //move diseqc motor to correct satellite</p><p> if (dvbsChannel != null && dvbsChannel.SatelliteIndex > 0 && _conditionalAccess.DiSEqCMotor != null)</p><p> {</p><p> _conditionalAccess.DiSEqCMotor.GotoPosition((byte)dvbsChannel.SatelliteIndex);</p><p> }</p><p></p><p> //int hr2 = ((IMediaControl)_graphBuilder).Pause();</p><p> _diseqCsucceded = _conditionalAccess.SendDiseqcCommand(_parameters, dvbsChannel);</p><p> //hr2 = ((IMediaControl)_graphBuilder).Run();</p><p> }[/code]</p><p></p><p>Move first the motor and then continue.</p><p>Maybe we need to have a return value on _conditionalAccess.DiSEqCMotor.GotoPosition((byte)dvbsChannel.SatelliteIndex); when motor has finished to move and then continue the rest of the code.</p><p></p><p>Maybe implement the 'bool ReadDiSEqCCommand(out byte[] reply);' in 'public void GotoPosition(byte position)' </p><p></p><p>something like that :</p><p></p><p>[code]while (_controller.ReadDiSEqCCommand(cmd))</p><p> {</p><p> System.Threading.Thread.Sleep(100);</p><p> }[/code]</p><p></p><p>The code will not compil but i think you'll get the idea <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite1" alt=":)" title="Smile :)" loading="lazy" data-shortname=":)" /></p></blockquote><p></p>
[QUOTE="Sebastiii, post: 1198563, member: 60104"] Maybe we can invert code ? [code]//set the DisEqC parameters if (_conditionalAccess != null) { //int hr2 = ((IMediaControl)_graphBuilder).Pause(); _diseqCsucceded = _conditionalAccess.SendDiseqcCommand(_parameters, dvbsChannel); //hr2 = ((IMediaControl)_graphBuilder).Run(); //move diseqc motor to correct satellite if (dvbsChannel != null && dvbsChannel.SatelliteIndex > 0 && _conditionalAccess.DiSEqCMotor != null) { _conditionalAccess.DiSEqCMotor.GotoPosition((byte)dvbsChannel.SatelliteIndex); } } [/code] to [code]//set the DisEqC parameters if (_conditionalAccess != null) { //move diseqc motor to correct satellite if (dvbsChannel != null && dvbsChannel.SatelliteIndex > 0 && _conditionalAccess.DiSEqCMotor != null) { _conditionalAccess.DiSEqCMotor.GotoPosition((byte)dvbsChannel.SatelliteIndex); } //int hr2 = ((IMediaControl)_graphBuilder).Pause(); _diseqCsucceded = _conditionalAccess.SendDiseqcCommand(_parameters, dvbsChannel); //hr2 = ((IMediaControl)_graphBuilder).Run(); }[/code] Move first the motor and then continue. Maybe we need to have a return value on _conditionalAccess.DiSEqCMotor.GotoPosition((byte)dvbsChannel.SatelliteIndex); when motor has finished to move and then continue the rest of the code. Maybe implement the 'bool ReadDiSEqCCommand(out byte[] reply);' in 'public void GotoPosition(byte position)' something like that : [code]while (_controller.ReadDiSEqCCommand(cmd)) { System.Threading.Thread.Sleep(100); }[/code] The code will not compil but i think you'll get the idea :) [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
HTPC Projects
Hardware
TV-Cards
DVB S/S2 cards on legacy PCI interface.
Contact us
RSS
Top
Bottom