Arduino Uno vs Arduino Mega

Yash Sanghvi
Updated on 30-Jul-2021 16:30:39

799 Views

We will have a comparison of the specifications of Arduino Uno and the Arduino Mega Board.Arduino UnoArduino MegaPlease refer to the table below −Dimensions Pricing I/O PinsUnoMegaGeneralDimensions2.7¨ x 2.1¨4¨ x 2.1¨Pricing$20-23$36-39ConnectivityI/O Pins1454PWM Pins615Analog Pins616ComputingProcessorATMega328PATmega2560Flash Memory32 kB256 kBSRAM2 kB8 kBEEPROM1 kB4 kBClock speed16 MHz16 MHzVoltage Level5V5VUSB ConnectivityStandard A/B USBStandard A/B USBCommunicationHardware Serial Ports14SPI SupportYesYesI2C SupportYesYes

Components of Arduino Uno Board

Yash Sanghvi
Updated on 30-Jul-2021 16:28:31

754 Views

The important components of the Arduino Uno Board are shown below −The following table contains the description for each of the labels −LabelDescription17-12 V Barrel Jack2Voltage Regulator316 MHz Crystal Oscillator4USB - B Port5Reset Button6Digital Pins7ICSP Pins (SPI can be accessed from here)8ATmega328P microcontroller9Analog Pins10Serial Port TX RX LEDs11USB to UART Conversion IC12Built-in LED (connected to pin 13)

Interface Arduino with Gas Sensor

Yash Sanghvi
Updated on 30-Jul-2021 16:25:28

7K+ Views

In this article, we will see how to interface Arduino with the MQ-2 gas sensor. MQ2 gas sensor is used for detecting smoke and some flammable gases like LPG, Methane, etc. It changes its resistance depending on the type of the gas. This principle can be used to raise an alarm based on the concentration of the gas.An image of the MQ2 gas sensor is given above. As you can see, it has 4 pins. Out of these the Aout pin gives the Analog voltage in proportion to the gas concentration. Higher the gas concentration, higher the voltage on the ... Read More

Interface Arduino with LoRa Module

Yash Sanghvi
Updated on 30-Jul-2021 16:20:53

2K+ Views

In this article we will see how to interface Arduino with the LoRa module E32. LoRa stands for Long Range. It uses license-free sub-GHz RF bands for operation. These bands are different in different countries. In India, the permissible band is 865-867 MHz. LoRa is very ideal for IoT applications thanks to its long range and low power consumption. However, the achievable data rates are limited (0.3 to 27 kbits/second). Longer the range, lower the data rate.The E32 module that we will use looks like the one below. Depending on the frequency the module variant changes. For example, the one ... Read More

Interface Zigbee with Arduino

Yash Sanghvi
Updated on 30-Jul-2021 16:17:46

11K+ Views

Zigbee is a wireless communication protocol targeted for battery powered devices (it has both low power and low cost). It generally operates in the 2.4GHz range (although there are geographic variations), and supports data ranges from 20 to 250 kbits/s.The transmission distance though, is small compared to the likes of LoRa. It is 10 to 100 m, whereas LoRa can transmit over a few kilometers. Another thing to note is that Zigbee communication doesn’t work very well if there is no line of sight between transmitter and receiver.Even minor obstacles have been observed to significantly degrade the communication. Keep these ... Read More

Send SMS Using a GSM Module Connected to Arduino

Yash Sanghvi
Updated on 30-Jul-2021 16:14:39

11K+ Views

In this article, we will see how to interface Arduino with a GSM Module, and send SMS using the module. You will need the following −Arduino boardA GSM Module (SIM800C, SIM900A, are popular examples, but you can have any other module as well)A GSM (2G) SIM Card, or a 4G SIM Card with 2G fallback option (Jio SIM Cards won’t work for this project)GSM AntennaYou could also get a GSM Module development board, like the one below (the SIM Card Holder is on the other side of the board) −A GSM Module interacts with a microcontroller via UART (see the ... Read More

Queue in FreeRTOS for Arduino

Yash Sanghvi
Updated on 30-Jul-2021 16:09:29

2K+ Views

Queue is a data structure that helps exchange data between different tasks or between tasks and interrupts. It holds a finite number of items (defined at the time of initialization) and operates in the FIFO mode.We will walk through an example that comes in with the FreeRTOS library, to understand queues.You can find the example in − File → Examples → FreeRTOS → StructQueue.In this code, two tasks read analog values from different analog pins, and pass these values in a queue. Another task reads the values from the queue and prints them onto the Serial Monitor. There is a ... Read More

Software Serial in Arduino

Yash Sanghvi
Updated on 30-Jul-2021 16:06:40

8K+ Views

The SoftwareSerial library was developed to ensure that any pins of Arduino can exchange Serial data with other peripherals, like GNSS receivers, using software. Arduino Uno, for example, has only one HardwareSerial port (pins 0 and 1), which is connected to the USB via the USB to UART conversion chip. Thus, if you have any other peripheral that requires serial communication, in the absence of SoftwareSerial, you’d have to do away with USB Serial communication.SoftwareSerial has some limitations −If you are using multiple SoftwareSerial ports, only one can receive data at a timeSpeeds can be up to a maximum of ... Read More

Calculate Average of Numbers in a Given List using Go

Rishikesh Kumar Rishi
Updated on 30-Jul-2021 15:41:19

1K+ Views

Input array is: [2, 4, 1, 6, 5]Sum = 2 + 4 + 1 + 6 + 5 => 18Average = 18/5 => 3.6 ~ 3To calculate the average of numbers in a given list, we can take following steps −Let's take an input list of numbers.Find the sum of numbers using sum() method.The sum method calculates the sum of numbers by iterating the given list.Print the average by dividing the sum with the length of the given list.Example Live Demopackage main import (    "fmt" ) func sum(arr []int) int{    result := 0    for _, i :=range arr ... Read More

Create a Class for Basic Calculator Operations in Golang

Rishikesh Kumar Rishi
Updated on 30-Jul-2021 15:38:15

1K+ Views

To create a class that can perform basic calculator operations, we can take following StepsWe can define a Calculator class with two numbers, a and b.Define a member method to calculate the addition of two numbers.Define a member method to calculate the multiplication of two numbers.Define a member method to calculate the division of two numbers.Define a member method to calculate the subtraction of two numbers.In the main method, declare two variables, a and b.Get an instance of Calculator.Initialize a choice variable, based on which mathematical operations could be performed.Example Live Demopackage main import (    "fmt" ) type Calculator struct ... Read More

Advertisements