[README] Coarse sweep to use markup in READMEs.

This should improve online readability of the readme files.
This commit is contained in:
Piotr Esden-Tempski
2015-01-19 19:20:12 -08:00
parent ab7efee88e
commit 1c4ae95729
121 changed files with 411 additions and 609 deletions

View File

@@ -1,6 +1,4 @@
------------------------------------------------------------------------------
README
------------------------------------------------------------------------------
# README
This is the smallest-possible example program using libopencm3.

View File

@@ -1,6 +1,4 @@
------------------------------------------------------------------------------
README
------------------------------------------------------------------------------
# README
This is the smallest-possible example program using libopencm3.

View File

@@ -1,6 +1,4 @@
------------------------------------------------------------------------------
README
------------------------------------------------------------------------------
# README
This example demonstrates the following:
* Configuriong GPIO pins

View File

@@ -1,6 +1,4 @@
------------------------------------------------------------------------------
README
------------------------------------------------------------------------------
# README
This example demonstrates the ease of setting up the UART with libopencm3, and
using UART interrupts. UART echo is achieved by echoing back received characters
@@ -15,4 +13,4 @@ necessary to test this example. Just connect the debug USB cable and use a
terminal program to open the ACM port with 921600-8N1.
For example:
$ picocom /dev/ttyACM0 -b921600
picocom /dev/ttyACM0 -b921600

View File

@@ -1,6 +1,4 @@
------------------------------------------------------------------------------
README
------------------------------------------------------------------------------
# README
This example demonstrates the ease of setting up the UART with libopencm3.
Basic UART echo is achieved by using blocking reads and writes. The UART is set
@@ -11,4 +9,4 @@ necessary to test this example. Just connect the debug USB cable and use a
terminal program to open the ACM port with 921600-8N1.
For example:
$ picocom /dev/ttyACM0 -b921600
picocom /dev/ttyACM0 -b921600

View File

@@ -1,13 +1,11 @@
usb_bulk_dev
============
# README
This example demonstrates the following:
* Setting up polled USB endpoints
* Setting up interrupt driven USB endpoints
* Using the UART as a debug tool
USB module
----------
## USB module
Several USB endpoints are being set up:
* EP1 OUT - interrupt driven RX endpoint
@@ -26,7 +24,7 @@ from the USB driver. Since the USB driver is run entirely from the USB ISR,
these callbacks are essentially interrupt driven.
The polled endpoints try to continuously read and write data. Even though
usbd_ep_read/write_packet is called continuously for these endpoints, the USB
usbd\_ep\_read/write\_packet is called continuously for these endpoints, the USB
driver will only write a packet to the TX FIFO if it is empty, and only read
a packet from the FIFO if one has arrived.
@@ -34,8 +32,7 @@ The endpoints with a misaligned buffer show the performance drop when the buffer
is not aligned to a 4 byte boundary. 32-bit memory accesses to the buffer are
downgraded to 8-bit accesses by the hardware.
Clock change module
-------------------
## Clock change module
Pressing SW2 toggles the system clock between 80MHz, 57MHz, 40MHz, 30MHz, 20MHz,
and 16MHz by changing the PLL divisor.
@@ -49,8 +46,7 @@ possible to change the system clock while benchmarking the USB endpoint.
The current system clock is printed on the debug interface. This allows testing
the performance of the USB endpoints under different clocks.
Debug module
------------
## Debug module
printf() support is provided via UART0. The UART0 pins are connected to the
CDCACM interface on the ICDI chip, so no extra hardware is necessary to check
@@ -58,4 +54,4 @@ the debug output. Just connect the debug USB cable and use a terminal program to
open the ACM port with 921600-8N1.
For example:
> $ picocom /dev/ttyACM0 -b921600
picocom /dev/ttyACM0 -b921600

View File

@@ -1,16 +1,14 @@
------------------------------------------------------------------------------
README
------------------------------------------------------------------------------
# README
This example demonstrates the following:
* Using the USB controller
* Setting up a simple usb to serial converter (CDCACM)
File list:
* usb_cdcacm.c - implementation of the CDCACM subclass
* uart.c - implementation of UART peripheral
* usb_to_serial_cdcacm.c - glue logic between UART and CDCACM device
* usb_to_serial_cdcacm.h - common definitions
* `usb_cdcacm.c` - implementation of the CDCACM subclass
* `uart.c` - implementation of UART peripheral
* `usb_to_serial_cdcacm.c` - glue logic between UART and CDCACM device
* `usb_to_serial_cdcacm.h` - common definitions
Implements a USB-to-serial adapter, compliant to the CDCACM subclass. UART1 is
@@ -31,7 +29,7 @@ Note that the CTS pin is unused. The CDCACM specification does not define a way
to control this pin, nor does it define a way to switch between flow control
mechanisms.
The glue logic in usb_to_serial_cdcacm.c receives requests from both the UART
The glue logic in `usb_to_serial_cdcacm.c` receives requests from both the UART
and CDCACM interface, and forward them to their destination, while also
controlling the LEDs
@@ -41,28 +39,27 @@ The blue LED is lit while data is read from the UART.
The red and blue LEDs will only be lit for very short periods of time, thus they
may be difficult to notice.
------------------------------------------------------------------------------
Windows Quirks
------------------------------------------------------------------------------
On openening the CDCACM port Windows send a SET_LINE_CODING request with the
## Windows Quirks
On openening the CDCACM port Windows send a `SET_LINE_CODING` request with the
desired baud rate but without valid databits. To run this example CDDACM device
under Windows you have to return always 1 when a SET_LINE_CODING request is
under Windows you have to return always 1 when a `SET_LINE_CODING` request is
received. The following code should work:
File: usb_cdcacm.c
Function: cdcacm_control_request()
File: `usb_cdcacm.c`
Function: `cdcacm_control_request()`
case USB_CDC_REQ_SET_LINE_CODING:{
struct usb_cdc_line_coding *coding;
if (*len < sizeof(struct usb_cdc_line_coding))
{
return 0;
}
coding = (struct usb_cdc_line_coding *)*buf;
glue_set_line_coding_cb(coding->dwDTERate,
coding->bDataBits,
coding->bParityType,
coding->bCharFormat);
return 1;