#Region Project Attributes
#MainFormWidth: 900
#MainFormHeight: 600
#End Region
Sub Process_Globals
Private fx As JFX
Private MainForm As Form
Private Serial1 As Serial
Private AStream As AsyncStreams
Private btnConnect As Button
Private cmbPorts As ComboBox
Private txtLog As TextArea
End Sub
Sub AppStart (Form1 As Form, Args() As String)
MainForm = Form1
MainForm.RootPane.LoadLayout("Main")
Serial1.Initialize("Serial1")
Dim Ports As List = Serial1.ListPorts
For Each p As String In Ports
cmbPorts.Items.Add(p)
Next
If cmbPorts.Items.Size > 0 Then
cmbPorts.SelectedIndex = 0
End If