Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 8

Western Mindanao State University

College of Engineering and Technology


Computer Engineering and Computer Science Department





CoE 155
Input/Output Systems and Memory Systems
Combolicious














Presented by:
Bucoy, Dennis John
Pusta, Alvin Allan Dan
Wee, Rodrigo




Instructor:
Engr. Odon A. Maravilla


Overview of the System

The project is inspired by the coffee vending machine; we made many changes to have a
different appeal to the users. For the users to enjoy the flavors of their choice, we made it easier for
them by having three main flavors, and these flavors can be mixed. Unfortunately the flavor of all three
when mixed together does not taste that good, so we disregarded it, we have 6(six) flavors available,
Orange, Pineapple, Mango, Orange-Pineapple, Orange-Mango and Pineapple-Mango.

Objective/Goals
The goal is to make a system that operates similarly to the coffee vending machine; the only
difference is that the three flavors can be mixed alternately. Also to be able to communicate with the
hardware machine to the computer via parallel port, the programming language used is Visual Basic 6.0.

Software Components
With the use of Visual Basic 6.0, the communication of the computer and the hardware machine
is made possible with the use of the parallel port. Sending signals through each of the data pins of the
parallel port, while receiving signals are in the status pins of the parallel port. We made use of
components such as forms, progress bars, timers and many more to make the user interface more users
friendly and colorful.

Hardware Components
CIRCUIT
3-6v mechanical relays
3- NPN transistors (C9013)
3- Colored LEDs
1- 6v voltage regulator (7806)
2- 0.01uF capacitors
3- 1k resistors
1- Inverter (7404)
1- NAND gate (7400)
Solid wires
12vdc & 5vdc power supply
SOLENOID VALVE
60grams #26 magnetic wire
Plastic syringes
Spring
Bolt
Plastic hose
DISPENSER
Illustration boards
Paints
3 -1.5L plastic bottles
MISCELLANEOUS MATERIALS
Masking tape
Instant glue
White glue

Circuit Diagram


Program Flow

The system starts when it turns on, from that the software will load the 1
st
page where it will ask
the user to insert a 5Php coin in the slot;

On the next page the system will detect if the cup is in place;



If the cup is detected, the system will ask for the user to select the desired flavor.

Upon the selection of the flavor, the system will ask for confirmation if the desired flavor is sure.


When confirmed, the system will now send data to the machine to pour the selected flavor; the
user will have to wait for the cup to fill.

After filling the cup, the program will now go back to the first page.

Now there are cases where the cup is placed first before the coin is inserted, upon doing this,
the page will go directly to the selection screen wherein the system will ask for the user to select the
desired flavor. And also for a safety feature, upon the selection screen, when we select the desired
flavor, the system will also confirm if the cup is still in place, when the cup is not there anymore, the
system will go back to the 2
nd
page where it will ask for the cup to be placed. The machine will only pour
the selected flavor if and only if the cup is in place.

Scope of the Project
The project will be all about serving juices to the users, having a healthy drink can strengthen
your immune system and a better mood. Also giving options on mixing 2(two) juices to make it more
delicious.



Methodology
We used the Rapid Application Development (RAD); this methodology focuses on developing
products faster with higher quality. When it comes to gathering requirements, it uses the workshop
method. Prototyping is used for getting clear requirements and re-use the software components to
accelerate the development timelines. Source from:
http://www.tutorialspoint.com/management_concepts/project_management_methodologies.htm.



There are four phases; the first phase is the Requirement Planning phase, wherein we planned
on what we needed to do, research on possible materials that can be used, and some we improvised.
We also do research about Visual Basic 6.0, to make an interesting and user friendly Graphical User
Interface. Next is the User Design phase, where we need to make it simple as possible, also imagining
that the system will be using a touch screen module like the Vending Load Machine. Also making it fruity
colored. Then the Construction phase, we made the a program codes possible with the Visual Basic 6.0,
by sending and receiving signals with the use of the parallel port. While constructing the program, we
also constructed the machine, wherein we develop ways to make results of the output given in the
parallel port to the LED lights and Solenoid, and the input to the parallel port from the coin detector and
cup detector. Lastly, the Cutover phase, where we finalize the project, getting it ready to be presented.


Program Code

module 1 code:

Public Declare Function Inp Lib "inpout32.dll" _
Alias "Inp32" (ByVal PortAddress As Integer) As
Integer
Public Declare Sub Out Lib "inpout32.dll" _
Alias "Out32" (ByVal PortAddress As Integer,
ByVal Value As Integer)


Form 1 Code: ---------------------------------


Private Sub Form_Load()
Timer1 = True
End Sub

Private Sub Timer1_Timer()
Out 888, 0

Var = Inp(889)
If Var = 63 Or Var = 191 Then ' 127 is default..
use 111
Form3.Show
Unload Me
Else
Form1.Show
End If
End Sub

Form 2 Code: ---------------------------------

Dim PortAddress As Integer

Private Sub cmdmango_Click(Index As Integer)
' click mango icon
Dim Example As Integer
Var = Inp(889)
Answer = MsgBox("ARE YOU SURE?", vbYesNo,
" ") ' prompt if yes/no
If Var = 255 And Answer = vbYes Then
' if yes
Out 888, 8 ' send signal
from port number 4
Form5.Show ' load form 5
Unload Me
Else
Form3.Show
Unload Me
End If

If Answer = vbNo Then ' if no
return to active screen

End If
End Sub

Private Sub cmdom_Click(Index As Integer)
Dim Example As Integer
Var = Inp(889)
Answer = MsgBox("ARE YOU SURE?", vbYesNo,
" ")
If Var = 255 And Answer = vbYes Then
Out 888, 9
Form7.Show
Unload Me
Else
Form3.Show
Unload Me
End If
If Answer = vbNo Then

End If
End Sub

Private Sub cmdorange_Click(Index As Integer)
Dim Example As Integer
Var = Inp(889)
Answer = MsgBox("ARE YOU SURE?", vbYesNo,
" ")
If Var = 255 And Answer = vbYes Then
Out 888, 1
Form5.Show
Unload Me
Else
Form3.Show
Unload Me
End If

If Answer = vbNo Then

End If
End Sub

Private Sub cmdpine_Click(Index As Integer)
Dim Example As Integer
Var = Inp(889)
Answer = MsgBox("ARE YOU SURE?", vbYesNo,
" ")
If Var = 255 And Answer = vbYes Then
Out 888, 2
Form5.Show
Unload Me
Else
Form3.Show
Unload Me
End If

If Answer = vbNo Then

End If
End Sub

Private Sub cmdpm_Click(Index As Integer)
Dim Example As Integer
Var = Inp(889)
Answer = MsgBox("ARE YOU SURE?", vbYesNo,
" ")
If Var = 255 And Answer = vbYes Then
Out 888, 10
Form7.Show
Unload Me
Else
Form3.Show
Unload Me
End If

If Answer = vbNo Then

End If
End Sub

Private Sub cmdpo_Click(Index As Integer)
Dim Example As Integer
Var = Inp(889)
Answer = MsgBox("ARE YOU SURE?", vbYesNo,
" ")
If Var = 255 And Answer = vbYes Then
Out 888, 3
Form7.Show
Unload Me
Else
Form3.Show
Unload Me
End If

If Answer = vbNo Then

End If
End Sub

Form 3 Code:-----------------------------------

Private Sub Form_Load()
Timer1 = True
End Sub

Private Sub Timer2_Timer()
Out 888, 0
' default port number
Var = Inp(889) ' getting input form the p.port
If Var = 255 Then
' 127 is default.. use 111
Form2.Show ' load form 2
Unload Me
Else
Form3.Show
End If
End Sub

Form 5 Code, pero el next code este which is
pang form 4 :----------------------------------


Private Sub Image1_Click()
ProgressBar1.Value = ProgressBar1.Min
'progress bar icon
End Sub

Private Sub Timer1_Timer() 'timer
ProgressBar1.Value = ProgressBar1.Value + 10
If ProgressBar1.Value = 50 Then
ProgressBar1.Value = ProgressBar1 + 50
If ProgressBar1.Value >= ProgressBar1.Max
Then
Timer1.Enabled = False
Form1.Show
Unload Me
End If
End If
End Sub


Form 7 Code:Which is pang next le so pang
form 5.-------------------------------------

Private Sub Image1_Click()
ProgressBar1.Value = ProgressBar1.Min
'progress bar icon
End Sub

Private Sub Timer1_Timer() 'timer
ProgressBar1.Value = ProgressBar1.Value + 10
If ProgressBar1.Value = 50 Then
ProgressBar1.Value = ProgressBar1 + 50
If ProgressBar1.Value >= ProgressBar1.Max
Then
Timer1.Enabled = False
Form1.Show
Unload Me
End If
End If
End Sub

You might also like