Author |
Message |
Topic: Fast ADC for 16F PIC needed |
rovtech
Replies: 3
Views: 751
|
Forum: General CCS C Discussion Posted: Mon Feb 24, 2025 5:55 pm Subject: Fast ADC for 16F PIC needed |
I think I need the 10 bits to read the peak voltage (rectifier and capacitor off the "Collector voltage" supply). Then a divider to 5v maximum for 200v.
I might be reading 1 volt or 200 vol ... |
Topic: Fast ADC for 16F PIC needed |
rovtech
Replies: 3
Views: 751
|
Forum: General CCS C Discussion Posted: Mon Feb 24, 2025 3:21 pm Subject: Fast ADC for 16F PIC needed |
The 16F1938 data sheet says to use fosc/16 for a 16 MHz clock but the .h file has ADC_CLOCK_DIV_16
I assume these are the same thing and refer to the PIC clock and not the ADC clock.
Is it OK to ke ... |
Topic: Fast ADC for 16F PIC needed |
rovtech
Replies: 3
Views: 751
|
Forum: General CCS C Discussion Posted: Mon Feb 24, 2025 11:10 am Subject: Fast ADC for 16F PIC needed |
Can someone suggest a PIC (with pins, no surface mount) that has a fast ADC conversion time in the order of 10 uSec. I would prefer 16Fxxx.
Surface mount is not out of the question but more difficult ... |
Topic: Mixing Int8 and float in CCS C math |
rovtech
Replies: 9
Views: 21653
|
Forum: General CCS C Discussion Posted: Fri Mar 17, 2023 6:31 pm Subject: Mixing Int8 and float in CCS C math |
To get a PWM frequency of 50 Hz compatible with RC servos I had to use 31.25 kHz and a PR2 of 156. I measured the time for a loop of While (1) without the math, with the math, and with the math and ca ... |
Topic: Mixing Int8 and float in CCS C math |
rovtech
Replies: 9
Views: 21653
|
Forum: General CCS C Discussion Posted: Thu Mar 16, 2023 9:17 am Subject: Mixing Int8 and float in CCS C math |
Thank you all, these are exactly the ideas I was hoping for but easier than I anticipated.
The problem of slow clock I am using got me re-thinking where to do the math. Briefly, my submersible ROV ha ... |
Topic: Mixing Int8 and float in CCS C math |
rovtech
Replies: 9
Views: 21653
|
Forum: General CCS C Discussion Posted: Wed Mar 15, 2023 6:18 pm Subject: Mixing Int8 and float in CCS C math |
Thank you, I use MPLAB 8.92
I read the link but see a problem. My clock is 32kHz so this may not work.
I wasn't looking for another project but appreciate learning about it and will try it when I ha ... |
Topic: Mixing Int8 and float in CCS C math |
rovtech
Replies: 9
Views: 21653
|
Forum: General CCS C Discussion Posted: Wed Mar 15, 2023 3:52 pm Subject: Mixing Int8 and float in CCS C math |
Doing math in CCS C
Y = mX + B
where Y and X are 8 bit integers (max 255), B is a constant 35, and m is a fraction 0.374
X and B get promoted in the expression to float for the evaluation, and the ... |
Topic: OT Intelligent Actuator IA-S-SEL-60 |
rovtech
Replies: 0
Views: 11086
|
Forum: General CCS C Discussion Posted: Fri Aug 20, 2021 7:25 am Subject: OT Intelligent Actuator IA-S-SEL-60 |
My apologies for this Off Topic.
Does anyone have experience with a SHIMIZU KIDEN INTELLIGENT ACTUATOR Controller IA-S-SEL-60 which can be seen here
https://www.ebay.ca/itm/112471329721
I bought th ... |
Topic: PIC problems |
rovtech
Replies: 2
Views: 14213
|
Forum: General CCS C Discussion Posted: Thu Aug 12, 2021 9:33 am Subject: PIC problems |
In another forum I read
"Microchip PIC, for example, are infamous for working even when part of the GPIO bank is toasted."
Is this true? Which family?
I have never experienced this. |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 61896
|
Forum: General CCS C Discussion Posted: Wed Apr 07, 2021 11:53 am Subject: Scrolling an LED display |
Thanks again Jerson;
I did not understand the SWAPF,22,w instruction. I did not know how many bits in a nibble. Now I see it swaps the four upper bit with the four lower bits so 0b00000010 becomes 0b ... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 61896
|
Forum: General CCS C Discussion Posted: Wed Apr 07, 2021 10:24 am Subject: Scrolling an LED display |
Thanks Jerson;
I investigated and printed the Mid-range MCU family instruction set.
Several things bother me:
Why are the operations carried out on the PORT_A?
Why are only two RLF 05,f shown? I a ... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 61896
|
Forum: General CCS C Discussion Posted: Tue Apr 06, 2021 4:52 pm Subject: Scrolling an LED display |
8008 in good shape are $20 ea and more like $100 if the gold ones. I have not checked for years. I had a big stash of Mitel 8008 that I got from Ford surplus when he shut down and I was selling them f ... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 61896
|
Forum: General CCS C Discussion Posted: Tue Apr 06, 2021 2:00 pm Subject: Scrolling an LED display |
For what it is worth here is the .lst that is relevant for someone who still remembers assembly. I used to use it on an Intel 8008 chip.
OOPS, wrong file. I will edit again in a second
Here it is:
... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 61896
|
Forum: General CCS C Discussion Posted: Tue Apr 06, 2021 1:48 pm Subject: Scrolling an LED display |
I never knew that and I have been using the 16F722 for many years!
It took a while to find out what VCAP meant because a search of the CCS manual turned up nothing. I found it on the data sheet but t ... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 61896
|
Forum: General CCS C Discussion Posted: Tue Apr 06, 2021 9:04 am Subject: Scrolling an LED display |
Thanks Jerson;
Interesting fact. The following works.
// main loop
while (1) // endless loop
{
for(i=0;i<=3;i++) // cycle through digits
... |
|