Comments (6)
I think this might be because the SPI clock speed is too fast at 96Mhz.
When running the benchmark example sketch, I took pictures of a scope on the SCLK line:
at 72Mhz:
The SSD1351 datasheet says that the minimum time between clock signals is 50ns, as you can see the divisions between the lines on the scope is 50ns, and the 96mhz SPI clock is under 50ns, while the 72Mhz SPI clock seems to be just over 50ns.
from ssd_13xx.
it also seems that if I change the speed in _cpuCommons.h to 23999999 it just jumps back down to 16mhz, which seems like it might be too slow?
from ssd_13xx.
at 72mhz CPU, SPI clock goes at clockdiv4, which is 18mhz, which seems to be just what the SSD1351 likes....
from ssd_13xx.
It seems to work at 8mhz SPI Clock, at 96Mhz CPU clock
from ssd_13xx.
clockdiv4 have nothing to do, Teensy use SPI transactions so the speed is directly handled in Mhz.
Try open _includes/_cpuCommons and change the SPI speed for Teensy, so try set 18000000.
The SPI speed in SPI transaction mode is handled like this: internally the value is corrected to match the legal values in relation to CPU speed.
I have 2 different SSD1531 based display here (chinese made), both works at all speed and I'm really sure that are SSD1531, I exposed MISO pin and writed a small code to identify it.
Are you sure there's any resistor,condenser in the display SPI lines? Or there's any other SPI device sharing same line (like SD card)?
from ssd_13xx.
I understand that you can specify the frequency in megahertz, but that is just the max frequency upper limit. when you view the SCLK lines on an oscilloscope, You can see that the teensy will only send spi clock at certain frequencies, like 8mhz, 12mhz, 16mhz, 18mhz, 24mhz. At 96mhz fclock speed though, it will not send a 18mhz SPI clock.
The board I have does have other SPI devices such as an sd card, but these are all connected properly and do not interfere with other spi mode0 devices. There is a 50 ohm source termination resistor inline to match line resistance and to improve the SPI clock waveform and reduce clock reflections.
Are the SSD1351 displays you are using that work 128x128? The ones I am using are 128x96. They are attached to boards I designed based on the Solomon datasheet.
As I said before though, it seems to work fine when you limit the SPI clock to 12mhz. Perhaps the 128x96 display does not like 16mhz. I tried changing the internal oscillator offset (I am not at my computer right now so I don't have the hex address in front of me)
Also, yes I have tried to set the SPI clock directly to 18000000 in cpuCommons, but when I measure the frequency with a scope, it jumps back down to 16 mhz. I don't think SPI transactions allows you to change the SPI clock frequency any different than without using transactions, if it is supposed to do that, it is not working. I changed the SPI clock to a whole bunch of different values, but it would always default to 8,12,16,24 mhz when at 96mhz CPU clock speed. I think it is because 96 is not divisible by 18 without a fraction (96/18=5.3333)
Thank you for your work!
from ssd_13xx.
Related Issues (20)
- Nothing displaying
- scrolling HOT 2
- Support for ESP32? HOT 4
- How to reset display? HOT 1
- Arduino IDE Library Manager
- Request support for SSD1357
- Custom Fonts HOT 5
- Arduino UNO connection with SSD1331 0.95inch RGB OLED from Waveshare? HOT 3
- Request SSD_13XX compilation for Raspberry PI and/or NodeJS
- Does not work with more than one screen
- SSD1351 Showing white noise only
- Terrific work! Great with ESP32 HOT 8
- Compatibility with this module
- SSD1331 DIM mode is disabled/NORMAL mode doesn't recover from DIM HOT 1
- ESP32 on HSPI
- drawRect does not work if the rectangle ends at the last pixel of the screen
- Color codes in the library are wrong!!! HOT 1
- How to draw custom images HOT 4
- Wemos D1 mini pro HOT 2
- Can't drawIcon an icon which width/height equal to the width/height of the OLED? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ssd_13xx.