Author Archives: Andi

Sensor Nodes Based on the Raspberry Pi

Building sensor networks is economical if a microcontroller hosts the sensors. However, sometimes the computational power a microcontroller offers is not adequate. For instance, it may be necessary to convert the data to a different format, print a hard copy of the sensor data, or incorporate the data within an application. What you need is a computer that not only has more processing power, but also allows the use of common applications, affords access to peripherals, and permits the use of scripting languages.

Although the use of an inexpensive personal computer would be of great advantage here, using them as sensor nodes in the networks has its own disadvantages. The primary hurdle is most personal computers are built for use as servers or desktop computers, and almost no general-purpose input/output ports are available. Of course, a data collection card added to the personal computer will serve the purpose, but the cost of the computer added to that of the data-collection card makes the cost of the sensor node uneconomical.

Fortunately, single board computers such as the Raspberry Pi (RBPi) provide an easy solution to the above problem. With sufficient processing power and memory, use of standard peripherals, supported programmable I/O ports, and a small form factor, the RBPi is the most suited for building sensor networks economically.

Essentially, the RBPi is a single board computer that runs Linux as its operating system. To get started with the RBPi, you need a few additional things, such as a USB power supply rated at 2 A with a male micro-USB connector, an HDMI monitor, a keyboard, an optional mouse, and most importantly, an SD card to hold the OS.

The most commonly used operating system for the RBPi is the Raspbian image provided by the Raspberry Pi Foundation on their download page. Once you have downloaded the image, you will have to unzip it and write it into an SD card. The easiest way to do this with a Windows PC is to use the Win32 Disk Imager software. Those on the Mac OS X or the Linux PC may use the dd command.

Now it is time to boot up your RBPi board. Plug in the SD card holding the new image, plug in the keyboard, mouse, and the monitor. Once all the peripherals are in place, plug in the USB power and turn on the power. When prompted to enter a username and password, use Pi and raspberry respectively, and configure the system to your requirement.

For connecting and experimenting with sensors, you may use expansion boards, but using a simple prototyping board instead is more flexible. Using a Pi Cobble Breakout board or similar allows a simple ribbon cable from the GPIO connector on the RBPi to the prototyping board, with the pins arranged in the same order as those on the RBPi are.

Be careful to make or change connections with the RBPi powered off. Also double-check all connections are rightly connected. The GPIO on the RBPi is not protected against short circuits and high voltages, and is easily damaged.

Intelligence in LED Lighting

Apart from illuminating dark spaces there is much more to LED lighting than otherwise thought of. LEDs can be connected in an intelligent network with a low-voltage IP-based infrastructure, and they become a part of a powerful network of systems. Such a system can cooperatively collect, analyze, manage, control, and respond to specific objectives based on real-time sensor feedback.

The building lit up by these LEDs now behaves as a smart building, offering better operational performance. It responds dynamically to operating issues related to power consumption and cost, increasing efficiency and efficacy. Moreover, such integrated intelligent lighting works smoothly with the other systems in the building.

The major issue confronting LED networks is decoupling from the relatively universal approach of a centralized lighting control. It makes more sense to change over to a solution that caters to the specific requirements of smaller segments across a large area within the building. Moreover, as lighting is a part of the intelligent network, it can integrate with and respond to other components on the network. Such an approach works very well for commercial office buildings, warehouses, healthcare facilities, manufacturing and industrial facilities, and other similar large or multipurpose areas, where a centralized approach will be inefficient and ineffective.

As an example, buildings are very commonly controlled through automated heating, ventilation, and air conditioning−also called the HVAC system. The HVAC has the task of monitoring and adjusting the temperature to make the building suitable for human comfort and machine performance. Moreover, it does this at optimal efficiency and cost. An intelligent LED lighting network connected to the system would allow lighting to synchronize into the same set of objectives. Now, the lighting couples actively and responds to environmental climate control.

This gives the lighting network the intelligence to increase the ability of users to adjust the light within the building to increase human productivity, concentration, positive mood, and well-being. Moreover, by adjusting light synchronized to the natural circadian cycle and adjusting the amount of light required depending on the amount of sunlight filtering through external windows, additional potential advantages can be achieved.

All intelligent LED lighting networks need power, and the key technology behind this is Power over Ethernet (PoE). This brings the equipment and low-voltage cabling necessary to connect the assets of Internet of Things (IoT) to LED fixtures. The success of IP-based infrastructure platforms makes PoE simple and available. Therefore, by using PoE as the arteries of the LED lighting systems for power and control, lighting also becomes a part of the building’s IoT asset.

PoE provides an infrastructure that is less expensive compared to copper cables, while offering a single layer for transferring power and data. Typically, the PoE system architecture consists of the PoE gateways, LED light fixtures, LED lights, smart drivers for LEDs, cable harnesses, sensors, wireless switches and dimmers. In general, PoE gateways are configured to use any one source from unregulated 48 VDC, constant voltage 24 VDC/48 VDC, or constant current.

There may be wireless PoE gateways as well, conforming to IEEE 802 standards. Usually, they run at standard frequencies such as 902 MHz in the North Americas, and at 868 MHz in Europe.

Less Expensive 3D Printing

3-D printing is no longer a new technology. Several design studios use it, along with some home users who make their products using 3-D printers. However, the general opinion is it is expensive, slow, and unable to compete with traditional mass-manufacturing processes. Although considered a revolutionary technology, so far, 3-D printing has remained on the periphery.

Now, a Massachusetts company is trying to prove the general opinion wrong. Desktop Metal is coming out with a 3-D metal printing system so fast, safe, and cheaper than any existing system, they claim it will compete directly with the traditional methods of mass manufacturing. In their Studio System, Desktop Metal presented an office-friendly, fully automated sintering furnace that had fast cycle times and a peak temperature of 1400°C. This allowed it to sinter a wide variety of materials.

On one hand, home users and design studios can afford only cheap ABS plastic printing materials on their desktop printers. On the other, organizations such as Boeing and NASA are going for laser-melted metal printing. Overall, the entire process of 3-D printing is very slow, expensive, and unable to scale up or scale down.

Desktop Metal, out of Massachusetts, is headed by a team among who are some that had first thought of additive manufacturing. They claim to have the right technology and machinery that is going to give the necessary impetus to 3-D printing to make it into big time.

Desktop Metal is claiming it can make metal printing reliable and up to 100 times faster than existing speeds and at 10 times cheaper initial costs. By using a much wider range of alloys, they claim they will incur 20 times cheaper material costs compared to the existing laser technologies. In fact, their machines may be the precursors for large-scale 3-D manufacturing.

In reality, Desktop Metal is presenting two systems. One of them is the Studio System and the other a production system. While the production system is meant for mass manufacturers, the studio system offers rapid, cheap metal prototyping aimed towards engineering groups.

The Studio System from Desktop Metal costs ten times lower than its equivalent laser system. It is also many times more safe and practical to keep in an office. Unlike the laser system, the Studio System does not use hazardous metal powders that are sometimes explosive or dangerous lasers. The Studio System may be placed anywhere in the office, as it does not require specialized ventilation installation, nor does it require operators wearing gas masks.

The metals offered by Desktop Metal are usually in rod form, bound with polymer binding agents, and shipped in cartridges. However, almost anything usable in a Metal Injection Molding system is acceptable to the Studio System. That means a wide variety of metal options including aluminum, bronze, copper, a range of stainless steels, 4140 chromoly steel, titanium, Hiperco 50 magnetic, and more than two hundred other alloys.

When running, the printer prints layers of bound metal parts. These have to go through a de-binding bath to remove most of the binding polymer. The parts can then go into the sintering furnace.

Bluetooth 5.0

Custodians of the Bluetooth standard are a flexible lot, considering the enhancements the popular short-range 2.4 GHz wireless technology has been receiving. The Bluetooth SIG or Special Interest Group has allowed it to evolve in ways not envisioned by the inventors. Their foresight will be allowing this technology to expand beyond three billion shipments beginning next year.

The latest incarnation of the technology is the Bluetooth 5.0. This indicates the seriousness with which SIG wants to entrench Bluetooth as a vital component of the IoT or Internet of Things. By 2025, more than 80 billion connected things will be busy exchanging data across networks wirelessly. According to IDC or the International Data Corporation, Bluetooth will be the governing standard for these networks.

That is understandable, as Bluetooth has its roots in short-range handset communication. It all started in mid 90s at Ericsson, when engineers Sven Mattisson and Jaap Haartsen wanted to get rid of the jumble of wires linking their electronic devices. They devised low-throughput, short-range radio links for exchanging information between handsets, without having to plug in a cable. The Ericsson endeavor turned into an open standard operating in the unlicensed 2.4 GHz band, and several others joined them, including Toshiba, IBM, and Nokia.

Around 1998, the standard was named Bluetooth, after an ancient Scandinavian king. However, performance of Bluetooth 1.0 was below expectations, achieving only 700 kbps under ideal but practical conditions. In addition, manufacturers had their own problems in getting their equipment to interoperate. Subsequent iterations not only added bandwidth but also added 79 1-MHz channels for randomly hopping around to avoid RF interference from other devices on the license-free 2.4 GHz band.

Incorporation into cellphones brought major success to Bluetooth, as the handset started to be center of the personal area networks, linking almost everything electronic to the smartphones. Additions to the firmware stack of Bluetooth optimized its performance to suit specific applications, such as in cars, printers, speakers, and in PCs. By now, Bluetooth was in version 3.0+, with a bandwidth of 3 Mbps. Moreover, by co-locating to an 802.11 channel, Bluetooth was soon competing with Wi-Fi at 24 Mbps.

Bluetooth was able to achieve its biggest breakthrough with version 4.0, also called Bluetooth low energy. This version introduced a second radio using a lightweight stack but interoperable with its elder brother. Now, even compact wireless devices could send a tiny amount of data in a rapid burst, returning to an ultra-low power consumption state of sleep. This mode allowed the devices to operate for long periods from small-capacity batteries.

With Bluetooth 5.0, its low energy part also gets a speed boost to 2 Mbps, which makes things run far more smoothly. Now, IoT sensors can receive over the air updates to keep them protected from hackers. The range has also increased four times. This makes Bluetooth 5.0 viable for the entire house applications such as smart lights, with the throughput dropping to 125 kbps when the range is extended.

To make it competitive to other industrial and smart home networking technologies such as Z-Wave, Zigbee, and Thread, Bluetooth 5.0 now incorporates the Mesh Networking standard.

Choosing a Regulator – Switching or LDO

Unlike AC circuits where a simple transformer can change the incoming voltage to a different level, DC circuits need an active device to change the voltage to the desired level. In general, there are two types of circuits to do this—switching and linear. Switching regulators are highly efficient and work on buck, boost, or buck-boost technology to change the voltage level. On the other hand, linear regulators such as LDOs are ideal for powering very low power devices or applications where the difference between the input and output voltages is small. Compared to switching regulators, linear regulators generate lower noise, are simple and cheap, but inefficient.

Linear Regulators (Low-Dropout Regulators)

Using linear circuits and non-linear techniques, linear regulators regulate the voltage output from the input supply. The resistance of the regulator varies according to the load and this creates a constant output voltage.

Irrespective of their make and design, all linear regulators must have their input voltage at least some minimum amount higher than the desired output voltage. Engineers call this minimum amount as the dropout voltage. An LDO regulator or low-dropout regulator is a DC linear regulator that is able to regulate the output voltage even for very low differences between the input and output voltages.

Therefore, applications that need an input voltage very close to the supply voltage and consume low power are ideal for linear regulators. As the product of the load current and difference of the input and output voltages governs the power dissipated by a linear regulator, a smaller difference means the regulator can handle higher power or allow a higher load current.

Although the linear regulators or low-dropout regulators offer a simple and cheap solution, these devices are notoriously inefficient as they dissipate heat based on the difference between the input voltage and the regulated output voltage. Most low-dropout regulators are low-current devices, offering well-regulate outputs, and require very few external components. They usually come in small packages, have fast transient response, and are highly accurate.

Switching Regulators

Most solutions for power management today require low power consumption under various load conditions, ability to operate in small spaces, offer high reliability, and the capability of withstanding wide input voltages. Therefore, a broad range of applications is moving towards highly efficient, wide input, low quiescent current switching regulators.

Switching regulators work by switching a series element on and off very rapidly. The series element can be either synchronous or non-synchronous FET switches. Usually, an associated inductor stores the input energy temporarily, and releases the energy subsequently to the output circuit at a different voltage level. The duty cycle of the switch determines the amount of charge transferred to the load.

Switching regulators operate efficiently, as their switching element dissipates almost no power, because the element is either switched off or fully conducting. Unlike linear regulators, switching regulators can generate output voltages higher than the input voltage or of the opposite polarity.

Therefore, switching regulators offer wide input and output voltage ranges, integrated series elements, pin-to-pin compatible parts, internal compensation, and light load efficiency modes, while being simple and easy to use.

Measuring 16 Temperatures Remotely

In several cases, one cannot access the area where the temperature needs to be monitored. For instance, the temperature inside a kiln may reach a few thousand degrees, which is beyond the tolerance of humans. Environment chambers may need to be completely sealed off when operating, which means monitoring the conditions within has to be remotely accomplished. Simpler cases may also be considered, where the computer logging the temperature is in a central location, whereas the monitored sites are spread out in different rooms.

The ideal instrument should allow measuring temperatures over a local or remote network, with a built-in web-server to access the instrument, requiring neither programming or app. Measurement Computing has just the instrument and it is the WebDaq-316, a stand-alone temperature logger that allows the user to measure temperatures on 16 channels using J, K, T, E, N. B, R, or S type thermocouples. The user can access the instrument through its web-server over a local or remote network.

With 3 GB of internal acquisition memory, the WebDaq-316 acquires samples at the rate of 75 samples/sec. However, if the memory is insufficient for the job on hand, the user can add more by inserting two USB flash drives or an internal SD memory card. The measurement data can be transferred from the SD card, flash drive, or the internal memory. Alternately, the user can download the acquired data from the web-server as well. It is easy to import the data to an analysis software or a spreadsheet as the WebDaq stores data in CSV format.

The user can operate the WebDaq-316 in two modes—normal or high resolution. In the normal mode, the instrument works at 75 samples/sec or 78 Hz maximum, whereas in high-resolution mode, it can scan at less than one sample/sec across all channels. In the high-resolution mode, WebDaq-316 drops its bandwidth to 14.4 Hz, which also lowers its noise and gain error. That allows the 24-bit delta-sigma ADC on the instrument to operate at its peak efficiency.

The web-server has the ability to send SMS texts or e-mail messages. Therefore, the user can receive an appropriate notification whenever a temperature moves out of limits. Additionally, there are four programmable digital IO channels on the WebDaq-316. The user can make use of these IO channels to operate some local activities such as trigger an alarm or shut down equipment. As the IO channels are programmable, they can be inputs or outputs. As inputs, they can act as trigger depending on external signal, and as outputs, they can trigger alarms. The channels are available on terminal strips on the front panel, which makes all T/C and DIO connections easier.

The user can assign measurement operations through jobs and schedules. For instance, the user may want to change jobs or sample rates whenever a temperature crosses the limits, or return to a schedule of lower rate when the temperature returns within the limits. The user may also want to schedule jobs for triggering alarms or receiving notifications of such conditions.

Based on the Raspberry Pi compute module, the WebDaq-316 operates on a DC power source of 6 to 16 V. This allows vehicular operation as well.

Measuring Air Quality with IoT Sensor

Bosch Sensortec is making an IoT environmental sensor for measuring air quality. The BME680 can measure the indoor air quality, relative humidity, barometric pressure, and ambient air temperature. It has four sensors housed within a single LGA package measuring 3x3x0.95 mm, and both mobile and stationary IoT applications can use the package for use in smart homes, offices, buildings, elder care, sports, and fitness wearables.

The BME680 measures the indoor air quality through its internal gas sensor by detecting a wide variety of gases in the range of parts per billion. The gases it can detect include hydrogen, carbon monoxide, and volatile organic compounds. While measuring altitude and pressure, the BME680 is accurate to within ±1 m and ±12 Pa respectively. Its temperature measurement capability extends from −40°C to +85°C, and it can measure relative humidity from 0% to 100%. In addition, the BME680 can measure an offset temperature coefficient of 1.5 Pa/K.

The BME680 consumes current according to its measuring parameter. While capable of operating from a supply voltage of 1.71 V to 3.6 V, it has a data refresh rate of 1 Hz. When measuring temperature and humidity, the BME680 consumes 2.1 µA, and 3.1 µA when measuring temperature and pressure. The current consumption goes up to 3.7 µA when measuring pressure, temperature, and humidity, while the maximum consumption is between 0.09 and 12 mA when the device is measuring gas, temperature, humidity, and pressure. Therefore, although the current consumption depends on its operating mode, its average current consumption in sleep mode goes down to 0.15 µA.

As an integrated environmental sensor, Bosch Sensortec has developed the BME680 specifically suited for mobile applications and wearables. As for both applications the size and low power consumption are key requirements, Bosch Sensortec has expanded its existing family of environmental sensors by adding the BME680 to its repertoire, while integrating the temperature, humidity, pressure and gas sensors, all of which are highly linear and highly accurate.

The BME680 comes in an 8-pin metal lid LGA package measuring only 3x3x0.95 mm. Bosch Sensortec has designed the sensor for optimized consumption that depends on its specific operating mode, high EMC robustness, and long-term stability. The specialty of the gas sensor within the BME680 is it can detect a wide spectrum of gases for assessing the indoor air quality for individual well-being. For instance, the BME680 can detect VOC or volatile organic compounds from alcohol, adhesives, glues, office equipment, furnishings, cleaning supplies, paint strippers, lacquers, and paints based on formaldehyde.

Applications for the BME680 are numerous. It can be used for altitude tracking as well as calorie expenditure for sports activities. It is sensitive enough for indoor navigation as it can detect change of floors and elevation. As GPS enhancement, it can improve time-to-first-fix, slope detection, and dead reckoning. As home automation control, the user can use the BME680 as an advanced HVAC control. Scientific experiments can use it for measuring volume and airflow, while agriculturists can use it as warning against dryness or high temperature. Sports enthusiasts can use it for monitoring fitness, well-being, detecting skin moisture, change in room, and for context awareness. BME680 is suitable for use as a personalized weather station and for indoor air quality measurement.

Voice HAT for Raspberry Pi for Controlling a Motor

If you were one of the unlucky ones to miss out on the issue 57 of the MagPi, then the only option is to buy the Voice HAT from the AIY projects. The issue 57 had offered a free AIY projects Voice Kit, which Google had developed to make a Voice Assistant, and you could control a speaker with the voice HAT that attached on top of a Raspberry Pi Zero (RBPiZ).

Other tutorials in the MagPi show how to connect the Voice HAT hardware to simple circuits.  So far, the tutorials have dealt with LED lights and servomotors, but this project is somewhat more complex—using the Voice HAT to control a DC motor. Therefore, you will need a DC motor, four AA size batteries, breadboard, and jumper wires.

Usually, the RBPiZ draws its power from the power supply on the Voice HAT board. For this project, this connection has to be broken, else the motor may draw too much power from the RBPiZ and short it. On the Voice HAT board, locate the external power jumper marked JP1, and use a sharp knife to cut the track. If you later wish the power to be shared again between the board and the RBPiZ, re-solder the cut joint.

Power off the RBPiZ and the Voice HAT, and connect the positive terminal of the DC motor to Driver 0, middle pin, which is marked with a “+” symbol. Same way, the negative terminal of the DC motor connects to the “–“ pin of the Driver 0. As this pin connects to the GPIO4 pin, it allows the motor to be turned on and off.

The four AA battery pack connects to the +V and GND pins on the Voice HAT. This ensures the motor is supplied adequate power from the battery pack and the Voice HAT and does not crash the RBPiZ when it draws power. Now turn on the power to the Voice HAT, and then turn on the battery pack.

At this point, you are ready to turn on power to the RBPiZ. Boot into the AIY Projects software and enter the code from motor.py for testing the circuit. The control to the motor comes from the PWMOutputDevice from GPIO Zero, and this allows managing the speed of the motor.

The motor is controlled via a Pulse Width Modulation (PWM) method. The RBPiZ controls the power to the motor by controlling the on and off periods. If the on period is more than the off period, the motor receives more power and therefore, rotates faster.

To manage the speed of the motor, you control the variables .on() and .off() in the software.  Alternately, you may set the value of the instance variable to a value between 0.0 and 1.0 for controlling the speed. Here, 0.0 means the motor is a dead stop, while 1.0 sets the motor to a maximum speed. The motor.py uses both techniques and you can also use pwm.pulse() for pulsing the motor on or off. To integrate this with the Voice Assistant, enter the code from add_to_action.py to the relevant sections. You can now control the motor using voice commands.

3D NAND Memories Cross 10TB

At the Flash Memory Summit in Toronto, Micron Technology exhibited their NVM Express or NVMe Solid State Drives that use the company’s 3D NAND technology to achieve capacities over 10 TB.

According to Dan Florence, Micron built the 9200 series of NVMe SSDs from ground up to overcome the restrictions placed by the legacy hard drives. Dan Florence is the SSD product manager for Micron’s Storage Business Unit. The design of the new storage portfolio addresses the data demands that are presently surging, while maximizing the efficiency of data centers. According to Florence, this improves the overall total cost of ownership for customers. The NVMe over Fabric architecture of Micron is way ahead of standard developments, and is the storage foundation for the Micron SolidState Platform.

According to Florence, the 9200 SSDs from Micron can be up to ten times faster than the fastest SATA SSDs. The 9200 SSDs can achieve transfer speeds of 4.6 GB/s with one million read IOPS. This makes them ideal for high-capacity use case performance as application/database acceleration, high frequency computing, and high frequency trading. Regular interfaces were more attuned to spinning media, which allows NVMe several advantages over the traditional interfaces. As the NVMe sits on the PCIe bus, it not only overcomes a huge amount of latency, but also offers higher bandwidth, allowing users to get much higher IOPS.

Traditionally, PCIe has many custom drivers working in iterations, and the NVMe offers better ease of use. This is allowing NVMe SSDs to be adopted faster, as they can be plugged into almost any system and with any operating system.

The earlier generation of NVMe SSDs from Micron was limited in capacity. The 9200 series can go up to 11 TB, almost three times the capacity of the older generation, making then the first monolithic NVMe SSDs to cross the 10 TB boundary. That also makes it easier for the operating system to manage, while allowing for lower power consumption. Additionally, Micron makes the 9200 series in the U.2 form factor, which allows the new SSDs to achieve more density per server.

Micron claims their new NVMe SSDs, in random performance, can outperform the fastest hard drives by 300-1200 times, and the fastest SSDs by three to seven times. Of course, this is dependent upon the use case and configuration. According to Florence, database applications and transaction processing are increasingly using random performance, as they use a random IO access pattern. Moreover, the workload of several data analyses also follow the same pattern, since working with large pipes of data makes sequential handling more important for data ingest. This includes massive amounts of IoT data as well as user-generated content.

Most general applications also use some level of random IO, and the new NVMe SSDs can use most of the bandwidth in the PCIe bus. According to Florence, the value driver lies in the amount of data moved and worked with, which is also applicable to a growing number of applications. The new NVMe SSDs are a clear leader this area, as the dollar per IOPS becomes increasingly more important.

Charlieplexing on the Raspberry Pi

If you suddenly find the need to control many LEDs and do not have the requisite electronics to do so, you can turn to your single board computer, the Raspberry Pi (RBPi) and use it to charlieplex the LEDs.

Charlieplexing is named after Charlie Allen, the inventor of the technique. Charlieplexing takes advantage of a feature of the GPIO pins of the RBPi, wherein they can change from outputs to inputs even when the RBPi is running a program. Simply setting a GPIO pin to be low does not allow enough current to pass through an LED or influence the other pins set as outputs and connected to the LED.

Using Charlieplexing, you can control up to six LEDs with three GPIO pins. For this, you will need three current limiting 470Ω resistors on each GPIO pin. The program charlieplexing.py defines a 3×6 array, which sets the state and direction of the three GPIO pins. The state defines whether the pin is set as digitally high or low, and the direction defines whether the pin is an output or an input.

Since LEDs are also diodes, they will light up only if their anodes are at a higher potential than their cathodes are, and not otherwise. Therefore, to light up a single LED, the program has to set the pin connected to its anode as output and drive it high. Next, the program must set the pin connected to the anode of the LED as input, while it sets the third pin as output and drive it low. Various combinations of the state and direction of the pins will drive all the LEDs on and off sequentially.

The array in the program holds the settings for each GPIO pin. A value of 0 means the pin is an output in a low state, 1 means the pin is an output in a high state, and -1 means the pin is set as an input.

In charlieplexing, it is easy to calculate how many LEDs each GPIO pin can control. The formula for this is, LEDs = n2-n, where n is the number of pins used. According to the charlieplexing formula, three GPIO pins can charlieplex 6 LEDs; four pins can control 12 LEDs, while 10 pins would allow control over a massive 90 LEDs.

Charlieplexing is good for not only lighting one LED at a time, but it is capable of lighting more at the same time also. For this, the program must run a refresh loop to keep the desired state of the LEDs in the array. While refreshing the display, the program must turn on other LEDs that need to be on, before moving on to the next. However, persistence of vision plays a large part here, and the program must be sufficiently fast to make it appear that more than one LED is on at a time.

However, there is a downside to lighting more LEDs at a time. Since more number of LEDs are now on to make it appear that more than one LED is on simultaneously, each LED is actually lit for a lower amount of time, which makes each LED glow less than at its full brightness.