Skip to main content

Posts

Arduino Code To Wire any Serial Device

#include <SoftwareSerial.h> SoftwareSerial mySerial(10, 11); // RX, TX ]] change this to pin to which arduino is connected void setup() {   // Open serial communications and wait for port to open:   Serial.begin(9600);   while (!Serial) {     ; // wait for serial port to connect. Needed for native USB port only   }   // set the data rate for the SoftwareSerial port   mySerial.begin(9600); } void loop() { // run over and over   if (mySerial.available()) {     Serial.write(mySerial.read());   }   if (Serial.available()) {     mySerial.write(Serial.read());   } }

Introduction To Windows Services

Understanding windows service fundamentals Overview : Why develop windows services ? 1. Run even when no user is logged in 2. Start automatically on machine boot 3. Run as different users(inc. built in) 4. Start,stop,pause, resume services 5. Failure Policy (eg . auto start ) 6. Manage from remote machines (eg stop) Typical usecase of windows services : 1. File conversion (e.g. video / audio ) 2. System intergration(file-ingenstion) 3. System integration (data transfer between systems) 4. Run web server (e.g owin self hosting) 5. Message queue processing (eg. MSMq) 6. Host remote Akka .Net Actor System 7. Host other services eg. Mail , Ftp etc. SERVICE STARTUP MODES 1. Manual 2. Automatic 3. Automatic(Delayed Start ) 4. Disabled 5. Triggers SERVICE LOG ON ACCOUNTS 1. Local system built in account 2. Local Service Account 3. Network Service Account 4. Local User custom Account 5. Domain User custom Account SERVICE RECOVERY OP...

Python Crash Course : Part 1

HISTORY :  Written by Guido Van Rossum in 1980s, i.e Guido started writing Python in 1989 December. Van Rossum is Python's principal author, and his continuing central role in deciding the direction of Python is reflected in the title given to him by the Python community,  benevolent dictator for life  (BDFL). INSTALLING PYTHON :  The python interpreted which can be downloaded from website www.python.org (https://www.python.org/download/releases) CHECKING SUCCESSFUL INSTALL : Open command prompt. Type " assoc .py " , without quotes. That should return ".py=Python.File Cool ! Up and Running to write the scripts !

Cheat Sheet for Windows Command Prompt

To open the Windows command prompt you may do one of the following: - Click Start -> Programs -> Accessories -> Command Prompt - Click Start (or hit the Windows key), type “cmd” in search, then hit [ENTER] - Windows Key + R (#r, not the pound symbol) brings up Run. Then type “cmd” then [ENTER] - SHIFT + right-click in any folder or desktop, then select “open command window here” Basic Command Prompt Commands x /? = provides syntax info and complete list of all parameters for x (a command, like “cd”) cd = change directory cd .. = move to the parent directory cd\ = move to the root of current drive cd x = move to the current\x directory cd z: = change to the z root directory (as opposed to c:\) copy x y = copy file x to directory y (Ex: D:\games\galaga.exe C:\programs[\awesome.exe]), [] = optional copy file con = display file contents in console copy con file.txt = create text file in the console window, end with ctrl+z (^z or F6) date = change the date de...

Procedure to enable wireless LAN adapter in vmware!

I have went to find the way in which wlan in Kali Linux could be made listed my airmon-ng command. Most of the videos and posts suggested me that it is necessary to have another wi-fi adapter to have connected to wifi network. But this is not necessary. The procedure to do this is as follows: 1. Download this package in Virtual Machine(Kali linux) " http://wireless.kernel.org/download/compat-wireless-2.6/compat-wireless-2010-06-26-p.tar.bz2" 2.Unzip this package in terminal i.e navigate to place where you have downloaded this file , say desktop then type : cd Desktop for unzip type : tar -jxvf compat-wireless-2010-06-26-p.tar.bz2 3. Navigate into the uncompressed directory and type: i."make unload"  (only words within the quotes are the commands) ii."make load" Done!  now airmon-ng  should have the list of the required devices.

Intuitive Way of understanding voltage!

Formal definition in an Electromagnetic course tells us that it is "It is the amount of work done in bringing a unit positive charge from infinity to that point".(definition of potential,voltage is potential difference) So it is basically work , and it is particular form of work i.e of a unit charge carrying work. Well the problem with this is we encounter the notion of infinity here. So infinity is bit paradox in nature. Lets try to get idea of infinity by some metaphor. Lets assume you are ant , but a scientific research ant and ant community is as good as human community. All facilities are to the scale of ant community.The ant present in a garden and mapping of garden and discovering many things and phenomenon in garden is work of generations for ant. So they have no idea of earth, planets or solar system.They would be calling that world beyond this park is infinity, it means the measure is way beyond the potential to measure such thing. All the story gave a perspec...

Why cross method of multiplication or vedic method of multiplication works?

It is evident the truth remains eternal even though you have many ways to reach it. With that quote .. So one perspective of the famous vedic method of multiplication can be broken down as follows: let there be two 2 digit numbers  , say       12     and  21   , so writing with their place values, we get (10+2)  and (20+1)  , so if we watch the operation we do in (a+b)(c+d)  is  ac+ad+bc+bd , the same holds good for any numbers. The application of  (a+b)^2 for square of a number is also a simplified version of the above notion. SO the cross multiplication method isn't that spooky , right?