# A completely different technological approach for smart cubes



## Wish Lin (Nov 24, 2019)

Spoiler: This early concept had been proven to be a bust, but I still think it has hope using some other technology I don't know



This is a concept I came up recently that just may be the future of smartcubes:
*Exciting things this technology could/might achieve*

The system can be installed to *ALL STICKERLESS CUBES WITH A HOLLOW EDGE(Probably most people's mains by now), so you can make your main a smart cube!*
*A smartcube that doesn't need charging at all!*
*Considerably cheaper(I hope so....)than smart cubes nowadays *like the Gan 356i or GoCube.
The system *can (only theoretically)be implanted to all twisty puzzles(smart 4x4 ,smart 5x5, smart skewb, etc)!*

*Technical Details*

This technology relies on *passive RFID chips, which will be installed in the 12 edges of the cube(9 at least)*, and since the chips are passive, you don't need to charge the cube at all, it's just like a regular cube.

For anyone who wants to recommend alternatives, make sure the technology uses passive chips(if not,totally fine, the only limit is no battery) and has a HUGE signal strength gradient over a small distance. The bigger the gradient is, the better.

*Current Design *
This design is straightforward and should have a high success rate, but has the down side of squeezing your turning space into a box, and the box is harder to carry around. This particular design only works for 3x3.

We have a box surrounding the cube, as shown in the picture, with* the small spheres representing the 8 RFID emitters/receivers. *Now, since the signal strength from the emitters will decrease when the distance between it and the chips increases(signal strength is inversely proportional to distance squared), *we need each chip to return two key information to the receiver: the chip's ID number and the signal strength it gets from each particular emitter. *

Let's consider only one chip for now. In total, each of the 8 receivers will get a value from the chip of it's own signal strength THAT IS DETECTED BY THE CHIP, *in these eight values, there will be two value that are the highest(strongest signal), which will be the two closest to the edge, as shown in the picture, thus we can know where the edge is. (In the picture, the blue edge is closest to the two blue receivers and red edge closest to the red receivers, so the chip will detect the strongest signal from them)*

The same process is repeated on each of the 12 chips for every couple of milliseconds. *When the cube turns, these values change, and by calculating these changes, we can locate each and every edge's movement, thus detecting the turns. *9 is the smallest amount of edge needed to have chips in them because for every move you make, at least one edge with a chip needs to be in that layer for the turn to be detected.(Tell me if I need to explain in detail)

Please post your thoughts about this below! Any technical thoughts(help!), usability problems and also, constructive criticism are very welcomed.





Spoiler: A success, but proven impractical



*#This is still in prototype stage. Don't put too much hope on it#*


*This prototype is a smart 2x2 system that can be installed on ANY 2X2!! It is also super cheap(~$20)*

*(Simplified)Appearance:*

*The most important piece of technology in this prototype are Hall sensors: They are sensors that can sense changes in the magnetic field. On a L-shaped frame, there are 8 hall sensors arranged like this:*


*And the 2x2 will embedded with 24 magnets on every piece facing outward, like this(1 of the magnets):*


*The idea is simple: when you turn the cube, at least 2 of the 8 hall sensors will detect a difference in the magnetic field, thus we can detect turns.*

*There is still a small problem though: although the turns can be detected, but the direction cannot(i.e. it can't tell R from R'). I have a clever trick to solve this problem, but I don't want to publish it yet.*



*Rough Calculation for the price(This will get even lower if it ever gets mass produced):*

*8 Hall sensors: 10¢ each*
*Arduino Nano: $4*
*Magnets: $1.5*
*2x2(Meilong 2x2): $1.5*
*3D printed Frame: Roughly $6 (will be close to zero if injection molded)*
*All the other stuff: $5 *
*Total: $19(!!!!!!!!)*


Check out the designs(up)

*(6/6/2020) A brand new design on the way! *


----------



## xyzzy (Nov 24, 2019)

Wish Lin said:


> I think 5 emitters will be plenty, but I am not sure AT ALL, since I know almost nothing about triangle location.


If you can (exactly) measure the distance of a chip from two emitters, that restricts its location to the intersection of two spheres, which is a circle. With three emitters, you can narrow that down to (at most) two points: one above the plate, one below. (If your emitters are exactly coplanar, then it can't possibly distinguish what's above the plate from what's below, but I expect this shouldn't be a problem if you just slap a "THIS SIDE UP" label on one of the sides.)

However, if all we know is the _relative_ distance (something like "the distance to emitter A is half that to emitter B, but we don't know the exact distances"), then we need an extra emitter to handle the extra degree of freedom, so four emitters would be needed. Either way, five emitters is more than the bare minimum needed, and the redundancy could serve as a way of improving location accuracy.

See also: https://en.wikipedia.org/wiki/True_range_multilateration

Disclaimer: I also know nothing about the hardware required for this to work, so I might be completely misunderstanding how the RFID chips or whatever really work. Naïvely, I'd expect interference from the different emitters to be a significant problem.


----------



## Wish Lin (Nov 24, 2019)

xyzzy said:


> Disclaimer: I also know nothing about the hardware required for this to work, so I might be completely misunderstanding how the RFID chips or whatever really work. Naïvely, I'd expect interference from the different emitters to be a significant problem.


Yes, that could be a problem(thought I am also not sure) So I am thinking doing the emits/receives one by one between a small time interval to prevent them from interfering each other.


----------



## Wish Lin (Nov 25, 2019)

Small update: The chips doesn’t necessarily need to be passive. They can be active as well, just replace the batteries with wireless charging coils(if possible)

Also, if the chip has a huge RESPONSE TIME DIFFERENCE when distance between it and the receiver changes, that should work as well.


----------



## Filipe Teixeira (Nov 26, 2019)

I found this amazing
*



Disclaimer---Please don't take this concept to commercial use without my notice if this turned out to be valuable!

Click to expand...

*
Wow just write a patent asap.
Don't rely on promises


----------



## Hazel (Nov 26, 2019)

If this becomes a thing, good on you! It seems super smart and would be a great step forward in cubing hardware.


----------



## Etotheipi (Nov 26, 2019)

Wish Lin said:


> Yes, that could be a problem(thought I am also not sure) So I am thinking doing the emits/receives one by one between a small time interval to prevent them from interfering each other.


To minimize interference you could just have each chip work on a different frequency.


----------



## Wish Lin (Nov 26, 2019)

Filipe Teixeira said:


> I found this amazing
> 
> 
> Wow just write a patent asap.
> Don't rely on promises


I want to! But let’s first make sure this actually can be a thing ASAP before I write the patent XD


----------



## Wish Lin (Nov 26, 2019)

Filipe Teixeira said:


> I found this amazing
> 
> 
> Wow just write a patent asap.
> Don't rely on promises


Working on it......


----------



## ImmolatedMarmoset (Nov 26, 2019)

Wish Lin said:


> Wait a second, is it a good idea to take this article down before I finish writing the patent? Seems like this can actually be a valuable technology judging from you guys’ replies.


dunno. I think of the cubing community as a community first and foremost. I wouldn’t worry about it too much but if you want to feel free


----------



## GAN 356 X (Nov 27, 2019)

Wow... this could be revolutionary for the cubing community... Like magnetising cubes yourself was several years ago


----------



## Wish Lin (Nov 29, 2019)

Update: The suitable technology has been found: It’s called RSSI, and I found most modern UHF RFID systems probably have it! 

I’ll update again when I know more about it and comes up with a detailed plan.


----------



## Wish Lin (Nov 30, 2019)

Update: 

1. I found that the idea of using RFID RSSI is not new to the world and has been developed under the name of "indoor RFID RSSI localization" for YEARS.
But still, The exact detail and technology varies quite a bit and I am the first one to put the idea together with speedcubing.

2. NEED SOME HELP HERE: I am having trouble finding which reader to buy that can return RSSI values. The ones I found now are either readers for 1m+ applications that has an RSSI accuracy of +-10cm, which is not going to work, or readers that cost $200 per reader. Please suggest me one if you somehow know one!

Impossible to use readers I found:

Mifare MFRC522 ------ No RSSI
Cottonwood reader -------- Expensive
AC3992 ------- Expensive


----------



## Wish Lin (Jan 5, 2020)

Update: After checking a bunch of datasheets, I am confident to say that there is no way RSSI can be used in this project. Back to square one now, but I do have another idea. Will update after further research.


----------



## CodingCuber (Jan 5, 2020)

I absolutely love this idea. If any and every cube could be a smart cube this would help so much with practice and seeing how you do in your solves statistically. My question is though, would there be one particular piece of software for the technology or would different companies be able to get licenses or something to develop their own software. Love the idea and wish you the best


----------



## Skittleskp (Jan 5, 2020)

This is super cool and innovative!!


----------



## Joe Archibald (Jan 5, 2020)

Couldn’t you just use 5/8 chips and put them in the corner pieces


----------



## Wish Lin (Jan 5, 2020)

Joe Archibald said:


> Couldn’t you just use 5/8 chips and put them in the corner pieces


I thought about that too, but then you can’t detect M,E,S moves since they don’t move any corner piece.


----------



## kubesolver (Jan 5, 2020)

I think the only reliable solution to make any cube i-cube is to record a cube with a camera and write some software to convert video to a move sequence. This kind of problem of tracking fast moving items in real time is very similar to what full experience VR simulators do and the
solution is to have many high speed cameras and do image recognition.


----------



## Wish Lin (Jan 5, 2020)

kubesolver said:


> I think the only reliable solution to make any cube i-cube is to record a cube with a camera and write some software to convert video to a move sequence. This kind of problem of tracking fast moving items in real time is very similar to what full experience VR simulators do and the
> solution is to have many high speed cameras and do image recognition.


Yes it is possible and is the only solution to literally anycube smartcube, but don’t forget that your hand will block L and R and parts of U,B,D and F, making the simple solution of N cameras pointing at N faces and analyze turns imposssible.

So the only possible solution is the computer will have to process it basically like a well trained human(Lazer0Monkey for instance) and as far as I know, such level of neural network for commercial use doesn’t exist.

(VR simulators don’t need to track a bunch of small pieces moving quickly in all three axis and its background is much, much easier to render away than some random guy’s desktop.)


----------



## kubesolver (Jan 5, 2020)

Yes to the first two paragraphs. 
But VR simulators do track a lot of small fast moving pieces and their view is often obstructed. In full body VR a person has several points on head, legs, torso and arms and they are being tracked in real-time at relatively high fps.


----------



## Wish Lin (Jan 5, 2020)

kubesolver said:


> Yes to the first two paragraphs.
> But VR simulators do track a lot of small fast moving pieces and their view is often obstructed.


Oh really? So I guess the only problem is that we don’t have a VR simulator built for speedcubing XD.


----------



## Wish Lin (Feb 17, 2020)

Ok. Big Update! I have come up with a WORKING prototype!

This prototype is a 2x2(for proof-of-concept) and uses Hall effect sensors and built in magnets in the 2x2. Will update again soon.


----------



## brododragon (Feb 17, 2020)

This is really cool. I was thinking of something like this, just using sensors/other tech to make any cube smart. Of course, I don't have the resources to make it, but I'm glad someone does


----------



## Wish Lin (Feb 22, 2020)

*#This is still in prototype stage. Don't put too much hope on it#


This prototype is a smart 2x2 system that can be installed on ANY 2X2!! It is also super cheap(~$20)

(Simplified)Appearance:

The most important piece of technology in this prototype are Hall sensors: They are sensors that can sense changes in the magnetic field. On a L-shaped frame, there are 8 hall sensors arranged like this:*


*And the 2x2 will embedded with 24 magnets on every piece facing outward, like this(1 of the magnets):*


*The idea is simple: when you turn the cube, at least 2 of the 8 hall sensors will detect a difference in the magnetic field, thus we can detect turns.

There is still a small problem though: although the turns can be detected, but the direction cannot(i.e. it can't tell R from R'). I have a clever trick to solve this problem, but I will not publish it now.



Rough Calculation for the price(This will get even lower if it ever gets mass produced):*

*8 Hall sensors: 10¢ each*
*Arduino Nano: $4*
*Magnets: $1.5*
*2x2(Meilong 2x2): $1.5*
*3D printed Frame: Roughly $6 (will be close to zero if injection molded)*
*All the other stuff: $5 *
*Total: $19(!!!!!!!!)*


----------



## Etotheipi (Feb 22, 2020)

If this gets improved and optimised we could have cheap smart cube tech for any cube for like $10. Wow. I can't wait until this gets refined into a phyisical working design. =D


----------



## Wish Lin (Feb 22, 2020)

Etotheipi said:


> If this gets improved and optimised we could have cheap smart cube tech for any cube for like $10. Wow. I can't wait until this gets refined into a phyisical working design. =D


Ha! I hope this happens as well, but apparently I still got a long way to go....If my plans go right, the first prototype will be finished before summer.


----------



## Wish Lin (Feb 24, 2020)

Update: I just bought a MF2S and here is the overall look:

This is the magnet I currently plan to use (4x2 N35）:

And this is where I plan to put them:


But there is a problem: the strength of these magnets are quite weak. In fact, at the 3cm distance(distance between it and the sensor when working), it can’t even pick up a stapler pin.

I am not sure whether the Hall sensor I use will use detect it clearly, but if it doesn’t, I can simply use a more precise Hall sensor, which I know where to buy, just a bit more expensive.

I can’t change to stronger magnets because that means bigger(without adding the N numbers, of course) magnets and I think this 4x2 size is the biggest size can be fit into all 2x2 designs, so......not an option.

I am planning to use AH3503 linear Hall sensor for now BTW.


----------



## ProStar (Mar 11, 2020)

Wish Lin said:


> *#This is still in prototype stage. Don't put too much hope on it#
> 
> 
> This prototype is a smart 2x2 system that can be installed on ANY 2X2!! It is also super cheap(~$20)
> ...



Woah, so I could make a 4x4 smart cube?


----------



## Wish Lin (Mar 11, 2020)

ProStar said:


> Woah, so I could make a 4x4 smart cube?


Theoretically, yes.

But I am currently having issues like sensor sensitivity on my 2x2 prototype so I am not sure if this is a good idea for bigger cubes.


----------



## Cuberstache (Mar 11, 2020)

Wish Lin said:


> *This prototype is a smart 2x2 system that can be installed on ANY 2X2!! It is also super cheap(~$20)*


This is awesome! How precisely do you have to hold the cube? It looks to me like if you angle the cube differently or move it too far away, it won't work properly. Is this something that can be fine-tuned by better sensors and/or magnets? Or is it not a problem at all? I love your thinking and I really hope this becomes a thing at some point. Smart megaminx ftw!


----------



## Wish Lin (Mar 12, 2020)

CuberStache said:


> This is awesome! How precisely do you have to hold the cube? It looks to me like if you angle the cube differently or move it too far away, it won't work properly. Is this something that can be fine-tuned by better sensors and/or magnets? Or is it not a problem at all? I love your thinking and I really hope this becomes a thing at some point. Smart megaminx ftw!


Unfortunately, you have to place it quite precisely, so it will effect the fluency of the solve and possible applications on big cubes, of course.

But still, this is the first attempt of making a smart cube without a smart core.


----------



## Spacey10 (May 21, 2020)

Wish Lin said:


> Unfortunately, you have to place it quite precisely, so it will effect the fluency of the solve and possible applications on big cubes, of course.
> 
> But still, this is the first attempt of making a smart cube without a smart core.


Could you somehow have electromagnets that detect when a magnet is being pulled on? And to identify which magnets is being pulled on, you could change the strength of the magnets very slightly for every magnet, and the difference would not be felt by the cuber, but the change in magnet strength would be felt by the Arduino, which allows the cube to know which magnet it is touching and where that piece is. It would also mean you could do corner twists without affecting the system because the Arduino would know what the magnet strength is, and so we can recognize it.

An example would be like this:
Turns a side
Arduino: checks magnet strength and the Arduino already knows which piece the magnet is attached to
Sends magnet strength to app or something, which can make the 3D model


----------



## brododragon (May 21, 2020)

Spacey10 said:


> Could you somehow have electromagnets that detect when a magnet is being pulled on? And to identify which magnets is being pulled on, you could change the strength of the magnets very slightly for every magnet, and the difference would not be felt by the cuber, but the change in magnet strength would be felt by the Arduino, which allows the cube to know which magnet it is touching and where that piece is. It would also mean you could do corner twists without affecting the system because the Arduino would know what the magnet strength is, and so we can recognize it.
> 
> An example would be like this:
> Turns a side
> ...


Something so slight probably won't work, because of real world conditions. First off all, you probably couldn't sense something so slight. Even if you could, things like dropping it or just intented use could wear the magnets unevenly. Also, things like cube flex would make that impossible.


----------



## Spacey10 (May 21, 2020)

brododragon said:


> Something so slight probably won't work, because of real world conditions. First off all, you probably couldn't sense something so slight. Even if you could, things like dropping it or just intented use could wear the magnets unevenly. Also, things like cube flex would make that impossible.


But the Arduino could somehow detect the amount of volts coming from the electromagnets. But for the rest, I have no clue.


----------



## Wish Lin (May 21, 2020)

Spacey10 said:


> Could you somehow have electromagnets that detect when a magnet is being pulled on? And to identify which magnets is being pulled on, you could change the strength of the magnets very slightly for every magnet, and the difference would not be felt by the cuber, but the change in magnet strength would be felt by the Arduino, which allows the cube to know which magnet it is touching and where that piece is. It would also mean you could do corner twists without affecting the system because the Arduino would know what the magnet strength is, and so we can recognize it.
> 
> An example would be like this:
> Turns a side
> ...


I have thought about that, but just as @brododragon said, the change is way to small(the space inside a cubie is very limited), and also, even if I did somehow get a good enough sensor for that, it will not be cheap, and the earth’s magnetic field will make the whole thing 10x more complicated.


----------



## Wish Lin (May 21, 2020)

Another fundamental problem is that linear hall sensor isn’t actual linear, it has saturation zones, so any magnetic field that is too weak(in my case, yes) will simply be indistinguishable.

Also, Arduino’s only has a 10-bit ADC, meaning the smallest voltage change it can sense is 5/2^10 = 0.004 Volt, which is unfortunately, still not accurate enough.


----------



## brododragon (May 22, 2020)

Wish Lin said:


> Another fundamental problem is that linear hall sensor isn’t actual linear, it has saturation zones, so any magnetic field that is too weak(in my case, yes) will simply be indistinguishable.
> 
> Also, Arduino’s only has a 10-bit ADC, meaning the smallest voltage change it can sense is 5/2^10 = 0.004 Volt, which is unfortunately, still not accurate enough.


are you gonna switch to a more advanced Arduino (also, which are you using right now?)?


----------



## FinnTheCuber (May 22, 2020)

Wish Lin said:


> Update: The suitable technology has been found: It’s called RSSI, and I found most modern UHF RFID systems probably have it!
> 
> I’ll update again when I know more about it and comes up with a detailed plan.


I didn't know uhf was used for rfid. ( I have a ham radio technition license)


----------



## Wish Lin (May 22, 2020)

FinnTheCuber said:


> I didn't know uhf was used for rfid. ( I have a ham radio technition license)


Ultra high frequency RFID, am I wrong about this ?


----------



## FinnTheCuber (May 22, 2020)

No i dont think so it would just seem that closer to microwave frequency would be for rfid.

Edit: just did some research and it looks like 13.56 MHz is used. I learned something new!


----------



## Wish Lin (May 23, 2020)

*Important new update (2020/5/23)
Just finished my mid-term exam, and I have some good news and bad news for you guys:

Let's start off with good news:

The. Thing. Actually. Worked.
Yes, I build the first prototype and tested it. Although the whole setup was kind of crappy, it WORKED. 

Bad news:*
*It turned out to be an impractical idea for speedcubing.*

Detailed process:

I finished 3D-printing all the parts around April, then got all the electronics ready recently. It worked just as expected.
But I instantly found out that this idea is not good, here is why:

The biggest problem is HOW ACCURATE YOU WILL HAVE TO TURN THE CUBE. Because my setup(I have tried every sensor/magnet setup I could think of) is already at the limit of the detection range of the Hall sensor, you have to turn the cube PERFECTLY ALIGNED WITH THE SENSOR plus no corner cutting at all. By now, if you are a speedcuber, you know it's a bust. If I try upgrading the sensor, the price just SKYROCKETS and you can get 2~3 356is with that price.
The cheap Hall sensors' data fluctuate easily, adding to the fact that it is already at detection limit, makes the whole thing very unstable and inconsistent.
*With this failure, I will say that all smart cube ideas regarding to an external frame is probably a bust(in my limited knowledge, of course). But I can't deny it's a success anyway, and I will NOT stop developing next generation smartcubes until it becomes a reality.*

Frame of the(already disassembled) prototype:

A hall sensor stuck on it and its legs broke off when I tried to remove it, so I just leave it there. I recovered all the electronics BTW.


----------



## brododragon (May 23, 2020)

Wish Lin said:


> *Important new update (2020/5/23)
> Just finished my mid-term exam, and I have some good news and bad news for you guys:
> 
> Let's start off with good news:
> ...


Could you use something to detect when a turn gets slowed by a magnet? Probably dumb but, who knows?


----------



## Wish Lin (May 23, 2020)

brododragon said:


> Could you use something to detect when a turn gets slowed by a magnet? Probably dumb but, who knows?


Yes, but I can't tell the turning direction.


----------



## Wish Lin (Jun 5, 2020)

A completely new approach is on its way!


----------



## Wish Lin (Jun 5, 2020)

The details will be revealed later, but this time, being cheap is no longer the primary goal, this idea is about a possibly all-cube-smart-cube system!(Of course, I still want to make it as cheap as possible, but $50 or less probably isn’t possible)

(Sorry @Etotheipi ,I failed to make the cheap smart cube you have hoped for, but someone out there will definitely make it in the near future, probably using a different insight compared to mine!)

Currently discussing the idea with @Lelouch, who is experienced in neural networks.


----------



## brododragon (Jun 5, 2020)

Wish Lin said:


> The details will be revealed later, but this time, being cheap is no longer the primary goal, this idea is about a possibly all-cube-smart-cube system!(Of course, I still want to make it as cheap as possible, but $50 or less probably isn’t possible)
> 
> (Sorry @Etotheipi ,I failed to make the cheap smart cube you have hoped for, but someone out there will definitely make it in the near future, probably using a different insight compared to mine!)
> 
> Currently discussing the idea with @Lelouch, who is experienced in neural networks.


Woaj deep learning?


----------

