Changeset 582

Show
Ignore:
Timestamp:
09/13/05 17:11:49 (8 years ago)
Author:
depriest
Message:

Updated readme and fixed more bugs in GUI

Location:
WaveDev/trunk/WaveDev
Files:
5 modified

Legend:

Unmodified
Added
Removed
  • WaveDev/trunk/WaveDev/README.txt

    r580 r582  
    86864. The waveform is now ready to be populated. Exit the Waveform Developer 
    8787 
    88 5. To create a functional waveform, the start() function in AssemblyController and pushPacket() 
    89    function in other components must be completed. 
     885. To create a functional waveform, the start() function in AssemblyController and pushPacket() function in other components must be completed. 
     89 
     906. To build the waveform: 
     91   >> cd <output directory from 3> 
     92   >> ./reconf 
     93   >> ./configure 
     94   >> make 
     95 
     967. To run: 
     97  - start the naming service 
     98  - start the event service 
     99  - run waveform_manager: >> ./waveform_manager 
     100  - run your waveform:    >> ./<waveform_name> 
     101 
     102NOTES: 
     1031) The edit feature in the GUI is not functional yet. 
     1042) You can add ports to a component, but it will not affect any of the 
     105   generated code (again, "yet") 
  • WaveDev/trunk/WaveDev/gui/ComponentFrame.py

    r528 r582  
    99    return CompFrame(parent) 
    1010 
    11 [wxID_COMPFRAME, wxID_COMPFRAMEADDPORTBTN, wxID_COMPFRAMEBUTTON2,  
    12  wxID_COMPFRAMEBUTTON3, wxID_COMPFRAMEBUTTON4, wxID_COMPFRAMECLOSEBTN,  
    13  wxID_COMPFRAMEGRID1, wxID_COMPFRAMENAMETEXT, wxID_COMPFRAMEPORTBOX,  
     11[wxID_COMPFRAME, wxID_COMPFRAMEADDPORTBTN, wxID_COMPFRAMEBUTTON3,  
     12 wxID_COMPFRAMEBUTTON4, wxID_COMPFRAMECLOSEBTN, wxID_COMPFRAMEGRID1,  
     13 wxID_COMPFRAMENAMETEXT, wxID_COMPFRAMEPORTBOX, wxID_COMPFRAMEREMOVEBTN,  
    1414 wxID_COMPFRAMESTATICTEXT1, wxID_COMPFRAMESTATICTEXT2,  
    1515 wxID_COMPFRAMESTATUSBARCOMPONENT,  
     
    9696              id=wxID_COMPFRAMEADDPORTBTN) 
    9797 
    98         self.button2 = wx.Button(id=wxID_COMPFRAMEBUTTON2, label='Delete', 
    99               name='button2', parent=self, pos=wx.Point(280, 181), 
    100               size=wx.Size(85, 30), style=0) 
     98        self.RemoveBtn = wx.Button(id=wxID_COMPFRAMEREMOVEBTN, label='Remove', 
     99              name='RemoveBtn', parent=self, pos=wx.Point(280, 181), 
     100              size=wx.Size(85, 30), style=0) 
     101        self.RemoveBtn.Bind(wx.EVT_BUTTON, self.OnRemoveBtnButton, 
     102              id=wxID_COMPFRAMEREMOVEBTN) 
    101103 
    102104        self.grid1 = wx.grid.Grid(id=wxID_COMPFRAMEGRID1, name='grid1', 
     
    105107        self.grid1.SetColLabelSize(20) 
    106108        self.grid1.SetRowLabelSize(52) 
     109        self.grid1.Enable(False) 
    107110 
    108111        self.button3 = wx.Button(id=wxID_COMPFRAMEBUTTON3, label='Add Prop', 
    109112              name='button3', parent=self, pos=wx.Point(64, 296), 
    110113              size=wx.Size(85, 30), style=0) 
     114        self.button3.Enable(False) 
    111115 
    112116        self.button4 = wx.Button(id=wxID_COMPFRAMEBUTTON4, label='Delete Prop', 
    113117              name='button4', parent=self, pos=wx.Point(192, 296), 
    114118              size=wx.Size(85, 30), style=0) 
     119        self.button4.Enable(False) 
    115120 
    116121        self.staticText1 = wx.StaticText(id=wxID_COMPFRAMESTATICTEXT1, 
     
    127132 
    128133        self.CloseBtn = wx.Button(id=wxID_COMPFRAMECLOSEBTN, label='Close', 
    129               name='CloseBtn', parent=self, pos=wx.Point(360, 256), 
     134              name='CloseBtn', parent=self, pos=wx.Point(360, 296), 
    130135              size=wx.Size(85, 30), style=0) 
    131136        self.CloseBtn.Bind(wx.EVT_BUTTON, self.OnCloseBtnButton, 
     
    136141        self.active_comp = parent.active_comp 
    137142        self._init_ctrls(parent) 
     143        self.grid1.CreateGrid(6,6) 
     144        self.grid1.SetColLabelValue(0,"Property") 
     145        self.grid1.SetColLabelValue(1,"Value") 
     146        self.grid1.SetColLabelValue(2,"Value2") 
     147        self.grid1.SetColLabelValue(3,"....") 
     148        self.grid1.SetColLabelValue(4,"....") 
     149        self.grid1.SetColLabelValue(5,"....") 
    138150 
    139151    def OnListBox1Listbox(self, event): 
     
    163175             
    164176        self.displayPorts()     
    165          
    166         #self.grid1.CreateGrid(6,6) 
    167         #self.grid1.SetColLabelValue(0,"Property") 
    168         #self.grid1.SetColLabelValue(1,"Value") 
    169         #self.grid1.SetColLabelValue(2,"Value2") 
    170         #self.grid1.SetColLabelValue(3,"....") 
    171         #self.grid1.SetColLabelValue(4,"....") 
    172         #self.grid1.SetColLabelValue(5,"....") 
    173177        event.Skip() 
    174178 
     
    195199     
    196200    def displayPorts(self): 
     201        self.PortBox.Clear() 
    197202        pnames = [] 
    198203        for p in self.active_comp.ports: 
     
    200205        print pnames 
    201206        self.PortBox.InsertItems(pnames,0) 
     207 
     208    def OnButton2Button(self, event): 
     209        event.Skip() 
     210 
     211    def OnRemoveBtnButton(self, event): 
     212        sels = self.PortBox.GetSelections() 
     213        if len(sels) == 0: 
     214            dlg = wx.MessageDialog(self, '("Please select a port to remove!")', 
     215              'Error', wx.OK | wx.ICON_INFORMATION) 
     216            try: 
     217                dlg.ShowModal() 
     218            finally: 
     219                dlg.Destroy() 
     220            return 
     221        for x in sels: 
     222            temp = self.PortBox.GetString(x) 
     223            plist = [y.name for y in self.active_comp.ports] 
     224            ti = plist.index(temp) 
     225            del self.active_comp.ports[ti] 
     226            self.PortBox.Delete(x) 
     227             
     228        self.displayPorts() 
     229        event.Skip() 
  • WaveDev/trunk/WaveDev/gui/ConnectDialog.py

    r581 r582  
    77    return ConnectDialog(parent) 
    88 
    9 [wxID_CONNECTDIALOG, wxID_CONNECTDIALOGCONLABEL, wxID_CONNECTDIALOGCONNECTBTN,  
    10  wxID_CONNECTDIALOGLISTBOX1,  
    11 ] = [wx.NewId() for _init_ctrls in range(4)] 
     9[wxID_CONNECTDIALOG, wxID_CONNECTDIALOGCANCELBTN, wxID_CONNECTDIALOGCONLABEL,  
     10 wxID_CONNECTDIALOGCONNECTBTN, wxID_CONNECTDIALOGLISTBOX1,  
     11] = [wx.NewId() for _init_ctrls in range(5)] 
    1212 
    1313class ConnectDialog(wx.Dialog): 
     
    2525        self.ConnectBtn = wx.Button(id=wxID_CONNECTDIALOGCONNECTBTN, 
    2626              label='Connect', name='ConnectBtn', parent=self, pos=wx.Point(273, 
    27               295), size=wx.Size(85, 30), style=0) 
     27              218), size=wx.Size(85, 30), style=0) 
    2828        self.ConnectBtn.Bind(wx.EVT_BUTTON, self.OnConnectBtnButton, 
    2929              id=wxID_CONNECTDIALOGCONNECTBTN) 
     
    3232              label='None', name='ConLabel', parent=self, pos=wx.Point(29, 21), 
    3333              size=wx.Size(31, 17), style=0) 
     34 
     35        self.CancelBtn = wx.Button(id=wxID_CONNECTDIALOGCANCELBTN, 
     36              label='Cancel', name='CancelBtn', parent=self, pos=wx.Point(273, 
     37              295), size=wx.Size(85, 30), style=0) 
     38        self.CancelBtn.Bind(wx.EVT_BUTTON, self.OnCancelBtnButton, 
     39              id=wxID_CONNECTDIALOGCANCELBTN) 
    3440 
    3541    def __init__(self, parent): 
     
    6167        self.Close() 
    6268        event.Skip() 
     69 
     70    def OnCancelBtnButton(self, event): 
     71        self.Close() 
     72        event.Skip() 
  • WaveDev/trunk/WaveDev/gui/MainFrame.py

    r581 r582  
    115115              name='EditBtn', parent=self, pos=wx.Point(336, 174), 
    116116              size=wx.Size(85, 32), style=0) 
     117        self.EditBtn.Enable(False) 
    117118        self.EditBtn.Bind(wx.EVT_BUTTON, self.OnEditBtnButton, 
    118119              id=wxID_FRAME1EDITBTN) 
     
    137138              name='button5', parent=self, pos=wx.Point(336, 290), 
    138139              size=wx.Size(85, 30), style=0) 
     140        self.button5.Enable(False) 
    139141 
    140142        self.treeBox = wx.TreeCtrl(id=wxID_FRAME1TREEBOX, name='treeBox', 
  • WaveDev/trunk/WaveDev/gui/PortDialog.py

    r528 r582  
    2727              name='choice1', parent=self, pos=wx.Point(192, 88), 
    2828              size=wx.Size(80, 27), style=0) 
     29        self.choice1.Enable(False) 
    2930 
    3031        self.choice2 = wx.Choice(choices=[], id=wxID_PORTDIALOGCHOICE2, 
    3132              name='choice2', parent=self, pos=wx.Point(72, 88), 
    3233              size=wx.Size(112, 27), style=0) 
     34        self.choice2.Enable(False) 
    3335 
    3436        self.OkBtn = wx.Button(id=wxID_PORTDIALOGOKBTN, label='Ok', 
     
    4850    def OnOkBtnButton(self, event): 
    4951        tempLn = self.portNameBox.GetLineText(0) 
     52        if tempLn == '': 
     53            dlg = wx.MessageDialog(self, '("Please enter a name first!")', 
     54              'Error', wx.OK | wx.ICON_INFORMATION) 
     55            try: 
     56                dlg.ShowModal() 
     57            finally: 
     58                dlg.Destroy() 
     59            return 
    5060        tempP = ComponentClass.Port(tempLn) 
    5161        self.active_comp.ports.append(tempP)