Haptix Week 45


Petter: 

I’ve been working on the input system of the cube, first debating it’s simplicity, intuitivity and scale, and from then I’ve chosen to make the input based on a single press and it’s angle compared to the side and block it touches, it will from then send the relevant data which will decide which way to make the cube rotate. I would have loved to create a more complex system which would have been multiple touch based, akin to real life, however with the rubix model I have already created and the expected time allotted and time spent already, I couldn’t  justify redoing it. 

Daniel: 

For this week I have continued to work on the serial controller (Arduino.cs) and fingertip script. Where I have implemented threading with enqueueing and dequeuing. That way, the Unity application can communicate in an asynchronous way with the Arduino through the serial port. Before implementing the threading, I had tried to use coroutines in Unity. 

My approach to this was to include the System.Threading library in Unity and use Queue.Synchronized. Where I had 2 different queue’s, one for Unity to Arduino and vice versa. I have set the thread to run in the background. Which will then be looping through both the queue’s, while checking if there’s anything to dequeue from them. This is on the premise that there is something already enqueued. E.g. a function in the serial controller is checking if there’s something to be read from the Arduino. If not, then the function will return null rather than enqueueing something. 

Furthermore, I will have to work a little more on the Arduino.cs script. As I do have some issues with both sending and receiving data. 

William: 

I made a flow chart diagram back in October, where I described that I wanted to implement a pause menu (Pause Application marked in red).  I have now made a “pause menu” in unity, where you can pause the game/application by pressing the ESC-button on your keyboard (shown in C# screenshot).  

As well as continuing working on the User Interface, Even and I is also going to make a “scoreboard” that shows how many engagements or puzzles you have done with the Cube. The scoreboard system is going to be uploaded to a database. 

Herman & Tom Erik: 

The IMU is now hooked up to an Arduino and been tested to see if it works. When reading the serial monitor of the IMU one can see that there is a lot of information at once. So here I must take out and decide what information is needed and then also interoperate what that information represents in the real world. To test this, I have started assembly of a test glove by using an old single glove that I had laying around. Here I will monitor the movement of my hand when doing things like rotating a rubix cube, grab objects, move my hand and so on.  Picture of the said output below, one can see a change in values as I shook the IMU.   

On the communication part I have somewhat finished the layout for how the microcontrollers are communicating but is yet to receive the microcontrollers, which are expected to arrive mid-week 46.   

,

Leave a Reply