FreeCalypso > hg > freecalypso-sw
comparison gsm-fw/g23m-gsm/sim/sim_fkt.c @ 752:ec171ca4afb4
sim_fkt.c compiles
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Sat, 11 Oct 2014 20:48:22 +0000 |
parents | 2f7df7a314f8 |
children |
comparison
equal
deleted
inserted
replaced
751:b15d4b9d49c4 | 752:ec171ca4afb4 |
---|---|
20 */ | 20 */ |
21 | 21 |
22 #ifndef SIM_FKT_C | 22 #ifndef SIM_FKT_C |
23 #define SIM_FKT_C | 23 #define SIM_FKT_C |
24 | 24 |
25 #include "config.h" | |
26 #include "fixedconf.h" | |
27 #include "condat-features.h" | |
28 | |
25 #define ENTITY_SIM | 29 #define ENTITY_SIM |
26 | 30 |
27 /*==== INCLUDES ===================================================*/ | 31 /*==== INCLUDES ===================================================*/ |
28 | 32 |
29 #include <string.h> | 33 #include <string.h> |
363 | 367 |
364 TRACE_FUNCTION ("FKT_Increase()"); | 368 TRACE_FUNCTION ("FKT_Increase()"); |
365 sw1sw2 = SIM_Increase ((UBYTE *)response, | 369 sw1sw2 = SIM_Increase ((UBYTE *)response, |
366 (UBYTE *)data, | 370 (UBYTE *)data, |
367 &size); | 371 &size); |
368 | 372 |
369 return FKT_convert_error (sw1sw2, size); | 373 return FKT_convert_error (sw1sw2, size); |
370 } | 374 } |
371 | 375 |
372 | 376 |
373 /* | 377 /* |
419 | 423 |
420 sw1sw2= SIM_ReadBinary ((UBYTE *)data, | 424 sw1sw2= SIM_ReadBinary ((UBYTE *)data, |
421 offset, | 425 offset, |
422 length, | 426 length, |
423 &size); | 427 &size); |
424 | 428 |
425 return FKT_convert_error (sw1sw2, size); | 429 return FKT_convert_error (sw1sw2, size); |
426 } | 430 } |
427 | 431 |
428 | 432 |
429 /* | 433 /* |
1268 { | 1272 { |
1269 | 1273 |
1270 USHORT size = 0; | 1274 USHORT size = 0; |
1271 USHORT sw1sw2; | 1275 USHORT sw1sw2; |
1272 USHORT error; | 1276 USHORT error; |
1273 | 1277 |
1274 | 1278 |
1275 TRACE_FUNCTION ("FKT_Envelope()"); | 1279 TRACE_FUNCTION ("FKT_Envelope()"); |
1276 | 1280 |
1277 sw1sw2 = SIM_Envelope (data_out, | 1281 sw1sw2 = SIM_Envelope (data_out, |
1278 data_in, | 1282 data_in, |
1288 | 1292 |
1289 if (error EQ SIM_NO_ERROR) | 1293 if (error EQ SIM_NO_ERROR) |
1290 { | 1294 { |
1291 if (data_out AND out_length) | 1295 if (data_out AND out_length) |
1292 { | 1296 { |
1293 if (sim_data.sim_data_len > 0) | 1297 if (sim_data.sim_data_len > 0) |
1294 { | 1298 { |
1295 stk_l_cmd = sim_data.sim_data_len << 3; | 1299 stk_l_cmd = sim_data.sim_data_len << 3; |
1296 out_length = (USHORT) (stk_l_cmd >> 3); | 1300 out_length = (USHORT) (stk_l_cmd >> 3); |
1297 error = FKT_GetResponse (data_out, out_length); | 1301 error = FKT_GetResponse (data_out, out_length); |
1298 } | 1302 } |
1299 } | 1303 } |
1300 } | 1304 } |
1301 | 1305 |
1302 return error; | 1306 return error; |