| 205 |
|
|
| 206 |
printf(" dwDefaultClock: %.3f MHz\n", dw2i(extra, 10)/1000.0); |
printf(" dwDefaultClock: %.3f MHz\n", dw2i(extra, 10)/1000.0); |
| 207 |
printf(" dwMaximumClock: %.3f MHz\n", dw2i(extra, 14)/1000.0); |
printf(" dwMaximumClock: %.3f MHz\n", dw2i(extra, 14)/1000.0); |
| 208 |
printf(" bNumClockSupported: %d\n", extra[18]); |
printf(" bNumClockSupported: %d %s\n", extra[18], |
| 209 |
if (extra[18]) |
extra[18] ? "" : "(will use whatever is returned)"); |
| 210 |
{ |
{ |
| 211 |
unsigned char buffer[256*sizeof(int)]; /* maximum is 256 records */ |
unsigned char buffer[256*sizeof(int)]; /* maximum is 256 records */ |
| 212 |
int n; |
int n; |
| 232 |
int i; |
int i; |
| 233 |
|
|
| 234 |
/* we do not get the expected number of data rates */ |
/* we do not get the expected number of data rates */ |
| 235 |
if (n != extra[18]*4) |
if ((n != extra[18]*4) && extra[18]) |
| 236 |
{ |
{ |
| 237 |
printf(" Got %d clock frequencies but was expecting %d\n", |
printf(" Got %d clock frequencies but was expecting %d\n", |
| 238 |
n/4, extra[18]); |
n/4, extra[18]); |
| 248 |
} |
} |
| 249 |
printf(" dwDataRate: %d bps\n", dw2i(extra, 19)); |
printf(" dwDataRate: %d bps\n", dw2i(extra, 19)); |
| 250 |
printf(" dwMaxDataRate: %d bps\n", dw2i(extra, 23)); |
printf(" dwMaxDataRate: %d bps\n", dw2i(extra, 23)); |
| 251 |
printf(" bNumDataRatesSupported: %d\n", extra[27]); |
printf(" bNumDataRatesSupported: %d %s\n", extra[27], |
| 252 |
if (extra[27]) |
extra[27] ? "" : "(will use whatever is returned)"); |
| 253 |
{ |
{ |
| 254 |
unsigned char buffer[256*sizeof(int)]; /* maximum is 256 records */ |
unsigned char buffer[256*sizeof(int)]; /* maximum is 256 records */ |
| 255 |
int n; |
int n; |
| 275 |
int i; |
int i; |
| 276 |
|
|
| 277 |
/* we do not get the expected number of data rates */ |
/* we do not get the expected number of data rates */ |
| 278 |
if (n != extra[27]*4) |
if ((n != extra[27]*4) && extra[27]) |
| 279 |
{ |
{ |
| 280 |
printf(" Got %d data rates but was expecting %d\n", n/4, |
printf(" Got %d data rates but was expecting %d\n", n/4, |
| 281 |
extra[27]); |
extra[27]); |