| View previous topic :: View next topic   | 
	
	
	
		| Author | 
		Message | 
	
	
		ptyhon
 
 
  Joined: 06 Jan 2010 Posts: 15
 
  | 
		
			
				 Posted: Wed Feb 17, 2010 9:45 am    Post subject: SIM Card Developemnt | 
				     | 
			 
			
				
  | 
			 
			
				Hi,
 
 
I had bought a TL2 and a TP. I want to develop an application that can interact with the phone SIM card interface. May i know how can i go about doing it? Can someone give me a brief description on what i need to do?
 
 
Thanks | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		pz Guest
 
 
 
 
 
  | 
		 | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		ptyhon
 
 
  Joined: 06 Jan 2010 Posts: 15
 
  | 
		
			
				 Posted: Tue Feb 23, 2010 9:34 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				I would like to develop an apps to intercept the communication between the SIM card and ME. basically like a proxy between the two.
 
 
I want all communication  packets to be handle by my program. 
 
 
Is this possible? | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		pz Guest
 
 
 
 
 
  | 
		
			
				 Posted: Mon Mar 01, 2010 9:45 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				Mmm, question is the "all communication packet". Do you really mean all/everything? That would be huge and somehow don't know why.
 
 
Turbo allows you to handle most, what we found logical/usable so far. | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		ptyhon
 
 
  Joined: 06 Jan 2010 Posts: 15
 
  | 
		
			
				 Posted: Wed Mar 03, 2010 6:42 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				Maybe not all communication packet   Basically i want to understand how the turbo lite2 work and how it can help me to develop and troubleshoot apps for mobile phone development.
 
 
I had some question:
 
 
1) how dbg.exe work to display the ME to SIM communciation? Is it becos there is a sim.trb loaded on the TL2 device. So whatever there is a known ME to SIM action, it will cause an interrupt and process the action programmed?
 
 
2) I understand that we are not able to know what apps are loaded on TL2. So i have this question on how the apps are treated inside the TL2. If I upload a program called "a.trb" on to TL2 and then later i upload "b.trb" onto TL2. Will this overwrite the "a.trb" that i had uploaded earlier or it will just addon to the program list on TL2 just like the TP?
 
 
 
Thanks | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		ptyhon
 
 
  Joined: 06 Jan 2010 Posts: 15
 
  | 
		
			
				 Posted: Wed Mar 03, 2010 9:42 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				| i am testing the apps on my own blackberry but cannot find the turbo program that i uploaded. Is it supported on this phone? | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		ptyhon
 
 
  Joined: 06 Jan 2010 Posts: 15
 
  | 
		
			
				 Posted: Fri Mar 05, 2010 9:28 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				Hi,
 
 
I wrote the following program but it does not work as what i intended.
 
 
This is how i tested it.
 
- I inserted the TL2 into the ME and also the TP.
 
- Using the TP i run dbg.exe to monitor the SIM and ME communication
 
- While i boot up the ME, i start to log down all the communication packet. But it seems that it does not trigger my handle_sim_file function at all during bootup.
 
 
Did i got the concept wrong?
 
 
void handle_sim_file (File_apdu_data * fa)
 
{
 
  u8 i;
 
 
  if (fa->ef == EF_IMSI && fa->ins == ME_CMD_READ_BINARY)
 
  {
 
    fa->p2 = 0xDE;
 
    fa->p1 = 0xAD;
 
    sim (fa->ins, fa->p1, fa->p2, fa->p3, fa->data);
 
  }
 
}
 
 
 
void action_menu (void *data)
 
{
 
  display_text_raw (t_Foo_en, Q_DISPLAY_TEXT_USER_CLEAR);
 
}
 
 
void turbo_handler (u8 action, void *data)
 
{
 
  switch (action)
 
  {
 
    case ACTION_INSERT_MENU:
 
      insert_menu (t_Foo_en);
 
      break;
 
    case ACTION_MENU_SELECTION:
 
      stk_thread (action_menu, data);
 
      break;
 
    case ACTION_FILE_APDU:
 
      handle_sim_file (data);
 
      break;
 
    default:
 
      break;
 
  }
 
} | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		pz Guest
 
 
 
 
 
  | 
		
			
				 Posted: Mon Mar 08, 2010 6:10 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				 	  | ptyhon wrote: | 	 		  | i am testing the apps on my own blackberry but cannot find the turbo program that i uploaded. Is it supported on this phone? | 	  
 
 
Yes, it should. Can you see the BLADOX->Setup? Start with helloworld to get familiar with how it works.
 
 
To your previous question - yes, it's multiapplication. | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		pz Guest
 
 
 
 
 
  | 
		
			
				 Posted: Mon Mar 08, 2010 6:11 am    Post subject:  | 
				     | 
			 
			
				
  | 
			 
			
				 	  | ptyhon wrote: | 	 		  Hi,
 
 
I wrote the following program but it does not work as what i intended.
 
 
This is how i tested it.
 
- I inserted the TL2 into the ME and also the TP.
 
- Using the TP i run dbg.exe to monitor the SIM and ME communication
 
- While i boot up the ME, i start to log down all the communication packet. But it seems that it does not trigger my handle_sim_file function at all during bootup.
 
 
Did i got the concept wrong?
 
 
void handle_sim_file (File_apdu_data * fa)
 
{
 
  u8 i;
 
 
  if (fa->ef == EF_IMSI && fa->ins == ME_CMD_READ_BINARY)
 
  {
 
    fa->p2 = 0xDE;
 
    fa->p1 = 0xAD;
 
    sim (fa->ins, fa->p1, fa->p2, fa->p3, fa->data);
 
  }
 
}
 
 
 
void action_menu (void *data)
 
{
 
  display_text_raw (t_Foo_en, Q_DISPLAY_TEXT_USER_CLEAR);
 
}
 
 
void turbo_handler (u8 action, void *data)
 
{
 
  switch (action)
 
  {
 
    case ACTION_INSERT_MENU:
 
      insert_menu (t_Foo_en);
 
      break;
 
    case ACTION_MENU_SELECTION:
 
      stk_thread (action_menu, data);
 
      break;
 
    case ACTION_FILE_APDU:
 
      handle_sim_file (data);
 
      break;
 
    default:
 
      break;
 
  }
 
} | 	  
 
 
You have to register what file (i.e. EF_IMSI in this case) you want to handle. Look at fakesim source, it's there. | 
			 
		  | 
	
	
		| Back to top | 
		 | 
	
	
		  | 
	
	
		 |