Need some newbie help please
- helder7
- Senior Member
- Posts: 369
- Joined: Tue Jan 03, 2012 11:24 pm
- Calculators: Casio Afx 1.0, Casio fx-9860GII SD, Casio Classpad 330, Casio fx-CG20, Casio Classpad fx-CP400
Re: Need some newbie help please
MrMagoo wrote:Ok excellent, can we add a select case control that allows the code to jump to various functions?
yes, using voids for the functions and something like this in getkey:
- Code: Select all
while(1){
GetKey( &key );
switch (key){
case KEY_CTRL_UP :
void1();
case KEY_CTRL_DOWN :
void2();
}
}
Also, how do we get an input from the user?
SDK doesnt have. But you can use mylib to do it.
SiO2 + CaCO3 ----------> CaSiO3 + CO2
- MrMagoo
- Member
-
- Posts: 44
- Joined: Tue Jul 02, 2013 11:57 am
- Location: London
- Calculators: Casio fx-7400G, Casio fx-7400G PLUS, Casio fx-7400GII, Casio fx-9750G, Casio fx-9750G PLUS, Casio fx-9860GII
Re: Need some newbie help please
Ok, so Ive tried the mylib, but keep getting this error
** L2310 (E) Undefined external symbol "_messageBox" referenced in "E:\Casio\Projects\Test\Debug\Test.obj"
Any ideas?
** L2310 (E) Undefined external symbol "_messageBox" referenced in "E:\Casio\Projects\Test\Debug\Test.obj"
Any ideas?
"The trouble with internet quotations, is that the majority are totally made up." - Abraham Lincoln 1863
- SimonLothar
- Senior Member
-
- 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
Re: Need some newbie help please
MrMagoo wrote:Ok, so Ive tried the mylib, but keep getting this error
** L2310 (E) Undefined external symbol "_messageBox" referenced in "E:\Casio\Projects\Test\Debug\Test.obj"
Any ideas?
Perhaps this
#include "mylib.h"
after
#include "fxlib.h"
is missing?
I'll be back!
- MrMagoo
- Member
-
- Posts: 44
- Joined: Tue Jul 02, 2013 11:57 am
- Location: London
- Calculators: Casio fx-7400G, Casio fx-7400G PLUS, Casio fx-7400GII, Casio fx-9750G, Casio fx-9750G PLUS, Casio fx-9860GII
Re: Need some newbie help please
I thought that, but they are both there.
I have copied them into both the include folders also, to be sure.
Still getting stuck
I have copied them into both the include folders also, to be sure.
Still getting stuck
"The trouble with internet quotations, is that the majority are totally made up." - Abraham Lincoln 1863
- SimonLothar
- Senior Member
-
- 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
Re: Need some newbie help please
did you include mylib.c into the project's source files?
I'll be back!
- MrMagoo
- Member
-
- Posts: 44
- Joined: Tue Jul 02, 2013 11:57 am
- Location: London
- Calculators: Casio fx-7400G, Casio fx-7400G PLUS, Casio fx-7400GII, Casio fx-9750G, Casio fx-9750G PLUS, Casio fx-9860GII
Re: Need some newbie help please
I hadn't, but I have now.
And Im still getting the same error.
And Im still getting the same error.
"The trouble with internet quotations, is that the majority are totally made up." - Abraham Lincoln 1863
- SimonLothar
- Senior Member
-
- 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
- MrMagoo
- Member
-
- Posts: 44
- Joined: Tue Jul 02, 2013 11:57 am
- Location: London
- Calculators: Casio fx-7400G, Casio fx-7400G PLUS, Casio fx-7400GII, Casio fx-9750G, Casio fx-9750G PLUS, Casio fx-9860GII
Re: Need some newbie help please
it wont currently build. I get this;
Executing Hitachi SH C/C++ Compiler/Assembler phase
set SHC_INC=E:\Casio\OS\SH\include
set PATH=E:\Casio\OS\SH\bin
set SHC_LIB=E:\Casio\OS\SH\bin
set SHC_TMP=E:\Casio\Projects\Test\Debug
"E:\Casio\OS\SH\bin\shc.exe" -subcommand=C:\Users\D~1.LAW\AppData\Local\Temp\hmk199B.tmp
Executing Hitachi OptLinker04 phase
"E:\Casio\OS\SH\bin\Optlnk.exe" -subcommand=C:\Users\D~1.LAW\AppData\Local\Temp\hmk6F59.tmp
** L2310 (E) Undefined external symbol "_stringSet" referenced in "E:\Casio\Projects\Test\Debug\Test.obj"
Optimizing Linkage Editor Abort
HMAKE MAKE UTILITY Ver. 1.1
Copyright (C) Hitachi Micro Systems Europe Ltd. 1998
Copyright (C) Hitachi Ltd. 1998
ERROR: Process failed with return code: 1
Build was not successful.
Executing Hitachi SH C/C++ Compiler/Assembler phase
set SHC_INC=E:\Casio\OS\SH\include
set PATH=E:\Casio\OS\SH\bin
set SHC_LIB=E:\Casio\OS\SH\bin
set SHC_TMP=E:\Casio\Projects\Test\Debug
"E:\Casio\OS\SH\bin\shc.exe" -subcommand=C:\Users\D~1.LAW\AppData\Local\Temp\hmk199B.tmp
Executing Hitachi OptLinker04 phase
"E:\Casio\OS\SH\bin\Optlnk.exe" -subcommand=C:\Users\D~1.LAW\AppData\Local\Temp\hmk6F59.tmp
** L2310 (E) Undefined external symbol "_stringSet" referenced in "E:\Casio\Projects\Test\Debug\Test.obj"
Optimizing Linkage Editor Abort
HMAKE MAKE UTILITY Ver. 1.1
Copyright (C) Hitachi Micro Systems Europe Ltd. 1998
Copyright (C) Hitachi Ltd. 1998
ERROR: Process failed with return code: 1
Build was not successful.
"The trouble with internet quotations, is that the majority are totally made up." - Abraham Lincoln 1863
- SimonLothar
- Senior Member
-
- 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
- MrMagoo
- Member
-
- Posts: 44
- Joined: Tue Jul 02, 2013 11:57 am
- Location: London
- Calculators: Casio fx-7400G, Casio fx-7400G PLUS, Casio fx-7400GII, Casio fx-9750G, Casio fx-9750G PLUS, Casio fx-9860GII
Re: Need some newbie help please
Ok sorry, didnt know what you meant 
This is as far as I have got, not loads of work, mostly copied and pasted from mylib example. But I thought this should start working by now. Thanks

- Code: Select all
#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include <string.h>
#include "fxlib.h"
#include "mylib.h"
//beforeRefresh is an example callback function
void callbackEvents(void* ptr)
{
double w,h,area;
struct Dialog* dlg;
struct DialogItem* item;
struct String* s;
dlg=(struct Dialog*)ptr;// cast ptr to dlg.
if(dlg->eventType==EVENT_BEFORE_REFRESH)
{
s=stringInit("",32);
item=dialogGet(dlg,2);//first edit box
w=atof(item->text->data);//w now holds the width
item=dialogGet(dlg,4);//second edit box
h=atof(item->text->data);//h now hold the height
area=w*h;
stringSprintf(s,"Area is:%f",area);
item=dialogGet(dlg,6);//the third label
stringSet(item->text,s->data);//sets the label text
stringFree(s);//frees temp string s
};
}
//****************************************************************************
// AddIn_main (Sample program main function)
//
// param : isAppli : 1 = This application is launched by MAIN MENU.
// : 0 = This application is launched by a strip in eACT application.
//
// OptionNum : Strip number (0~3)
// (This parameter is only used when isAppli parameter is 0.)
//
// retval : 1 = No error / 0 = Error
//
//****************************************************************************
int AddIn_main(int isAppli, unsigned short OptionNum)
{
unsigned int key;
int ret,w1,w2,w3,w4,w5;
double d1,d2,d3;
struct String* s1;
struct String* s2;
struct String* s3;
struct StringList* sl;
struct StringListNode* slnode;
char* bufp;
struct Dialog* dlg;
struct DialogItem* item;
messageBox("Press OK to enter","Welcome Screen");
Bdisp_AllClr_DDVRAM();
w1=execMenu("Cord,WCB,Offs,LclG,Intr,More");
stringSprintf(s1,"menu choice :%d",w1);
messageBox(s1->data,"You chose");
return 0;
}
#pragma section _BR_Size
unsigned long BR_Size;
#pragma section
#pragma section _TOP
int InitializeSystem(int isAppli, unsigned short OptionNum)
{
return INIT_ADDIN_APPLICATION(isAppli, OptionNum);
}
#pragma section
This is as far as I have got, not loads of work, mostly copied and pasted from mylib example. But I thought this should start working by now. Thanks
"The trouble with internet quotations, is that the majority are totally made up." - Abraham Lincoln 1863
Who is online
Users browsing this forum: No registered users and 11 guests