Skip to: Site menu | Main content


Welcome to PSP-Programming.com, a place for developers to get together.

Welcome to the forums. Here you can find other user tutorials as well as homebrew releases and the source code repository. You can also ask for help with your code here and post your own homebrew!

PSP-Programming.com Forums
February 04, 2012, 10:09:43 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

News: Welcome to PSP-Programming.com
Home Help Search Shop Login Register
Digg This!
Pages: [1]
Print
Author Topic: Chat room / Shout Box ?  (Read 893 times)
Sargon
Newbie
*

Karma: +0/-0
Offline Offline

Posts: 13
700.16 points

View Inventory
Send Money to Sargon


View Profile
« on: May 09, 2010, 04:19:10 AM »

When I feel like asking quick question like syntax or why when I add a very bit of code then my PSP freezed I couldn't find any way to ask besides creating new topic, most ppl here hiding their E-mail.


anyway my question is I'm printing text with intraFont from 'general' char array,
sprintf(general,"Current Beats : %f",beat); worked
but sprintf(general,"Current Beats : %f ::: %d",beat,(int)beat/4);   freezed my PSP.
Logged


mowglisanu

C/C++ Developer
Hero Member
*

Karma: +36/-11
Offline Offline

Posts: 787
0.00 points

View Inventory
Send Money to mowglisanu


View Profile
« Reply #1 on: May 09, 2010, 12:55:01 PM »

A good way to test your code is psplink it tells you where and why your app crashes(usually)

don't worry psplink is part of the toolchain, still if you don't have it you can pull a compiled version from minpsp (use the oe version)

put psplink oe on your psp and compile your app as a prx

1. connect your psp to your computer(you might need the drivers PSP Type B Driver install - ENG)

2. start usbhostfs_pc from your project directory(from command prompt)

3. start pspsh from your project directory(from command prompt)

4. start psplink from your psp (you will see it connected in usbhostfs_pc and pspsh)

5. from pspsh type in the name of your app (ex musicapp.prx) and press enter to run

if you get an exception it'll tell you what type of exception, the address where it happened and what instruction caused it.

To find out where in the source code the error occurred type
Code:
calc $epc-$mod
and use the result in psp-addr2line like
psp-addr2line -fCe musicapp.elf result
Logged

Check out my:
 Audio lib
 Pmf Viewer
Pages: [1]
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
Page created in 0.093 seconds with 25 queries.
Sister Sites: Guitar Hero 4   BrokeniTouch.com