Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Munchor

Pages: 1 ... 12 13 [14] 15 16 ... 20
196
Computer Programming / MatLab
« on: January 31, 2011, 09:42:24 am »
Hello,

I decided to create a topic about Matlab.

Has anyone tried Matlab? Unlike Python, C and Java, etc, it's paid and it's not 'batteries included', so most extra libraries need to be paid and they cost a lot! Thousands of euros!

I'm going to have to learn it in the first year of university (if I go to computer engineer).

So, I will probably give it a try someday. For now, wondering if someone tried it already.

197
Computer Programming / C programming problem
« on: January 31, 2011, 09:08:38 am »
Code: [Select]
#include <stdio.h>

main() {
    // This program solves the f91 recursive function for a given number
    // This program was coded by David
    printf("Enter number: ");
    int input;
   
    scanf("%d",input);
   
    printf("The result is: ",f91(input));
   
    getch();
    return 0; 
}

int f91(n) {
    if (n<101)
    {
        return f91(f91(n+11));           
    }   
    else
    {
        return n-10;
    }
}

This is my code, which is supposed to solve the f91 function. I was converting it from my other python program here.

The program allows input but then crashes. Any idea?

198
Humour and Jokes / Scout, the Poster
« on: January 31, 2011, 09:01:16 am »
 :w00t:



I post quite a lot sometimes ;D

Don't look at my bookmarks.

199
TI Z80 / Z80 Tables Program
« on: January 31, 2011, 08:45:31 am »
I decided to port this to a computer program. There is a .html file in ticalc.org, but I started coding a C# program to learn and also because I don't know when it can be useful.

I am a crazy fan of portability, and the program is packed in a single .exe! So, it shouldn't be hard to try it.

There are buttons to go to Extended Instructions and Bit Instructions. IX/IY not finished for now.

Hope you enjoy them ;D

200
Math and Science / Catalan Number
« on: January 30, 2011, 06:16:50 pm »
Hey Omnimathematicians!

Who knows what the Catalan Number is?

You can find some information here.

But in other "images", this what a catalan number is:




So, I just made a simple program in C (I had already made one in python) to calculate the catalan number of n. However, I do not know how to do the opposite :S Can anyone help me with that?

Code: [Select]

#include <stdio.h>


main() {
     // This program was coded by David
     // This program calculates Catalan Numbers and the opposite too
     printf("Choose:\n");
     printf("1: Calculate Catalan Number of given number\n");
     printf("2: Calculate original number of Catalan Number\n");
     
     int answer;
     scanf("%d",&answer);
     
     if (answer == 1)
     {
          // Returns the catalan number
          printf("Enter original number: ");
          int input;
          scanf("%d",&input);
          int catalanNumber = factorial(2*input)/(factorial(input+1)*factorial(input));
          printf("The catalan number is: %d",catalanNumber);
     }
     if (answer == 2)
     {
          // Returns the original number
          printf("Not finished for now.");
          //printf("Enter catalan number: ");
          //int catalan;
          //scanf("%d,&cataln);
     }
     
     getch();
     return 0;
}

int factorial( int n )
{
    if ( n <= 1 )
        return 1;
    else
        return  n * factorial( n-1 );
}

The .exe is executable, try it!

201
Axe / Using the Asm( token inside a program
« on: January 24, 2011, 05:20:18 pm »
If you consider this a bug, then merge into bugs and reports please.

Code: [Select]
.UPROG
Asm(EF4045
Asm(FDCB00AE
Asm(EF7045
Asm(210100
0->I
While I<5
Asm(EF0745
I+1->I
End

(Not sure if this code is correct, it's just a sample one)

Code: [Select]
Asm(EF4045
Asm(FDCB00AE
Asm(EF7045
//The above lines could be changed to:
ClrDraw
DiagnosticOff

In fact, they're just the same thing. However, the second option runs much faster.

Now, the questions:

1. Is it just me?
2. Is it supposed to be like this?
3. If not, can it be fixed?

I think it is supposed to be this way, hence not considering it a 'bug'.

Thanks.

202
Math and Science / Factorials
« on: January 24, 2011, 09:42:18 am »
Hello everybody,

I know the basics of factorials:

5! = 5*4*3*2*1 = 120

However, I do not know about negative numbers and how to use them in calculus and what they are useful for.

I know floats won't work ;D

Can someone tell me some more about them?

203
The Axe Parser Project / ERR:
« on: January 22, 2011, 07:18:34 pm »
Hey guys,

I was wondering, what is the Axe error that most drives you mad while programming?

From all the list of errors, what is the one you most get? Discuss.
_________________________________________________________

The one I most get is probably BLOCK but it's easily fixable. The one I most dislike is ERR:DUPLICATE, I'm so used to it in PC programming :)




Also, is this topic in the right section?

204
Art / Shapes Icon Request
« on: January 22, 2011, 05:25:17 pm »
Hello everyone, I really need a shapes icon, what I mean is a 16*16 coloured icon with a rectangle and a triangle (one over the other) or maybe two or three shapes, but coloured, I need a simple sprite.

You'll be credited ;D

Also, .png file would be appreciated.

Thanks.

205
ASM / Hexadecimal Assembly Programming
« on: January 22, 2011, 09:02:57 am »
I decided to create a topic for general discussion about general Hexadecimal Assembly programming. It is also a small tutorial and introduction.

What is hexadecimal?

Hexadecimal is a numeration system just like the Arabic one (1,2,3,4,5,6,7,8,9.5,11,12,...) or the Roman one (I,II,III,IV,V,X,L,MCM,...).
So, a number like seven can have multiple representations, according to the system used, let's check the number 28:

Code: [Select]
28          // Arabic
XXVIII    // Roman
1C        // Hexadecimal
11100  // Binary

So, why don't we all use the same? It's hard for all of us to use the same and some are useful in some situations but terrible in others. For example, to make a sprite we use binary or hexadecimal, but to solve a giant equation using any of those would be a pain in the ass!

Now, when we make a Calculator Assembly program (ld hl,1 ....), it is written as a binary file (10010101011110101010...). Binary is hard to read, so we just use Hexadecimal.

So, why don't we just program in Assembly and leave the Hexadecimal alone?

If we know how to code in Hexadecimal instead of using an assembler that makes our assembly code hexadecimal, we can program assembly on the calculator. Of course, with Mimas (and some others) we can also do it, and Mimas is quite good. However, I'm not sure if we can all use Mimas or if it has everything there is.

So, I assume you already know Assembly if you're reading this, and here's an Assembly program:

Code: [Select]
.nolist
#include "ti83plus.inc"
.list
    .org $9D95-2
    .db $BB, $6D

Start:
  B_CALL (_ClrLCDFull)
  ld hl,1
  B_CALL (_DispHL)
  B_CALL (_GetKey)
 
  ret

This program will Clear the Screen, the set the hl registers to 1, then display "1" and wait for a key press until ending.

The hexadecimal code it creates (the data) is something like:

Code: [Select]
EF4045  // ClrLCDFull
210100  // Set hl registers to 1
EF0745  // Display the hl registers, so display "1"
EF7249  // Wait for key press
C9

Now, how do I know this is the hexadecimal code for it? One, I checked the ti83plus.inc, I use Assemblex and I learnt it with Xeda. Now, the ti83plus.inc has all the hexadecimal codes for BCalls. Assemblex converts hexadecimal to assembly and disassembles files which lets me learn it from other programs.

Also, for opcodes such as 210100, I check this all the time!

How to program in my calculator?

Press PRGM
Create a new PRGM
Call it whatever you want
Then make it like this:

Code: [Select]
AsmPrgm
EF4045
EF7045 // Turns the run diagnostic off  B_CALL (_RunIndicOff)
FDCB00AE  // Disables the 'Done' message when the program closes (res 5,(iy+0))
210100
EF0745
EF7249
C9




Never forget the ending C9 (ret), without it the calculator crashes!

Now you can run that program by typing Asm(prgmNAME.

You can also compile it so you can run it in shells and it is a true Assembly program: AsmComp(prgmNAME,prgmNAME2)

Note, in AsmComp( the names have to be different. Also, press 2ND + 0 to access the catalog and use the Asm( and AsmPrgm and AsmComp( tokens, don't just type them.

I hope more discussion comes, for now, skim through the pages I gave you and try and make something new.

Note: The language on this tutorial may be wrong. For example, I said that AsmComp( made it a real Assembly program, but it was already, it just compiles it.

Also, concerning Assemblex, the last uploaded version is still not perfect, so you can have a demo here, but the 'Export to 8xp' isn't finished, so it does not count as an upload. Assemblex is what I use to program in Hexadecimal in my computer.

Discuss!

EDIT: You can also use brandonw's website for more bcalls and information, I think. The Z80 tables with opcodes can also be found in ticalc.org.


EDIT 2:
I have a lot to tell you yet, but for now, here's another program:

Code: [Select]
EF4045
3E01
C60A
2600
6F
EF0745
EF7249
EF4045
C9

Who guesses what this does?

206
Casio Calculators / The Inside of a Casio Prizm
« on: January 21, 2011, 03:23:59 pm »
I was wondering how the inside of the Casio Prizm looks... Can anyone take a picture of it and post it here?

207
Gaming Discussion / Quake Live
« on: January 21, 2011, 01:46:03 pm »
Hello everyone,

I am a big fan of Quake Live, my account name is 'Dgdsmaster', so go ahead and add me if you play too.

I was wondering if anyone else played it? I really enjoy playing InstaCTF and InstaGib.

So, this is a topic kind of like 'Minecraft Anyone?'.

Also:

www.quakelive.com

Free Game!

Firefox: CHECK
Internet Explorer: CHECK
Chrome: CHECK (Only if you have the Quake Live Application it seems)
Others: I don't think it works in the other browsers.

208
Other Calculators / How do you feel about POTY Awards?
« on: January 18, 2011, 03:23:25 pm »
Hey guys, I was wondering how you feel about POTY awards :P

209
Casio Calculators / PRIZM Disassembler
« on: January 16, 2011, 07:34:40 am »
I just made a GUI Disassembler for the Casio Prizm, the first GUI disassembler for the Prizm actually  :w00t:

Below is a link for the setup.exe for Windows Users, but also the .pyw file for Linux/Mac OS users or even Windows Users looking for portability. Whoever decides to use this .pyw file will need Python and wxPython installed in their computers.

What can I say? I'll try to release a new version as soon as possible with an About Box, a Link to Omnimaga Forums and Support for reading .g3a files. All these 3 features are really easy to make, but I just don't have the time at the moment.

The source code may be public, but any release on the Net without my authorization is not allowed.

Also, this is a disassembler, not a detokenizer, so only Assembly files are supported.

But it's also quite good to have a Disassembler (even though it is quite basic) a few days after the Prizm was released.

Downloads:


Setup - http://www.megaupload.com/?d=T76Q1EK0
.exe - www.davidgom.co.cc/PrizmDisassembler.zip

Sorry for megaupload link, but I can't host it at my website at the moment, only the .zip. Would I be able to upload it to Omnimaga Downloads, though?

EDIT: I really recommend the .pyw file (install Python 2.6 and wxPython), it's much faster than the others.

EDIT 2: I really forgot to, but special thanks to JosJuice, for helping me with databases, no About Box in this version, but in the next one you'll be credited.

210
Casio Calculators / Casio Prizm - Kind of hiring patient person
« on: January 15, 2011, 03:54:37 pm »
Hello everyone,

if you are willing to help the PRIZM community;
if you want to be credited in the SH3 Disassembler I'm making;
if you are patient;
if you don't mind spending half an hour, or maybe two halfs, working in something boring...

Then you are the right person!

Code: [Select]
equates = ['Enii','9ndd']

prizmInstructions = ['Mov #imm, Rn','Mov.W @(disp*2+PC),Rn']

I need you to complete those lists (arrays in fact), according to the tables here. Stuff that is less than 4 characters long should be 0009 for example, or 00XX. You will be credited for the disassembler I'm making (which will be released right after someone does this for me).

I've been quite busy and can't do it, but trust me, this is all it takes for finishing a very basic disassembler and it is really easy! It just takes some time.


Note: Make all the instructions and equates in order, and don't include stuff like 'Data Transfer Instructions' and 'System Control Instructions'.

Then PM me or post the lists ;D As you can see, it's python syntax so, in BLEEP BLOOP it should look like:

equates = ['BLEEP','BLOOP','BLEEP','BLOOP','BLEEP]

Thanks Much!

Pages: 1 ... 12 13 [14] 15 16 ... 20