Go4Expert

Go4Expert (http://www.go4expert.com/)
-   Assembly Language Programming (ALP) Forum (http://www.go4expert.com/forums/assembly-language-programming-forum/)
-   -   sorting of numbers in assembly langauge programming (http://www.go4expert.com/forums/sorting-assembly-langauge-programming-t612/)

nikhil4u 4Mar2006 22:01

sorting of numbers in assembly language programming
 
hey shabbir i am new to assembly programming
can u send me a program for sorting of numbers in assembly language for 8085 microprocessor.

shabbir 5Mar2006 00:26

Re: sorting of numbers in assembly langauge programming
 
Hey its not good to give the complete program but will definitely help you with the main part of the program. It finds the maximum number and this can help you write the sort program
Code:

LXI H,ADD1
; Load 16 bit data in reg pair H
MOV C,M
; Load the counter to compare the total no of data to count
INX H
; Increment the address to point to the next location
MOV A,M
; Load the second no in the accumulator
ADD2:
; Label to jump at
INX H
; Increment the address to point to the next location
CMP M
; Compate the accumulator with the next no in series
JNC LESS:
; Jmp to a location with the comparision returns a carry
MOV A,M
; Move the content of the location M into the accumulator if the Jump fails
LESS:
; Label to jump at
DCR C
; decrement the counter
JNZ ADD2
; Jump if there is anything more to compare
STA ADD_OUTPUT
; Accumulator will contain the Max no and move to the out put address.

Thanks
Shabbir

coderzone 5Mar2006 11:13

Re: sorting of numbers in assembly language programming
 
Quote:

Originally Posted by nikhil4u
hey shabbir i am new to assembly programming
can u send me a program for sorting of numbers in assembly language for 8085 microprocessor.

Do you mind sharing the programs with us.

nikhil4u 5Mar2006 21:21

Re: sorting of numbers in assembly langauge programming
 
actually i have to complete an assignment in which i have to design an emulator in which sorting can be done as chief operation.

shabbir 5Mar2006 22:07

Re: sorting of numbers in assembly langauge programming
 
Quote:

Originally Posted by nikhil4u
actually i have to complete an assignment in which i have to design an emulator in which sorting can be done as chief operation.

The routine will help you to design the sort program.

khurramee1 30Oct2006 17:29

Re: sorting of numbers in assembly langauge programming
 
sir i need a programme in Assembly Language to find the maximum number and the minimum number from an array of ten numbers.

shabbir 30Oct2006 18:03

Re: sorting of numbers in assembly langauge programming
 
Quote:

Originally Posted by khurramee1
sir i need a programme in Assembly Language to find the maximum number and the minimum number from an array of ten numbers.

khurramee1 please post it as seperate thread for it to be seen by the experts.

emreee 12May2008 12:13

Re: sorting of numbers in assembly langauge programming
 
Please Help me,

I dont know 8085 assembly but this is a school homework

1) D recorder < 11
E recorder < 11
D+E = write to B recorder
But If Not E < 9 or Not D < 9 Then exit program

2) If (01H + 03H) < AAH Then
01H + 03H = write 2000H
Else
01H + 03H = write 3000H
End If

This Questions write to assemly 8085 language.Please Help me :embarasse

xpi0t0s 18Aug2008 13:15

Re: sorting of numbers in assembly langauge programming
 
How come you don't have knowledge of 8085 assembly but are getting homework projects anyway? If you're not on the course then you shouldn't get the homework. If you are on the course then (a) you've been goofing around and deserve to fail or (b) you'll know some 8085 in which case you can at least get started and show us where you're stuck, at which point we'll help.

digitalpbk 23Jun2009 12:19

Re: sorting of numbers in assembly langauge programming
 
thanx for the codes...
you can check out my online simulator and assembler and play with it to start coding for 8085 ... sadly i cant post any links here .. so it is at

labs.kitiyo.com/8085/

check out


All times are GMT +5.5. The time now is 10:43.