bladox.com Forum Index bladox.com
Turbo SIM Toolkit Adapter Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Turbo STK application debugging

 
Post new topic   Reply to topic    bladox.com Forum Index -> Development
View previous topic :: View next topic  
Author Message
hermano



Joined: 04 Feb 2008
Posts: 4

PostPosted: Mon Feb 04, 2008 11:12 am    Post subject: Turbo STK application debugging Reply with quote

Good morning everybody.
Im a new in Turbo STK programming. I'm uising winAVR and turbo-devel as the development tool. I would like to know how to debug a program.
Thanks.
________
STOCKS TO BUY NOW


Last edited by hermano on Thu Feb 24, 2011 7:43 am; edited 1 time in total
Back to top
View user's profile Send private message
pz
Guest





PostPosted: Sat Feb 09, 2008 8:06 am    Post subject: Reply with quote

You need to have:
- Turbo Lite 2
- Turbo Programmer 2
- optionaly also debug kernel that shows all ME-SIM communication (not needed but handy, L1 kernel is free, just send us request)

But with every kernel you can include dbsp(), dbc(), dbch(), dbih() calls to print strings or content of variables. These are sent from TL2 to programmer and via USB to PC. With "dbg" utility you can see the output, see what's going on in your application.

There is an example in developer documentation.
Back to top
hermano



Joined: 04 Feb 2008
Posts: 4

PostPosted: Thu Feb 14, 2008 4:45 pm    Post subject: Reply with quote

Ok. I have Turbo Lite 2 and Turbo Programmer 2 but I don't know how to proceed. Plz help.
________
Miscarriage / Still Birth Forums


Last edited by hermano on Thu Feb 24, 2011 7:44 am; edited 1 time in total
Back to top
View user's profile Send private message
pz
Guest





PostPosted: Mon Feb 18, 2008 8:06 am    Post subject: Reply with quote

Use dbs(), dbc(), dbch(), dbih() calls in your code. You have to uncommend #DEBUG in config.h - this makes these macros to work. That means you can have many such debug comments in your code and turn them on/off just by #DEBUG. Load application, plug turbo in to phone+TP2, start "dbg" application and turn on phone. You should see your debug messages.

Have you seen developer documentation? There is example.
Back to top
hermano



Joined: 04 Feb 2008
Posts: 4

PostPosted: Tue Apr 01, 2008 10:16 am    Post subject: dbg utility Reply with quote

Hi everyone.
I'm trying to use dbg utility, but i still have this message: Cannot Open IO port COM3 <error 2>. Use format \\.\COM#

Can anyone help me?
________
Jacques Swaters


Last edited by hermano on Thu Feb 24, 2011 7:44 am; edited 1 time in total
Back to top
View user's profile Send private message
hermano



Joined: 04 Feb 2008
Posts: 4

PostPosted: Thu Apr 03, 2008 11:18 am    Post subject: Reply with quote

Ok. I have'nt yet fix the problem, but i discovered the reason of this message.
The reason is that i load the application first, using cemu utility (cemu -v -d COM1 --app appfile.trb). But it don't terminate. I have the message.
Initializing device
Device initialized
Entering application mode


So when i launch the dbg utility (in another console) with command
dbg -d COM1, it can't use the COM1 port, because the cemu utility is still using it.

So this is my question: Why the cemu utility don't terminate, and what can i do to use it successfully.
Thanks
________
TWO AND A HALF MEN FORUM


Last edited by hermano on Thu Feb 24, 2011 7:44 am; edited 1 time in total
Back to top
View user's profile Send private message
pz
Guest





PostPosted: Sat Apr 05, 2008 7:31 am    Post subject: Reply with quote

hermano wrote:
Ok. I have'nt yet fix the problem, but i discovered the reason of this message.
The reason is that i load the application first, using cemu utility (cemu -v -d COM1 --app appfile.trb). But it don't terminate. I have the message.
Initializing device
Device initialized
Entering application mode


So when i launch the dbg utility (in another console) with command
dbg -d COM1, it can't use the COM1 port, because the cemu utility is still using it.

So this is my question: Why the cemu utility don't terminate, and what can i do to use it successfully.
Thanks


Do you have TL2+SIM (or TSIM+SIM) in programmer SIM connector? The above looks just like it's either not there or bad contact in prog SIM connector. cemu is waiting for ATR.

The prog SIM connector is quite bad quality, we use it for historical reason. The best way is leave the lock open and either press TL2 SIM shape with finger in there or use cloth peg to keep it in place.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    bladox.com Forum Index -> Development All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group