<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>EmbLogic &#187; gaurav.bahuguna</title>
	<atom:link href="https://www.emblogic.com/blog/author/gaurav-bahuguna/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.emblogic.com/blog</link>
	<description>Embedded System and ARM Training</description>
	<lastBuildDate>Tue, 03 Mar 2020 13:00:06 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.9.1</generator>
	<item>
		<title>Serial Vs Parallel Port communication, which one is faster and better ?</title>
		<link>https://www.emblogic.com/blog/03/serial-vs-parallel-port-communication-which-one-is-faster-and-better/</link>
		<comments>https://www.emblogic.com/blog/03/serial-vs-parallel-port-communication-which-one-is-faster-and-better/#comments</comments>
		<pubDate>Mon, 03 Mar 2014 06:42:10 +0000</pubDate>
		<dc:creator><![CDATA[gaurav.bahuguna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.emblogic.com/blog/?p=8781</guid>
		<description><![CDATA[The communication links across which computers—or parts of computers—talk to one another may be either serial or parallel. A parallel link transmits several streams of data (perhaps representing particular bits of a stream of bytes) along multiple channels (wires, printed &#8230; <a href="https://www.emblogic.com/blog/03/serial-vs-parallel-port-communication-which-one-is-faster-and-better/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>The communication links across which computers—or parts of computers—talk to one another may be either serial or parallel. A parallel link transmits several streams of data (perhaps representing particular bits of a stream of bytes) along multiple channels (wires, printed circuit tracks, optical fibres, etc.); a serial link transmits a single stream of data.</p>
<p>At first sight it would seem that a serial link must be inferior to a parallel one, because it can transmit less data on each clock tick. However, it is often the case that serial links can be clocked considerably faster than parallel links, and achieve a higher data rate. A number of factors allow serial to be clocked at a greater rate:</p>
<p>Clock skew between different channels is not an issue (for unclocked asynchronous serial communication links)<br />
A serial connection requires fewer interconnecting cables (e.g. wires/fibres) and hence occupies less space. The extra space allows for better isolation of the channel from its surroundings<br />
Crosstalk is less of an issue, because there are fewer conductors in proximity.<br />
In many cases, serial is a better option because it is cheaper to implement. Many ICs have serial interfaces, as opposed to parallel ones, so that they have fewer pins and are therefore less expensive</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/03/serial-vs-parallel-port-communication-which-one-is-faster-and-better/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Centronics parallel interface</title>
		<link>https://www.emblogic.com/blog/02/centronics-parallel-interface/</link>
		<comments>https://www.emblogic.com/blog/02/centronics-parallel-interface/#comments</comments>
		<pubDate>Sat, 22 Feb 2014 11:46:26 +0000</pubDate>
		<dc:creator><![CDATA[gaurav.bahuguna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.emblogic.com/blog/?p=8522</guid>
		<description><![CDATA[The Centronics parallel interface is an older and still widely-used standard I/O interface for connecting printer s and certain other devices to computers. The interface typically includes a somewhat cumbersome cable and a 36- pin male and female connector at &#8230; <a href="https://www.emblogic.com/blog/02/centronics-parallel-interface/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>The Centronics parallel interface is an older and still widely-used standard I/O interface for connecting printer s and certain other devices to computers. The interface typically includes a somewhat cumbersome cable and a 36- pin male and female connector at the printer or other device. The cable plugs into a 25-pin parallel port on the computer. Data flows in one direction only, from the computer to the printer or other device. In addition to eight parallel data lines, other lines are used to read status information and send control signals. Centronics Corporation designed the original Centronics parallel interface for dot matrix printers. In 1981, IBM used this interface as an alternative to the slower one-bit-at-a-time serial interface.</p>
<p>When the Centronics parallel interface was first developed, the main peripheral was the printer. Since then, portable disk drives, tape backup drives, and CD-ROM players are among devices that have adopted the parallel interface. These new uses caused manufacturers to look at new ways to make the Centronics parallel interface better. In 1991, Lexmark, IBM, Texas instruments, and others met to discuss a standard that would offer more speed and bi-directional communication. Their effort and the sponsorship of the IEEE resulted in the IEEE 1284 committee. The IEEE 1284 standard was approved for release in March, 1994.</p>
<p>The IEEE 1284 standard specifies five modes of operation, each mode providing data transfer in either the forward direction (computer to peripheral), backward direction (peripheral to computer), or bi-directional (one direction at a time).</p>
<ul>
<li><strong>Compatibility mode</strong> is the original Centronics parallel interface and intended for use with dot matrix printers and older laser printers. The compatibility mode can be combined with the nibble mode for bi-directional data transfer.</li>
<li><strong>Nibble mode</strong> allows data transfer back to the computer. The nibble mode uses the status lines to send 2 nibble s (4-bit units) of data to the computer in two data transfer cycles. This mode is best used with printers.</li>
<li><strong>Byte mode</strong> uses software driver s to disable the drivers that control the data lines in order for data to be sent from the printer to the computer. The data is sent at the same speed as when data is sent from the computer to the printer. One byte of data is transferred instead of the two data cycles required by the nibble mode.</li>
<li><strong>ECP mode</strong> (Enhanced Capability Port mode) is an advanced bi-directional mode for use with printers and scanner s. It allows data compression for image s, FIFO (first in, first out) for items in queue s, and high-speed, bi-directional communication. Data transfer occurs at two to four megabytes per second. An advanced feature of ECP is channel addressing . This is used for multifunction devices such as printer/fax/modem devices. For example, if a printer/fax/modem device needs to print and send data over the modem at the same time, the channel address software driver of the ECP mode assigns a new channel to the modem so that both devices can work simultaneously.</li>
<li><strong>EPP mode</strong> (Enhanced Parallel Port mode) was designed by Intel, Xircom, and Zenith Data Systems to provide a high-performance parallel interface that could also be used with the standard interface. EPP mode was adopted as part of the IEEE 1284 standard. The EPP mode uses data cycles that transfer data between the computer and the peripheral and address cycles that assign address, channel, or command information. This allows data transfer speeds of 500 kilobytes to 2 megabytes per second, depending on the speed of the slowest interface. The EPP mode is bi-directional. It is suited for network adapters, data acquisition, portable hard drives, and other devices that need speed.</li>
</ul>
<p>The computer must determine what the capabilities of the attached peripheral are and which mode to utilize. The concept developed to determine these factors is called negotiation. Negotiation is a sequence of events on the parallel port interface that determines which IEEE 1284 modes the device can handle. An older device will not respond to the negotiation sequence and compatibility mode is selected to operate that device. A newer device will respond to the negotiation sequence and a more advanced mode can be set.</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/02/centronics-parallel-interface/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Understanding The Fork Bomb</title>
		<link>https://www.emblogic.com/blog/01/understanding-the-fork-bomb/</link>
		<comments>https://www.emblogic.com/blog/01/understanding-the-fork-bomb/#comments</comments>
		<pubDate>Sun, 12 Jan 2014 10:16:00 +0000</pubDate>
		<dc:creator><![CDATA[gaurav.bahuguna]]></dc:creator>
				<category><![CDATA[Linux Internals and System Programming]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.emblogic.com/blog/?p=8101</guid>
		<description><![CDATA[The fork bomb is a form of denial-of-service (DoS) attack against a Linux based system. It makes use of the fork operation. the processes recursively fork until a denial of service or a crash occurs Fork bombs count as wabbits &#8230; <a href="https://www.emblogic.com/blog/01/understanding-the-fork-bomb/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>The fork bomb is a form of denial-of-service (DoS) attack against a Linux based system. It makes use of the fork operation. the processes recursively fork until a denial of service or a crash occurs<br />
Fork bombs count as wabbits (a type of self-replicating computer program) they typically do not spread as worms or viruses. To incapacitate a system they rely on the (generally valid) assumption that the number of programs and processes which may execute simultaneously on a computer, has a limit.</p>
<p><a href="http://www.emblogic.com/blog/01/understanding-the-fork-bomb/800px-fork_bomb-svg/" rel="attachment wp-att-8109"><img class="aligncenter size-medium wp-image-8109" src="http://www.emblogic.com/blog/wp-content/uploads/2014/01/800px-Fork_bomb.svg_-300x184.png" alt="" width="300" height="184" /></a><br />
A fork bomb works by creating a large number of processes very quickly in order to saturate the available space in the list of processes kept by the computer&#8217;s operating system. If the process table becomes saturated, no new programs may start until another process terminates. Even if that happens, it is not likely that a useful program may be started since the instances of the bomb program will each attempt to take any newly-available slot themselves.<br />
Not only do fork bombs use space in the process table each child process uses further processor-time and memory. As a result of this, the system and existing programs slow down and become much more unresponsive and difficult or even impossible to use.</p>
<p>fork bombs can occur by accident in the normal development of software. The development of an application that listens on a network socket and acts as the server in a Client-server system may well use an infinite loop and fork operation in a manner similar to one of the programs presented below. A trivial bug in the source of this kind of application could cause a fork bomb during testing.</p>
<h1>How to Make a Fork Bomb Virus</h1>
<p>This is how to make a fork bomb, open the terminal as superuser, and execute the following</p>
<div dir="ltr">
<div>
<pre>: (){ :|:&amp; };:</pre>
</div>
</div>
<p>Understanding the above:</p>
<div dir="ltr">
<div>
<pre>: ()      # define ':' -- whenever we say ':', do this:
{        # beginning of what to do when we say ':'
    :    # load another copy of the ':' function into memory...
    |    # ...and pipe its output to...
    :    # ...another copy of ':' function, which has to be loaded into memory
         # (therefore, ':|:' simply gets two copies of ':' loaded whenever ':' is called)
    &amp;    # disown the functions -- if the first ':' is killed, all of the functions that it has started should NOT be auto-killed
}        # end of what to do when we say ':'
;        # Having defined ':', we should now...
:        # ...call ':', initiating a chain-reaction: each ':' will start two more.</pre>
</div>
</div>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/01/understanding-the-fork-bomb/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Client Server Endpoints Communication using AF_UNIX Sockets [RCS Log]</title>
		<link>https://www.emblogic.com/blog/12/client-server-endpoints-communication-using-af_unix-sockets-rcs-log/</link>
		<comments>https://www.emblogic.com/blog/12/client-server-endpoints-communication-using-af_unix-sockets-rcs-log/#comments</comments>
		<pubDate>Mon, 30 Dec 2013 07:59:37 +0000</pubDate>
		<dc:creator><![CDATA[gaurav.bahuguna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.emblogic.com/blog/?p=7927</guid>
		<description><![CDATA[SERVER RCS head 1.3; access; symbols; locks; strict; comment @ * @; 1.3 date 2013.12.30.07.41.22; author root; state Exp; branches; next 1.2; 1.2 date 2013.12.29.10.18.09; author root; state Exp; branches; next 1.1; 1.1 date 2013.12.29.09.45.45; author root; state Exp; branches; &#8230; <a href="https://www.emblogic.com/blog/12/client-server-endpoints-communication-using-af_unix-sockets-rcs-log/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p><strong>SERVER RCS</strong><br />
<code></code><br />
head 1.3;<br />
access;<br />
symbols;<br />
locks; strict;<br />
comment @ * @;<br />
1.3<br />
date 2013.12.30.07.41.22; author root; state Exp;<br />
branches;<br />
next 1.2;<br />
1.2<br />
date 2013.12.29.10.18.09; author root; state Exp;<br />
branches;<br />
next 1.1;<br />
1.1<br />
date 2013.12.29.09.45.45; author root; state Exp;<br />
branches;<br />
next ;<br />
desc<br />
@Server Program is ready to roll ..<br />
@<br />
1.3<br />
log<br />
@after few modifications server will now read data from socket, and increment the the recieved character by one and will write again: New Functionality Added in this version.<br />
@</p>
<p>&nbsp;<br />
<strong>CLIENT RCS</strong></p>
<p>head 1.3;<br />
access;<br />
symbols;<br />
locks; strict;<br />
comment @ * @;</p>
<p>1.3<br />
date 2013.12.30.07.44.46; author root; state Exp;<br />
branches;<br />
next 1.2;</p>
<p>1.2<br />
date 2013.12.29.10.18.44; author root; state Exp;<br />
branches;<br />
next 1.1;</p>
<p>1.1<br />
date 2013.12.29.10.06.57; author root; state Exp;<br />
branches;<br />
next ;</p>
<p>desc<br />
@Client program<br />
@</p>
<p>1.3<br />
log<br />
@in this version client will connect to server and will write a character on socket, and after procesing from server, it will read and display the character from socket.<br />
@</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/12/client-server-endpoints-communication-using-af_unix-sockets-rcs-log/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Advantages and Disadvantages of Semaphores</title>
		<link>https://www.emblogic.com/blog/12/advantages-and-disadvantages-of-semaphores/</link>
		<comments>https://www.emblogic.com/blog/12/advantages-and-disadvantages-of-semaphores/#comments</comments>
		<pubDate>Mon, 30 Dec 2013 07:37:30 +0000</pubDate>
		<dc:creator><![CDATA[gaurav.bahuguna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.emblogic.com/blog/?p=7818</guid>
		<description><![CDATA[&#160; Advantages In semaphores there is no spinning, hence no waste of resources due to no busy waiting. That is because threads intending to access the critical section are queued. And could access the priority section when the are de-queued, &#8230; <a href="https://www.emblogic.com/blog/12/advantages-and-disadvantages-of-semaphores/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>&nbsp;</p>
<p style="color: white;background-color: black">Advantages</p>
<p style="color: white;background-color: gray">In semaphores there is no spinning, hence no waste of resources due to no busy waiting. That is because threads intending to access the critical section are queued. And could access the priority section when the are de-queued, which is done by the semaphore implementation itself, hence, unnecessary CPU time is not spent on checking if a condition is satisfied to allow the thread to access the critical section.</p>
<p style="color: white;background-color: gray">Semaphores permit more than one thread to access the critical section, in contrast to alternative solution of synchronization like monitors, which follow the mutual exclusion principle strictly. Hence, semaphores allow flexible resource management.<br />
Finally, semaphores are machine independent, as they are implemented in the machine independent code of the microkernel services.</p>
<p style="color: white;background-color: black">Disadvantages</p>
<p style="color: white;background-color: gray">Problem 1: Programming using Semaphores makes life harder as utmost care must be taken to ensure Ps and Vs are inserted correspondingly and in the correct order so that mutual exclusion and deadlocks are prevented. In addition, it is difficult to produce a structured layout for a program as the Ps and Vs are scattered all over the place. So the modularity is lost. Semaphores are quite impractical when it comes to large scale use.</p>
<p style="color: white;background-color: gray">Problem 2: Semaphores involve a queue in its implementation. For a FIFO queue, there is a high probability for a priority inversion to take place wherein a high priority process which came a bit later might just have to wait when a low priority one is in the critical section. For example, consider a case when a new smoker joins and is desperate to smoke. What if the agent who handles the distribution of the ingredients follows a FIFO queue (wherein the desperate smoker is last according to FIFO) and chooses the ingredients apt for another smoker who would rather wait some more time for a next puff?</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/12/advantages-and-disadvantages-of-semaphores/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
