CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Search found 281 matches
CCS Forum Index
Author Message
  Topic: pic18F26k40 encoder
georpo

Replies: 4
Views: 5143

PostForum: General CCS C Discussion   Posted: Thu Oct 10, 2024 2:35 am   Subject: pic18F26k40 encoder
yes I know what you mean and how to do it.
I was loooking for a "better" way.
Is there an example of how to setup the timer1 as counter with external clock from RB1?

This is the first ...
  Topic: pic18F26k40 encoder
georpo

Replies: 4
Views: 5143

PostForum: General CCS C Discussion   Posted: Thu Oct 10, 2024 1:37 am   Subject: pic18F26k40 encoder
At 100% PWM I saw 625Hz on the encoder output, an interrupt about every 1.6mS but I do not like the idea.

The timer is a better solution but again I will have to keep track of the overflow. I am su ...
  Topic: pic18F26k40 encoder
georpo

Replies: 4
Views: 5143

PostForum: General CCS C Discussion   Posted: Wed Oct 09, 2024 1:54 pm   Subject: pic18F26k40 encoder
Hello,

I am using a pic18F26k40 to drive a DC motor with PWM.
The motor is used in my garage door and has a single output encoder.
So what would be the best way to measure the pulses from the enc ...
  Topic: dspic audio dac + DMA
georpo

Replies: 6
Views: 10169

PostForum: General CCS C Discussion   Posted: Mon Apr 08, 2024 3:20 am   Subject: dspic audio dac + DMA
yes I have read the 70211B.pdf

I have to tell you that I have an audio device playing wav files from SD for many years now. The DAC clock rate is set for 22050 and I just wait for the buffer to emp ...
  Topic: dspic audio dac + DMA
georpo

Replies: 6
Views: 10169

PostForum: General CCS C Discussion   Posted: Sun Apr 07, 2024 5:21 am   Subject: dspic audio dac + DMA
The DAC has 4 word deep FiFo.
My DMA buffer is 256 16bit words because each sector read from the SD card is 512 bytes.

Is the DMA supposed to feed the DAC from this buffer 4 words at the time unti ...
  Topic: dspic audio dac + DMA
georpo

Replies: 6
Views: 10169

PostForum: General CCS C Discussion   Posted: Fri Apr 05, 2024 5:09 pm   Subject: dspic audio dac + DMA
When I use the DAC without DMA I just wait for the buffer to empty then fill in some bytes and it is working good.
I just want to test the DMA to free my CPU but I can not see how to "sync" ...
  Topic: dspic audio dac + DMA
georpo

Replies: 6
Views: 10169

PostForum: General CCS C Discussion   Posted: Fri Apr 05, 2024 3:43 pm   Subject: dspic audio dac + DMA
Hello,
I have setup the dspic33fj64gp802 audio dac to work with continuous ping pong DMA playing wav from SD card.



#bank_dma
int16 AudioBufferA[256];
#bank_dma
int16 AudioB ...
  Topic: DSPIC33EP128GP506 CAN BAUD RATE
georpo

Replies: 12
Views: 14978

PostForum: General CCS C Discussion   Posted: Thu Jan 25, 2024 8:00 am   Subject: DSPIC33EP128GP506 CAN BAUD RATE
I just used a completely different example "EX_CAN_CCS_A_PCD.C"
compiled ok, no reception on th pic.

I will try 1k/2k resistors and order some MCP2562
  Topic: DSPIC33EP128GP506 CAN BAUD RATE
georpo

Replies: 12
Views: 14978

PostForum: General CCS C Discussion   Posted: Thu Jan 25, 2024 7:50 am   Subject: DSPIC33EP128GP506 CAN BAUD RATE
I have used many many times USB-TTL adapters that are 5V directly to UART '5v tolerant" RX pins with no problem.

OK, I will just add 2 resistors and see how it goes.
  Topic: DSPIC33EP128GP506 CAN BAUD RATE
georpo

Replies: 12
Views: 14978

PostForum: General CCS C Discussion   Posted: Thu Jan 25, 2024 7:38 am   Subject: DSPIC33EP128GP506 CAN BAUD RATE
Ttelmah,
I know that but the mcp2551 data out is connected to a 5v tolerant pin of the dspic.
I have done this before, I do not think this is the problem. Do you? should I add a voltage divider?
  Topic: DSPIC33EP128GP506 CAN BAUD RATE
georpo

Replies: 12
Views: 14978

PostForum: General CCS C Discussion   Posted: Thu Jan 25, 2024 6:21 am   Subject: DSPIC33EP128GP506 CAN BAUD RATE
it just means that there is no ACK from the other side.
I have the microchip analyzer sending data at 250k verified at the oscilloscope and on the mcp2551 data pin but my dspic never receives. on the ...
  Topic: DSPIC33EP128GP506 CAN BAUD RATE
georpo

Replies: 12
Views: 14978

PostForum: General CCS C Discussion   Posted: Thu Jan 25, 2024 3:55 am   Subject: DSPIC33EP128GP506 CAN BAUD RATE
Ttelmah thanks for the reply.
No matter what settings, the microchip can bus analyzer tool says "error passive" "TX ERR:128"
  Topic: DSPIC33EP128GP506 CAN BAUD RATE
georpo

Replies: 12
Views: 14978

PostForum: General CCS C Discussion   Posted: Thu Jan 25, 2024 3:29 am   Subject: DSPIC33EP128GP506 CAN BAUD RATE
Hello,

I am using a DSPIC33EP128GP506 with MCP2551.


#use delay(clock=120MHz, crystal=8MHz)



How can I set the baud rate to 500K?
What are the proper values for C1CFG1 and C1CFG ...
  Topic: atof error
georpo

Replies: 2
Views: 28913

PostForum: General CCS C Discussion   Posted: Fri Jan 27, 2023 3:28 am   Subject: atof error
Hi,

I am using a PIC24FJ128GL305
Compiler 5.104

I get a wrong value returned from atof()


fprintf(DBGUART,"\n\r%s",DatStr);
fprintf(DBGUART,"\n\r%2.2f",ato ...
  Topic: EX_PCD_BOOTLOADER PIC24FJ128GL305
georpo

Replies: 10
Views: 27062

PostForum: General CCS C Discussion   Posted: Wed Dec 28, 2022 4:27 am   Subject: EX_PCD_BOOTLOADER PIC24FJ128GL305

ROM used: 5890 bytes (7%)
Largest free fragment is 53502
RAM used: 1593 (19%) at main() level
...
 
Page 1 of 19 Goto page 1, 2, 3 ... 17, 18, 19  Next
All times are GMT - 6 Hours
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group