turboscrew's Profile User Rating: -----

Reputation: 103 Stalwart
Active Posts:
677 (0.57 per day)
03-April 12
Profile Views:
Last Active:
User is offline Jun 08 2015 03:45 PM

Previous Fields

OS Preference:
Who Cares
Favorite Browser:
Who Cares
Favorite Processor:
Who Cares
Favorite Gaming Platform:
Who Cares
Your Car:
Who Cares
Dream Kudos:

Latest Visitors

Icon   turboscrew has not set their status

Posts I've Made

  1. In Topic: Mips Matrix question

    Posted 8 Jun 2015

    80	 la $a0, matBSize
    89	 lb $t2, ($a0)
    93	 addi $t1, $t1, -1
    94	 bnez $t1, C2

    If I read it right (hint: comments would have helped),
    You load the count in $t2, but decrement and test $t1.
  2. In Topic: Need help converting a decimal number to different bases

    Posted 8 Jun 2015

    Well, your code is 16-bit, and I don't see why you would need 32-bit stuff.
    The 16-bit instructions work on 16-, 32- and 64-bit machines.

    Basically you need an input-part and a "base"-loop.
    If I were you I'd use some "storage variables" (like your 'num').

    You read the digits with an int21h and output with another int21h (within the loop)
    just as you did in your code.

    In the loop you do the conversions:

    And please, use comments.
  3. In Topic: Need help converting a decimal number to different bases

    Posted 7 Jun 2015

    I quite didn't get it. What did you understand and what do you need help with?
  4. In Topic: How to code bootable calculator by using assembly?

    Posted 7 Jun 2015

    I'm not sure what you are asking, but I vaguely recall that the boot loads the stuff at 0x7C00. In your program you should make sure that your program is linked to that address and the entry point is at the beginning.

    Other folks, correct me if I remember wrong.
  5. In Topic: Getting and storing user input for matrices

    Posted 3 Jun 2015

    Yep, two nested loops - one for rows, the other for columns.
    The next question: integers or floats? (Maybe something else?)

    Here's a list of MARS system calls:
    You'll probably use those for input and output of the numbers.

    I don't remember MIPS instructions very well, but the basic idea is:

       la $s0, array           # matrix
       li $s1, 0               # row counter
       li $s2, 0               # column counter
       li  $v0, ?              # a system call number
       # maybe other system call parameters
       # now maybe $v0 contains the number read
       mul $s3, $s1, 24        # 6 columns x 4 bytes per number
       mul $s4, $s2, 4         # column
       add $t0, $s3, $s4       # offset from start of matrix
       add $t0, $t0, $s0       # matrix base address
       sw  $v0, 0($t0)         # store element into matrix
       addi $s2, $s2, 1        # increment column
       slti $t1, $s2, 6        # compare to 6
       bne  $t1, $zero, column_loop
       addi $s1, $s1, 1        # increment row
       slti $t1, $s1, 6        # compare to 6
       bne  $t1, $zero, row_loop

    Than may be wrong really, because I don't remember MIPS instructions very well,
    but I think the idea should be visible.

My Information

Member Title:
D.I.C Addict
52 years old
February 6, 1963
Nokia (town), Finland
Computers, programming, different branches of science, different branches of technology
Full Name:
Juha Aaltonen
Years Programming:
Programming Languages:
C, C++, Ada, Pascal, Lisp, Occam, Forth, Fortran and some assembly
(6502, 6800, 6809, 68000, 8085, 8031, PDP11/70, basics of C64x+ and PPC)

Contact Information




Page 1 of 1
  1. Photo

    askyy Icon

    06 Apr 2013 - 19:42
    would you like tom give me some help doing a programm in aseembly MIPS to verify if a number is power of two?
  2. Photo

    cool_moon Icon

    24 Apr 2012 - 03:49
    I didnt undestand ur explanation will u please explain it clearly
  3. Photo

    cool_moon Icon

    23 Apr 2012 - 23:29
    hi..Im new to lpc1768 please help me to understand the GPIO selection. how to select the gpio. i worked in mc8051 but it is entirly different from that. kindly help me
  4. Photo

    jon.kiparsky Icon

    10 Apr 2012 - 23:53
    Well, I've tried to set up a discussion. Let's see what comes of it.
    In answer to your question, I found my way to Finnish because my father is a Finn, and I'm interested in languages. As I say, though, Finnish defeated me pretty soundly.
Page 1 of 1