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.

[Moved] Are we allowerd to ask for code writing in this forum as a service?

Status
Not open for further replies.

casemod

Member level 1
Member level 1
Joined
Sep 21, 2013
Messages
34
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Visit site
Activity points
1,618
Code Writing - Frequency calculation for dsPIC

I need to set up the input capture peripheral on a PIC 33F using ASM language.

The objective is to convert a 0 to 1400Hz frequency from an external pin into a 11bit variable ranging from 0b0000000000 to 0b10101000110, however this needs to be calculated on a pulse by pulse basis (period between pulses) as to have a higher refresh rate at lower revs.

**broken link removed**
Attached is the code. Line 128 was set with a dummy 11 bit variable that sets the frequency to 150.8hz.
The resulting variable From the frequency calculation should replace this.
 
Last edited:

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top