Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT




Loading

pic24f / explorer 16 rate is SLOW

Posted by matt on April 24, 2011
Ok, so I ran the explorer demo, both the board and FreeRTOS right out of the box, no modifications, and everything seemed alright. I modified the demo code, stripped it of its tasks, and created one simple task
void vTaskFunction( void * pvParameters )
{
/* Block for 1000ms. */
const portTickType xDelay = 1000 / portTICK_RATE_MS;

for( ;; )
{
LATA = ~LATA;
vTaskDelay( xDelay );
}
}

to toggle the LED's on port a.

Everything works, however, instead of taking 1000 milliseconds (1 second) blocks for about 8 seconds. I have not modified any other settings for it to work like this. A block of 2 ms is still visible to the naked eye.

I can modify PIC configuration bits and oscillator settings, change the configCPU_CLOCK_HZ from 32000 up to 16000000, and see very little change.

If you need me to post more code or any configuration details please let me know.
Thanks

RE: pic24f / explorer 16 rate is SLOW

Posted by Richard on April 25, 2011
“I can modify PIC configuration bits and oscillator settings, change the configCPU_CLOCK_HZ from 32000 up to 16000000”


I'm not sure I understand this. The default setting (the setting in the official demo) is 16000000, so do you mean set it to 32000 *from* 16000000, rather than the other way around.

When using MPLAB, there is the choice to configure the PIC24 fuse settings either through the MPLAB IDE, or from the source code using #pragmas. I think, from memory, that demo configures the PIC24 device fuse settings through the MPLAB IDE. Have you changed that in the project? If you are no longer using MPLAB for fuse setting configurations you will have to add the required #pragmas directly in the code to get the device running at the expected speed.

Regards.

RE: pic24f / explorer 16 rate is SLOW

Posted by matt on April 25, 2011
Sorry, I meant that I can modify that setting to almost any value and see very little difference, not sure if that is even related or not. I am still using MPLAB, are fuse settings another word for configuration bits? Im fairly certain I tried running it unmodified, and with a variety of other settings, though I try again. Ill be able to work on this more tomorrow afternoon, until then is there anything else I should look at?

RE: pic24f / explorer 16 rate is SLOW

Posted by Richard on April 26, 2011
Yes - I meant the configuration bits. I was getting the terminology mixed up with AVRs I think.

Regards.


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

FreeRTOS kernel V10 is available for immediate download. Now MIT licensed.


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS