NeoMatrix with Wemos D1 esp8266

As I tried to explain before, if you are using the pin labelled D5, you need to define the pin as "D5", not "5".

There are two versions of the Wemos D1, called the "D1" and the "D2 R2". There are some pin differences between them.

I have never owned a D1 or D1 R2. All the Wemos I own are D1 Mini, and there are three versions of those, the V1, V2 and Pro. Fortunately, unlike the D1 and D1 R2, there are no pinout differences between the version of the Mini.