Skip to content

RP2: machine.spi LSB first is unsupported (also SoftSPI) #11404

@peterhinch

Description

@peterhinch

This arose here. The driver sets up a passed SPI instance as follows:

    def __init__(self, spi, pincs, height=240, width=400, vcom=False):
        spi.init(baudrate=2_000_000, firstbit=machine.SPI.LSB)
        self._spi = spi

which fails with NotImplementedError: LSB (hard SPI) or ValueError:firstbit must be MSB (soft SPI).

The constant LSB does exist.

>>> dir(SPI)
['__class__', '__name__', 'read', 'readinto', 'write', '__bases__', '__dict__', 'LSB', 'MSB', 'deinit', 'init', 'write_readinto']

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy