Team Status Report for 11/16

For verification right now, we are each testing our individual subsections, with a regression model of testing. For example, with our networked devices, we began by sending the most basic of packages, and ensuring that it was being received. Then, we began working on two way communication, having device A send data to Device B, having Device B manipulate it and then sending it back to Device A. Then we would build to having multiple devices networked, with a main device operating as a broker. Now the packets contain IDs of the device that the message is addressed too, and our receiving devices interpret these packets to determine if they are for them.

In terms of validation, once we integrate all our subsystems, we plan on tracing a picture taken with the RPi Camera through our system as it gets translated into a 2D array, validates words and calculates score as well as outputting the result to the main LCD display. We will manually check along the way through print statements that the board is updated properly. Additionally, we plan on testing the system in various lighting scenarios to ensure that the ring light is sufficient for proper lighting of the board and tiles.

In our design report, we mentioned having a focus group of individuals play Scrabble with Scrabbletron so we can determine whether our updates really improve the Scrabble playing experience. We plan on running this study once we have a working system after integration.

Jolie’s Status Report for 11/16

This past week I wrote and debugged functions for validating a new board and calculating the score for that new move. The check_board function takes in the board with the possible new word placed in it and a list of the squares that tiles were just placed (should be in order left to right or up to down). The function find the new board made, looks it up in the dawg (much quicker look up time than a simple linear search in the dictionary). If it’s not in the dawg, the function returns a tuple of (False, 0), meaning it’s not a valid word and scores 0 points. If it is a word, the new board, start and end position of the word, and tiles added are passed into the calculate_score function I wrote which only includes the score and letter multipliers for tiles that are newly placed (accoding to official Scrabble rules). The total score for the new word is updated in check_board. If the placed word is horizontal, the function goes through each letter and does word validation and score updating on the new word made vertically if there is one, and vice versa for a vertical main word.

Denis has been able to refactor my hint logic and put it on the Pi for communication with the Pi 0s. This will be used for our demo next week.

I completed my tasks on time so far, and in the coming weeks, I will pick up some integration tasks in terms of interfacing with the LCD displays and interfacing the output of Cody’s cv with the input of the check_board function.

Verification:

For the scoring, I ran tests where I placed different words (horizontal and vertical) on the board (2D list) and verified that the computed score was correct. I also varied the “tiled_added” list so make sure that letter and word multipliers weren’t added to already filled in squares. I did a similar practice with the check_board function.

For the hints algorithm, I used a unit testing approach where I tested each function on it’s own before testing the whole hint generation since it is a complex algorithm. Timing wise, the hint generation takes about 0.05 seconds on my computer. On the Pi, processes seem to run 8 times slower, but this is still well within our time allotted of 1.4 seconds (design requirement).

Cody’s status report for 11/9

I was able to make a good amount of progress on the CV this week. I’m at the point where I believe the preprocessing is as good as possible, but Pytesseract still sometimes misclassifies some characters. In the next few days I’m going to try a few different OCR libraries to see if others are more accurate. The logic to map the identified characters onto the board is also almost done.

Denis’s Status Report for 11/9

This week I began working with the main RPI4 board, and having that work as the main communication hub. I set up the RPI 0s to send messages to the hub and the RPI4 to process these and send back messages. For all MQTT communication we will use a format similar to this, sending arrays between the devices.

  • Index 0: Sender ID
  • Index 1: Receiver ID
  • Index 2: Task ID
  • Index 3-end: Data

As an example, sending a tile rack from device 1 to the main device could look like this:

[1,0,0,”d”,”e”,”n”,”i”,”s”]

As a final thing to do this week, I added the hint logic and began running that off of the main pi, sending a tile rack from the RPI0 to the main board, counting all the possible words and sending back one of the words for now.

For next week, I’m hoping to begin working on the portable powering and the touchscreens. I feel pretty on schedule, but I’m worried I could fall behind at any point.

Team Status Report for 11/9

Hardware Info:

RPI SSH cheatsheet: how to ssh into an rpi on CMU-DEVICE:

  • ssh username@IP

how to reboot rpi:

  • sudo shutdown -r now

MQTT communication format:

  • Index 0: Sender ID
  • Index 1: Receiver ID
  • Index 2: Task ID
  • Index 3-end: Data

 

This week, we interfaced the wireless communication and the hint logic, creating a basic setup where given a board state on the main Pi and a tile rack on the Rpi0, we can generate all of the possible words on the main Pi and send it back to the Rpi0. We also created a communication system that will standardize all of the communication that we will do between devices.

Jolie’s Status Report for 11/9

Last week, I finished up the hint logic, fixing some of the last little bugs as well as generalizing the algorithm to the vertical direction. Denis is now able to run the hint logic on the main RPi and can send receive hints with the RPi0s.. Also, I set up the gooseneck camera mount. I laser cut a platform (rectangle with four holes in it so that I could zip tieĀ  it to the top of the camera mount we bought). I then was able to clip the ring light onto the platform. The RPi and RPi camera rest on the platform and the camera is looped through the ring light. The picture below is what the mount + platform looks like (without the RPi on it). The other picture is what I took from my phone camera. Just from that, we can see how the ring light really helps eliminate shadows that we were seeing before.

Last week, I wrote a preliminary scoring function where letter and word multipliers are taken into account (but haven’t tested it yet). This upcoming week, I plan on testing the scoring function as well as writing the function that takes in the newly placed tiles and validates/scores all the newly created words.

After this week, I feel more confident that we are running on schedule, but we must not let up and finish strong this last month of the semester.

 

Team Status Report for 11/2

This week we made big strides with the hardware components of the project, getting 2 raspberry pi 0s to communicate with each other. We are waiting on a couple more parts to come in, which are holding us up right now. That is currently a big risk, but we are trying to mitigate that by developing as much as possible around that, including writing a thorough skeleton code for each of the RPi’s.

Cody’s status report for 11/2

I’ve spent some time trying to incorporate edge detection into contour recognition for the OCR, but I’m growing convinced that is not the way to go, as it has not seemed to help with recognizing the contours of characters without curves. I instead am beginning to believe I need to instead get the preprocessing as good as possible, as it currently is fairly grainy and has some noise, despite some attempt to reduce it. I’m going to continue improving this next week as well as put together the logic to combine adjacent characters into words.

Denis Status Report for 11/2

This week I was able to make strides forward with the hardware components of the project. The biggest step was getting two Raspberry Pi’s communicating with each other and sending data back and forth. I also moved them from my home WiFi to CMU-Device, which will be important for the demos. I was hoping to also start working with the LCD touchscreens but they have not come in yet, I think that I filled out the form too late.

In this next week, I would like to begin working with the touchscreens and developing the program that will be running on each of the RPI0s. I would also like to begin working on the battery packs that will be powering the Rpis. I would say that I am slightly behind schedule but should be able to easily catch up provided that the hardware comes in this week. I am also planning on designing the case that we will be putting the RPi 0 and the batteries into.

the two raspberry pi’s communicating. The time listed is total latency from A->B, calculations, and B->A
current rpi setup

Jolie’s Status Report for 11/2

This week I made a lot of progress with the hint generation. Right now, we can find all the horizontal words possible given the state of the board and rack. There is still one bug that I need to fix dealing with anchor squares which also have a filled square to the left. I just need to remove those anchor squares from the anchor list so that invalid words don’t propagate through, which shouldn’t be hard to fix. I also need to generalize the algorithm to the vertical direction. The hard part was already done in the horizontal direction, so the vertical functions should be easy to implement as they are just the transpose of the horizontal functions. Shown below is a snippet of the list of valid words, along with there start and end square, that the backtracking function returns.