Subversion Repositories NaviCtrl

Rev

Rev 516 | Rev 687 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 516 Rev 678
Line 312... Line 312...
312
 
312
 
313
void SDC_PrintCID(u8 * pCID)
313
void SDC_PrintCID(u8 * pCID)
314
{
314
{
315
        u8 pn[6];
315
        u8 pn[6];
316
        u16 temp1, temp2;
316
        u16 temp1, temp2;
317
 
317
/*
318
        sprintf(text, "\r\n Manufacturer ID: %i\r\n", pCID[0]);
318
        sprintf(text, "\r\n Manufacturer ID: %i\r\n", pCID[0]);
319
        UART1_PutString(text);
319
        UART1_PutString(text);
320
        memcpy(pn, &pCID[1], 2);
320
        memcpy(pn, &pCID[1], 2);
321
        pn[2] = '\0'; // terminate string
321
        pn[2] = '\0'; // terminate string
Line 331... Line 331...
331
        for(temp1 = 0; temp1<4; temp1++)
331
        for(temp1 = 0; temp1<4; temp1++)
332
        {
332
        {
333
                sprintf(text,"%02X", pCID[9+temp1]);
333
                sprintf(text,"%02X", pCID[9+temp1]);
334
                UART1_PutString(text);
334
                UART1_PutString(text);
335
        }
335
        }
-
 
336
*/
336
        UART1_PutString("\r\n");
337
        UART1_PutString("\r\n");
337
        temp1 = pCID[14] & 0x0F;    // month 
338
        temp1 = pCID[14] & 0x0F;    // month 
338
        temp2 = ((pCID[14]>>4)|(pCID[13]<<4)) + 2000; // year 
339
        temp2 = ((pCID[14]>>4)|(pCID[13]<<4)) + 2000; // year 
339
        sprintf(text, " Manufac. Date: %i/%i\r\n\r\n",temp1, temp2);
340
        sprintf(text, " Manufac. Date: %i/%i\r\n\r\n",temp1, temp2);
340
        UART1_PutString(text);
341
        UART1_PutString(text);
Line 531... Line 532...
531
               
532
               
532
                SSC_Disable(); // set SD_CS high                                                                         
533
                SSC_Disable(); // set SD_CS high                                                                         
Line 533... Line 534...
533
                // here is the right place to inrease the SPI baud rate to maximum              
534
                // here is the right place to inrease the SPI baud rate to maximum              
534
 
535
 
Line 535... Line 536...
535
        SSC_Speed(speed);
536
        SSC_Speed(speed);
Line 536... Line 537...
536
                if(print) { sprintf(text,"\r\n Setting SPI speed to %d ", SPI_Speed);UART1_PutString(text); }
537
                if(print) { sprintf(text,"\r\n Setting SD-Card speed to %d ", SPI_Speed);UART1_PutString(text); }
537
               
538