Rob,
You really don't state what the problem is, only that you see a problem.
A quick scan of the code leads to too many questions for me.
What are you trying to accomplish in the different...
Type: Posts; User: Tabsoft; Keyword(s):
Rob,
You really don't state what the problem is, only that you see a problem.
A quick scan of the code leads to too many questions for me.
What are you trying to accomplish in the different...
Rob,
Why don't you check this out.
'PIC 12F683
#CONFIG
__config _INTRC_OSC_NOCLKOUT & _WDT_OFF & _MCLRE_OFF & _CP_OFF
Rob,
Looks like you got it working.:)
One little thing though.
The Pause command is based upon the "DEFINE OSC" value to calculate the pause interval correctly.
It is a good practice to have...
Glad to hear if Rob.
You did not say what is happening only that it is not working.
I took a look at your code and several things jump out at me.
1. You are jumping into the deep end of the...
Exactly!:biggrin:
CMCON0 Register:
bit 6 COUT: Comparator Output bit.
This is the logic bit output of the Comparator.
CM: Comparator Mode = 100
7686
With this setup the comparator is...
Rob,
Yes you're not testing the correct bit for the actual output of the Comparator..
Look at my post again where I listed the things you need to correct. Look at item 2.
I point you to...
Rob,
One correction in my earlier post.
The CVref calculation for High Range is CVREF = (VDD/4) + (VR3:VR0 X VDD/32).
Using your input values of VDD=3.3 and VR3:VR0=8, the calculation will...
Rob,
Glad to see your working through the design and issues.
You are very close.:smile:
Here are a couple of things you need to correct.
1. VRCON: Look at the register description in...
Rob,
Yes Comparators can be confusing the 1st time using them on the PIC MCU.
First, have a read through this link. ...
Rob,
I don't think the ADC module will accomplish what you are attempting as Henrik stated in his last reply.
You should look into the Comparator of the PIC, again as Henrik suggested.
:D
Rob,
Glad it worked for you.
I'm not sure if you want/need to stay in the ISR as I don't know your final objective.
I would suggest using a flag to determine the state of the IOC.3 interrupt...
This should work for you. It works in my simulator.
Also, since PBP's ON INTERRUPT only checks to see if an interrupt has occurred between PBP commands, you may want to use a loop counter in your...