<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openmano-mpy/drivers/memory, branch master</title>
<subtitle>MicroPython source and hardware configuration for OpenMano</subtitle>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/'/>
<entry>
<title>drivers/memory/spiflash: Add MICROPY_HW_SPIFLASH_ENABLE_CACHE option.</title>
<updated>2020-12-18T02:39:32+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2020-12-17T05:59:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=e43a74a4db484ac1bfef191a8aa19b58b519efc6'/>
<id>e43a74a4db484ac1bfef191a8aa19b58b519efc6</id>
<content type='text'>
This only needs to be enabled if a board uses FAT FS on external SPI flash.
When disabled (and using external SPI flash) 4k of RAM can be saved.

Signed-off-by: Damien George &lt;damien@micropython.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This only needs to be enabled if a board uses FAT FS on external SPI flash.
When disabled (and using external SPI flash) 4k of RAM can be saved.

Signed-off-by: Damien George &lt;damien@micropython.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers, stm32: Support SPI/QSPI flash chips over 16MB.</title>
<updated>2020-01-30T02:18:38+00:00</updated>
<author>
<name>Andrew Leech</name>
</author>
<published>2020-01-28T03:59:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=30501d3f54fa642770faefa117b4c39d95aff549'/>
<id>30501d3f54fa642770faefa117b4c39d95aff549</id>
<content type='text'>
With a SPI flash that has more than 16MB, 32-bit addressing is required
rather than the standard 24-bit.  This commit adds support for 32-bit
addressing so that the SPI flash commands (read/write/erase) are selected
automatically depending on the size of the address being used at each
operation.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With a SPI flash that has more than 16MB, 32-bit addressing is required
rather than the standard 24-bit.  This commit adds support for 32-bit
addressing so that the SPI flash commands (read/write/erase) are selected
automatically depending on the size of the address being used at each
operation.
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Add support to put SPI flash in sleep mode.</title>
<updated>2019-07-02T15:27:33+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2019-07-02T15:03:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=8cde5faedd63ea1b21b7adef87e50e6a036c7e5a'/>
<id>8cde5faedd63ea1b21b7adef87e50e6a036c7e5a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Rework wait_sr to fix uninit'd variable 'sr'.</title>
<updated>2019-03-08T12:11:13+00:00</updated>
<author>
<name>Andrew Leech</name>
</author>
<published>2019-01-29T04:20:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=2ed2ec1711b13dd9a28bdc29ce8cba13ca7d503f'/>
<id>2ed2ec1711b13dd9a28bdc29ce8cba13ca7d503f</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Add functions for direct erase/read/write.</title>
<updated>2018-06-14T06:52:56+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2018-06-07T05:39:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=b78ca32476ba666412a9ec44a5453094fbf0dbd7'/>
<id>b78ca32476ba666412a9ec44a5453094fbf0dbd7</id>
<content type='text'>
These new API functions do not use the cache.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These new API functions do not use the cache.
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Rename functions to indicate they use cache.</title>
<updated>2018-06-14T06:52:56+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2018-06-07T05:36:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=cc5a94044a670f5acccefa8e04a38e81d882e087'/>
<id>cc5a94044a670f5acccefa8e04a38e81d882e087</id>
<content type='text'>
This patch renames the existing SPI flash API functions to reflect the fact
that the go through the cache:

    mp_spiflash_flush -&gt; mp_spiflash_cache_flush
    mp_spiflash_read  -&gt; mp_spiflash_cached_read
    mp_spiflash_write -&gt; mp_spiflash_cached_write
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch renames the existing SPI flash API functions to reflect the fact
that the go through the cache:

    mp_spiflash_flush -&gt; mp_spiflash_cache_flush
    mp_spiflash_read  -&gt; mp_spiflash_cached_read
    mp_spiflash_write -&gt; mp_spiflash_cached_write
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Move cache buffer to user-provided config.</title>
<updated>2018-06-14T06:52:56+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2018-06-07T04:09:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=86fe73beb99686ea15787f0603ad6f10a642054c'/>
<id>86fe73beb99686ea15787f0603ad6f10a642054c</id>
<content type='text'>
This patch removes the global cache variables from the SPI flash driver and
now requires the user to provide the cache memory themselves, via the SPI
flash configuration struct.  This allows to either have a shared cache for
multiple SPI flash devices (by sharing a mp_spiflash_cache_t struct), or
have a single cache per device (or a mix of these options).

To configure the cache use:

    mp_spiflash_cache_t spi_bdev_cache;

    const mp_spiflash_config_t spiflash_config =
        // any bus options
        .cache = &amp;spi_bdev_cache,
    };
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch removes the global cache variables from the SPI flash driver and
now requires the user to provide the cache memory themselves, via the SPI
flash configuration struct.  This allows to either have a shared cache for
multiple SPI flash devices (by sharing a mp_spiflash_cache_t struct), or
have a single cache per device (or a mix of these options).

To configure the cache use:

    mp_spiflash_cache_t spi_bdev_cache;

    const mp_spiflash_config_t spiflash_config =
        // any bus options
        .cache = &amp;spi_bdev_cache,
    };
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Fix bugs in and clean up read/write functions.</title>
<updated>2018-03-13T03:13:30+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2018-03-13T03:13:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=bdc875e602f687bf0fb28c3a18565ffec4157f59'/>
<id>bdc875e602f687bf0fb28c3a18565ffec4157f59</id>
<content type='text'>
mp_spiflash_read had a bug in it where "dest" and "addr" were incremented
twice for a certain special case.  This was fixed, which then allowed the
function to be simplified to reduce code size.

mp_spiflash_write had a bug in it where "src" was not incremented correctly
for the case where the data to be written included the caching buffer as
well as some bytes after this buffer.  This was fixed and the resulting
code simplified.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
mp_spiflash_read had a bug in it where "dest" and "addr" were incremented
twice for a certain special case.  This was fixed, which then allowed the
function to be simplified to reduce code size.

mp_spiflash_write had a bug in it where "src" was not incremented correctly
for the case where the data to be written included the caching buffer as
well as some bytes after this buffer.  This was fixed and the resulting
code simplified.
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Fix setting of QE bit in flash register.</title>
<updated>2018-03-11T00:25:38+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2018-03-11T00:25:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=cc34b087f0fe121afb03dcfe99180737ab925372'/>
<id>cc34b087f0fe121afb03dcfe99180737ab925372</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>drivers/memory/spiflash: Change to use low-level SPI object not uPy one.</title>
<updated>2018-03-09T13:59:43+00:00</updated>
<author>
<name>Damien George</name>
</author>
<published>2018-03-09T06:32:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.0x7felf.com/openmano-mpy/commit/?id=a739b35a9618c2dd2d25c9ef4d076eeffddbb399'/>
<id>a739b35a9618c2dd2d25c9ef4d076eeffddbb399</id>
<content type='text'>
This patch alters the SPI-flash memory driver so that it uses the new
low-level C SPI protocol (from drivers/bus/spi.h) instead of the uPy SPI
protocol (from extmod/machine_spi.h).  This allows the SPI-flash driver to
be used independently from the uPy runtime.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch alters the SPI-flash memory driver so that it uses the new
low-level C SPI protocol (from drivers/bus/spi.h) instead of the uPy SPI
protocol (from extmod/machine_spi.h).  This allows the SPI-flash driver to
be used independently from the uPy runtime.
</pre>
</div>
</content>
</entry>
</feed>
