FreeRTOS Support Archive
The FreeRTOS support forum is used to obtain active support directly from Real
Time Engineers Ltd. In return for using our top quality software and services for
free, we request you play fair and do your bit to help others too! Sign up
to receive notifications of new support topics then help where you can.
This is a read only archive of threads posted to the FreeRTOS support forum.
The archive is updated every week, so will not always contain the very latest posts.
Use these archive pages to search previous posts. Use the Live FreeRTOS Forum
link to reply to a post, or start a new support thread.
[FreeRTOS Home] [Live FreeRTOS Forum] [FAQ] [Archive Top] [August 2008 Threads] waiting before Scheduler initPosted by bacalao on August 11, 2008 Hi all,
I have a kinda general question but here it is, first of all I am working with FreeRTOS v5.02, AT91SAM7X port and GCC compiler.
I would like to use the SPI (Serial Peripheral Interface) of this processor to send data to an LCD, so I initialize this peripheric in the main function, as in the prvSetupHardware() function in the demo. However, the initialization procedure requests to wait some dead time between commands are sent to LCD driver, and vTaskDelay() funtion is useless as i didnt have called thevTaskStartScheduler function (where system tick is set). I wouldn't like to modify the FreeRTOS kernel, so I am searching for any alternative. Any ideas ?
Thanks,
RE: waiting before Scheduler initPosted by Bob Cobb on August 11, 2008 Most LCD drivers have a ‘Ready’ bit that can be read from the bus. I would suggest looping on a read to this condition instead of a simple dead timed loop.
RE: waiting before Scheduler initPosted by Dave on August 11, 2008 You could also do the LCD initialization from a task. This is how the LMI examples work. Another way is to have a start up task that does the init then spawns all the other tasks before entering its while(1) loop or simply deleting itself.
RE: waiting before Scheduler initPosted by bacalao on August 11, 2008 Thank you very much for your answers. In my configuration it is not possible to read data from the LCD driver so the first proposal which is the proper way to do it itsn't possible... I saw the LMI LM3S102 demo and I think I will adopt Dave's solution, deleting the initialization task. Thanks again !
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|