@@ -63,8 +63,8 @@ used for communication with a device. A typical driver will create the buffer in
6363constructor and use it in its I/O methods which will be called repeatedly.
6464
6565The MicroPython libraries typically provide support for pre-allocated buffers. For
66- example, objects which support stream interface (e.g., file or UART) provide `read() `
67- method which allocates new buffer for read data, but also a `readinto() ` method
66+ example, objects which support stream interface (e.g., file or UART) provide `` read() ` `
67+ method which allocates new buffer for read data, but also a `` readinto() ` ` method
6868to read data into an existing buffer.
6969
7070Floating Point
@@ -109,10 +109,10 @@ the 10K buffer go (be ready for garbage collection), instead of making a
109109long-living memoryview and keeping 10K blocked for GC.
110110
111111Nonetheless, `memoryview ` is indispensable for advanced preallocated buffer
112- management. `readinto() ` method discussed above puts data at the beginning
112+ management. `` readinto() ` ` method discussed above puts data at the beginning
113113of buffer and fills in entire buffer. What if you need to put data in the
114114middle of existing buffer? Just create a memoryview into the needed section
115- of buffer and pass it to `readinto() `.
115+ of buffer and pass it to `` readinto() ` `.
116116
117117Identifying the slowest section of code
118118---------------------------------------
@@ -326,7 +326,7 @@ standard approach would be to write
326326
327327 mypin.value(mypin.value() ^ 1 ) # mypin was instantiated as an output pin
328328
329- This involves the overhead of two calls to the ` Pin ` instance's :meth: `~machine.Pin.value() `
329+ This involves the overhead of two calls to the :class: ` ~machine. Pin ` instance's :meth: `~machine.Pin.value() `
330330method. This overhead can be eliminated by performing a read/write to the relevant bit
331331of the chip's GPIO port output data register (odr). To facilitate this the ``stm ``
332332module provides a set of constants providing the addresses of the relevant registers.
0 commit comments