Sunday, July 24, 2016


If you go out to visit someplace or go on camping a torch will be very handy right? You can use a mobile phone flash for the job but it will be much more comfortable to use an actual torch and it will be more fun if you can make one for yourself right? This post is about making your own LED torch.

Components needed:

1. Integrated circuit: MAX660.
2. Capacitor: 1*22uF and 1*100uF, better to get tantalum type capacitor.
3. Diode: 3*1N4148, LED: 3*High brightness LED.
4. For power use 2*AA Cells.
5. Enclosure for circuit, battery and reflector for LED.
6. Don't forget to put a switch between source and circuit that will serve the purpose of turning on/off.

Circuit Diagram:

 How it works? 

The first question that you might ask is why do we need an Integrated circuit for this! LED can be used directly with a power source, maybe limiting the current via a resistor will be enough and yes you are correct but in this arrangement of constant current provided by the MAX660 integrated circuit that is in voltage Inverter mode will be able to drive them at constant brightness.

So simply we are powering the LED via two AA cells, typically 1.5V per cell for non rechargeable one. You can use rechargeable cells too but probably disposable Alkaline cells will be better suited for this purpose. You might want to read why is that!

Like I mentioned above MAX660 will provide a constant current which in this case is 100mA is enough to drive multiple LED which is done in this circuit.

I forgot to add a switch to this circuit, you can just add it between Bat+ and Pin 8 of the integrated circuit.


1. MAX660 Datasheet
2. LED Driven in constant Current
3. My other posts.

Main Line Powered LED Pilot Lamp

This is a post about AC main line powered LED lamp with minimum components.

There is not much to write about this circuit so I will try to go a bit deeper and explain how the whole thing works. This circuit can be used with any electrical outlet that does not have a pilot lamp or indicator.

So what do we need for this?

1. A small circuit board to assemble, or you can just solder parts to each other.
2. 0.1uF 400V non polar capacitor, it might read 104 in front of it.
3. 1kohm 1/4W Resistor.
4. 1N4004 diode.
5. LED

That's all!

Circuit Diagram:

How it works? 

Simply the capacitor is dropping the voltage and the resistor is limiting the inrush current. The diode 1N4004 is performing two crucial tasks here. First one is it is limiting the maximum reverse voltage across the LED and the second one is it is providing a path for the negative half cycle so that the capacitor can pass current in both direction. During positive half cycle it will pass through the LED and for the negative one like I mentioned above the diode will be used. If you want to work with lower input voltage just increase the value of the capacitor and that's pretty much it!


This circuit is not isolated from the AC main line so do not touch any part of the circuit without testing even when the power is off.


1. Diode 4004 can be replaced with another LED. Same orientation as the diode.
2. A resistor can be used across the capacitor to discharge it when not in use. 

Hope it will help! Happy Experimenting!

You can read my other posts here.
Learn about Inrush Current.

Friday, July 22, 2016

SLi, Everything you need to know

Good evening everyone, today again slightly different topic and kinda written in brief and it is about SLI. Hope you will enjoy it.

What is SLI?

I won't go much into details here with all those technical terms of how it works but to put simply this is a GPU technology developed and used by Nvidia to utilize more than one GPU in a single system to boost the performance. For two cards alternate frame rendering can be used where one GPU renders the odd frames other one renders the even frames thus increasing the overall throughput. Although SLI was first used by 3DFX on their Voodoo2 cards but that SLI meant Scan Line Interleave and SLI used by Nvidia means Scalable Link Interface.

3DFX Cards in SLI configuration

What Do you need? 

1. Multiple SLI capable GPU.

2. SLI enabled motherboard.

3. SLI Bridge.

4. SLI enabled operating system.

5. Proper drivers and applications.

Nvidia GTX980 2 Way SLI on an Asus X99 board.

Gains and advantages: 

1. Substantial performance increase.

2. It might be the case when you already have the best card and you want more performance out of your system you have no choice but to add in another card.

3. Chances are you are running a card from older generation and price of your card has dropped as with the release of new generation it always happens. You can either get a new card from new generation or add in a same card and get more performance out of it.

4. You can easily hit higher frame rates or better quality with SLI, there are games at this time that would even put the best card out there in good amount of stress.

5. Show off and bragging rights, don't deny it many people use SLI just for this. You will get huge scores in benchmarks.

Limitations and disadvantages:

1. Video RAM won't add up which means two 4GB card won't give you 8GB of video memory instead it will give you 4GB. The reason being each card has to store the same data so eventually the total effective memory stays the same.

2. Not all tittles support SLI and many of the games are optimized for taking full advantages of it. So many games will just run on a single card. For example Company of Heroes does not even support SLI, so when I played this game with my SLI setup only one card was essentially taken all the load.

3. Performance does not scale up that much, two cards do not necessarily guarantee 200% performance and three of them won't give you 300% and as more and more cards are added the scaling goes down even further and latest generation of 1000 series cards actually have a lot of things regarding SLI but it is ideal to use only two of them.

4. You will need a SLI capable motherboard that will be slightly costly and as you add in more cards PCI express link width will decrease in most cases. Let me remind you that most common AMD and Intel desktop processors only have 16 PCI Express lanes. For example the Core i7 6700k has 16 lanes. So for single card it will be 16X but if you add in another card the link speed will go down to 8X, adding a third card will decrease the link speed to 4X for two of them. For single moderately powerful card 8X bus speed is enough but for high end card you might loose a little performance for decrease of Bandwidth. However for 28/40 lane Intel Extreme processors you can add up multiple cards without loosing that much bandwidth.

5. A much beefier power supply is needed, preferably one with SLI certification. Personally I use one with a single 12V Rail that can provide good amount of current on it because that way I don't have to worry about balancing the load. To learn more about this you can check this post.

6. Only same Graphics Processing Card can be used together. For example you can use two GTX980 together but not one GTX980 with a GTX970. You can however use different manufacturer. I have used Gigabyte Card with MSI card, as long as they have the same Graphics processing unit you can use them together. DirectX 12 supposed to solve this issue but let's see how things turn out.

7. Cards with aftermarket cooler might make the inside of the case hotter as these cards tend to exert heat inside the case. Blower style reference cards are better in this regard as they blow heat out of the case. Moreover top card might run hotter in many cases as it will get less air due to the close proximity of another card.

8. In poorly optimized games it might result in stuttering which drastically decreases the overall gaming experience. You will see that the game is running at a very high frame rate but frame time will be so different that the game won't be enjoyable any more. For example I had this issue with Far Cry 4 and Call of Duty Advanced Warfare with my SLI setup.

9. Many CUDA enabled software won't be able to use both cards at the same time. In that case a single card would have been better.

Final thought:

So if you are out for shopping a new card buy the absolute best you can get for your budget. It is not wise to spend on two moderately powered cards over a powerful one. Think about it in this way, if you want to accommodate multiple cards you will be using SLI enabled motherboard and high end power supply unit rather you can just go with a single GPU and a slightly cheap board which will actually give you more performance for the money.

But like I said earlier, if you want the absolute best and even the single card in the market is way below your maximum capability, by all means go ahead and add another one and if you want to get a older generation card to pair with your existing one rather than buying a new generation card, you can do that too.

That's pretty much it, good day everyone.

Visit my full blog here.

Tuesday, July 19, 2016

Why does Bangladesh Import academic books?

Good evening, so I came across this interesting discussion so I think it is worth sharing!

Let's talk about O/A level books first.

As far as I’m concerned they have to stick to the regulations of IGCSE and most O/A level books that I have seen might be from India but they are not written by Indians rather most of them are written by probably Europeans. So probably even if any Bangladeshi person writes a book on O/A level topics won’t be accepted as a textbook and students have to buy the ones that are suggested by the curriculum. This is a standard they want to maintain or maybe even a monopoly so won’t accept anything else.

Look at school and college level books, they are pretty much the same as O/A level books only difference being O/A level books have more topics but SSC/HSC level books go much deeper into any certain topic and these books(SSC/HSC) are written solely by Bangladeshi writers, you probably won’t find any SSC/HSC book written by anyone else, even the ones that are in English so apply the same thing to O/A level, it is easy to understand Bangladesh has to import them. You probably will get pirated O/A level books in Bangladesh too, printed locally.

*Now what is wrong with Bangladesh’s publication industry?

Nothing is wrong, they act the same way as any other publication industry, quality is not the concern, profit is so they will publish anything that sales better no matter what the quality is and then again for artistic point of view everything is relative.

*Don’t Bangladesh has quality writers?

Question to this answer actually lies within the answer of your next question so let me tackle both at the same time.

*Don’t Bangladeshi people buy books?

This is a broad question because you were talking about Academic books but now this question also applies to general class too. The simple answer is no, most Bangladeshi people don’t want to buy books anymore and they read much less than they once read at a time and you can guess the reason too, there are more ways of entertainment available this days, you have huge amount of TV channels, radio channels, social networking sites, YouTube etc and Bangladesh has moderately high speed internet this days so people passes time on them more than anything. Look at the modern generation, they rarely read a book and what can you do they have grown up with these technological wonders and we all know how they can impact attention. There was a time when people bought a lot of books. Book fairs had huge amount of sell, libraries had too but now people just visit those places and if you don’t have an audience no one’s gonna create what a small minority might demand. You probably won’t get to live by the earning from writing a book so it is better to do something else and think about it more and more generations are distancing themselves from books so who is going to write them?

On academic level however it is even more painful, most people will go to KFC or Pizza hut and spend thousands on food, they will buy pricey dresses, pricey cosmetics but when it comes to buying books they will look for free digital copy, not all of them of-course but most of them will do it and can’t fathom this. Many private universities solely depend on presentation files and often times people print them or use any device to read them so the market is shrinking, if you write something and no one buys that you won’t write anymore.

Although luckily we have some good books written by teachers from University of Dhaka, I can give one good example, math books like Linear Algebra, a good book written by Prof. MD. Abdur Rahman of dept. of mathematics. I will hope view of Bangladeshi people will change and then Bangladesh can import less and it will eventually fuel other teachers to write something.

Hope it has given you something to think about. 

Q:1 Non Rechargeable Batteries, why do we still use them?

Good evening everyone, this is another new segment where I try to write about question or queries that I was asked and think they are worth writing about. So the very first post is about batteries, rechargeable versus non rechargeable. In this day and age where rechargeable cells are very common why do we still use one time use ones? If you have this question too let's see if I can answer that.

Collection of non-rechargeable AA cells
NiMH AA cells being Charged

Most devices that we use today are powered by rechargeable cells and it is understandable why because even if the rechargeable one will cost you more money to get it will cover that up with it's ability to be used for many times. Even if you have to buy a charger for it and charging will cost you some electricity bill yet your money will be saved because you will be able to charge them and use them for moderately long period of time.

Both rechargeable and non-rechargeable cells have their usage and most of the time in different scenarios. So let me mention some of those scenarios where non-rechargeable cells might perform better and then explain why.
  1. In low drain devices like Infrared Remote Controller, Electronic Calculator, Wall clocks or different other similar gadgets non-rechargeable cells are better. Lets think about the wall clock, you know those clocks that run on single AA cell. If you put a normal AA cell that might cost 1/8th of a dollar it probably will run for a year, put an Alkaline one that might cost you 1/2 dollar and it will run for around 3 years so where is the point of even putting a pricey rechargeable cell! Same thing is true for other products that I have mentioned.
  2. Electronic devices that are hardly used and might sit on the shelf for a long time and you might need them to work right away, in this case Disposable cells will be much better suited.
  3. One thing to remember is the NiMH cells have a nominal voltage of 1.2V where standard non rechargeable ones have 1.5V so in many cases the rechargeable one might be considered to be low in voltage even though it has good capacity left.
  4. Charging NiMH is a bit tricky so you will need a good charger so ultimately you will have to invest a good amount of money if you want to use rechargeable cells as oppose to non-rechargeable ones.
Now let’s think about why. Well the very first reason is self discharge rate of NiMH is much higher than non-rechargeable Alkaline cells. The AA Alkaline cells that I bought last year comes with an expiry date of 2022 and I know for fact that they will even work after that time but NiMH will need to charged up occasionally.

For low drain device it might even be the case where the current that the device drains is smaller than the self discharge rate so really not suitable for low drain devices and if for devices that are just kept for emergency like a flash light if you just keep that like for couple years chances are the NiMH cells will just discharge fully and won’t work when you will need it.

NiMH dumb chargers might not be that pricey but they are not good for the cells and might overcharge and cause them to fail prematurely to avoid this you will need a smart charger and usually those smart chargers cost much more than dumb ones.

Another important thing to remember is the environmental impact, yes primary cells(or non rechargeable cells) might be the the bigger contributor to this although the use of mercury is no longer prohibited so environmental impact is not that severe and as I was saying earlier if an AA Alkaline can power a wall clock for 3 years that impact is really negligible although we should be careful while using these cells, stopping unnecessary usage will be eventually be better for everyone.


Notice that I have spoken mostly about NiMH, why is that? Because in places where lithium ion or lead acid batteries are used it is very hard to replace them with non-rechargeable ones as the cost will go up significantly for example in mobile phone or laptop or uninterruptible power supplies but for NiMH in low drain application you might even get better value using non-rechargeable cells.

Hopefully this small discussion has given you something to think of.

Visit the Index page of my blog for more posts.