I have this available pins on my Epaper side and I made this connections according to your diagram.
VCC -> Not mentioned I assumed 3V3
GND -> Not mentioned I assumed GND
DIN -> A5
CLK -> A3
CS -> A2
DC -> A1
RST -> A0
BUSY -> D7
I then flashed this sample you provided: https://build.particle.io/build/5a7e2f45bac3fca9dc000c94
I don’t see any changes or anything appearing on my Epaper display. Are my Pin assumption for VCC and GND correct? Am I missing something?
Thank you!!!
That sample link doesn’t work for public use - your projects are private.
To let someone else have a look you need to share a public link to a snapshot
I’m wondering if this library works on the black only display. It mentions red and black in the code. And the display I’m using is black only.
This is the link of the display https://www.waveshare.com/wiki/1.54inch_e-Paper_Module1
I’m just trying to print a Hello World. The code gets flashed correctly to my Particle but nothing changes on the display.
AFAICT, the library layout of WaveShare is not targeted for flexibility/interoperability.
I think you can use the 29b (b/r/w) library for the 29 (b/w) by just using the single frame functions, but I’m quite convinced it won’t play well with the 1.54" display.
But as I found, as clumsy the stock libraries for their displays are, they should be able to build for Particle without alteration. I just couldn’t resist rewriting the most unsettling code portions.
@ScruffR Thank you so much! I’m gonna try with that library. 29b… How do I add it to my project on the particle cloud? Is already there or I need to download it from WaveShare and include it manually?
29b is for the 2.9" display. You said yours is 1.54" and I don’t think that the 2.9" lib will give you any recognisable image.
As I haven’t ported the 1.54 library, you will need to download it from WaveShare and copy-paste it into your project.
Hey @ScruffR thank you once again. I was able to download the library from:
and add it to an empty project https://go.particle.io/shared_apps/5a7fca526204ca298d0010a5
However, when trying to run it I’m getting all kind of errors. Am I doing anything wrong? @gedeondt I saw you were also trying to use a 1.54" Waveshare display, were you able to do it?
GxGDEP015OC1.h:62:1: expected class-name before '{' token
Which indicates that you are missing the class definition for GxEPD. Hence this commented code line
//#include "../GxEPD.h"
Since this header is not included chances are that every error that follows may go away, once you also add this definition and implementation to the project.
I just got a Waveshare 2.9" Module B inspired in part by your video. Unlike you, I could not get the code provided by Waveshare to compile and was wondering if you might share a link to your code.
I’ll have to have another look. For some reason these functions are commented out (who knows why I did that back then )
But you can try the EPaper29bRotate demo. This doesn’t seem to use these functions.
Also, there is a line in the main loop: if (!digitalRead(BTN)), that makes me think there is another connection I need to make. I did not see a reference to BTN anywhere else in the code.
BTN is the GPIO designation for the SETUP/MODE button on your device.
I’ll take apart my current ePaper project and figure what’s wrong.
Since I originally hadn’t published the library but only used it privately it may well be that I over-tweaked the lib to fit my own needs better, not double-checking the samples before later on publishing it on Web IDE
I’ve just now tried out the rotation demo and it worked for me, but since I’ve got my display soldered to my project I couldn’t test your connections.
This is how I have connected the display and set it up in code
//CLK = A3; // SPI CLK
//DI = A5; // SPI MOSI (master out slave in)
const int pCS = A2;
const int pRESET = D6;
const int pDC = D5;
const int pBUSY = D4;
Epd epd(SPI, pCS, pDC, pRESET, pBUSY);
I think the main point with your setup is that you are using A4 (MISO = master in slave out) which is the wrong communication direction. The µC is the master the display the slave.
BTW, I now remember why I commented these two functions.
The reason was that I intended to rewrite these functions to cater for screen rotations, but due to some unexpected memory layout for the data, it turned out to be a bigger task than I first anticipated, so I just moved on to get my project finished (which doesn’t need it) and then totally forgot about it