Arduino P2,P3,P4 RGB DMD cascade 2 x 32 x 64

(Topic ID: 235272)

Arduino P2,P3,P4 RGB DMD cascade 2 x 32 x 64


By legtod2

13 days ago



Topic Stats

  • 45 posts
  • 4 Pinsiders participating
  • Latest reply 5 days ago by legtod2
  • Topic is favorited by 6 Pinsiders

You

Linked Games

No games have been linked to this topic.

    Topic Gallery

    One image has been uploaded to this topic. (View topic image gallery).

    image1 (resized).jpeg

    #1 13 days ago

    Yes I'm sure this has been discussed before ...
    I know that color2dmd exists, ultradmd exists, etc, etc.

    What I actually am doing are two different idea's.

    The first idea is to have a simple wireless topper with a dmd display to display the machines top scores and entertaining animation/advertisement.
    A phone app or bluetooth will upload the message line 1 & 2 or animation file display and the topper will display it.
    Image going to your pinball tourneys and the tourney machine has a topper displaying high scores, tourney rules, player information or just sponsor ads.
    The device would be self contained and sit on top of the pinball backglass. Laptop power feed or battery feed to the unit. When the tourney is over upload what every display or high scores you want.

    The 2nd part is to enable the homebrew builder to add an inexpensive RGB DMD display to their home brew pinball machine.

    For me I intend to play arround with P3 and P4 32 x 64 RGB LED's and see what I come up with.
    Sure I could do the same with 32 x 32 and other assortments, but this is a continuation of my journey in learning how this stuff works.

    Today, these component are used to build outboard billboard signs and store signs. They are cascaded together to make a large screen picture.

    The pitch or space between the led's denotes the P number. So P3 is 3 mm's spacing, P4 is 4 mm's spacing between LED.

    A number of libraries exist for the arduino and other board types to power these components and example sketches demonstrate the capabilities.

    Be warned my journey will allow me to do simple and basic manipulations to aid in the scoring and simple animations of the device.

    Color2dmd and ultrdmd, and other products are more mature products and offer better plug an play capability.

    For me I just want to learn (the hard way) how this stuff works and apply it to my own home brew pinball creation.

    I will share with you my journey and share arduino code, connection schematics, successes and failures.

    As usual I will also invite input from the Zen masters here at Pinside to help give me sanity checks along the way.

    Come along for the ride if interested.

    #2 13 days ago

    Part one TOPPER with DMD display and wireless or bluetooth interface:

    I have never really been to a true pinball tourney. It is my understanding that a series of machines are set up and score results are recorded at a central location. Crowds will wander past each of the machines and try to determine what high scores are present on the machine.

    Now with of wireless or bluetooth DMD toppers, each machine could receive a scrolling display of high scores of individuals plus push other message types, maybe some animations or attract modes, of vendor sponsor ads. The central recording group could simply update the toppers and broadcast the message to them.

    #3 13 days ago

    Part two 2 - cascaded RGB 32 x 64 LED DMD.

    For my own home build home brew pinball machine this will enable me the growing room to build my own non-rom based pinball machines.
    This is where I will document my journey and detail what I am doing and trying in order to get there.

    Today I see a single 32x64 RGB varies in price from $20.00 - $89.00 for a P3 or P4 unit. Thats a big difference.

    If you are crazy like me, you want to cascade these suckers together and see what Frankenstein abomination you can come up with.

    #4 13 days ago

    You gotta start somewhere, so here I go...

    My Ultrathin 16 x 32 Red LED matrix was my christening into simple DMD programming with the arduino.

    In reality you can break this display into a series of 8x8 matrix's strung together.

    For my learning purposes the 16 x 32 was broken up to 2 lines of scrolling and static displays.

    For my first leson, I learned how to scroll text accross the top line and have the bottom line a static display.

    Then moved on to using a larger font that scrolled the text of line 1 & 2 accross the screen.

    The final lesson was some simple pixel placement accross the screen.

    The good news is the home brew beginner should be easily able to download the same libraries and example code to familiarize themself with this stuff.
    Yup it took about an hour to do all this learning, or more accurately it took one beer hour (or the time to drink one beer).
    Warning your beer hour and my beer hour may differ.

    #5 13 days ago

    We support something similar in MPF (but we are open to more options):

    RGB DMDs on a RPi: http://docs.missionpinball.org/en/dev/hardware/rpi_dmd/index.html

    RGB DMDs on a Teensy: http://docs.missionpinball.org/en/dev/hardware/smartmatrix/index.html

    #6 13 days ago

    Thank you for sharing. I appreciate the help and support from the many members here like yourself that demonstrate that regularly.

    #7 12 days ago

    Jabdoa,

    The docs are great, I have not done really anything with the teensy yet. All the font stuff is readily available via libraries.

    I would like to be able to record the playback of pinmame DMD game action then use that for the topper attract mode...

    Sort of like the vcr recorder. These recorded sections may then be played back on the topper for what ever .

    #8 12 days ago

    I wouldn't use Arduino its very slow (unless some new powerful version has been recently released) Use a teensy(dev board) or one of the very powerful nxp arm micro controllers for far more powerful / capable micro controllers (but not the silly 400mhz speed ones no one needs that much power to drive a basic led display). Or even a raspberry pi with the rgb rpi lib (all led driver work has been done for you) You get the wifi for free with the raspberry pi route

    #9 12 days ago

    Russdx,

    I will order a few teensy along with my RGB DMD boards.

    Here is the link to recording the DMD and other rom stuff ...

    https://pinside.com/pinball/forum/topic/wpc-emulator-in-your-browser

    #10 12 days ago

    Yeah the RGB DMD board is designed to have a teensy plugged into it (if its the one i think your referring to)

    #11 12 days ago

    It looks like pin2dmd is my answer for learn the craft of recording.

    Very impressive tool.

    #12 12 days ago

    from all the features you mentioned sounds like you would need your own custom firmware to implement them? pin2dmd firmware is not public and you would be stuck with its default features. Unless you have a computer sat in the middle.

    #13 12 days ago

    I will try doing the simple stuff first first like generating static frames into a simple text file then replay the frame.
    Start with a mono colour default characteristics and replay that frame to my rgb led matrix
    As time goes by I should have several frames built some may have true colour stuff.
    It will all be home grown stuff that is Mickey Mouse in complexity.

    Yah gotta crawl before you can walk.

    #14 11 days ago

    Shopping for a teensy and a rgb P3 or P4 panel.

    Its amazing how much the price varies for the individual panel. When I look at shipping the chinese panels to Canada it varies with a delivery date of more than a month or 2 month.

    When I look at adafruit they want $89.00 for a P3 32x64 RGB. Cascading these puppies together is an expensive undertaking for just a learning process.

    Gonna half to find some economical alternatives ...

    #15 11 days ago

    Buy directly from alibaba/aliexpress not from adafruit unless you want to pay x10 the price. Its very cheap directly from china. You just gotta wait. Usually come within 4 weeks but can have shipped quicker if your desperate for em.

    #16 11 days ago

    Today's programming lesson was to use my 16 x 32 simple DMD single color (Red) and display a 5 digit score.
    The dmd is a clone of the 16x32 Ultrathin. Pretty cheap but it lets me experiment with my coding methods which ultimately will channel back to my homebrew pinball machine.

    I did the exercise in two parts.
    a) Use a simple for loop and count up 0 - 99999
    b) Use serial port to accept input to provide a 5 digit score & text message line 1

    A 16x32 display using font5x7 provides just enough width to display the 5 digit score
    This also allow 2 lines of display using the same font size for lines 1 and 2.

    I used line 2 for score display and line 1 for scrolling text or stationary text message.
    If I want to display 6 digit or 7 digit displays, 16x32 is too small. Perhaps if I cascade some 16x32 together it would be better.

    Pretty mickey mouse stuff. This shows me very quickly that I will need RGB panels that are 32x64 in size.
    Using a cascade of 2 32x64 I can begin my learning curve of recreating my own Pinball DMD with simple imagery.

    I have learned from this experiment that I don't like RED as an LED color and it appear too bright.
    My present DMD does not let me play with the intensity

    #17 11 days ago

    Sample Arduino code to use the 16x32DMD and display 5 digit score...
    The myMATRIX.h gives the macros and 5x7fonts.
    Also since the dmd is red only the choice of colors in the macros uses red led only.

    #include "myMATRIX.h"
    #define RowA_Pin 2
    #define RowB_Pin 3
    #define RowC_Pin 4
    #define RowD_Pin 5
    #define OE_Pin 6
    #define Red_Pin 7
    #define Green_Pin 8
    #define CLK_Pin 9
    #define STB_Pin 10
    unsigned int value;
    int Score100K;
    int Score10K;
    int ScoreK;
    int Score100;
    int Score10;
    int Score1;

    char b[5] = "00000";

    void setup (){
    myMatrix.Init(Red_Pin,Green_Pin,CLK_Pin,RowA_Pin,RowB_Pin,RowC_Pin,RowD_Pin,OE_Pin,STB_Pin);
    }

    void loop(){

    for (value = 29999; value > 0; value--) {
    myMatrix.clearScreen();
    Score100K = (value/100000.0);
    Score10K = ((value-(Score100K*100000.0))/10000.0);
    ScoreK = ((value-(Score100K*100000.0)-(Score10K*10000.0))/1000.0);
    Score100 = ((value-(Score100K*100000.0)-(Score10K*10000.0)-(ScoreK*1000.0))/100.0);
    Score10 = ((value-(Score100K*100000.0)-(Score10K*10000.0)-(ScoreK*1000.0)-(Score100*100.0))/10.0);
    Score1 = (value-(Score100K*100000.0)-(Score10K*10000.0)-(ScoreK*1000.0)-(Score100*100.0)-(Score10*10.0));
    b[0] = Score10K + 48;
    b[1] = ScoreK + 48;
    b[2] = Score100 + 48;
    b[3] = Score10 + 48;
    b[4] = Score1 + 48;
    myMatrix.printString(0,8,yellow,black, b);
    delay(100);
    }

    }

    #18 11 days ago

    A very simple website https://www.pixilart.com allows me to experiment constructing simple pixel artwork.

    When I get my RGB DMD I will construct some simple images and then draft my associated code on the arduino/teensy.

    Remember I am learning and purposely doing things the long and hard way.

    #19 10 days ago

    Teensy is a good platform but smartmatrix seems to be a bit unstable if the cpu get´s more busy with other things.
    When I ported pin2dmd to teensy3.6/MK66 I first tried to use RGB.DMD from ecurtz as a base but soon found out that it will
    not work. I´m currently thinking about redoing the wifi interface of pin2dmd. The esp code will be public and
    can be modified to your needs (hiscore screen capture etc).

    #20 10 days ago

    In the signage board world these P2,P3,P4 boards mass together to form a sign large wall TV screen. They provide amazing TV screen reproduction for advertisement.

    They do a fine job in reproducing short AVI's, gif's and relaying animations.

    For my Topper application, the needs are for periodic wifi connections to update backend display cycles.
    The update would be stored on the internal sd and cycled endlessly until the next message is received.

    For example: A scrolling message "New High Score on Adams Family by JMJ 12,000,000" or "Beer Special, 2 for $5.00", or "Event Sponsored by Molsons".
    As well some simple GIFS or AVI's of recorded game DMD to display.

    I am not looking to create a mass of panels strung together into a large screen TV, rather something simple as a Topper.

    My other end goal is to string two 32x64 panels together for my home brew pinball game. It will display the score and maybe a few of my own
    low tech gifs or catch displays.

    The teensy or other board of choice will be dedicated to just serving one purpose. My home brew pinball machine will have other dedicated board doing other things.

    #21 10 days ago

    For my homebrew pinball DMD the messaging would be simple serial port connection.

    The master arduino would signal the teeny with a prefix + qualifier message.
    Example:

    Prefix(1 Character) + Qualifier(String)
    1 + "999999" + ","+"2","1" # User Frame display format 1, Score player 1, ball 2, credit 1
    2 + "1" # Play animation #1 New High Score
    2 + "2" # Play animation #2 Shoot again
    2 + "3" # Play animation # 3 Attract mode sequence 1

    I won't go into the more detailed protocol for interrupts but this explains what I will be doing at a simple level.

    Obviously the need for interupt will be required.

    I will mock something up using my 16x32 DMD to demonstrate the concept and post the code to help other understand the concept.

    Basically the teensy or other board will be dedicated component of the DMD to the master controlling program.

    #22 10 days ago

    teensy handles all the uart interrupts for you and will call a function onced its received a uart packet. There are some great example on sending uart data on there main website.

    #23 10 days ago
    Quoted from legtod2:

    For my homebrew pinball DMD the messaging would be simple serial port connection.
    The master arduino would signal the teeny with a prefix + qualifier message.
    Example:
    Prefix(1 Character) + Qualifier(String)
    1 + "999999" + ","+"2","1" # User Frame display format 1, Score player 1, ball 2, credit 1
    2 + "1" # Play animation #1 New High Score
    2 + "2" # Play animation #2 Shoot again
    2 + "3" # Play animation # 3 Attract mode sequence 1
    I won't go into the more detailed protocol for interrupts but this explains what I will be doing at a simple level.
    Obviously the need for interupt will be required.
    I will mock something up using my 16x32 DMD to demonstrate the concept and post the code to help other understand the concept.
    Basically the teensy or other board will be dedicated component of the DMD to the master controlling program.

    Sounds similar to the serial media server Steve programmed to play videos from a RASPI for e.g. the CFTBL video mod. https://github.com/sker65/serial-media-srv It also uses a simple serial protocol to trigger videos by either sounds (raspinsound) or dmd frames (pin2dmd). You can define trigger points that send out two bytes over the serial port. byte 1 is the device ID and byte 2 the event ID.

    #24 10 days ago

    Lucky1,

    We are on the same wavelength.

    Russdx,

    Thanks, I will do my lookups on the teensy side.

    #26 9 days ago

    Cheap and fast dont go together when it comes to shipping. If you cant wait you will have to pay more!!

    Also order few more then you neef they can often come faulty.

    #28 8 days ago

    Ok, shopping list made
    Getting a teensey 3.6 with headers and sd card
    Ordering two P2.5 Coreman 64x32 panels and maybe the smart connect between the teensy and the panel.
    Gonna use a PC power supply that I have thats collecting dust.

    As my coding library increases I will experiment with getting a few gif from google search and replay them by loading the gif file from the SD card.
    So hopefully I can find a few pinball dmd gif files laying arround for replaying on my cascaded dmd displays.

    A simple serial port connection will listen for doing score or clock display or replay gif animation file request.

    Next step order the stuff and wait for it to arrive.

    #29 8 days ago

    I have a teensy 3.6 shield pcb layout we used for testing with the pin2dmd port for DMDMK66.
    It has a HUB75E output which also supports 1/32 scan panels, a pinball DMD input with level shifters,
    a serial interface with max232, two user buttons and a SWD debug pinheader.
    I can provide you the schematics if you want. Just PM me.

    image1 (resized).jpeg

    #30 8 days ago

    Lucky1,

    1/32 scan... wowsers. I was getting excited about having 1/16 scan.
    Drooling on my keyboard right now.

    The HUB75 (whatever you want to call it) seems to vary. For me I will use a break out board anyway in the beginning to map the pins accordingly.

    #31 8 days ago

    Forgot to ask, what are the functions of the two user buttons ?

    Is one button labeled DO NOT PUSH THIS BUTTON ?

    #32 8 days ago

    HUB75 does not vary very much. Only the address lines change a little which can be adjusted by the software side. The user buttons are meant for pin2dmd onscreen menu functions.

    #33 8 days ago

    Ordered two P2.5 panels and teensy 3.5 (not 3.6) with pins.
    Went the 3.5 route because of the 5.0 volt tolerant.
    Also 120 clock speed should do the job, especially when you compare that against what I have on the uno or the mega.

    #34 7 days ago
    Quoted from legtod2:

    Ordered two P2.5 panels and teensy 3.5 (not 3.6) with pins.
    Went the 3.5 route because of the 5.0 volt tolerant.
    Also 120 clock speed should do the job, especially when you compare that against what I have on the uno or the mega.

    Why do you need 5V tolerance if you don´t have any 5V GPIO input pins ?

    #35 7 days ago

    Lucky1

    I was thinking about my input power connect. USB cables, to power the device.
    All my Arduinos and interconnects are 5 volts.
    So if I string an Arduino Uno or mega with the teensy, my power connect can be confusing.

    #36 7 days ago

    just power it all from one 5v rail via your psu, usb should just be for data you don't wanna power much from it.

    #37 7 days ago

    Teensy looks to be a capable little device.

    #38 7 days ago

    teensys are great little devices for people learning hardware.

    #39 7 days ago

    Is there any python code to talk to pin2dmd? I would like to support it in MPF. Alternatively C code would work when we compile it into a python module.

    #40 7 days ago
    Quoted from jabdoa:

    Is there any python code to talk to pin2dmd? I would like to support it in MPF. Alternatively C code would work when we compile it into a python module.

    You should be able to talk to it with a Python wrapper for libusb. A sample code how to talk to pin2dmd is here https://github.com/lucky01/PIN2DMD/tree/master/integration/source

    #41 6 days ago

    Well it looks like there are a few sources and methodologies of gathering short existing DMD video's and DMD gif for play back on the topper project.
    The methodology reminds me of my myth tv pvr days. Capturing video and editing using gimp and special video card to capture the video stream.

    Really all I need is some short captured dmd sequences that are converted into a format that are dmd friendly for playback to a 128 x 32 or 64 x 32 dmd.

    It is a lot of work to take a raw avi, or mp4 video and convert it into gif or other dmd friendly format using a series of other tools like gimp or others.

    For the newbie homebrew pinball hobbyist this might be a bit overwelming. So I will do my best to document and explain in byte sizes chunks how I will do it.

    #42 6 days ago

    I am building the library of data needed to take still images and display them to the dmd.

    Presumably I could export my still picture to a gif or png file then crop and size it accordingly then output it to dmd.

    Already have my simple text and side scrolling text library stuff ready. Simple effects like left scroll, right scroll, top scroll, and bottom scroll should fit the bill.

    #43 6 days ago

    Converting just a normal image / video to 128x32 res usually looks pretty crap without a lot if touch ups. Almost all pinball dmd artwork is handrawn or created using special tools for low res displays. If you want good looking animations probably exporting from pinMame is your best bet.

    #44 6 days ago

    Russdx

    Agreed. Low Rez picture or hand drawn or pixel artwork.
    Even single frame gif’s. For me my stuff will be home grown for my home brew pinball creations.
    My canvas will be 128 x 32 pixels with rgb.

    #45 5 days ago

    Here is a quick youtube to demo some simple effects with the 16x32 Red-only DMD.

    It shows simple transitions or effect of a ping ping ball bouncing, Curtain fall & rise, Curtain slide Left & Right.
    It also shows a marque on the top line scrolling with a score display advancing.

    Promoted items from the Pinside Marketplace
    $ 48.00
    Cabinet - Other
    ModFather Pinball Mods
    $ 999.00
    Pinball Machine
    Mircoplayfields
    $ 149.00
    Playfield - Toys/Add-ons
    Sparky Pinball
    $ 5,999.00
    Pinball Machine
    Classic Game Rooms
    $ 79.99
    Playfield - Toys/Add-ons
    Lighted Pinball Mods
    $ 72.95
    Cabinet - Shooter Rods
    Super Skill Shot Shop
    $ 9.99
    Eproms
    Matt's Basement Arcade
    From: $ 42.00
    Cabinet - Shooter Rods
    ModFather Pinball Mods
    $ 12.00
    Lighting - Led
    Bright Lights Pinball
    $ 27.99
    Eproms
    Matt's Basement Arcade
    $ 69.99
    Playfield - Toys/Add-ons
    Lighted Pinball Mods
    $ 49.00
    Cabinet - Other
    Chrome Candy
    $ 29.99
    Cabinet - Sound/Speakers
    Lighted Pinball Mods
    $ 99.99
    Lighting - Other
    Lighted Pinball Mods
    $ 7,599.00
    Pinball Machine
    Operation Pinball
    $ 28.00
    Playfield - Toys/Add-ons
    The MOD Couple
    From: $ 99.99
    Cabinet - Other
    Lighted Pinball Mods
    $ 35.00
    Cabinet - Decals
    Bright Lights Pinball
    $ 239.99
    Lighting - Led
    PinballBulbs
    $ 120.00
    Playfield - Toys/Add-ons
    ModFather Pinball Mods
    $ 69.00
    Playfield - Toys/Add-ons
    The MOD Couple
    From: $ 155.00
    $ 7,199.00
    Pinball Machine
    Classic Game Rooms
    From: $ 99.99

    Hey there! Got a moment?

    Great to see you're enjoying Pinside! Did you know Pinside is able to run thanks to donations from our visitors? Please donate to Pinside, support the site and get anext to your username to show for it! Donate to Pinside