#Region Project Attributes
#ApplicationLabel: b4aGeneralIRremote
#VersionCode: 1
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: portrait
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: False
#IncludeTitle: True
#End Region
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Dim gr As GeneralIRcontrol
Private Button1 As Button
Private Button2 As Button
Dim frequency As Int = 38000
'Add your commands here. There are 50 commands provided for in the library
Dim AirConOn() As Int = Array As Int(173,161,26,55,26,15,25,55,26,54,26,15,26,15,25,54,27,15,25,15,25,55,26,15,25,15,26,54,26,55,26,15,25,54,27,54,27,14,26,54,26,55,26,54,27,54,26,54,27,54,26,15,26,54,26,15,26,14,26,15,25,15,26,15,26,15,25,15,26,54,26,15,25,15,26,15,25,15,26,14,26,15,26,53,27,15,25,54,27,54,26,55,26,54,27,54,26,54,27,207,173,161,26,54,27,14,26,54,27,54,26,15,25,15,26,54,26,15,26,15,25,55,26,15,25,15,26,54,26,54,27,14,26,54,27,54,26,15,25,55,26,54,27,54,26,54,27,54,26,55,26,15,25,55,26,15,25,15,26,15,25,15,25,15,26,15,25,15,26,54,26,13,27,13,26,15,25,15,26,15,25,13,27,54,26,15,26,54,26,54,27,54,26,54,27,54,26,54,27,2500)
Dim AirConOff() As Int = Array As Int(173,160,27,54,26,15,26,54,26,54,27,14,26,15,26,53,27,15,25,15,26,54,26,15,26,15,25,54,27,54,26,15,26,54,26,15,26,54,26,54,27,54,26,54,27,15,25,55,26,54,26,54,27,15,26,14,26,15,25,15,25,54,27,15,25,15,26,54,26,55,26,54,27,14,26,15,25,13,26,15,26,15,25,15,26,15,25,15,25,55,26,54,27,54,26,54,27,54,27,206,174,160,27,54,26,15,26,54,26,54,27,15,25,15,25,55,26,15,26,15,25,54,27,14,26,15,25,54,27,54,26,15,26,54,26,15,26,55,26,54,27,53,27,54,27,14,26,54,26,55,26,54,27,15,25,15,25,15,26,15,25,54,27,14,26,15,26,54,26,54,27,54,26,15,26,15,25,15,25,15,26,15,25,15,26,14,26,13,26,54,27,54,26,55,26,54,26,55,26,2500)
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
Activity.LoadLayout("main")
gr.Initialize("")
End Sub
Sub Activity_Resume
gr.StartInfraRed
End Sub
Sub Activity_Pause (UserClosed As Boolean)
gr.StopInfraRed
End Sub
Sub Button1_Click
'Using the first command
gr.Command(frequency,AirConOn)
End Sub
Sub Button2_Click
'Using the second command
gr.Command(frequency,AirConOff)
End Sub
'Add from here onwards more buttons for the other 48 available command