I2S-parallel example: Drive a 64x32 display

codetastic
Posts: 4
Joined: Fri Oct 12, 2018 10:02 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby codetastic » Sat Oct 13, 2018 1:27 am

embedded-creations wrote:I got I2S Parallel working in 8-bit mode so the SmartMatrix Library can refresh the panel with I2S data stored in uint8_t instead of uint16_t, cutting the RAM needed to hold the refresh buffer in half. I made the modifications inside SmartMatrix Library and not Sprite_TM's I2S Parallel example, but for anyone that needs it, hopefully this GitHub commit gets you going in the right direction (it’s not well documented in the reference manual and what I have working seems like a bit of a hack!):

https://github.com/pixelmatix/SmartMatr ... 05546c0e78
Hi EC,

I can't get this to work at all. Are you able to provide your project code?

embedded-creations
Posts: 13
Joined: Thu Feb 15, 2018 11:22 am

Re: I2S-parallel example: Drive a 64x32 display

Postby embedded-creations » Thu Oct 18, 2018 12:51 pm

The link you quoted is to a commit in my project code repository, so you're close. This is the full project code:

https://github.com/pixelmatix/SmartMatrix/tree/teensylc

codetastic
Posts: 4
Joined: Fri Oct 12, 2018 10:02 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby codetastic » Mon Oct 22, 2018 9:40 am

Thank you for that.

However, what I want to understand is how I can get this to work in a simpler example, such as the original I2S Parallel DMA example?

https://github.com/pixelmatix/esp32_I2s ... aLedMatrix

If your commit as what are the difference, it seems on face value all that needs to change is set the DMA mode to 8 bit, and then re-order the bytes before they go into the buffer, but I can't get this to work and only ever get a garbled or blank display.

Any chance you could quickly hack the DMA example ? Thank you!

Code: Select all

                        if(k%4 == 0){
                            p->data[(i+k)+2] = v;
                        } else if(k%4 == 1) {
                            p->data[(i+k)+2] = v;
                        } else if(k%4 == 2) {
                            p->data[(i+k)-2] = v;
                        } else { //if(k%4 == 3)
                            p->data[(i+k)-2] = v;
                        }


codetastic
Posts: 4
Joined: Fri Oct 12, 2018 10:02 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby codetastic » Tue Oct 23, 2018 7:11 am

For those that might be interested... I have turned this experimental code into an Arduino Adafruit_GFX compatible library, to allow for simple graphics and text using DMA. I have tested this with a 64x32 Matrix.

https://github.com/mrfaptastic/ESP32-RG ... el-I2S-DMA

embedded-creations
Posts: 13
Joined: Thu Feb 15, 2018 11:22 am

Re: I2S-parallel example: Drive a 64x32 display

Postby embedded-creations » Tue Oct 23, 2018 11:14 am

all that needs to change is set the DMA mode to 8 bit
Make sure that you make all the changes needed to put the DMA in 8 bit mode, they're all in that commit, but changes are made in several places.

djRimzi
Posts: 1
Joined: Tue Dec 25, 2018 3:41 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby djRimzi » Tue Dec 25, 2018 3:55 pm

rudi ;-) wrote:
Sat Dec 02, 2017 2:51 am
@wobblyboots
txs again. few hours after, i figured (indexing) it out now. all data fly to the right pixel, line, row, column :mrgreen:

64x32_ok_now.jpg

@jeroen
txs again

keep this in mind - this is a great example for I2S, shift, latches, and in RTOS for semaphore.( update, give and more )
i try to make few changes now for an expand ( more clients, more panels.. )

best wishes
rudi ;-)
@rudi ;-) what have you changed to index it right? I've got the same problem right now. Also the Animation are not so smooth on the panel. Is it because of the code or because of my wifi? Is there a newer version of your code?

Sorry for all those Questions :)
Rimzi

User avatar
rudi ;-)
Posts: 1698
Joined: Fri Nov 13, 2015 3:25 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby rudi ;-) » Sun Dec 30, 2018 11:37 pm

djRimzi wrote:
Tue Dec 25, 2018 3:55 pm
@rudi ;-) what have you changed to index it right? I've got the same problem right now. Also the Animation are not so smooth on the panel. Is it because of the code or because of my wifi? Is there a newer version of your code?
Look here

hope this helps

best wishes
rudi ;-)
-------------------------------------
love it, change it or leave it.
-------------------------------------
問候飛出去的朋友遍全球魯迪

marcmerlin
Posts: 30
Joined: Mon Apr 17, 2017 12:50 am

Re: I2S-parallel example: Drive a 64x32 display

Postby marcmerlin » Wed Feb 20, 2019 1:42 am

codetastic wrote:
Tue Oct 23, 2018 7:11 am
For those that might be interested... I have turned this experimental code into an Arduino Adafruit_GFX compatible library, to allow for simple graphics and text using DMA. I have tested this with a 64x32 Matrix.

https://github.com/mrfaptastic/ESP32-RG ... el-I2S-DMA
I forgot to mention that if anyone needs Adafruit::GFX API, FastLED, and/or FastLED::NeoMatrix API with more than 64x32 (I think SmartMatrix supports up to 128x128 on teensy 3.6), you can use my glue library on top of Louis' SmartMatrix:
https://github.com/marcmerlin/SmartMatrix_GFX

shanghailoz
Posts: 1
Joined: Thu Mar 21, 2019 3:40 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby shanghailoz » Thu Mar 21, 2019 3:58 pm

@codetastic

I want to say thank you for the DMA code, it works really well for me, I've left it running for a day, no crashes.
I've made a ESP32 PCB adaptor that plugs straight into the HUB75E panels, let me know if you want one, I'll post to you.

Cheers,

L.

codetastic
Posts: 4
Joined: Fri Oct 12, 2018 10:02 pm

Re: I2S-parallel example: Drive a 64x32 display

Postby codetastic » Sun Mar 24, 2019 10:32 pm

embedded-creations wrote:
Thu Oct 18, 2018 12:51 pm
The link you quoted is to a commit in my project code repository, so you're close. This is the full project code:

https://github.com/pixelmatix/SmartMatrix/tree/teensylc
Hi EC,

A silly question from me.... But in order to use I2S 8bit parallel mode successfully, one needs to use an external latch / add-on card to interface with the RGB matrix right? Like the SmartLed shield etc.?

I don't understand how only being able to output 8 GPIO's in parallel can work with the typical HUB75 that needs 13 pins.

Kind Regards.

Who is online

Users browsing this forum: No registered users and 32 guests