Changeset 5738
- Timestamp:
- 07/27/11 17:27:42 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/reader-videoguard2.c
r5737 r5738 639 639 640 640 // process cw2 641 int32_t ind; 642 for(ind=15; ind<l+5-10; ind++) { // +5 for 5 ins bytes, -10 to prevent memcpy ind+3,8 from reading past 643 // rxbuffer we start searching at 15 because start at 13 goes wrong 644 // with 090F 090b and 096a 645 if((rbuff[ind]==0x25) && ((rbuff[ind+1] == 0x13) || (rbuff[ind+1] == 0x11))) { 646 memcpy(er->cw+8,rbuff+ind+3,8); //tested on viasat 093E, sky uk 0963, sky it 919 647 //don't care whether cw is 0 or not 648 break; 641 unsigned char *payload = rbuff+5; 642 int payloadLen = rbuff[4]; 643 int ind=8+6; // +8 for CW1, +6 for counter(?) 644 645 while(ind<payloadLen) { 646 switch(payload[ind]) 647 { 648 case 0x25: // CW2 649 //cs_dump (payload + ind, payload[ind+1]+2, "INS54 - CW2"); 650 memcpy(er->cw+8,&payload[ind+3],8); 651 ind += payload[ind+1]+2; 652 break; 653 654 default: 655 //cs_dump (payload + ind, payload[ind+1]+2, "INS54"); 656 ind += payload[ind+1]+2; 657 break; 649 658 } 650 659 }
Note:
See TracChangeset
for help on using the changeset viewer.