Register

Add functions to Basic Casio programs

Topics on released projects. Only the author of a program should start a topic on it.
Senior Member
User avatar
Posts: 605
Joined: Sat Sep 15, 2012 6:59 am
Location: Krautland ****
Calculators: Casio fx-7400GII, Casio fx-7400GII (SH4), Casio fx-9750GII, Casio fx-9750GII (SH4), Casio fx-9860G, Casio fx-9860G SD, Casio fx-9860G Slim, Casio fx-9860GII SD, Casio fx-9860GII SD Power Graphic 2, Casio Classpad 330 plus, Casio fx-CG20, Casio fx-CG50, Casio Classpad fx-CP400

Postby SimonLothar » Wed May 16, 2012 5:22 pm

Purobaz wrote:Yes, but where can I get the compiled code ?

I do not know, which SDK you use. With CASIO SDK you have to use SHC.EXE, OPTLNK.EXE and possibly ASMSH.EXE separately.
You have to ensure, that the BASIC-extension's entry-code supports the interface of int PRGM_Send( short*opcode, char**program, TBCDvalue result[2] ).

Purobaz wrote:I can't redirect on this adress, only in changing opcode with syscall 0x0CB0 : int PRGM_Send( short*opcode, char**program, TBCDvalue result[2] ) ?

To redirect a syscall, the following steps have to be performed:
1. make a backup of your OS image
2. find the address of syscall 0x0CB0.
3. replace the bytes at this address with a far jump to the memory-address, which will contain the BASIC-extension-code (some fixed flash- or RAM-location; mind the alignment).
4. if the BASIC-extension should reside in the flash, copy the code into the target-address range (mind the limits), otherwise skip this step
5. adjust the checksum.
6. restore the OS image to your calculator
7. if the BASIC-extension should reside in RAM, use some G1A to load it into the RAM-range (mind the limits), otherwise skip this step
8. call PRGM_Send from out of a PRGM-program
I'll be back!

Member
User avatar
Posts: 33
Joined: Sat Apr 07, 2012 10:08 am
Location: France

Postby Purobaz » Wed May 16, 2012 5:38 pm

Thanks a lot, I'm going to try:)


[color="#FF0000"]EDIT[/color]
It's more difficult than I could imagine.

This is a small feedback :
1. done :D
2. I think I've found the syscall, see picture, but where is the offset ?
[ATTACH=CONFIG]46[/ATTACH]
3. I do not know how do this :mad:

7. I use Casio SDK. I have compiled my function and I will copy it at adress 0xA5600200. But how many bytes has a g1a file header ?
Attachments
adress.jpg
adress.jpg (0 Bytes) Viewed 17094 times

Member
User avatar
Posts: 33
Joined: Sat Apr 07, 2012 10:08 am
Location: France

Postby Purobaz » Wed May 16, 2012 11:09 pm

It's more difficult than I could imagine.

Member
Posts: 48
Joined: Mon Apr 23, 2012 3:58 am
Location: Chennai,India
Calculators: Casio fx-9750GII, Casio fx-9860G Slim, Casio fx-9860GII

Prgm 2 help

Postby nagarajan » Thu May 24, 2012 10:11 am

Hello all,

I have the PRGM 2 addin in my calculator.
I need some examples for the addin like reading the clock,displaying in smaller font size(like print mini) and some mathematical calculations.
How to create PRGM 2 files?
Please help friends.
:)

Member
User avatar
Posts: 33
Joined: Sat Apr 07, 2012 10:08 am
Location: France

Postby Purobaz » Thu May 24, 2012 10:55 am

Hi,

Thanks for try PRGM2, but it is not ready to use yet.
It's just a demo.

To answer your questions you should try examples that you can download here.
Sorry but currently the projet is only in french.

I'm going to work on it :eek:

Member
Posts: 48
Joined: Mon Apr 23, 2012 3:58 am
Location: Chennai,India
Calculators: Casio fx-9750GII, Casio fx-9860G Slim, Casio fx-9860GII

Postby nagarajan » Thu May 24, 2012 11:16 am

Welcome Purobaz.

Its a nice program.
Kindly help me in creating programs for the addin.

Member
User avatar
Posts: 33
Joined: Sat Apr 07, 2012 10:08 am
Location: France

Postby Purobaz » Thu May 24, 2012 9:51 pm

Just write 'PRGM2 at the beginning of your program.
Then call a function like this :
function_number -> F
While F:WhileEnd

Currently you can't display a small font size easily.
You should wait a month. I will release a new version more understandable.

Member
Posts: 48
Joined: Mon Apr 23, 2012 3:58 am
Location: Chennai,India
Calculators: Casio fx-9750GII, Casio fx-9860G Slim, Casio fx-9860GII

Postby nagarajan » Fri May 25, 2012 4:09 am

Purobaz wrote:Just write 'PRGM2 at the beginning of your program.
Then call a function like this :
function_number -> F
While F:WhileEnd

Currently you can't display a small font size easily.
You should wait a month. I will release a new version more understandable.


Wow a new version.
Go ahead all the best Purobaz.
Thanks for the help.

Senior Member
User avatar
Posts: 605
Joined: Sat Sep 15, 2012 6:59 am
Location: Krautland ****
Calculators: Casio fx-7400GII, Casio fx-7400GII (SH4), Casio fx-9750GII, Casio fx-9750GII (SH4), Casio fx-9860G, Casio fx-9860G SD, Casio fx-9860G Slim, Casio fx-9860GII SD, Casio fx-9860GII SD Power Graphic 2, Casio Classpad 330 plus, Casio fx-CG20, Casio fx-CG50, Casio Classpad fx-CP400

Postby SimonLothar » Fri May 25, 2012 6:48 am

Purobaz wrote:[color="#FF0000"]EDIT[/color]
It's more difficult than I could imagine.

This is a small feedback :
1. done :D
2. I think I've found the syscall, see picture, but where is the offset ?
[ATTACH=CONFIG]46[/ATTACH]
3. I do not know how do this :mad:

7. I use Casio SDK. I have compiled my function and I will copy it at adress 0xA5600200. But how many bytes has a g1a file header ?

Sry. EDITs do not trigger notifications and tend to be missed. I will answer this afternoon.
I'll be back!

Member
User avatar
Posts: 33
Joined: Sat Apr 07, 2012 10:08 am
Location: France

Postby Purobaz » Fri May 25, 2012 1:53 pm

Thanks for your help ;)

PreviousNext

Return to Released Projects

Who is online

Users browsing this forum: No registered users and 31 guests