Search Results
109 items found for ""
- 4 IR Remote Control
Small Robot : 4 IR Remote Control # . < < < Previous List All Next > > > . Introduction Another way to control the Small Robot is, using an IR (infra Red) remote. Here, a handy remote with direction markings is selected for controlling the Small Robot. The IR remote sends a specific pattern of digital signal through its IR LED, based on the button press. An IR receiver module (TSOP 1738) receives the IR signal from the IR remote and sends to the micro-controller (ATTINY13). Then, the micro-controller decodes the signal and converts it to 4 bit binary code, which is available as D0,D1,D2 & D3 at 6 pin connector. Then, the 4 bit code is received by the motor driver IC (L293D) on the Base Frame, to drive the two B.O. motors accordingly. (refer Small-Robot Base Frame for motor control codes) A small 8 pin micro-controller (ATTINY13) is used in Receiver circuit. As the transmitter is IR remote, so there is no need of Transmitter board and micro-controller. Any IR remote may be used to control the Small Robot. But, the signal generated by the IR remote should be decoded and then it shall be converted to, required 4 bit binary code, to control the Small Robot. Similarly, any IR receiver with 38KHz carrier frequency may be used, like TSOP1838, TSOP98138, TSOP38328, TSPO38438 etc. The pinouts should match with the circuit. IR (Infra Red) Transmitter: The IR remote used in the project is clone to Panasonic Audio remote control, which is easily available at affordable price (The original Panasonic remote is costly and not advisable for our project). The main advantage with this IR remote is, it has the four direction keys on a handy size. The front two buttons used for volume control are used to rotate the Small Robot in Clockwise and Counter-Clockwise directions. Most of the IR remotes use 38 KHz carrier frequency. It means, the IR LED of the remote glows on/off for 38000 times per second, which is called as Carrier Frequency. Again, the time of 38 KHz IR LED frequency varies for code generation. Say, to send a digital code '1' , the 38 KHz frequency is available for more time, compared to send code '0', before stopping the Carrier Frequency. So, a specific pattern of digital code is sent by the IR remote, on each key press. To differentiate or identify the IR code from each IR remote manufacturer, a header code is sent initially and the digital time also varies. (The header code ignored in our case). IR (Infra Red) Receiver: In the IR Receiver Board, the IR receiver, TSOP1738, is used, for easy identification of its pin-outs. One of its pin, out of 4 pins, is absent, which makes the pin identification fool proof. (Refer the circuit diagram below for better understanding). So, the Infra-red signals received by the IR receiver, TSOP1738, filters the Carrier Frequency and sends the digital code to the micro-controller (ATTINY13). An LED is provided to show the status of data reception from the IR receiver. The micro-controller decodes the received data, and converts to four bit parallel data. Then the four bits are sent to the base frame through the 6 pin connector, which in turn controls the movement of the Small Robot. In case, to use different remote, the IR pattern has to be studied and the Source code is to be modified accordingly (modify the getIRcode() function as required). The 5VDC power supply for Receiver board is derived from the Main board of Base Frame, through 6 pin connector. Good Luck Download IR HEX file Contact for Source Code Download file from above link and remove .TXT extension. . < < < Previous Once Small Robot's Base Frame is made, then, various control systems for Small Robot are developed and available for selection, using 'Previous ' and 'Next ' buttons here. Next > > > .
- 9 Obstacle Avoider
Small Robot : 9 Obstacle Avoider # . < < < Previous List All Next > > > . Introduction: An Obstacle Avoider is also a self controlled Robot, which will recognize obstacle (like wall) and avoids collision with the vertical surfaces. Many types of sensors may be used for finding obstacle, like IR distance sensor, Ultrasonic Distance sensor, pressure switches etc. But, using Ultrasonic sensor is simple and reasonable to recognize the obstacle. One Ultrasonic distance sensor is fitted on front side of the Small Robot to measure the distance of obstacle. The distance is read from the ultrasonic sensor by the micro-controller (ATTINY84), then analyzed to take turn accordingly, based on the 4 bit motor control data, through the motor driver IC (L293D) on base board. (refer Small Robot Base Frame for motor control codes). The concept of Obstacle Avoider Robot is to avoid flat vertical obstacles. Basically, the Obstacle Avoider periodically sends an ultrasonic wave and measures the distance of obstacle by the time taken to receive its reflected wave from the obstacle. If the distance measured is less than the set distance value, then takes turn accordingly. Here, the Small Robot is programmed to take a right or left turn, when it founds any obstacle within its set distance, else moves forward continuously. About Obstacle Sensing: Here, the Obstacle Avoider uses one ultrasonic sensor module, HC-SR04 (readily available) to read the presence of obstacle in front of it. The ultrasonic sensor module, consists of a ultrasonic wave generator and ultrasonic wave receiver, with required on-board electronic circuit. The ultrasonic sensor module is available with four pinouts, i.e., Vcc, Ground, Trigger and Echo. The ultrasonic sensor module is connected to 5VDC supply across Vcc and Ground pins. Whenever the Trigger pin goes HIGH ( logic 1 ), for 10 micro-seconds, the ultrasonic wave generator sends ultrasonic waves, about 40 KHz, which is not audible to human ears. Then the ultrasonic wave receiver starts listening for the reflected ultrasonic wave. Then, a high pulse is generated from Echo pin, proportional to the time taken to receive the reflected ultrasonic wave by the ultrasonic wave receiver. The Echo pulse time ( or Time of Flight ) is measured by the micro-controller (ATTINY84) and converted to distance by using suitable formula. If the distance obtained by the formula is less than the set distance (means obstacle is near to the Obstacle Avoider or within critical distance), then, the Obstacle Avoider takes turn accordingly, else moves forward. The Concept of working of Ultrasonic sensor is shown below. As the generated Ultrasonic wave moves in a narrow path, sometimes the ultrasonic sensor module may not recognize thin obstacles (like wires etc.) and obstacles above or below the ultrasonic wave path. The ultrasonic sensor module may not recognize the obstacle with inclined surfaces, as the ultrasonic wave may get diverted its path and the ultrasonic receiver may not receive the reflected ultrasonic wave. To avoid such errors, multiple ultrasonic sensor modules are to be used at various directions. Working of Obstacle Avoider: Two versions of Obstacle Avoider are developed. The first version uses a bracket to hold the ultrasonic sensor module at fixed position. So, to check the obstacles at sides, the Small Robot takes right and left turns, at regular intervals. In the first version, only the ultrasonic sensor module is connected to the control board, using jumper wires. The distance of obstacle is measured continuously by the micro-controller (ATTINY84), then takes turn, if the obstacle is found within the critical distance, else moves forward. In this version, the movement of Small Robot is slow, with intermittent brakes, since it takes small turn at regular intervals, to find obstacles at sides. In the second version, a servo is fitted on the bracket and used to swing the ultrasonic sensor module on its horn. The servo motor is also controlled by the micro-controller (ATTINY84) and set to swing right and left side. So, the obstacle distance is read continuously from right, left and forward. The Small Robot takes turn according to the obstacle found, else moves forward. Here, the searching angle for obstacle is high and movement of the Small Robot is also improved. On the control board, no shorting jumper should be used (existing shorting jumper should be removed, if any). Then, the RED LED glows, when the obstacle is found within critical distance, else YELLOW LED glows. This is simple and very useful indication, to know the working status of ultrasonic sensor module. A button switch, SW1 on control board, is useful to start the Obstacle Avoider, after switching ON the power supply to the Control Board. The SW1 switch should be pressed twice in first version, to search the obstacle in both sides, else the Small Robot will search for obstacle in forward direction only. The complete circuit diagram of Control Board with ATTINY84, is available below. Use separate jumper wires to connect ultrasonic sensor module and servo motor to Control board. Omit servo motor and its connections in first version. Download OA1 HEX file Download OA2 HEX file Contact for Source Code Download file(s) from above link and remove .TXT extension. . < < < Previous Once Small Robot's Base Frame is made, then, various control systems for Small Robot are developed and available for selection, using 'Previous ' and 'Next ' buttons here. Next > > > .
- Robotics | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
ROBOT : INTRODUCTION ROBOT PROJECTS NO Microcontroller ::SLIM-BOT:: #1 Base & IR follower #2 IR Line Follower #3 LDR Line Follower #4 W/L Keypad Control #5 W/L Joystick Control #6 W/L 5D Rocker Control #7 W/L Hand Gesture Control AVR/ATTINY based :Small Robot: #1 Base Frame #2 Keypad Control #3 Joystick Control #4 IR Remote Control #6 Line Follower #7 Path Follower #8 Edge Detector #9 Obstacle Avoider o o d
- SeriesLI_ionCharger | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
Series Balanced Li-Ion Charger The Lithium Ion (Li-Ion) Cells are highly used as storage cells in power banks and electronic gadgets. The charger is designed to balance charge three Li-Ion cells in series using 12V transformer and LM338 adjustable voltage regulators. The circuit may be modified to charge 4 cells in series, using 15V transformer, if required. Some of the advantages of Lithium Ion cells are listed below: 1) High capacity to weight ratio (high specific energy storage) 2) Available in high capacity, 1800mAH or more. 3) Easily available and affordable 4 ) Suitable for power banks and so on.... The circuit diagram presented here is simple (without any micro-controller) and easy make-at-home project. The current circuit diagram can charge THREE cells in series, but can be modified to FOUR (or more) as required. The full circuit diagram of Series Balanced Li-Ion (3 cells) Charger is shown below: WORKING PRINCIPLE: The mains power supply is stepped down to 12VAC using a transformer (12-0-12V 3A) and rectified to DC volts using 2 nos of 1N5408 diodes. A 4700 micro-Farad capacitor is used as filter capacitor. Then the Raw-DC is stepped down to 4.2VDC, 8.4VDC and 12.6VDC, using three numbers of LM338 voltage regulator ICs. Three trimpots are provided to get required output voltages by adjustment. The three outputs and ground connections are used for charging the three cells in series as shown. Using a four pin connector to battery pack (or separate three cells in series) is useful to quickly connect and disconnect for charging. A 7812 fixed voltage regulator IC, is used to get 12VDC, which is useful to connect 12V cooling fan for cooling of three LM338 ICs. Heat sinks are to be provided for the LM338 ICs, which may be get heated up, while charging of cells. As the difference between the two successive outputs of the four connections should not exceed 4.2VDC, the charging voltage for each cell also limited to 4.2V only. A combined Digital Voltmeter-cum-Ammeter is connected to know the voltage across the three cells and charging current value at any moment. Once the charging current shows 0.00A, then it is an indication of full charge of the cells. It is also observed that, if the charging current is less than 0.02A, then it indicates, the cells are charged more than 95 percent.
- Arduino_Nokia5110 | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
Introduction to Nokia 5110 Display : The Nokia 5110 is a simple Monochrome Graphical (LCD) Display with 84 x 48 pixel resolution, which is useful in Arduino projects for displaying small and simple Graphics. The price of the Nokia 5110 display is affordable and ease to interface with Arduino board. The Display have a Back Light, like other LCD displays, for clarity. The data is also visible, without switching on the Back Light. The Nokia 5110 resolution consists of 6 row banks. each row bank has 8 vertical pixels and 84 horizontal pixels. So, total pixels per row bank = 8x84 = 672 pixels Hence, overall resolution for 6 row banks = 6x672 = 4032 pixels or, vertical resolution (y-axis) = 6 row banks x 8 rows per bank = 48 pixels Horizontal Resolution (x-axis) = 84 pixels in each row . Total resolution = 84 x 48 = 4032 pixels Since, each pixels requires 1 bit (for monochrome) only, total memory space required = 4032/8 = 504 bytes (where 8 bits makes a byte) Here, Front and Back views of actual Nokia 5110 display is shown. The pixel orientation is also shown as schematic, for better understanding. The pinouts of Nokia 5110 are shown above. It has 8 pins, out of which 2 pins are used for serial data comminication (i.e. Data Input and Clock), 3 pins are used for control (i.e., Reset, Chip Enable and Data/Command Select), 2 pins for power supply (i.e., Vcc and Ground) and one pin is used to switch on/off Back Light (connected to Vcc through a series resistor). Interfacing Nokia5110 to Arduino : So, as per the pin-outs of Nokia 5110, the data and control pins (total 5 nos) are to be connected to Arduino digital pins. The Vcc pin to 3.3V pin, Ground to Gnd pin of Arduino. The BL (Back Light) pin may be connected to 3.3V or 5V supply through a series resistor. The basic connections to Nokia 5110 to Arduino Nano are shown, as an example (or test circuit) in below circuit diagram. Now, open Nokia5110.ino using Arduino IDE. The sketch includes library file Nokia5110.CPP and a font file LCDfont.h . Now, compile the sketch and upload to the Arduino board. After uploading the sketch the Various display options on Nokia 5110 are shown as examples. like displaying an image, text message, simple graphics, inverted text, inverted colour (display on black background), with and without Back light on. View Video For full source code and library files contact us through Contact Form.
- Arduino | Adruino | Uno | Mega | Nano | Arduino Projects | Simple MECHATRONICSsimple mechatronics
Arduino TYPES Arduino IDE Arduino BLINK LED Arduino DIGITAL I/O Arduino 7SEGMENT Arduino LCD control Arduino KEYPAD Arduino ADC Arduino PROJECTS Sanitizer - Full Automatic Super Power LiFePO4 Cell Charger Satellite Clock Arise, Awake and Stop NOT until the goal is reached – Swamy Vivekananda Arduino Nokia Display N
- Imp.ICs | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
IMP. ICs PAGE IS UNDER CONSTRUCTION. PLEASE ALLOW SOME TIME FOR COMPLETION. SORRY FOR INCONVENIENCE CAUSED.
- Digital | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
PAGE IS UNDER CONSTRUCTION. PLEASE ALLOW SOME TIME FOR COMPLETION. SORRY FOR INCONVENIENCE CAUSED.
- Arduino_ADC | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
Introduction to Arduino ADC : Analog to Digital Converter (ADC) is a very useful feature available with Arduino boards. The Analog input voltage is converted propotionally to 10 bit Digital form, i.e., 0 to 1023 in decimal format. Reference Voltage: The default referernce voltage (analog) is set to Vcc of the board, i.e., 5V or 3.3V . But, it can be changed to a required value (input voltage, which shall be less thant the Vcc of the MCU) and the sketch has to be set for the external input voltage reference. The reference voltage may also be set to built-in, fixed, internal reference voltage and the sketch is to be updated accordingly. Input Voltage: The input voltage is the analog voltage, that is to be measured and converted to Digital form, which shall not be more than Vcc of the Arduino board. The input voltage shall be positive only, starting from 0V (ground reference of the Arduino board). The ADC of the Arduino cannot measure negative voltage, i.e., voltage less than ground voltage of the Arduino board. ADC Register : The ADC register holds the 10 bit digital data , after performing the ADC operation. The data is available for reading until next ADC operation. So, the digital data has to be read / saved to the user variable, if required, before performing next ADC operation. Playing with Arduino ADC : Measuring Analog Voltage with DEFAULT settings : The Arduino board is set to DEFAULT for Analog Reference voltage, by default (unless changed), which is same as Vcc voltage of the board. i.e., 5V or 3.3V, depending on the Arduino board. So, following statement in the sketch may be added to set the Analog reference voltage as Default, which is optional. analogReference(DEFAULT); // may be used once in the setup() Then, call the following statement to convert the Analog voltage to 10 bit Digital format, and store the value in ADC Register. analogRead (ADC_PIN); // read analog voltage from the specific ADC pin, and saves digital value in ADC reg. To save the digital value, assign it a variable, as shown below. int var = analogRead (ADC_PIN); // returns digital value Now, the var value is set in between 0 to 1023, where 0 indicates 0 Volts and 1023 is equal to Vcc voltage . So, to summarize the above steps, to read an analog voltage (shall be less than Vcc of the Arduino board) from one of the ADC pins ( A0 or A1 or A2 ...) int adc_val; // to hold adc (digital) value #define adc_pin A0 // select one of the ADC pins void setup () { Serial.begin(9600); // initiate Serial Communication analogReference(DEFAULT); // optional } void loop () { adc_val = analogRead (adc_pin); // or A0 or A1 . . . Serial.println( adc_val ); // display the value on serial monitor delay ( 500 ); // wait for 500 milli sec } However, discard some initial readings, which may not be accurate. The ADC pins on Arduino Uno and Arduino Nano are shown below as an example. The POSITIVE input voltage to be read, shall be connected to one of the Analog pins ( A0 / A1 / A2 / . . .) and NEGATIV E input voltage shall be connected to any GND pin marked on the Arduino board. Measuring Analog Voltage with EXTERNAL Reference Voltage : The Input Voltage may be measured in a range required (of user's choice) like 0 to 2.0V for more accuracy, instead of default Vcc voltage reference. This concept also avoids inaccurate Vcc voltage reference (eg Vcc varies from 4.75 to 5.25 V), and precision ADC conversion is obtained with regulated voltage reference. The concept of Analog to Digital Covertion (ADC) is shown as schematic above. So, following statement in the sketch may be added to set the Analog reference voltage as EXTERNAL, which is mandatory. The external reference voltage shall be connected across AREF pin (positive) and GND pin Inegative), before using the following statement. analogReference(EXTERNAL); // may be used once in the setup() Then, call the following statement, as earlier to convert the Analog voltage to 10 bit Digital format, and store the value in ADC Register. analogRead (ADC_PIN); // read analog voltage from the specific ADC pin, and saves digital value in ADC reg. To save the digital value, assign it a variable, as shown below. int var = analogRead (ADC_PIN); // returns digital value Now, the var value is set in between 0 to 1023, where 0 indicates 0 Volts and 1023 is equal to voltage at AREF pin. So, to summarize the above steps, to read an analog voltage (shall be less than Voltage at AREF pin of the Arduino board) from one of the ADC pins ( A0 or A1 or A2 ...) int adc_val; // to hold adc (digital) value #define adc_pin A0 // select one of the ADC pins void setup () { Serial.begin(9600); // initiate Serial Communication analogReference(EXTERNAL); // mandatory and connect reference voltage across VREF pin (+ve) and GND pin (-ve) before switch on. } void loop () { adc_val = analogRead (adc_pin); // or A0 or A1 . . . Serial.println( adc_val ); // display the value on serial monitor delay ( 500 ); // wait for 500 milli sec } Here also, discard some initial readings, which may not be accurate. Measuring Analog Voltage with INTERNAL Reference Voltage : The Input Voltage may be measured with an internal fixed voltage available in the micro controller. This is also a good choice for accurate measurement, but some fixed voltage only possible to select. This concept avoids connecting any external power supply and reduces external wiring also. The concept of Analog to Digital Covertion (ADC) using internal voltage reference, is shown as schematic above. So, the following statement(s) in the sketch may be added to set the Analog reference voltage as INTERNAL, which is mandatory. The various internal reference voltage are available based on the selected Arduino board. Use one of the statements matching to the selected Arduino board // mandatory, may be used once in the setup() analogReference(INTERNAL); // = 1.1V on the ATmega168 or ATmega328P and 2.56V on the ATmega32U4 micro-controllers analogReference(INTERNAL1V1); // = 1.1V for ArduinoMega analogReference(INTERNAL2V26); // = 2.56 V for ArduinoMega (Please refer Arduino Data sheets, to select internal reference voltages of other Arduino boards or micro-controllers) So, to read an analog voltage (shall be less than the set Internal Voltage, from one of the ADC pins ( A0 or A1 or A2 ...), the Arduino sketch shall be, int adc_val; // to hold adc (digital) value #define adc_pin A0 // select one of the ADC pins void setup () { Serial.begin(9600); // initiate Serial Communication analogReference(INTERNAL); // mandatory and select one of the statements as explained above } void loop () { adc_val = analogRead (adc_pin); // or A0 or A1 . . . Serial.println( adc_val ); // display the value on serial monitor delay ( 500 ); // wait for 500 milli sec } Here also, discard some initial readings, which may not be accurate. Making a simple Voltmeter : Making a Voltmeter using Arduino: Any one of the ADC input may be used to make a voltmeter, and the result may be viewed on the screen using Serial Monitor of Arduino IDE. Here, Arduino Uno board is used for making Voltmeter ranging from 0 to 5V (maximum). Follow the required circuit and sketch as shown below int adc_val; // to hold adc (digital) value double adc_volts; // to hold adc (digital) value #define adc_pin A0 // select one of the ADC pins# #define max_volts 5.0 // set max volts void setup () { Serial.begin(9600); // initiate Serial Communication analogReference(DEFAULT); // upto 5V adc_val = analogRead (adc_pin); // discard reading(s) } void loop () { adc_val = analogRead (adc_pin); // read from A0 adc_volts = (max_volts*adc_val)/1023; // calculate volts // display the value(s) on serial monitor Serial.print( "ADC VALUE : "); Serial.print( adc_val ); Serial.print( " -> VOLTS : "); Serial.println( adc_volts ); delay ( 1000 ); // wait for 1 sec } Download above Sketch Making a Voltmeter using LCD : Making a Voltmeter using Arduino and a LCD display: Here also one of the ADC input is used, but the values are displayed on a LCD, so that, the circuit is independent of your laptop or PC, after uploading the sketch to the Arduino. The circuit is shown below for 10V / 25V Voltmeter and use contact form for complete sketch / soruce code Select the Series Resistor, RS, as per the Voltage Range to be measured. Then, connect a known DC power source (eg. 5V or 9V battery), and adjust the trimpot, until correct voltage value is displayed on the LCD. Now, your Arduino Voltmeter is ready to use.
- Arduino_LCD | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
Introduction to LCD (text mode) : The LCDs (Liquid Crystal Displays) are highly used in Arduino projects for displaying required text message and status of the process. The price of the LCD is affordable and easily available. The standard LCDs can display text message with various colour LED background s. The commonly available text sizes of LCDs are: 1) 1 row x 16 columns 2) 2 rows x 16 columns 3) 4 rows x 16 columns 4) 4 rows x 20 columns with green or blue or while background colour light. The 2 rows x 16 columns with green background is highly used in the Arduino projects. For all the above listed LCD s, 16 pins are available to control and display the text. The pins 1 and 2, are for power supply of the circuit and 15 and 16 are background LED power supply. The pin 3 is for adjusting contrast of the display and pins 4, 5 and 6 are control pins i.e., RS (Register Select), RW (Read/Write) and Enable. The remaining 8 pins (byte) from 7 to 14 are data pins. (Refer pinouts of LCD below.) The LCD have two options for its data bits operation. i.e., 8 bit mode and 4 bit mode. While in 8 bit mode, the data byte is read/write in one enable clock pulse, whereas in 4 bit mode, the data byte is divided in to two parts and read/write using two clock pulses of enable pin. So, in 4 bit mode, you may save number of pins connected to Arduino board, at an expense of a very little delay (double time) for data transfer. Normally, you may be writing the data to LCD. So, the R/W pin (no 5) is connected to ground (logic low). In case you want to read any register of LCD, the R/W pin should be set to logic high (hardly reads the LCD register). Interfacing LCD to Arduino : Any LCD (which are listed above), may be connected to any Arduino board with minimum 6 digital pins. i.e., 4 data pins and 2 control pins, RS & enable. A simple generalized circuit diagram for interfacing LCD with Arduino Uno board is shown below. You may observe that the pin 5 (R/W) is connected to ground and pin 3 (VEE) is connected to a trimpot's mid pin. The trimpot's end pins are connected to Vcc and ground. The trimpot should be adjusted for good contrast of display after displaying any text on LCD. Now, open Arduino IDE, then select from menu, File->Examples->Liquid Crystal->Hello World. Then, declare the pin connections of LCD to Arduino board, as shown below. // include the library code #include // Pin connection sequence RS, Enble, D4, D5, D6, D7 LiquidCrystal my_lcd { 2, 3, 4, 5, 6, 7 }; Initially, set LCD's number of columns and rows in begin function. Then, enter the required text to be displayed using print function. The setCursor function locates the cursor on the LCD to display the next text using print function. void setup() { // set up the LCD's number of columns and rows: my_lcd.begin(16, 2); // std : 16,2 or 16,4 or 20,4 // Print a message to the LCD. my_lcd.print("Simple"); my_lcd.setCursor (4, 1); my_lcd.print ("MECHATRONICS"); } Then, continue with the existing loop function, to display counting seconds at 1st col 2nd row void loop() // for displaying number of seconds lapsed { // set the cursor to column 0, line 1 // (note: line 1 is the second row, since counting begins with 0): my_lcd.setCursor(0, 1); // print the number of seconds since reset: my_lcd.print(millis() / 1000); } The, output of the sketch is shown here. You may adjust the trimpot for good contrast. For 16 coloumns x 1 row also, it should be declared as my_lcd.begin(16, 2); only. The first row text will be displayed on left 8 columns and second row text will be displayed on right side 8 columns (starting from 9th column) Similarly, declartion for 16 columns x 4 rows, my_lcd.begin(16, 4); and declartion for 20 columns x 4 rows, my_lcd.begin(20, 4); Simple LCD control functions: View VIDEO Some simple functions, which are useful and frequently used are explained below: // for clearing all the contents (text) on the LCD my_lcd.clear(); // To display and hide the text displayed on the LCD my_lcd.display(); // To SHOW contents of LCD my_lcd.noDisplay(); / / To HIDE contents of LCD // for positioning the cursor at required position (x, y) // (x,y) numbers starts from (0,0) // so 0 means 1st, 1 means 2nd. . . and so on. my_lcd.setCursor(5, 1); / / Position at 2nd row, 6th column // To display or hide a rectangular blinking cursor // positioned by setCursor function. my_lcd.blink(); // To SHOW rectangular blinking cursor my_lcd.noBlink(); // To HIDE rectangular blinking cursor // To display or hide an underline type cursor // positioned by setCursor function. my_lcd.cursor(); // To SHOW underline type cursor my_lcd.noCursor(); // To HIDE underline type cursor LCD text scroll functions: View VIDEO Some simple scroll functions, which are used to scroll displayed text on LCD to either side are explained below: // To scroll the displayed text to RIGHTside by one step my_lcd.scrollDisplayRight(); // To scroll the displayed text to LEFT side by one step my_lcd.scrollDisplayLeft(); // for automatically scroll a long text to left // for reading long text sentences. my_lcd.autoscroll(); / / scrolls the text to left by one step Before using the scrolling functions, the required text should be displayed using my_lcd.print function. Then, f or continuous scrolling effect of the text sentence (text string), the above functions should be used in a for loop function.
- ESSENTIALS | Simple Mechatronics| Simple MECHATRONICSsimple mechatronics
ESSENTIALS The general use and essentials for Make-at-Home projects are listed below with comment as Basic or Important or Optional keyword, which means that, BASIC : very much required and affordable IMPORTANT : having this item is advantageous OPTIONAL : may be purchased later BREAD BOARD : A bread board is used for connecting electronic components of a circuit, quickly. The bread board has holes to insert leads of electronic components and interconnecting them using flexible jumper wires. The bread boards are available in various sizes and their ends have slots and projections for adding more bread boards in cascading. Normally, holes of top two lines and bottom two lines are connected horizontally in parallel, which are useful for connecting power supply. The remaining holes, which are in between the horizontal lines, are divided into two groups, top and bottom from mid-line. Each group have holes with vertical connecting lines for connecting main circuit (or components) (BASIC) A model Bread Board with connecting lines, underneath is shown below. Some bread boards with with various sizes are also shown for reference. PRINTED CIRCUIT BOARD (PCB) : A PCB is used to assemble a circuit, using soldering method. A PCB is made of flat insulating material (FR-4, glass epoxy etc.), contains copper tracks (strips) stick on its surface, as connectors for a circuit, is known as Single sided PCB. Holes are made, wherever required to insert the particular electronic component through it, then solder on other side. The surface of PCB, where pinouts of the components to be inserted are printed is called as Silkscreen side . The other surface, on which the leads of the components are soldered is called Soldering side . ( IMPORTANT) Some PCBs have copper track on both the surfaces, is called Double sided PCB . Some PCBs have insulating material and copper tracks as alternate layers is called multi-layer PCB s. The insulating material selection depends on the di-electric strength required and frequency of the data transfer for the circuit. The thickness and width of the copper track depends upon the current carrying capacity required between in the components in the circuit. Single sided, general purpose PCBs, which are easily available and affordable, are normally used in our Make-at-Home projects. If you want to make a complete project and enclose it aesthetically, then select proper PCB, with required size. Some general purpose PCBs with various sizes and connecting lines (dots and lines) are shown for reference. One custom made PCB (green coloured) is also shown as an example. JUMPER WIRES : Jumper wire means , a small wire (about 15cm to 30cm length), low current capacity (normally used for signal transmission) with black coloured end connections on either end (or sometimes one end only). The end connection may be male type (which has pin projecting out) or female type (which has hole). So, the jumper wires are available with following end connectors 1) Male-Male 2)Female-Male and 3) Female-Female. The jumper wires are frequently used for prototyping and quick testing, by connecting holes of bread board or to external components or other circuits/modules. (BASIC) CONNECTORS : Connectors are used to connect / disconnect single or multiple wiring connections easily and quickly. Various types are used on a circuit board, which depends on number of wire connections and current flow through them. The Berg strips and DC power connectors are highly used in most of the circuits. Some connectors, which are frequently used in the circuits are shown below. (IMPORTANT) RELIMATE CONNECTORS : Relimate connectors are also used for quick connect/disconnect multiple wire connections, mostly for PCB to the electronic component or module. Single or double row pins are used for these connectors and the number of pins varies per row as per requirement. The main advantage with Relimate connectors is, they are polarized, i.e., connects in one direction only, to avoid reverse connection. Some Relimate connectors are shown for reference below. (IMPORTANT) CLIPS : Clips are used to connect / disconnect a wiring connections easily and quickly, while testing a circuit. Various types of clips are used as per requirement. Some clipos, which are frequently used in the circuits are shown below. (IMPORTANT) WIRES : Single or multi-strand copper wires (electrical conducting material) are used for connection between electronic components and power supply connections. The cross-section of copper wire depends on the required current to flow through it, (which is directly proportional). Most of the times the copper wire is covered with insulating material (as a sleeve) like, PVC, PTFE etc. For easy identification of wire connection(s), various coloured sleeved wires are used in the circuit board(s) (BASIC) JUMPER CAPS : Jumper cap ( or shorting jumper) is a small connector with 0.1" (2.54mm) pitch, with rectangular plastic enclosure. A small groove is provided on upper portion, as a grip, for easy removal of jumper cap from a circuit. Jumper caps are used to simply connect or disconnect two pins as per users requirements / settings, which is provided in the circuit. It is also useful to quick testing of a circuit. (BASIC) HEAT SHRINK TUBE : A Heat shrink tube is made up of rubber material, in a tubular form. When a small length of the tube is exposed to small flame (or heat), the diameter of the tube shrinks to lower diameter. So, this is positioned on a soldered joint (or any wire joint), and small heat applied to it, to shrink and fit on the exposed metal joint and protect as insulator. (IMPORTANT) The Heat shrink tubes are available with various diameters, out of which, 3mm and 5mm are very useful for Make_at-Home projects. A small gas lighter or hot air blower, is required to apply heat on the surface of the heat shrink tube. INSULATION TAPE : An insulation tape is used to cover joined wires, especially used for mains supply, to avoid electrical leakage and protect from shock, through the exposed copper (metal) wire. Now-a-days, the insulation tapes are available in various colours also. Having at least one insulation tape is recommended. (BASIC) CELLO TAPE : A Cello tape ( or Cellophane tape ) is easily available and affordable, which is transparent and having glue one side. Due to it's transparency and quick fixing on surfaces, it is very much useful to hold small electronic components in position and insulating from conductors (tracks, wires etc.). The cello tapes are available in various widths, like half-inch, one-inch, 2 inch etc. Select the width to suit your requirement. (IMPORTANT) DOUBLE SIDED TAPE : A double sided foam tape is useful to quickly position some electronic modules / components and its related items together. eg: placing small displays, modules on main PCB. (IMPORTANT) EMERY PAPER : A emery / sand paper is also very useful, to clean the surfaces of PCBs before soldering. It is also useful to clean the leads of electronic components before soldering. A high dense, very fine size emery should be used to avoid, unnecessary scratches on the surface, instead of cleaning. So, select emery paper with grit about 1000. (BASIC) CABLE TIES : A cable tie (nylon zip tie) is useful to tie multiple wires / cables together. A cable tie is wrapped around a group of wires and cables and its free end is pulled though its rectangular opening for locking. By pulling the free end, through the eye on other end, the wrapped cables get tightened and locked automatically. A marking on the cable tie or a label used with wires tie is useful for grouping the wires and identify them easily and their functionality. Now-a-days, cable ties are available in various sizes and colors. You have to select the required size. Using multi-coloured coloured cable ties are also useful to easily identifying the group of wires and purpose. (OPTIONAL) SCREWS & NUTS : Fasteners like small screws / bolts, nuts and washers are also important to fix the PCBs, heat sinks, displays, some bigger size components etc. Most of the times M2.7, M3 and M4 screw set of half-inch or one-inch lenght is used. The higher size fasteners are rarely used. Some times wood screws are also used, if the base or cabinet is made of wood / plywood etc. (IMPORTANT) ANTI-STATIC ENVELOPES : Better to maintain anti-static envelopes to keep the modules / circuits, which will protect them from damage due to static electricity, if any. Keeping the components and circuits at-least in a plastic self-sealing cover is preferable. (OPTIONAL) CONTAINERS/RACKS : To keep the electronic components, modules, circuits etc., suitable containers and racks are required. To assemble the completed circuit also, suitable containers / cabinets are to be selected. (OPTIONAL) WORKING TABLE AND CHAIR : Last but not least, a wooden table and chair is required for keeping the components, circuits, soldering station, power supplies etc., at a reach of hand is appreciated. The table and chair should be comfortable while working with the circuits (ergonically designed, if possible) (OPTIONAL) Seek ADVICE, but use your own COMMON SENSE. – Yiddish Proverb
- 01 Omni Robo Base
Previous < Back Next DESC ABOUT OMNI ROBO BASE Intro to Omni Robo - BASE