Greetings all.. I've developed and created the "Poolroom Scorekeeper Mini". whoo hoo.. well after hours and hours of work developing and then printing a custom enclosure, tests show that the individual numbers on the display are too small to see while streaming online.
Here's a quick video showing the completed product:
see attached image to see what it looks like when viewing online.
also see attached image for the current LED modules I use.. they are the standard 8*8 32x32mm times 4.
Its obviously too small to see and I need to make the displays BIGGER..
what would you suggest?? I was thinking 8*8 but making them 5mm LED size which would increase each letter by almost 4 times.. I'm sure there are many other options and I'm wondering how you would do it.. should I use a LED screen or maybe paper display?? any suggestions REALLY APPRECIATED!!
please also keep in mind the scorekeeper connected to the pool table is pointed almost downward so i will have to make a base so its tilted upwards which should increase the readability of it..
here is code for those interested..
#include <LedMatrix.h>
#include <cp437font.h>
/*
scorekeeper mini 4-26-20206
*/
//because there is a 3 second delay the player must wait until the LED lights up before they can release the button.
//the delay is useful for only recording and increase by 1 otherwise it will increase by 3 in one button push.
#define lowBatteryThresh 478 //**Connect a 1 Mega Ohm resister between the battery and lowBatteryIn.
#define lowBatteryIn A0 //**Connect a 500 Kilo Ohm resistor between lowBatteryIn and ground.
#define Rst 7
#define buttonDelay 250 //delay in microseconds, 1000 should equal 3 seconds for a button press
const int player1_up = 4; // the pin number of player1_up integer
const int player2_up = 2; // the pin number of player2_up integer
const int low_power_led = 12; // low power led pin
int player1_up_buttonState = 0;
int player2_up_buttonState = 0;
int player1_score = 0;
int player2_score = 0;
int loopCounter = 0;
#define matrix_1_count 4
#define cs_pin_1 10 //cs pin of first matrix connected to Arduino D3
LedMatrix mat(matrix_1_count, cs_pin_1);
void setup() {
// initialize serial:
Serial.begin(9600);
// initialize the pushbutton pin as an input:
pinMode(player1_up, INPUT);
pinMode(player2_up, INPUT);
pinMode(low_power_led, OUTPUT);
pinMode(lowBatteryIn, INPUT);
pinMode(Rst, INPUT);
mat.init();
mat.setIntensity(4);
mat.setTextAlignment(TEXT_ALIGN_LEFT);
mat.setCharWidth(8);
}
void loop() {
// read the state of the pushbutton value:
player1_up_buttonState = digitalRead(player1_up);
player2_up_buttonState = digitalRead(player2_up);
if (analogRead(lowBatteryIn) <= lowBatteryThresh) //test if the potential divider value is less than the threshold
digitalWrite(low_power_led, HIGH);
else
digitalWrite(low_power_led, LOW);
if (player1_up_buttonState == HIGH) {
while(digitalRead(player1_up));
changeScore(1, 1);
}
loopCounter = 0;
if (player2_up_buttonState == HIGH) {
while(digitalRead(player2_up));
changeScore(2, 1);
}
if(digitalRead(Rst)){
player1_score = 0;
player2_score = 0;
Serial.print(player1_score);
Serial.print(" ");
Serial.print(player2_score);
Serial.println();
}
writeScore();
}
void changeScore(int player, int by){
if (player == 1)
player1_score += by;
else if (player == 2)
player2_score += by;
else
Serial.println("Undefined player number in function: changeScore()");
}
void writeScore(){
String toShow = "";
if (player1_score < 10)
toShow += "0";
toShow += player1_score;
if (player2_score < 10)
toShow += "0";
toShow += player2_score;
mat.setText(toShow);
mat.drawText();
mat.commit();
}


