Found another post related to this subject but did not find any answers from all the replies..
I'm attempting to write to a LCD12864 in SPI . Can't get an SPI.wirte() to work and the SPI.send doesn't do the job either.In the docs they are different but what I do not get is does the import from pyb and import from machine work independently can both be loaded?. Is the pyb version a low level and the machine calls it or visa versa. Bottom line like another post found on here I can get my program to find the SPI.write() function. Anyone out there can shed some light on how the 2 version of SPI import work...???
Thanks Denis
pyb SPI versus MACHINE SPI which to use or not to...
- pythoncoder
- Posts: 5956
- Joined: Fri Jul 18, 2014 8:01 am
- Location: UK
- Contact:
Re: pyb SPI versus MACHINE SPI which to use or not to...
The pyb library is specific to STM processors (e.g. the Pyboard). It includes some features specific to that hardware.
In general best practice is to use machine where possible, not least because such code can be ported to other MicroPython hardware.
In general best practice is to use machine where possible, not least because such code can be ported to other MicroPython hardware.
Peter Hinch
Index to my micropython libraries.
Index to my micropython libraries.