As per Oracle documentation, SimpleDateFormat is a concrete class for formatting and parsing dates in a locale-sensitive manner. In this example, we have imported simple date format class from java as shown below -import java.text.SimpleDateFormat; import java.util.Date;Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml. In the above code, we have given text view, it going to print the current date on the window manager.Step 3 − Add the following code to ... Read More
Sometimes we need to test our iOS app with multiple cases and we may not have physical device all the time. For example if we need to see if image upload is working correctly but we do not have an actual iPhone then we may need to add more images to the simulator and test from there. Adding images to simulator is an easy task and can be done in a few different ways. Some of them are mentioned below.Method 1Open Simulator appSelect the image you want to addDrag and drop it in the simulatorIt will be added to the ... Read More
To send an email from our application we'll need to use URL Schemes and some action on event of which the email will be sent. We can not actually send email from the application, unless it is an mailing application and we use MessageUI framework of iOS, but we can open some email app from our application with prefilled email and subject.We'll see both the ways of doing this.Let's see how we can open the MAIL app of iOS with an example.Create a project and on its first view controlleradd a button and change it's text to open "open e-mail", ... Read More
To create a web view in iOS we'll use Webkit framework of iOS. Previously UIWebView was used to create web views but that has been deprecated now.We'll use WebKit View in this project.Create a new project and from object library drag and drop webKit View to the ViewController.Give constraints as per your requirement.Make an outlet connection to the webKit in ViewController.We'll open facebook in this example using the code below.let url = URL(string: "https://www.facebook.com") override func viewDidLoad() { super.viewDidLoad() let request = URLRequest.init(url: self.url!) self.wbView.load(request) }Now finally we need to add a key App Transport Security Settings ... Read More
We find 8212 available in nowadays as a package chip which is dual inline having 24 pins total. We find its functional pin diagram below.Fig: Pin diagram of 8212 functionalFig: Pin diagram of 8212Voltage of + 5 V is required for it to work based on the supply which is DC. The latch which is 8 bit in 8212 receives the information which is present on the eight data inputs ranging from DI7 to D10. The condition which helps in information latching is present on DI7 to DI0 depends on the state of logic of the pin which is of ... Read More
The below fig shows clearly how 8212 works in the mode 0Fig: 8212 working in mode 0We use this mode generally when we want 8212 to function like an input port. An input device gets connected to DI7-0, and the microprocessor employed here receives the information on DOs ranging from D7-D0. Here in this mode STB acts as clock for the given latches. The latch which is of 8 bits in 8212 follows the series information which is present on DI7 to DI0 as long as STB is equal to 1. When the STB makes a transition, which is high ... Read More
The figure below shows the working of 8212 in mode 1Fig: Working of 8212 in mode 1We use this mode generally when we want 8212 to function as an output port. Here, microprocessor drives DI7-0, and the device at the output receives the information on Do7-0. The clock to the latches is provided in this mode. 8212 latches the information on DI7-0 when the CS makes transition from high to low. The CS signal gets activates when INT* is transferred by the interrupts by the driven data transfer scheme which is always performed when desired. The buffer at the output ... Read More
We use Intel 8212 in variety of applications. Let us discuss applications of 8212 in Mode 0It acts as buffer which is gatedBus driver which is Bi-directionalFor Interrupting the input portTo supply of eight instructions based on RST.Intel 8212 as gated buffer: A weak logic signal is converted to a strong logic when 8212 works in logic 0. The outputs of 8212 in mode0 is capable of sinking the 15 mA in 0 state, and which proves that a minimum high output voltage of nearly 3.65 V is in the state 1. Intel8212 is always given backup when the input ... Read More
Let's discuss the Following two applicationsLow order address latchOutput port which is interrupting.Intel 8212 as low-order address latch − Here the low-order address lines and data lines are multiplexed and are available as AD7-0. It is convenient to have the address as many times and the separation of data on the different lines. Let's for an example, if we connect a chip like 2716 in an 8085-based system, the 2716 needs bit address of11 bits in its address pins, and here is separate 8 pins kept for data. Now connecting the AD7-0 pins of 8085 to the LS 8 address ... Read More
To create a button on toolbar we'll need to use two different components of iOS and another image that is a back arrow. Before that let's see what those components areToolbar − Toolbar is a native iOS component that is used to display items or toolbar on the bottom of screen.Bar Button item − It is a button that's usually created on a Toolbar or a navigation bar.When a toolbar is created using storyboard, it comes with a Bar button item.Let's start by creating a new project, in the main.storyboard give some background color to the only viewController we have.From ... Read More
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP