From 427688677e365bdec801cad640b84ef215870e71 Mon Sep 17 00:00:00 2001 From: Bjoern Kerler Date: Fri, 21 Oct 2011 20:01:01 +0200 Subject: Fix fi/di calculation for certain mobiles like GT-S770 or HTC Raphael There were some mistakes while copying the tables from ISO 7816-3, and also a quite old version of 7816-3 was used. --- firmware/src/simtrace/iso7816_uart.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'firmware/src') diff --git a/firmware/src/simtrace/iso7816_uart.c b/firmware/src/simtrace/iso7816_uart.c index 37b2fd7..17303ca 100644 --- a/firmware/src/simtrace/iso7816_uart.c +++ b/firmware/src/simtrace/iso7816_uart.c @@ -113,14 +113,14 @@ struct iso7816_3_handle isoh; /* Table 6 from ISO 7816-3 */ static const u_int16_t fi_table[] = { - 0, 372, 558, 744, 1116, 1488, 1860, 0, + 372, 372, 558, 744, 1116, 1488, 1860, 0, 0, 512, 768, 1024, 1536, 2048, 0, 0 }; /* Table 7 from ISO 7816-3 */ static const u_int8_t di_table[] = { - 0, 1, 2, 4, 8, 16, 0, 0, - 0, 0, 2, 4, 8, 16, 32, 64, + 0, 1, 2, 4, 8, 16, 32, 0, + 12, 20, 2, 4, 8, 16, 32, 64, }; /* compute the F/D ratio based on Fi and Di values */ -- cgit v1.2.3