![]() |
| ||
| Need help with 8086 assembly language I am new to Microprocessor 8086. i should submit this assignment by monday evening. Can anybody help me with this question? Q1 Write an 8086 assembly language program that will compute: 2.0 * log10 X for x = 0.1, 1.0, 10.0, 100.5, 1000.0, and six other values using a loop. All values are in the single-precision (short real) format. Kindly help me. I am breaking my head like anything |
| ||
| Re: Need help with 8086 assembly language post the code you are writing. Are you allowed to use the math coprocessor for log and other math functions ? |
| ||
| Re: Need help with 8086 assembly language I would try using the FYL2X instruction, which computes: st(1) = st(1) * log2(st(0) Where log2 is logarithm to base 2. You can get from log base 2 to log base 10 with the formula: log10(x) = log2(x) * log10(2) |
| ||
| Re: Need help with 8086 assembly language Hi even im looking out the answer for the same question in case u know the answer or get it from some one kindly send it to me... |
| ||
| Re: Need help with 8086 assembly language .data short REAL4 0.1,1.0,10.0, 100.5, 1000.0, 400.0, 40.5, 60.6,8.9,10.1 count db 0ah .code Lea si, short Mov cl, count Loop1: ;moving the element to to ax register Mov ax, [si] ;Push ax into first position fld ax ;This instruction is used to find the logarithm of the top most element of the stack FLDLG2 ;Pop the element from the stack Fstp dl ;displaying the value Mov ah,02h Int 21h Loop Loop1 Mov ah,4ch Int 21h If u have any queries, just reply me |
| ||
| Re: Need help with 8086 assembly language Quote:
|
| ||
| Re: Need help with 8086 assembly language Quote:
|
| ||
| Re: Need help with 8086 assembly language Quote:
Q1 Write an 8086 assembly language program that will compute: 2.0 * log10 X for x = 0.1, 1.0, 10.0, 100.5, 1000.0, and six other values using a loop. All values are in the single-precision (short real) format. Kindly help me. I am breaking my head like anything[/quote] if u get the answer of this question plz mail me...... <snipped email> |
| ||
| Re: Need help with 8086 assembly language iam new to Microprocessor 8086. i should submit this assignment by 27th /04/2007i evening. Can anybody help me with this question? Q1 Write an 8086 assembly language program that will compute: 2.0 * log10 X for x = 0.1, 1.0, 10.0, 100.5, 1000.0, and six other values using a loop. All values are in the single-precision (short real) format. Kindly help me. I am breaking my head like anything if u get the answer of this question plz mail me...... <snipped email> it is urgent............... |
| ||
| Re: Need help with 8086 assembly language .data short REAL4 0.1,1.0,10.0, 100.5, 1000.0, 400.0, 40.5, 60.6,8.9,10.1 count db 0ah .code Lea si, short Mov cl, count Loop1: ;moving the element to to ax register Mov ax, [si] ;Push ax into first position fld ax ;This instruction is used to find the logarithm of the top most element of the stack FLDLG2 ;Pop the element from the stack Fstp dl ;displaying the value Mov ah,02h Int 21h Loop Loop1 Mov ah,4ch Int 21h |
| All times are GMT -4. The time now is 1:08 am. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC