home *** CD-ROM | disk | FTP | other *** search
Wrap
VERSION 5.00 Object = "{E0DE79BD-3DF3-11D3-8B34-0080ADB93D50}#14.0#0"; "FireCraxor.ocx" Begin VB.Form Form1 BorderStyle = 4 'Fixed ToolWindow Caption = "FireCrax0r - Using FireCraxor.ocx" ClientHeight = 1575 ClientLeft = 45 ClientTop = 285 ClientWidth = 3690 Icon = "FireCraxor_OCX.frx":0000 LinkTopic = "Form1" MaxButton = 0 'False MinButton = 0 'False ScaleHeight = 1575 ScaleWidth = 3690 StartUpPosition = 2 'CenterScreen Begin VB.CommandButton Command1 Caption = "&About" Height = 255 Left = 2760 TabIndex = 10 Top = 120 Width = 855 End Begin VB.TextBox txtCommPort Height = 285 Left = 1200 TabIndex = 9 Text = "2" Top = 120 Width = 615 End Begin FireCraxorCTL.FireCraxor FireCraxor1 Left = 240 Top = 720 _ExtentX = 926 _ExtentY = 926 CommPort = 0 End Begin VB.CommandButton cmdOn Caption = "Turn O&n" Height = 375 Left = 1920 TabIndex = 5 Top = 600 Width = 735 End Begin VB.ComboBox cmbHouseCode Height = 315 Left = 1200 Style = 2 'Dropdown List TabIndex = 4 Top = 600 Width = 615 End Begin VB.ComboBox cmbAppNum Height = 315 Left = 1200 Style = 2 'Dropdown List TabIndex = 3 Top = 1080 Width = 615 End Begin VB.CommandButton cmdOff Caption = "Turn Of&f" Height = 375 Left = 1920 TabIndex = 2 Top = 1080 Width = 735 End Begin VB.CommandButton cmdBright Caption = "&Brighten" Height = 375 Left = 2760 TabIndex = 1 Top = 600 Width = 855 End Begin VB.CommandButton cmdDim Caption = "&Dim" Height = 375 Left = 2760 TabIndex = 0 Top = 1080 Width = 855 End Begin VB.Label Label3 Caption = "Comm Port:" Height = 255 Left = 120 TabIndex = 8 Top = 120 Width = 975 End Begin VB.Label Label1 Caption = "Housecode:" Height = 255 Left = 120 TabIndex = 7 Top = 600 Width = 975 End Begin VB.Label Label2 Caption = "Appliance ID:" Height = 255 Left = 120 TabIndex = 6 Top = 1080 Width = 975 End Attribute VB_Name = "Form1" Attribute VB_GlobalNameSpace = False Attribute VB_Creatable = False Attribute VB_PredeclaredId = True Attribute VB_Exposed = False Private Sub cmdBright_Click() FireCraxor1.SendCommand cmbHouseCode.Text, Val(cmbAppNum.Text), "BRT" End Sub Private Sub cmdDim_Click() FireCraxor1.SendCommand cmbHouseCode.Text, Val(cmbAppNum.Text), "DIM" End Sub Private Sub cmdOff_Click() FireCraxor1.SendCommand cmbHouseCode.Text, Val(cmbAppNum.Text), "OFF" End Sub Private Sub cmdOn_Click() FireCraxor1.SendCommand cmbHouseCode.Text, Val(cmbAppNum.Text), "ON" End Sub Private Sub Command1_Click() MsgBox "This is a test of the FireCraxor Control for X10's FireCracker home automation system (info: www.x10.com). Written by Joseph Sola, homepage at http://reet.i.am" End Sub Private Sub Form_Load() txtCommPort.Text = FireCraxor1.CommPort cmbHouseCode.AddItem "A" cmbHouseCode.AddItem "B" cmbHouseCode.AddItem "C" cmbHouseCode.AddItem "D" cmbHouseCode.AddItem "E" cmbHouseCode.AddItem "F" cmbHouseCode.AddItem "G" cmbHouseCode.AddItem "H" cmbHouseCode.AddItem "I" cmbHouseCode.AddItem "J" cmbHouseCode.AddItem "K" cmbHouseCode.AddItem "L" cmbHouseCode.AddItem "M" cmbHouseCode.AddItem "N" cmbHouseCode.AddItem "O" cmbHouseCode.AddItem "P" cmbHouseCode.ListIndex = 0 For Asdf = 1 To 16 Step 1 cmbAppNum.AddItem Asdf cmbAppNum.ListIndex = 0 End Sub Private Sub txtCommPort_LostFocus() FireCraxor1.CommPort = Val(txtCommPort.Text) End Sub