Generating Fibonacci Series with LabVIEW

Fibonacci series can be generated with LabVIEW using a For Loop, Shift Registers and an Addition Operator. In the example below, we provide a Front Panel Control with the number of Fibonacci series entries to generate. We initialize two shift registers, and pass the current Fibonacci sum as well as the previous Fibonacci entry to […]

Using MCP3008 ADC with Raspberry Pi

Raspberry Pi does not have a built-in ADC. Which means an external ADC has to be used to capture analog signals. In theory, it is possible to capture certain analog signals via the audio input jack, but there may be limitations on the signal amplitude and frequency ranges, among other issues. MCP3008 is an 8 […]

Continuously updating audio waveform display using Python

While matplotlib works well for displaying static graphs and charts, sometimes we may need to display a continuous (live) waveform on a graph. This requires repeatedly retrieving and displaying samples of incoming data (an audio stream, for example). An interesting way to display such a continuously varying waveform is to use the ‘Animation’ classes built […]

Creating games with C using ASCII characters

While it is possible to use full fledged graphics to create games, but learning how to use a game engine or a game development framework usually takes time. It is equally fun and probably easier to use only ASCII characters and no graphics libraries or game engines to make simple games. ASCII characters can be […]

How to get values in a dictionary as a list in C#

If you have a dictionary with scalar entities, its is fairly straightforward to get either all the Keys or the Values as a list: Let’s say we have: Dictionary<string, string> MyDictionary To get all the keys as a list: MyDictionary.Keys.ToList() To get all the values as a list: MyDictionary.Values.ToList() If you have a case where […]

Embedding images directly into HTML with C#

The usual approach is to reference an image using the image name. But it is also possible to embed the image directly into a webpage. This is especially useful for report generation where it is required to move the report files from one location to another. Embedding an image into the webpage ensures you don’t […]

Scrolling data into View in a WPF Datagrid

There may be cases where you’d want to programmatically select an item in a WPF datagrid or a list. Usually, if the collection is large and only a part of it is visible at a time, you would also want the items to scroll into view automatically. Otherwise there’s no point in “selecting” an item […]