Menu

4 x 16 Matrix

Anonymous
2016-12-14
2017-01-02
  • Anonymous

    Anonymous - 2016-12-14

    Hi, is it possible to change the Arduino program so it runs with a 4 x 16 Matrix?
    I would like to use an Arduino Mega 2560.

     
  • poilou

    poilou - 2016-12-15

    Yes it is possible.

    Diego will give you a sample, that you will have to adapt to your needs.

    If you manage to make it work, send it to me, I will add it to the arduino configuration samples.

    Cheers !

     
  • diego

    diego - 2016-12-15

    can you send us a picture of the inner board?

     
  • diego

    diego - 2016-12-16

    here is a arduino mega256 config for 4*16 matrix

    /#include <Keypad.h>
    /
    const byte numRows = 4; //four rows
    const byte numCols = 16; //four columns
    const int debounceTime = 100;//20 works better than great !
    //define the cymbols on the buttons of the keypads
    char keymap[numRows][numCols] = {
    {'0','1','2','3','4','5','6','7','8','9','*','B','C','D','E','F'},
    {'a','b','c','d','e','f','g','h','i','?','K','L','M','N','O','P'},
    {'j','k','l','m','n','o','p','q','r','&','T','U','V','W','X','Y'},
    {'s','t','u','v','w','x','y','z','A','@','+','-',']','/','!','$'}
    };
    byte rowPins[numRows] = {1, 2, 3, 4}; //connect to the row pinouts of the keypad
    byte colPins[numCols] = {22, 23, 24, 25, 26, 27 ,28, 29, 30, 31, 32, 33, 34, 35, 36, 37}; //connect to the column pinouts of the keypad

    //initialize an instance of class NewKeypad
    /Keypad customKeypad = Keypad( makeKeymap(Keys), rowPins, colPins, ROWS, COLS);
    /
    void setup()
    {
    Serial.begin(9600);
    for (int row = 0; row < numRows; row++)
    {
    pinMode(rowPins[row],INPUT); // Set row pins as input
    digitalWrite(rowPins[row],HIGH); // turn on Pull-ups
    }
    for (int column = 0; column < numCols; column++)
    {
    pinMode(colPins[column],OUTPUT); // Set column pins as outputs
    // for writing
    digitalWrite(colPins[column],HIGH); // Make all columns inactive
    }
    }

    void loop()
    {
    char key = getKey();
    if( key != 0) { // if the character is not 0 then
    // it's a valid key press
    /Serial.print("Got key ");/
    Serial.print(key);
    }
    }

    // returns with the key pressed, or 0 if no key is pressed
    char getKey()
    {
    char key = 0; // 0 indicates no key pressed

    for(int column = 0; column < numCols; column++)
    {
    digitalWrite(colPins[column],LOW); // Activate the current column.
    for(int row = 0; row < numRows; row++) // Scan all rows for
    // a key press.
    {
    if(digitalRead(rowPins[row]) == LOW) // Is a key pressed?
    {
    delay(debounceTime); // debounce
    while(digitalRead(rowPins[row]) == LOW)
    ; // wait for key to be released
    key = keymap[row][column]; // Remember which key
    // was pressed.
    }
    }
    digitalWrite(colPins[column],HIGH); // De-activate the current column.
    }
    return key; // returns the key pressed or 0 if none
    }

     
  • Anonymous

    Anonymous - 2016-12-25

    Thanks for the program. It worked great.

     
  • poilou

    poilou - 2016-12-25

    Pleased to read that !
    You're the first offical tester of Arduino Mega and pyDarts ! Congrats ;)
    Enjoy :)

     
  • Anonymous

    Anonymous - 2016-12-26

    Hello

    Is it possible to change the display in the game as shown in the picture?
    And would it be possible to end the game Ho-One with double off?
    I have tried it myself, but it does not get there

     
  • poilou

    poilou - 2016-12-27

    Hi !
    Unfortunately it will not be possible for the display. The place used on your screen shot is the place used by the score table. If you play a game with 10 other players, your screen will be full !

    Regarding the Double-In, Double-out option in Ho-one, it will add it to the roadmap for v1.0 !
    Great idea !

    Cheers

     
  • Anonymous

    Anonymous - 2016-12-28

    When and where does this roadmap exist for v1.0?

     
  • poilou

    poilou - 2016-12-29

    Since I am the only dev of pyDarts, the roadmap is moslty in my head. But I write some things to do in the release note.
    The v1.0 will be "when it's done", but we can expect it for the first three month of 2017.

     
  • Andreas

    Andreas - 2016-12-29

    when it is done? Or Duke Nukem Forever when it is done? :)
    be sure to cut out the copyrighted stuff "like the opening of "eye of the tiger"
    If you like i can take a look in my soundBox, so i can povide some sounds for the game. Then you are more secure for the law side.

     
  • Anonymous

    Anonymous - 2016-12-29

    Oh that would be great if this option would soon be.

     
  • poilou

    poilou - 2016-12-30

    I don't have the the founds of ID software ;) so it could be worse ;)
    Replacing all the copyrighted stuff by free ones could be really great. That was definitly something I wished. Don't hesitate to send me sounds and source to my email address labiloute@neuf.fr

    Regarding the Ho One double in / out, it could be really fast.

     
  • diego

    diego - 2016-12-30

    so guys, when are we playing all together online??

     
  • Andreas

    Andreas - 2016-12-30

    yes, lets make a date for it. All here available in a social network like facebook? my account on FB is:
    andreas.otten.10 the old guy with the sword. make a group pydarts there?

     
  • poilou

    poilou - 2017-01-02

    I do not use facebook but post the date on this forum, I'll do my best to be there !

    Please also post pydarts version used and server if required.

    I was thinking of creating a monthly event for a multiplayer game, somthing like "The first sunday of each month @ 7pm TZ Europe/Paris". What do you think about that ?

     
  • Andreas

    Andreas - 2017-01-02

    Sounds, good.
    may be a little chat interface make sense? To write what to play etc.?

     
  • poilou

    poilou - 2017-01-02

    Definitly.
    Since there is no chat embeded in pydarts so far, I suggest opening a video/write chat on this kind of service :
    https://appear.in/pydarts
    (use it with a modern browser)

     
  • Andreas

    Andreas - 2017-01-02

    ok i try Sunday 7 pm paris time

     

Anonymous
Anonymous

Add attachments
Cancel





Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.