Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

assembly problem pls help

Status
Not open for further replies.

Raju C

Member level 2
Joined
Sep 17, 2009
Messages
50
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Location
Bangalore
Activity points
1,558
Hi all..
how to implement 400.125MHz/25k=3E85 this in assembly program.. ?? i am using pic 18f .. pls help any one
 

One is a frequency, one is a number, what are you trying to do, divide a signal or do a math equation?

Brian.
 

actually i am entering frequency in GUI .. it is a variable that i am taking into my code ..and dividing it by 25k that is constant for all freq .. math equation only
 

I can't help you directly but the best source of information on math routines like that is at:

You will find all sorts of useful routines there.

Brian.
 

betwixt said:
I can't help you directly but the best source of information on math routines like that is at:

You will find all sorts of useful routines there.

Brian.
I tried this code but i am not getting where i am going wrong bcz not getting the exact answer??
 

It still isn't clear what you are trying to do. Are you dividing 400.125/25 or 400125000/25000 ?

I'm guessing you are working out a frequency division ratio, perhaps for a PLL synthesizer. If you want to know how many times 25KHz fits into 400.125MHz, the answer is 16,005 or 0x3E85 exactly, but you had that worked out already.

If it is a frequency divider and 25K is the divisor, scale it down by 1,000 times so everything is in KHz and the equation becomes 400125/25.

Brian.
 

Raju C said:
thanks to every one i got this ..
It is nice to know that you got the solution. But for information sake of all the intrested memebers, can you post your solution here? Cheers.
 

ya sure.. actually i was dividing frequency with BW , BW is constant , i wanted to take the result value in my code , but what i thought instead of calculating it in code i can create one GUI their i will enter frequency and BW also their i can divide just i have to take that value in the main code..
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top