2021年9月9日 星期四

RDM DISCOVERY_COMMAND use Recursive Method

void DiscoveryAll( void ) {     /// unmute all devices : RDM_UnMute()     /// implement DISCOVERY_COMMAND:DISC_UNMUTE    RDM_UnMute( 0xFFFFFFFFFFFF ); 

    /// discovery full range      Discovery( 0, 0xFFFFFFFFFFFE );           }

void Discovery( long long low, long long high ) {     unsigned char res;

    while(1)     {         /// try to discover devices : RDM_Discovery()         /// implement DISCOVERY_COMMAND:DISC_UNIQUE_BRANCH        res = RDM_Discovery( low, high ); 

        if( res == TARGET_IDENTIFIED )    /// target identified                {             /// mute identified target : RDM_Mute()             /// implement DISCOVERY_COMMAND:DISC_MUTE            RDM_Mute(target);                continue;    /// repeat         } else if( res == DETECT_COLLISIONS )    /// detect collisions        {            Discovery( low, (low+high)/2 );    /// discovery low bound            Discovery( (low+high)/2+1, high );    /// discovery high bound        }

        return;    /// finish     } }

沒有留言:

VirtualBox 空間減肥

sdelete64 -z c: VBoxManage  modifymedium  disk  "/Users/fellow/VirtualBox VMs/Win10/Win10.vdi"  --compact *.vdi 路徑可以在 VirtualBox 儲...