コード例 #1
0
        private void bnCleanUp_Click(object sender, EventArgs e)
        {
            // Disable SynchGate1 output: Omit "Gate" parameter
            // (Not available prior to ALP-4)
            AlpImport.DevControlEx_SynchGate(m_DevId, 1, true);

            // Recommendation: always call DevHalt() before DevFree()
            AlpImport.Result result = AlpImport.DevFree(m_DevId);
            txResult.Text = "DevFree " + AlpErrorString(result);
            if (AlpImport.Result.ALP_OK != result)
            {
                return;                                     // error -> exit
            }
            m_DevId = UInt32.MaxValue;
        }
コード例 #2
0
 // Convert error string
 private string AlpErrorString(AlpImport.Result result)
 {
     return(String.Format("{0}", result));
 }
コード例 #3
0
 private void bnHalt_Click(object sender, EventArgs e)
 {
     AlpImport.Result result = AlpImport.ProjHalt(m_DevId);
     txResult.Text = "ProjHalt " + AlpErrorString(result);
 }