Electronics

TOTEM: studying by experimenting – Open Electronics


 

Let’s study an attention-grabbing academic platform that permits you to make and examine an actual multitude of digital circuits and their functions.

Among the many strategies to strategy college students and really younger individuals, the one among utilizing ecosystems associated to prototyping boards comparable to Arduino has proved to be very efficient; subsequent to it and, we are able to say, in synergy with it, a sequence of mini-labs and experiment kits have developed. Amongst these, it appears attention-grabbing to level out Totem Mini Lab, which is a small however highly effective moveable and benchtop electronics lab to experiment and be taught the fundamentals of electronics.

Absolutely appropriate with the Arduino programming atmosphere, since it’s based mostly on an Arduino-like board, Totem Mini Lab consists of quite a lot of measurement instruments and digital blocks prepared to make use of for experiments.

Designed for use at the side of the Totem constructing system, it permits you to construct compact workbenches with built-in breadboards, saving you from flying connections. It is usually appropriate with I/O, sensor and audio growth boards, which may additional increase capabilities.

The usage of Totem Mini Lab is straightforward and enticing, additionally as a result of it’ll now not be vital to fret about making wiring, usually messy, precarious connections, and many others.. for instance when with jumpers you wire the varied breakout boards with Arduino: right here we’re confronted with a body that homes, already interconnected, the required boards and that teams all the fundamental electronics of the laboratory.

 

WHAT IT IS COMPOSED OF

The core of the electronics is a particular model of Arduino UNO known as TotemDuino and specifically developed. Let’s see what components make up the Totem experiment equipment, ranging from what’s within the field:

  • TotemDuino;
  • LabBoard, which is an experimentation and measurement platform;
  • 34-pin flat-cable to interconnect TotemDuino and LabBoard;
  • body to be assembled for the development of Totem workbenches;
  • mains energy provide (220 Vac / 12 Vdc 1.5 A) to energy your laboratory;
  • 2 breadboards with 700 contacts to attach exterior elements and circuits as a way to increase the experimentation space when the weather on the body aren’t sufficient;
  • 40 male-male jumpers about 20 cm lengthy + Set of 140 jumper cables for making connections on the experimental bases;
  • 1-meter lengthy USB-mini USB 2.0 cable to attach TotemDuino to the Private Laptop.

 

Full with a richly illustrated technical guide in English, explaining how you can get began and using Totem elements to construct a workbench.

 

MAINBOARD

Let’s now spend a number of strains going deeper into the primary board of Totem MiniLab, proven in Fig. 1.

 

Fig. 1

 

This board incorporates a variety of peripherals and interfaces and might have a dual-use.

It may be used each as an growth board for the TotemDuino system (because it gives simply accessible enter and output connections) and as a measurement and take a look at unit.

The cardboard comprises the next modules:

  • part appropriate with Arduino Shields;

obtainable output voltages:

  • 12 V/1 A – direct provide voltage
  • 5 V/0,5 A – regulated provide voltage, shared with TotemDuino.
  • 3,3V/0,25 A – regulated provide voltage, shared with TotemDuino and LabBoard processor;
  • -5V/0,5A – Separate regulated voltage, for experimentation with amplifiers;
  • programmable voltage output from 0 to three.3 V, as much as 0.35A;
  • digital/analog converter;
  • voltage measurement:

– ± 0.5 V for use when measuring small amplitude alerts;

– ± 5V to measure alerts with TTL logic stage;

– ± 50 V for measuring exterior alerts;

  • present measurement as much as 800 mA;
  • frequency meter with sign measurement functionality as much as 1 MHz;
  • pulse counter as much as 999.999.999;
  • arbitrary pulse generator, able to producing a sequence of pulses with programmable width and interval.

 

TotemDuino

Absolutely appropriate with Arduino UNO, the board that’s the mind of the TotemDuino platform has the next functionalities:

  • I / O safety; all of the output pins that enter the LabBoard are protected towards overvoltage or quick circuits;
  • 34-pin growth connector for flat cable that permits you to join TotemDuino to the LabBoard, facilitating entry to the pins;
  • 5V voltage regulator to provide comparatively excessive energy masses;
  • microcontroller logic voltage selectable between 5 V and three.3 V.

The board is due to this fact a board with an Arduino UNO core however outfitted with connections and {hardware} configuration optimized for the Totem atmosphere. The format of the board elements is proven in Fig. 2.

 

Fig. 2

 

MINILAB FRAME

One characteristic of the Totem platform is that it’s based mostly on a body that teams the electronics, so experimentation turns into straightforward and doesn’t contain having the bench suffering from digital boards in disarray; all the things is organized on a three-dimensional body that makes it straightforward to see and join all the weather on board. This construction makes it straightforward to improve and increase: simply add the mechanical or digital elements required by the appliance.

It additionally consists of all of the mechanical components wanted to assemble the body.

The construction based mostly on the body is so compact that, if wanted, it’s doable to maneuver the circuit realized from the laboratory bench straight on the sphere, for instance, to check in observe a simulated utility; multi functional physique, with out having to get assist to maneuver and to assist boards, wires and some other “flying” components.

This attribute of the Totem system, which you’ll uncover by utilizing it, is especially considerable and makes a distinction with competing options.

 

Fig. 3

 

SIDE PANELS EXPANSION

The Totem MiniLab system features a sequence of non-obligatory facet panels that comprise separate, ready-to-use digital modules comparable to shows, sensors, switches and the rest that will should be added to carry out specific experiments.

Fig. 4 reveals the MiniLab Totem outfitted with what they name “Aspect Panels” and a breakout board hooked up to the body and prepared for interconnection. The Aspect Panels comprise elements and modules which are usually used when testing an embedded challenge.

This lets you clear up many issues typical of experimental circuits that require many components.

 

Fig. 4

 

One other drawback when constructing prototypes, or simply wanting to check a code for a challenge, is connecting sure digital elements to the Arduino as a result of generally it’s troublesome to do and might trigger connection errors and generally injury from them since many elements don’t match nicely on a breadboard and should be related flying. The great thing about Totem is that it already has many elements on board (Fig. 5) to be interconnected for the conclusion of experiments and that its construction simplifies the addition of exterior components.

 

Fig. 5

 

The Aspect Panels have blocks that accomplish a number of continuously used features: there are audio circuits, operate mills, and BF amplifiers with audio system.

The opposite facet panels have enter gadgets comparable to potentiometers and switches, relay drivers and DC motor drivers. There are additionally LED drivers and an OLED show to be used in additional advanced designs when values and indications should be displayed.

 

Fig. 6

 

USING THE FUNCTION GENERATOR

After having launched the Totem MiniLab platform, to provide you an thought of what you are able to do with it, we suggest the conclusion of an train that higher than any phrases exposes and explains the potential of the system: we’re going to use the on-board operate generator based mostly on the built-in AD9833, which lets you generate sine, triangle and sq./rectangular waveforms.

The frequency generator is managed by the Arduino board by way of three I/O pins, which is the SPI interface within the ARDUINO (Serial Programming Interface) code. We’ll use the included audio amplifier to get extra amplitude from the frequency generator and we’ll set the quantity pot to most, once more to maximise the obtainable amplitude.

Be aware you can take heed to the sign by inserting a jumper on the contacts (headers) labelled “SP ON” that’s situated simply above the speaker on the correct.

 

Fig. 7

 

TEST THE CUT-OFF FREQUENCY OF A HIGH-PASS FILTER

The experiment we are going to present right here will use the operate generator to supply a sinusoidal sign that will likely be despatched to a easy high-pass LC filter. Since we will likely be measuring standing waves solely, it isn’t essential to match the output impedance of the generator and the enter impedance of the filter; it is not going to be, as a substitute, doable to make use of such a filter for transient alerts, however right here it isn’t an issue as a result of we’re merely focused on discovering the cutoff frequency. Fig. 8 reveals the schematic of the filter and the situation of its elements on the corresponding Aspect Panel.

Fig. 8

 

When measuring sinusoidal waveforms, one of the best factor to do is to rectify the waveform and create a unidirectional, quasi-continuous voltage, which the Arduino ADC can precisely measure.

For this function, on the output of the filter, we join a small circuit known as a peak detector, along with a blocking diode. The blocking diode (it’s a Schottky related in such a means as to chop off the damaging half-waves) ensures that the sign downstream of the circuit, i.e. at its ends, is all constructive (above zero volts). The height detector circuit returns on the cathode of the second Schottky (the one in sequence with the capacitor) a no-load voltage that ideally is the same as the height voltage of the sine wave (in actuality it is the same as the height minus the minimal direct drop on the Schottky diode), which permits acquiring a steady part proportional to the amplitude of the sine wave sign popping out of the high-pass filter (Fig. 9). Figuring out the amplitude of the enter sign we are able to deduce the cut-off frequency as a result of it’s the one at which the ratio between the output voltage and the enter voltage is 0.5 or -6dB (do not forget that it is a second-order filter). The cut-off frequency of our filter is given by the formulation:

fc= 1 / (2*π*√LC )

 

and the values predicted by the experiment, proven within the electrical diagram of the filter in Fig. 8 are theoretically 340 Hz. It ought to be famous, nonetheless, that it could possibly differ relying on the tolerance of the elements, as we are going to see by analyzing the outcomes of the experiment performed.

 

Fig. 9

 

THE ARDUINO SKETCH

So let’s have a look at the firmware to be loaded into Arduino, which routinely performs the cut-off frequency measurement take a look at within the full circuit carried out on the platform as proven in Fig. 10. To carry out the duty, the sketch makes use of some libraries for the features of the electronics obtainable on the facet panel, comparable to SPI.h for 3-wire serial communication with the AD9833 frequency generator and Wire.h for I²C serial communication. The firmware additionally consists of the MD_AD9833.h library for managing the AD9833 operate generator chip and gives for the administration of the 128×64 pixel OLED show utilizing the Adafruit particular libraries: Adafruit_SSD1306.h and Adafruit_GFX.h for drawing and writing to the show.

 

Fig. 10

 

In our design, the outcomes of the frequency scan after which sweep are displayed on an OLED show on Aspect Panel 2 within the type of a frequency response curve (Fig. 11). Every measurement is saved in a knowledge array and plotted as a pixel on the show. Then the cutoff frequency is calculated and written down. The show is managed by the Arduino by way of the I²C bus. The TotemDuino makes use of the Wire.h library for communication over the I²C bus by way of the A4 (SDA) and A5 (SCL) I/O pins.

 

Fig. 11

 

The code, proven in full within the screenshots how straightforward it’s to make use of the totally different modules within the Aspect Panels, and many of the code offers with the frequency sweep, measurements, and end result show.

The sweep is used to ship a large sufficient frequency spectrum to the enter of the filter that the amplitude development can then be checked on the output, i.e. on the filter capacitor underneath take a look at.

Itemizing

// Primary MD_AD9833 take a look at file
//
// Initialises the machine to default situations
//
#embrace <SPI.h>
#embrace <Wire.h>
#embrace <MD_AD9833.h>
#embrace <Adafruit_GFX.h>
#embrace <Adafruit_SSD1306.h>
//Outline display measurement in pixel
#outline SCREEN_WIDTH 128 // OLED show width
#outline SCREEN_HEIGHT 64 // OLED show top
// Declaration for an SSD1306 show
#outline OLED_RESET -1
// Reset pin # (or -1 if sharing Arduino reset pin)
//Initialize show
Adafruit_SSD1306 show (SCREEN_WIDTH,
SCREEN_HEIGHT, &Wire, OLED_RESET);
// Pins for SPI comm with the AD9833 IC
#outline DATA 11 ///< SPI Information pin quantity
#outline CLK 13 ///< SPI Clock pin quantity
#outline FSYNC 10 ///< SPI Load pin quantity
#outline SAMPLES 64
MD_AD9833 AD(FSYNC); // {Hardware} SPI
int freq;
int buffer[SAMPLES];
void setup(void)
{
Serial.start(57600);
show.start(SSD1306_SWITCHCAPVCC, 0x3C);
show.show();
show.clearDisplay();
AD.start();
freq = 100;
AD.setMode(MD_AD9833::MODE_SINE);
}
void graphSpectrum(void)
{
int i;
show.clearDisplay();
for(i=0;i<SAMPLES;i++)
{
int worth = buffer[i] / 4;
show.drawLine(i*2, 63-value, (i*2)+1,
63-value, SSD1306_WHITE);
}
}
int minfreq;
int maxfreq;
int stepF;
void frequencySweep(int minf, int maxf, int steps)
{
minfreq = minf;
maxfreq = maxf;
stepF = (maxf - minf) / steps;
AD.setMode(MD_AD9833::MODE_OFF);
delay(150);
AD.setMode(MD_AD9833::MODE_SINE);
int f = minf;
for(int i=0;i<steps;i++){
AD.setFrequency(MD_AD9833::CHAN_0, f);
f += stepF;
delay(50);
buffer[i] = analogRead(A0)/4;
}
}
void calculateFreq()
{
//seek for min and max
int minv=255,maxv=0;
int mini=0,maxi=0;
for(int i=0;i<SAMPLES;i++)
{
if(minv>buffer[i])
{
minv = buffer[i];
mini = i;
}
if(maxv<buffer[i])
{
maxv = buffer[i];
maxi = i;
}
}
int f = 0;
for(int i=0;i<SAMPLES;i++)
{
//discover the worth that goes -3dB from max:
if(buffer[i]> (maxv/2))
{
f = i;
break;
}
}
//Print on serial
Serial.print(“max:”);
Serial.print(maxv);
Serial.print(“ “);
Serial.print(buffer[f]);
Serial.print(“ “);
Serial.println(f);
//Print on show
show.drawLine(f*2, 0, (f*2),
show.top(), SSD1306_WHITE);
char message[16];
sprintf(message,”fc:%d Hz”, minfreq + (stepF*f));
show.setTextSize(2);
show.setTextColor(SSD1306_BLACK,
SSD1306_WHITE);
show.setCursor(0, 0);
show.print(message);
}
//loop routine
void loop(void)
{
//accumulate samples
frequencySweep(20, 1000, SAMPLES);
//replace display
graphSpectrum();
//calculate restrict freq
calculateFreq();
show.show();
}

 

CONCLUSIONS

The experiment we simply performed reveals that with easy strategies, Arduino or not less than an Arduino-like board just like the TotemDuino can be utilized for automated measurements in important electrical and digital circuits.

The LC filter we used on this setup was an illustration of how measurements might be made, acquiring numerical and even graphical outcomes, due to the power to make use of the small OLED show as information output. The train is usually a foundation to increase, for instance by sending the outcomes to a PC for a greater display to indicate the graphs.

 

FROM OPENSTORE

A platform of experiments

Minilab sensor growth

Audio Enlargement for Minilab

I/O Enlargement for Minilab

 



What's your reaction?

Leave A Reply

Your email address will not be published.