2015. május 13., szerda

DevEnv - LightUp - followup

It looks like my previous problems with LightUp gets handled.



Two days ago a Kickstarter update come. Two major things in it:
  • The public beta of the LightUp Code what is basically Scratch for Arduino what supports the LightUp MCU and in addition Arduino boards
  • The new Faraday Kit what contains the new LightUp MCU modul, what is programmable through Bluetooth. It looks like an iPad will be enough for programming, no desktop and driver hassle needed anymore
And yesterday also the new Kickstarter campaign for the Faraday kit started, what I put on the right side in the blog also.
Well done guys!

2015. május 8., péntek

Router repair

To be honest, I've confusing thoughts about repairing various electronics equipment. Some of the people tell, just trow away what is stopped to work. Others tell, to repair everything. As I see the world goes to the first direction. Less and less electronic equipment gets repaired. It is just not the cost of the repair, but also energy efficiency issue. I'm somewhere between this two. I think we should consider each time, various factors.
To the people who say throw away and buy a new one:
What if we have a Wi-Fi router. It aged, but not to much (already Wi-Fi N based). Likely 3-5 years old. A new one costs $50-70. Died. Low cost, throw it away.
But...
What if? The problem can be identified with just looking on the board:


and the repair costs ~$0.2 and 10 minutes work?
The dead cap - originally 680uF:


By the way. May I ask the dear manufacturer why a hack they are using the cheapest crap capacitor in the most critical part of the circuit?
The 20 cent is the price of the cheapest crap at the local store, but...
You can get a Panasonic with 8000h endurance for 15 cents/piece in 1000 pack at Farnell (what is not cheap).
Cap changed, router works.

2015. május 5., kedd

CNC Motor Driver 5.

I planed to build the new motor driver during the weekend, what unfortunately doesn't happened. It took an additional week. What I want to mention here, that together with the motor driver I also designed a new measurement circuit. This one is able to measure not just the rotational speed but the current (it was also in the previous but untested) and the voltage of the motor. In addition I included the necessary protection diodes what was left out from the previous one, and a configurable fifth order low pass filter to test the filter for the final design.

Here is the schematic diagram:

And the PCB design:


The first weekend achievement - etching the boards and collecting the parts:


A week later - the boards cut, populated:


The next things to come (not necessarily in this order):
  • Test this two boards
  • Design a home made pcb for MCU+Display
  • Add additional filtering into the adjustable DC
  • Design and build the last missing piece - the high voltage input 3.3V PSU
  • Test and tune the PID controller code
  • Move to the final PSU from the lab supply
  • Put everything together - write the code for the rpm setting from G-Code
  • Write the code for the voltage/current/power measurement
  • Design and order the final boards
  • Build everything into the original controller box

2015. április 30., csütörtök

Freescale training

There was an MCU training organized by Freescale here in Budapest. This was the third one I attended in the last two years.
It looks like I was the favorite of one of the instructors (had answers to the questions raised to the audience, and had on spot questions):

2015. április 24., péntek

CNC Motor Driver 4. - MOSFET Driver revised

I was thinking, looking around a lot before I designed and built the current motor driver circuit. I wanted to use something cheep, something I can learn from.
The current one is working, but I was thinking, how can I make it a little bit faster. When I designed the current one, experimented lot on the breadboard, but not used ltspice to simulate the circuit. When it was finished, I needed to tweak it, here and there, to be able to reduce the noise for the clear measurement signal.
Now I'm trying to get faster switching, to reduce the heat generated by the MOSFET.
First of all I run a simulation of the original circuit.

The circuit:
And the result:
As you can see the the timing results:
Switch on time: ~500ns
Switch off time: ~500ns

After 2-3 weeks of continuous (in my spare time, what I not really have to much) simulation, changing components, pursuing different ideas, finally I created a little bit better one.

The circuit:




And the result:
And the timing:

Switch on time: ~30ns
Switch off time: ~100ns

Much better.
Based on the things above, I designed a little bit different circuit. The reason: I use mostly trough hole components for the home made PCB and switch to SMD when I order the final one.

The schematic
And the PCB design:
Hopefully I'll be to build it during the weekend.

2015. április 6., hétfő

CNC Motor Driver 3.

Since the last post regarding my CNC Motor Driver, in my spare time I was continuously working on the MCU board and the software for it.
Two days ago I connected the digital part to the power electronics. It started to work immediately, but unfortunately the rpm measurement was messy.
After some thinking and trying, I realized, that the source square wave has some narrow pulses around the edges, what are messing up my measurement.
The Nuvoton MCU I'm using is able to add some de-bouncing delay to the timer's capture input. Adding this feature looks like solving my problems.



Today finally I see the end of this project's. I'm trying to collect the thing still need to be finished:
  • Test and tune the PID controller
  • Try out additional filtering on the power input side
  • Try out additional filtering at the motor
  • Try out the 5th order filter I designed for the measurement
  • Test and write code for the current measurement
  • Add voltage measurement solution (circuit and code)
  • Add code for power display
  • Add code for measuring the control signal from the Linux CNC (this allows the control of the rotational speed from g-code)
  • Design a high voltage input 3.3V power supply (actually the 48V input is to much for the regular buck converter chips)
  • Design and order (hopefully) the final panel for the whole electronics
  • Correct the code for the rotary encoder (it is a little bit problematic today)
  • Clean up the code (not modularized enough, many comments missing)

2015. április 5., vasárnap

Dev Env - LightUp

The story starts almost two years ago.
As my son gets older (8 years old now), I was thinking to teach electronics, programing or both to him somehow. As I looking around just pop up something called LightUp on the Kickstarter.

http://www.lightup.io

I immediately jumped in to it, hoping that I'll get it to Christmas of 2013.
It didn't happened. After long waiting I got the kit sometime in Autumn 2014. It became a Christmas present for 2014.
My son started to play with the electronics part of the kit but not touched the MCU module included. As he reached the point making all of the tasks was included in the iOS app (what is unfortunately not too much), I tried to setup the MCU.
It was something like two month ago, and it was a major failure. I had two problem with it. The first is theoretical. I don't believe that is the best language to teach an 8 year old to program is the C++ even it is the simpler arduino's one. The second is the driver.
LightUp partnered with codebender to provide programing environment to the kit. Codebender is nothing else just an online Arduino IDE. They provide a driver pack, what is able to connect to virtually every Arduino compatible board. But the driver pack was not working with the LightUp MCU on my desk.
The story was put aside in this point.
A few days ago I seen, that my son started to play with the LightUp kit. This was a good indication to put some further work into the setup.
Went to codebender, downloaded the driver installed it, and the result was the same as two month ago:
This time I wasn't stopped here:
After installing it the result:
Success!
Finally I went to the CodeBender side to try it. When I started the IDE for the LightUp a LED blinking project was showing up:
Just downloaded it to the board, and started to work:
Conclusion:
What I see about the LightUp: This is an unfinished something. After a good start they lost their tempo. The idea to check the circuit with a camera is exciting, but they got nothing more. A large amount of example circuits and a kid friendly programing environment is missing.
In addition tons of far better kits are exists on the market (for example littlebits), what is kid friendly and gives the possibility to grow further. This one not.