Skip to content
This repository has been archived by the owner on Oct 15, 2024. It is now read-only.

mbed: SPI not working correctly #16

Closed
raffiniert opened this issue Jan 15, 2023 · 1 comment
Closed

mbed: SPI not working correctly #16

raffiniert opened this issue Jan 15, 2023 · 1 comment
Assignees
Labels
ArduinoCore-mbed Label for ArduinoCore-mbed UAY Unassigned yet

Comments

@raffiniert
Copy link

raffiniert commented Jan 15, 2023

Both clock frequencies are 8MHz, but the interval between one data transfer and the next is 20uS for mbed, while non-mbed is 6uS. The throughput is very different. The mbed’s SPI has poor performance.

(quote of msfuijno from https://forum.seeedstudio.com/t/spi-not-working-with-mbed-was-performance-of-xiao-with-sharp-memory-display/268057/7)

SPI is basically unusable on mbed.

On top, a Sharp Memory Display does not work at all using hardware SPI but does work in software SPI (same pins!). Maybe the waveform is not accurate enough (not square enough because they are not high power) in mbed. See the above thread.

@msfujino
Copy link

msfujino commented Jan 19, 2023

I knew that there were differences between “mbed” and “non-mbed” in terms of maximum SPI clock frequency (mbed:8MHz non-mbed:32MHz) and port drive mode (mbed:standard drive non-mbed:high drive). However, when I used an OLED display at the same 8 MHz, I found that there was a big difference in frame rate. I investigated and found that the main reason is that the 1-byte transfer time is 5.6uS for “non-mbed” and 19.5uS for “mbed”. The data transfer throughput is only 1/3.5.
See link below.
"https://forum.seeedstudio.com/t/xiao-nrf52840-mbeds-spi-performance-is-only-1-3-5-of-non-mbeds/268145"

@MatthewJeffson MatthewJeffson added UAY Unassigned yet ArduinoCore-mbed Label for ArduinoCore-mbed labels Oct 9, 2024
@Lesords Lesords self-assigned this Oct 14, 2024
@baorepo baorepo closed this as completed Oct 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
ArduinoCore-mbed Label for ArduinoCore-mbed UAY Unassigned yet
Projects
Status: Done
Development

No branches or pull requests

5 participants