WS 5 Ans Key
WS 5 Ans Key
1) Visual Basic application source code is structured into ___________ with a .vb suffix.
2) The code to create a form called Form1 will be placed in module file named ________________.
(A) Form1.Designer.vb (B) Form1.Exe
(C) Form1.pdf (D) Form1.Docx
3) Any code that has been defined by the developer to handle events from controls in the form will be
placed by Visual Studio into a module file called __________
(A) VB.Net.pk (B) Form1.vb
(C) Form1.Net (D) Form1.xlsx
4) When the user enters text value in one of the numeric fields (textbox), while doing the calculation the
program will give an “error” called __________
(A) Distinct Error (B) Synchronous Error
(C) Direct Error (D) Faulty Error
5) Logical Operators return ________.
(A) Boolean Result (B) Equal to Result
`(C) Not equal to Result (D) none of the above
Function Module
A function is a type of procedure that returns a value A Module is used to organize the code. Also to wrap
that is passed on to the main procedure to finish up variables, properties, events, and procedures of
execution. similar use.
Correct
Mouse Events Description
Option
1 MouseUp A It occurs when a mouse button is pressed 1D
It occurs when the mouse pointer moves over the control 2C
2 Mouse Hover B
element
It occurs when the mouse pointer hovers over the control 3A
3 MouseDown C
element.
It occurs when the mouse pointer is over the control 4B
4 MouseMove D
element and the mouse button is released
Q8 Identify the type and meaning of the given operators.
XOR Logical Operator One of the two conditions must be true but not both
Q2. Give answer of the following questions about the SERVO MOTOR.
i. What is the purpose of using the SONAR sensor in the Bumble Pi Car project?
SONAR Sensor is used in the Bumble Pi car project to find the obstacles also to measure its distance.
A Sonar Sensor transmits the ultrasonic sound wave (which is inaudible to human ear, for 0.0001 seconds).
The transmitted wave will bounce back when it hits the object.
iii. Give few real life examples of its use.
iv. Sonar Sensor is used in driver-less cars, drones, automatic doors, lifts, radars, submarines and Bumble Pi
Car.
Q4(c)What equipment is used to connect the Servo Motor with Raspberry Pi.
For mobility purposes, we can also make a bootloader, which will automatically start the command or
program whenever the Raspbian OS will boot.
Every device can have a bootloader, that tells the operating system to run which programs after the
startup/system boot. Following are the examples;
1. PC/Laptop: After the Operating System (Windows or MacOS) starts, the AntiVirus app runs
automatically.
2. Mobile Phone: First the OS (Android / IOS) loads, then other social media apps load in the
background, giving notifications etc.
3. Bumble Pi Robotic Car Kit: Raspbian OS loads, then the the SRC.py (program to control the car) runs
automatically.