Fixed bug 3579734.

git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4787 35acf78f-673a-0410-8e92-d51de3d6d3f4
master
gdisirio 2012-10-28 07:47:01 +00:00
parent 950cacebb0
commit 8d9074541c
13 changed files with 27 additions and 22 deletions

View File

@ -56,7 +56,7 @@ int main(void) {
chSysInit();
/*
* Activates the serial driver 2 using the driver default configuration.
* Activates the serial driver 1 using the driver default configuration.
*/
sdStart(&SD1, NULL);

View File

@ -327,7 +327,7 @@ int main(void) {
chSysInit();
/*
* Activates the serial driver 2 using the driver default configuration.
* Activates the serial driver 1 using the driver default configuration.
*/
sdStart(&SD1, NULL);

View File

@ -163,7 +163,7 @@ int main(void) {
System::Init();
/*
* Activates the serial driver 2 using the driver default configuration.
* Activates the serial driver 1 using the driver default configuration.
*/
sdStart(&SD1, NULL);

View File

@ -78,7 +78,7 @@ int main(void) {
chSysInit();
/*
* Activates the serial driver 2 using the driver default configuration.
* Activates the serial driver 1 using the driver default configuration.
*/
sdStart(&SD1, NULL);
@ -93,7 +93,8 @@ int main(void) {
/*
* Normal main() thread activity, in this demo it does nothing except
* sleeping in a loop and check the buttons state.
* sleeping in a loop and check the buttons state and run test procedure
* or print "Hello World!" on serial driver 1.
*/
while (TRUE) {
if (!palReadPad(IOPORT1, PA_BUTTON1))

View File

@ -209,7 +209,7 @@ int main(void) {
palSetGroupMode(GPIOC, PAL_PORT_BIT(0), 0, PAL_MODE_INPUT_ANALOG);
/*
* Initializes the PWM driver 1, re-routes the TIM3 outputs, programs the
* Initializes the PWM driver 3, re-routes the TIM3 outputs, programs the
* pins as alternate functions.
* Note, the AFIO access routes the TIM3 output pins on the PC6...PC9
* where the LEDs are connected.

View File

@ -335,7 +335,7 @@ int main(void) {
chSysInit();
/*
* Activates the serial driver 2 using the driver default configuration.
* Activates the serial driver 3 using the driver default configuration.
*/
sdStart(&SD3, NULL);

View File

@ -32,6 +32,7 @@ static msg_t Thread1(void *arg) {
(void)arg;
chRegSetThreadName("blinker");
while (TRUE) {
/* TODO */
// palSetPad(GPIOD, GPIOD_LED3); /* Orange. */
chThdSleepMilliseconds(500);
// palClearPad(GPIOD, GPIOD_LED3); /* Orange. */
@ -54,6 +55,8 @@ int main(void) {
halInit();
chSysInit();
/* TODO: inialize serial driver 1 or 2 */
/*
* Creates the example thread.
*/
@ -62,10 +65,10 @@ int main(void) {
/*
* Normal main() thread activity, in this demo it does nothing except
* sleeping in a loop and check the button state, when the button is
* pressed the test procedure is launched with output on the serial
* driver 2.
* pressed the test procedure is launched.
*/
while (TRUE) {
/* TODO */
// if (palReadPad(GPIOA, GPIOA_BUTTON))
// TestThread(&SD2);
chThdSleepMilliseconds(500);

View File

@ -151,8 +151,8 @@ static const SPIConfig spi2cfg = {
};
/*
* This is a periodic thread that does absolutely nothing except flashing
* a LED.
* This is a periodic thread that reads accelerometer and outputs
* result to SPI2 and PWM.
*/
static WORKING_AREA(waThread1, 128);
static msg_t Thread1(void *arg) {
@ -306,10 +306,8 @@ int main(void) {
NORMALPRIO + 10, Thread1, NULL);
/*
* Normal main() thread activity, in this demo it does nothing except
* sleeping in a loop and check the button state, when the button is
* pressed the test procedure is launched with output on the serial
* driver 2.
* Normal main() thread activity, in this demo it just performs
* a shell respawn upon its termination.
*/
while (TRUE) {
if (!shelltp) {

View File

@ -9,10 +9,10 @@ The demo runs on an ST STM32F4-Discovery board.
** The Demo **
The demo shows how to use PWM and SPI drivers using synchronous APIs. The PWM
driver the four board lets with the data read from the LIS320DL accelerometer.
driver the four board LEDs with the data read from the LIS320DL accelerometer.
The data is also transmitted on the SPI2 port.
By pressing the button located on the board the test procedure is activated
with output on the serial port SD2 (USART2).
A simple command shell is activated on virtual serial port SD2 via USB-CDC
driver (use micro-USB plug on STM32F4-Discovery board).
** Build Procedure **

View File

@ -11,8 +11,8 @@ I/O is simulated over TCP/IP sockets.
The demo listens on the two serial ports, when a connection is detected a
thread is started that serves a small command shell.
The demo shows how create/terminate threads at runtime, how listen to events,
how ho work with serial ports, how use the messages.
The demo shows how to create/terminate threads at runtime, how to listen to
events, how to work with serial ports, how to use the messages.
You can develop your ChibiOS/RT application using this demo as a simulator
then you can recompile it for a different architecture.
See demo.c for details.

View File

@ -53,7 +53,7 @@ void main(void) {
chSysInit();
/*
* Activates the serial driver 1 using the driver default configuration.
* Activates the serial driver 2 using the driver default configuration.
*/
sdStart(&SD2, NULL);

View File

@ -55,7 +55,7 @@ void main(void) {
chSysInit();
/*
* Activates the serial driver 1 using the driver default configuration.
* Activates the serial driver 2 using the driver default configuration.
*/
sdStart(&SD2, NULL);

View File

@ -82,6 +82,9 @@
*****************************************************************************
*** 2.5.1 ***
- FIX: Fixed double chSysInit() call in MSP430F1611 demo (bug 3581304)
(backported to 2.2.10 and 2.4.3).
- FIX: Fixed patch for various demos (bug 3579734).
- FIX: Fixed bug in abstract file interface (bug 3579660)(backported to
2.2.10 and 2.4.3).
- FIX: Fixed wrong type for UART config registers (bug 3579434).