Author |
Message |
Topic: Mixing Int8 and float in CCS C math |
rovtech
Replies: 9
Views: 16795
|
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: 16795
|
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: 16795
|
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: 16795
|
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: 9452
|
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: 12267
|
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: 52963
|
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: 52963
|
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: 52963
|
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: 52963
|
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: 52963
|
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: 52963
|
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
... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 52963
|
Forum: General CCS C Discussion Posted: Tue Apr 06, 2021 8:50 am Subject: Scrolling an LED display |
Thanks PCM Programmer; Those are suggestions I was hoping for, as well as pointing out my errors. I investigated each of them:
"Since you are not using #fast_io, CCS defaults to standard i/o mo ... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 52963
|
Forum: General CCS C Discussion Posted: Mon Apr 05, 2021 7:05 pm Subject: Scrolling an LED display |
Jay: I have Mostek 5002 and 5009, some of my favourite chips at one time.
Re my problem. I have LEDs on A7 and A6 using a simple circuit on a breadboard. All other pins floating (except MCLR and th ... |
Topic: Scrolling an LED display |
rovtech
Replies: 23
Views: 52963
|
Forum: General CCS C Discussion Posted: Mon Apr 05, 2021 11:44 am Subject: Scrolling an LED display |
I don't see how the Capacitive sensing module could affect a pin. It relies on a frequency change.
I'm going to set up another 16F722A on a plugin breadboard to experiment easier. I don't like shorti ... |
|