#include <N1568DemoMain.h>

Public Member Functions | |
| N1568DemoFrame (wxFrame *frame) | |
| ~N1568DemoFrame () | |
| void | SetStatusBarText (const wxString &msg, STATUS_BAR_PANE pane) |
| void | AddToLogger (const wxString &msg, LOG_MESSAGE_TYPE type=LMT_INTERNAL) |
| N1568_data * | GetBoardData () |
| bool | SetModuleAddress () |
| bool | RefreshChannels () |
| void | DoExport (bool prompt) |
| void | DoDirectCmdSend () |
| void | DoSetMuxOut () |
Static Public Member Functions | |
| static wxString | GetExecutablePath () |
Private Member Functions | |
| virtual void | OnClose (wxCloseEvent &event) |
| virtual void | OnQuit (wxCommandEvent &event) |
| virtual void | OnAbout (wxCommandEvent &event) |
| virtual void | OnFileQuitToolClicked (wxCommandEvent &event) |
| virtual void | OnToolsConnectToolClicked (wxCommandEvent &event) |
| virtual void | OnToolsExportToolClicked (wxCommandEvent &event) |
| virtual void | OnToolsDownloadToolClicked (wxCommandEvent &event) |
| virtual void | OnToolsSettingsToolClicked (wxCommandEvent &event) |
| virtual void | OnHelpAboutToolClicked (wxCommandEvent &event) |
| virtual void | OnMenuToolsConnect (wxCommandEvent &event) |
| virtual void | OnMenuToolsExport (wxCommandEvent &event) |
| virtual void | OnMenuToolsDownload (wxCommandEvent &event) |
| virtual void | OnMenuToolsSettings (wxCommandEvent &event) |
| virtual void | OnCmdTextCtrlEnter (wxCommandEvent &event) |
| virtual void | OnCmdTextCtrl (wxCommandEvent &event) |
| virtual void | OnCmdSendClick (wxCommandEvent &event) |
| virtual void | OnMuxOutChanged (wxSpinEvent &event) |
| virtual void | OnIdle (wxIdleEvent &event) |
| virtual void | OnModuleAddressChanged (wxSpinEvent &event) |
| virtual void | OnSize (wxSizeEvent &event) |
| bool | ConnectToDevice (bool connect) |
| void | SetupSettings () |
| void | LayoutWindow () |
Private Attributes | |
| ApplicationSettings | m_application_settings |
| ChannelPanelImpl * | m_channel_panel_array [MAX_CHANNELS] |
| AllChannelPanelImpl * | m_all_channel_panel |
| bool | m_is_connect |
| N1568_data | m_board_data |
| wxDateTime | m_next_module_address_sent |
| wxDateTime | m_next_mux_out_sent |
Static Private Attributes | |
| static const int | SPIN_CTRL_DELAY_MSEC = 1500 |
Definition at line 28 of file N1568DemoMain.h.
| N1568DemoFrame::N1568DemoFrame | ( | wxFrame * | frame | ) |
Definition at line 55 of file N1568DemoMain.cpp.
References AddToLogger(), ChannelPanelImpl::EnableCommunication(), ID_TOOLS_DOWNLOAD_TOOL, ID_TOOLS_EXPORT_TOOL, LayoutWindow(), LMT_INTERNAL, m_all_channel_panel, m_application_settings, m_channel_panel_array, GUIFrame::m_channel_sizer, GUIFrame::m_channels_scrolledWindow, GUIFrame::m_cmd_send_button, ApplicationSettings::m_default_module_address, ApplicationSettings::m_default_mux_out, m_is_connect, GUIFrame::m_main_toolBar, GUIFrame::m_module_address_spinCtrl, GUIFrame::m_mux_out_spinCtrl, m_next_module_address_sent, m_next_mux_out_sent, MAX_CHANNELS, ApplicationSettings::ReadSettings(), SBP_SW_REVISION, AllChannelPanelImpl::SetChannelId(), ChannelPanelImpl::SetChannelId(), SetStatusBarText(), and SW_REVISION.
| N1568DemoFrame::~N1568DemoFrame | ( | ) |
Definition at line 98 of file N1568DemoMain.cpp.
| void N1568DemoFrame::SetStatusBarText | ( | const wxString & | msg, | |
| STATUS_BAR_PANE | pane | |||
| ) |
Definition at line 288 of file N1568DemoMain.cpp.
References GUIFrame::m_main_statusBar.
Referenced by ConnectToDevice(), N1568DemoFrame(), and SetModuleAddress().
| void N1568DemoFrame::AddToLogger | ( | const wxString & | msg, | |
| LOG_MESSAGE_TYPE | type = LMT_INTERNAL | |||
| ) |
Definition at line 417 of file N1568DemoMain.cpp.
References LMT_COMMUNICATION, LMT_INTERNAL, m_application_settings, ApplicationSettings::m_is_logger_enabled, GUIFrame::m_logger_richText, and NULL.
Referenced by ChannelPanelImpl::AddToLogger(), ConnectToDevice(), DoDirectCmdSend(), DoExport(), DoSetMuxOut(), N1568DemoFrame(), OnMenuToolsDownload(), and SetModuleAddress().
| N1568_data* N1568DemoFrame::GetBoardData | ( | ) | [inline] |
Definition at line 34 of file N1568DemoMain.h.
References m_board_data.
Referenced by ChannelPanelImpl::ChannelPanelImpl().
| bool N1568DemoFrame::SetModuleAddress | ( | ) |
Definition at line 361 of file N1568DemoMain.cpp.
References AddToLogger(), LMT_COMMUNICATION, LMT_INTERNAL, m_board_data, GUIFrame::m_module_address_spinCtrl, N1568_get_last_answer(), N1568_set_module(), SBP_MODULE_ADDRESS, and SetStatusBarText().
Referenced by OnIdle().
| bool N1568DemoFrame::RefreshChannels | ( | ) |
Definition at line 352 of file N1568DemoMain.cpp.
References DoSetMuxOut(), m_channel_panel_array, and MAX_CHANNELS.
Referenced by DoExport(), OnIdle(), OnMenuToolsDownload(), and AllChannelPanelImpl::OnReadClicked().
| wxString N1568DemoFrame::GetExecutablePath | ( | ) | [static] |
Definition at line 100 of file N1568DemoMain.cpp.
References NULL.
Referenced by N1568DemoApp::OnInit().
| void N1568DemoFrame::DoExport | ( | bool | prompt | ) |
Definition at line 186 of file N1568DemoMain.cpp.
References AddToLogger(), LMT_COMMUNICATION, LMT_INTERNAL, m_board_data, m_is_connect, N1568_export(), N1568_get_last_answer(), and RefreshChannels().
Referenced by OnMenuToolsExport(), OnToolsExportToolClicked(), and AllChannelPanelImpl::OnWriteClicked().
| void N1568DemoFrame::DoDirectCmdSend | ( | ) |
Definition at line 465 of file N1568DemoMain.cpp.
References AddToLogger(), ASW_BUFF_SIZE, LMT_COMMUNICATION, LMT_INTERNAL, N1568_data::m_asw_buff_len, m_board_data, GUIFrame::m_cmd_textCtrl, N1568_data::m_common_data, m_is_connect, N1568_get_last_answer(), receive_buffer(), and send_buffer().
Referenced by OnCmdSendClick(), and OnCmdTextCtrlEnter().
| void N1568DemoFrame::DoSetMuxOut | ( | ) |
Definition at line 533 of file N1568DemoMain.cpp.
References AddToLogger(), LMT_COMMUNICATION, m_board_data, m_is_connect, GUIFrame::m_mux_out_spinCtrl, N1568_get_last_answer(), N1568_set_channel(), and NULL.
Referenced by ConnectToDevice(), OnIdle(), ChannelPanelImpl::OnWriteClicked(), ChannelPanelImpl::ReadFromBoard(), and RefreshChannels().
| void N1568DemoFrame::OnClose | ( | wxCloseEvent & | event | ) | [private, virtual] |
| void N1568DemoFrame::OnQuit | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 152 of file N1568DemoMain.cpp.
Referenced by OnFileQuitToolClicked().
| void N1568DemoFrame::OnAbout | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 156 of file N1568DemoMain.cpp.
References AboutDialog::m_sdk_sw_rev_Text, AboutDialog::m_sw_rev_Text, N1568_SW_rev(), and SW_REVISION.
Referenced by OnHelpAboutToolClicked().
| void N1568DemoFrame::OnFileQuitToolClicked | ( | wxCommandEvent & | event | ) | [private, virtual] |
| void N1568DemoFrame::OnToolsConnectToolClicked | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 168 of file N1568DemoMain.cpp.
References OnMenuToolsConnect().
| void N1568DemoFrame::OnToolsExportToolClicked | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 171 of file N1568DemoMain.cpp.
References DoExport().
| void N1568DemoFrame::OnToolsDownloadToolClicked | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 174 of file N1568DemoMain.cpp.
References OnMenuToolsDownload().
| void N1568DemoFrame::OnToolsSettingsToolClicked | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 177 of file N1568DemoMain.cpp.
References OnMenuToolsSettings().
| void N1568DemoFrame::OnHelpAboutToolClicked | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 285 of file N1568DemoMain.cpp.
References OnAbout().
| void N1568DemoFrame::OnMenuToolsConnect | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 180 of file N1568DemoMain.cpp.
References ConnectToDevice(), and m_is_connect.
Referenced by OnToolsConnectToolClicked().
| void N1568DemoFrame::OnMenuToolsExport | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 183 of file N1568DemoMain.cpp.
References DoExport().
| void N1568DemoFrame::OnMenuToolsDownload | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 209 of file N1568DemoMain.cpp.
References AddToLogger(), ASW_BUFF_SIZE, LMT_COMMUNICATION, LMT_INTERNAL, N1568_data::m_asw_buff_len, m_board_data, N1568_data::m_common_data, m_is_connect, N1568_get_last_answer(), receive_buffer(), RefreshChannels(), and send_buffer().
Referenced by OnToolsDownloadToolClicked().
| void N1568DemoFrame::OnMenuToolsSettings | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 281 of file N1568DemoMain.cpp.
References SetupSettings().
Referenced by OnToolsSettingsToolClicked().
| void N1568DemoFrame::OnCmdTextCtrlEnter | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 462 of file N1568DemoMain.cpp.
References DoDirectCmdSend().
| void N1568DemoFrame::OnCmdTextCtrl | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 520 of file N1568DemoMain.cpp.
References GUIFrame::m_cmd_textCtrl.
| void N1568DemoFrame::OnCmdSendClick | ( | wxCommandEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 525 of file N1568DemoMain.cpp.
References DoDirectCmdSend().
| void N1568DemoFrame::OnMuxOutChanged | ( | wxSpinEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 528 of file N1568DemoMain.cpp.
References m_next_mux_out_sent, and SPIN_CTRL_DELAY_MSEC.
| void N1568DemoFrame::OnIdle | ( | wxIdleEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 555 of file N1568DemoMain.cpp.
References DoSetMuxOut(), m_is_connect, m_next_module_address_sent, m_next_mux_out_sent, RefreshChannels(), and SetModuleAddress().
| void N1568DemoFrame::OnModuleAddressChanged | ( | wxSpinEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 551 of file N1568DemoMain.cpp.
References m_next_module_address_sent, and SPIN_CTRL_DELAY_MSEC.
| void N1568DemoFrame::OnSize | ( | wxSizeEvent & | event | ) | [private, virtual] |
Reimplemented from GUIFrame.
Definition at line 575 of file N1568DemoMain.cpp.
References GUIFrame::m_main_toolBar.
| bool N1568DemoFrame::ConnectToDevice | ( | bool | connect | ) | [private] |
Definition at line 293 of file N1568DemoMain.cpp.
References AddToLogger(), DoSetMuxOut(), ChannelPanelImpl::EnableCommunication(), ID_TOOLS_CONNECT_TOOL, ID_TOOLS_DOWNLOAD_TOOL, ID_TOOLS_EXPORT_TOOL, LMT_INTERNAL, m_all_channel_panel, m_application_settings, m_board_data, m_channel_panel_array, GUIFrame::m_cmd_send_button, ApplicationSettings::m_communication_device_id, m_is_connect, GUIFrame::m_main_toolBar, GUIFrame::m_menu_tools_connect, GUIFrame::m_menu_tools_download, GUIFrame::m_menu_tools_export, MAX_CHANNELS, N1568_close(), N1568_open(), SBP_CONNECTION_STATUS, SBP_MODULE_ADDRESS, and SetStatusBarText().
Referenced by OnMenuToolsConnect(), and SetupSettings().
| void N1568DemoFrame::SetupSettings | ( | ) | [private] |
Definition at line 378 of file N1568DemoMain.cpp.
References ConnectToDevice(), LayoutWindow(), m_application_settings, GUIFrame::m_channel_sizer, ApplicationSettings::m_communication_device_id, m_is_connect, and ApplicationSettings::ReadSettings().
Referenced by OnMenuToolsSettings().
| void N1568DemoFrame::LayoutWindow | ( | ) | [private] |
Definition at line 441 of file N1568DemoMain.cpp.
References m_all_channel_panel, m_application_settings, GUIFrame::m_bottom_panel, m_channel_panel_array, GUIFrame::m_channels_scrolledWindow, ApplicationSettings::m_first_visible_channel, ApplicationSettings::m_is_logger_visible, ApplicationSettings::m_last_visible_channel, GUIFrame::m_main_splitter, MAX_CHANNELS, and ChannelPanelImpl::ShowLabels().
Referenced by N1568DemoFrame(), and SetupSettings().
Definition at line 68 of file N1568DemoMain.h.
Referenced by AddToLogger(), ConnectToDevice(), LayoutWindow(), N1568DemoFrame(), and SetupSettings().
ChannelPanelImpl* N1568DemoFrame::m_channel_panel_array[MAX_CHANNELS] [private] |
Definition at line 70 of file N1568DemoMain.h.
Referenced by ConnectToDevice(), LayoutWindow(), N1568DemoFrame(), and RefreshChannels().
Definition at line 71 of file N1568DemoMain.h.
Referenced by ConnectToDevice(), LayoutWindow(), and N1568DemoFrame().
bool N1568DemoFrame::m_is_connect [private] |
Definition at line 72 of file N1568DemoMain.h.
Referenced by ConnectToDevice(), DoDirectCmdSend(), DoExport(), DoSetMuxOut(), N1568DemoFrame(), OnIdle(), OnMenuToolsConnect(), OnMenuToolsDownload(), and SetupSettings().
N1568_data N1568DemoFrame::m_board_data [private] |
Definition at line 73 of file N1568DemoMain.h.
Referenced by ConnectToDevice(), DoDirectCmdSend(), DoExport(), DoSetMuxOut(), GetBoardData(), OnMenuToolsDownload(), and SetModuleAddress().
wxDateTime N1568DemoFrame::m_next_module_address_sent [private] |
Definition at line 74 of file N1568DemoMain.h.
Referenced by N1568DemoFrame(), OnIdle(), and OnModuleAddressChanged().
wxDateTime N1568DemoFrame::m_next_mux_out_sent [private] |
Definition at line 75 of file N1568DemoMain.h.
Referenced by N1568DemoFrame(), OnIdle(), and OnMuxOutChanged().
const int N1568DemoFrame::SPIN_CTRL_DELAY_MSEC = 1500 [static, private] |
Definition at line 76 of file N1568DemoMain.h.
Referenced by OnModuleAddressChanged(), and OnMuxOutChanged().
1.5.6