Wednesday, June 20, 2018

UPDATE: Virtual Reality Fun

Last weekend we bought a Virtual Reality headset, a 2nd hand Lenovo Explorer which is one of the variants of the Windows Mixed Reality headsets
Besides using it to play really immersive video games another cool thing you could use it for is viewing 3D models. Since my wife and I tend to build shelves to save space in our tiny apartment here is how our workflow could change

First off my wife would do a sketch of a possible design with some rough dimensions:

I would key this into a program like SolidWorks:

Then we could play around with design variations in VR to get a better idea of how it all fits together:
NOTE: See below for how to import a SolidWorks model into VR

And finally we build the thing:

Importing SolidWorks file into Mixed Reality Portal

The easiest way to view a SolidWorks model in VR is to export it as an OBJ file using this macro. Before you do make sure that the model orientation is correct as you can only rotate in 2 axis in the Mixed Reality Portal

Now put on your headset and open the Mixed Reality Portal, here you can import the OBJ file using Mixed Reality Viewer. If you have trouble importing the object try making it less complex, for example with above model I had to remove the 3D printer for it to import properly

Once your model is there scale it manually until it looks right, we found an easy way of doing this is by physically holding an object you know the size of and scaling it to that

Thursday, May 10, 2018

UPDATE: Various Projects

Not enough time/energy (yay cold) to do a whole write-up, so here is a quick update on what we have been up to:
  1. A while back I ordered a new 3D printer, a Prusa i3 MK3. This gave us the motivation to make some bookshelves that would house the unit along with our other "clutter". Once my partner finished the design I keyed it into SolidWorks, that way we could see how it all fitted together before actually building it. After we were happy it was on to cutting the wood, and wowsers there was so much cutting that we had to make a cover for our circular-saw to catch all the dust. One last interesting point, the shelves were mostly made from wood we had found on the street, we only had to get a couple of meters or extra wood for the bottom rails. Anyway here is how it came out:
  2. I have finally joined the dual monitor club :D After upgrading my laptop screen I had a spare 1366 x 768 panel lying around, so I decided to try and make this into a 2nd monitor. If you have ever seen the port of a laptop screen you would know that you can't just plug it directly into a DVI/HDMI/VGA port, instead you have to use an adapter board. After contacting a seller they said that this board would be compatible with my screen (M125NWR3). If you plan on doing this yourself my advice is to contact the seller, as there is no "one size fits all" converter board. Finally you can get the SolidWorks & STL files here, and here is what the assembly looks like:
  3. Lastly I am working on a small project with a mate. Can't say what it is yet but can say that PCB design is coming along nicely, just need to finish off the last PCB section and then we can place an order for the boards & parts. I also received my ReflowR a while back, so am super excited to try it out with this.

Saturday, February 17, 2018

RESEARCH: Behavior of QX5252F (and probably CL0116)


The QX5252F (and it's brother? CL0116) are a joule-thief type LED driver that can also use a solar-cell to charge a 1.2V (2.4V will now work, for this use YX8018) rechargeable battery. Here I share my findings to try and figure out how this IC works.

Solar-cell Characterization

First off here is the IV & PV curve of the (shoddy) solar cell I made up. The test was done on a hot summer day with clear skies, so results are rough and don't use an exact 1000W/m² lamp.
As you can see peak power (~390mW) occurs at ~1.7V (~230mA).

QX5252F Tests


I used the exact same circuit as shown in the datasheet which you can see here:

L = 100uH

Initially I tried setting the inductor (L) to 100uH, interestingly this limited the charging current to ~40mA. This might be relevant to table on pg3 of datasheet, but this is do LED current not battery current ?_?

L = 20uH

I then lowered the inductor to 20uH, this time current was not limited and the battery got a much better charge. Also the battery I used had a capacity of 1200mWhr and the QX5252F managed to charge the battery to 925mWhr (77%) for the day.

SBAT to VBAT Diode Drop

From further tests I concluded a few of things:
  1. The battery is charged directly by the solar-cell via a Schottky diode, hence the voltage drop varies with current. What this means is that at a low charging current you have a higher efficiency and at a high charging current you see a lower efficiency; for example with above data the peak efficiency (98.1%) occurred at a current of 0.01mA, while the lowest efficiency (83.8%) occurred at 136.44mA, also the overall efficiency for the day was 86.9% which is pretty close to the datasheet value of 90%
  2. I don't think the QX5252F does any maximum power point tracking (MPPT), interestingly enough the peak power (230mW) for the 20uH test occurs at Vsolar-cell ~= 1.7V which if you look at the PV curve (different light conditions) is also the peak power voltage. I think this is more to do with me choosing an appropriate solar-cell arrangement, as when I used the same solar-cell on a YX8018 while trying to charge a 2.4V battery the circuit would peak at 10mA before steadily dropping to 1mA (terrible charging efficiency).
  3. Strangely the inductor value seems to set a charging current limit for the battery, I am not sure how this works as I thought charging the battery occurred via an inline diode. Also looking at the oscilloscope wave-forms I did not see any switching DC-DC converter behavior when charging the battery (light hitting solar-cell). 
  4. When the battery is discharging the operational frequency of the QX5252F is ~133kHz.


The QX5252F is a pretty nifty IC which makes building a simple solar harvesting circuit very easy. A few small downsides is that you are limited to a single 1.2V battery, you have to choose solar-cell that has a Voc of at least 2.4V (2x1.2V) for it to work properly, and there is no MPPT. 

Saturday, January 20, 2018

PROJECT: Solar Picture Frame

Quick update. This year we decided to give our family a solar powered photo frame that used a 3D printed photo from our wedding. Here is how it all works:
  1. During day time sun shines on photo making it visible, sun also shines on solar panel
  2. CL0116/QX5252/YX8018 senses sun is present and decides to charge the battery
  3. During night time CL0116/QX5252/YX8018 senses sun is gone and decides to turn ON the LED’s which in turn illuminates the photo from the back
For the circuit refer to this post from 2015. You will need to replace D1/C1/R1 with a string of LED's in parallel, and play around with L1 till you get the best brightness per current, for me this was 47uH.

Anyway, here is a video of me testing the assembly in SolidWorks before 3D printing the models:

And here is the end result:

Friday, January 5, 2018

PROJECT: Slow Motion Frame

This/last year (2017/2018) I decided to make a slow motion frame to celebrate our Anniversary/Xmas/New Year/Valentines/Birthday... lots of birds with one stone ;^)

Here & here is the tutorial I followed. How the frame works is that the electromagnet causes the flower (or what ever you attach) to vibrate at a certain base frequency (say 79.8Hz), if you then strobe the LED's at say ±0.1Hz to 5Hz to the base frequency you will get an interesting optical illusion, the flower will seem to be moving in slow motion.

And here is a video showcasing it working, as well as some progress photos of the build: