예제 #1
0
        /// <summary>
        /// 车速温度显示
        /// </summary>
        public void LedSWShow()
        {
            LedShow show  = new LedShow();
            string  text1 = "当前车速:" + v.ToString() + " km/h   外温:" + OutstrWen + " ℃";
            string  text2 = "Current speed: " + v.ToString() + " km/h   Outside temperature: " + OutstrWen + " ℃";

            show.ShowLEDMessage(text1 + "     " + text2 + "                ", this.textBox1.Text, this.textBox17.Text);
            Thread.Sleep(20000);//暂停20秒
            show.ShowLEDMessage(" ", this.textBox1.Text, this.textBox17.Text);
        }
예제 #2
0
        /// <summary>
        /// 终点站语音播报
        /// </summary>

        public void speechDaoZDZ()
        {
            LedShow            led    = new LedShow();
            Speech             sp     = new Speech();
            SpeechOperat       spo    = new SpeechOperat();
            string             text1  = null;
            string             text2  = null;
            string             ent1   = "intp65";
            string             vcn1   = "xiaoyan";
            string             ent2   = "intp65";
            string             vcn2   = "henry";
            List <SpeechModel> listYu = new List <SpeechModel>();

            listYu = spo.SelectSp("终点站提示语");
            for (int i = 0; i < listYu.Count; i++)
            {
                text1 = listYu[i].speechContent;
                text2 = listYu[i].speechEnContent;
            }
            text1 = "惠而浦冰箱洗衣机提醒您,列车已经安全抵达我们的终点站 " + textBox14.Text + "," + text1;
            text2 = "Whirlpool refrigerator washing machine remind you,The train has arrived safely at our terminal " + this.dataGridView1.Rows[m].Cells[1].Value.ToString() + " station," + text2;
            led.ShowLEDMessage(text1 + "  " + text2 + "                     ", this.textBox1.Text, this.textBox17.Text);
            sp.SpeechTest(text1, ent1, vcn1);
            Thread.Sleep(2000);  // 停顿2秒
            sp.SpeechTest(text2, ent2, vcn2);
            Thread.Sleep(35000); // 停顿35秒
            led.ShowLedFLStation(this.textBox2.Text + "——" + this.textBox3.Text, this.textBox1.Text, this.textBox17.Text);
        }
예제 #3
0
        /// <summary>
        /// 预到站语音播报
        /// </summary>

        public void speechYu()
        {
            LedShow            led    = new LedShow();
            Speech             sp     = new Speech();
            SpeechOperat       spo    = new SpeechOperat();
            string             text1  = null;
            string             text2  = null;
            string             ent1   = "intp65";
            string             vcn1   = "xiaoyan";
            string             ent2   = "intp65";
            string             vcn2   = "henry";
            List <SpeechModel> listYu = new List <SpeechModel>();

            listYu = spo.SelectSp("预到站提示语");
            for (int i = 0; i < listYu.Count; i++)
            {
                text1 = listYu[i].speechContent;
                text2 = listYu[i].speechEnContent;
            }
            text1 = "惠而浦冰箱洗衣机提醒您,列车即将到达 " + textBox14.Text + "," + text1;
            text2 = "Whirlpool refrigerator washing machine remind you,The train is about to arrive " + this.dataGridView1.Rows[m].Cells[1].Value.ToString() + " Station," + text2;
            led.ShowLEDMessage(text1 + "  " + text2 + "                     ", this.textBox1.Text, this.textBox17.Text);
            sp.SpeechTest(text1, ent1, vcn1);
            Thread.Sleep(4000);  // 停顿4秒
            sp.SpeechTest(text2, ent2, vcn2);
            Thread.Sleep(48000); // 停顿48秒
            led.ShowLedFLStation(" ", this.textBox1.Text, this.textBox17.Text);
        }
예제 #4
0
        /// <summary>
        /// 爱护设施提示语显示
        /// </summary>
        public void LedEqumShow()
        {
            LedShow            show     = new LedShow();
            SpeechOperat       spo      = new SpeechOperat();
            List <SpeechModel> ListEnvi = new List <SpeechModel>();
            List <SpeechModel> ListEqum = new List <SpeechModel>();
            string             text     = null;

            ListEqum = spo.SelectSp("爱护设施提示语");
            for (int i = 0; i < ListEqum.Count; i++)
            {
                text = ListEqum[i].speechContent;
                text = text + "     " + ListEqum[i].speechEnContent;
            }
            show.ShowLEDMessage(text + "                   ", this.textBox1.Text, this.textBox17.Text);
            Thread.Sleep(35000);//暂停35秒
            show.ShowLEDMessage(" ", this.textBox1.Text, this.textBox17.Text);
        }
예제 #5
0
        /// <summary>
        /// 发车语音播报
        /// </summary>

        public void SpeechFa()
        {
            LedShow led   = new LedShow();
            string  text1 = null;
            string  text2 = null;

            string[]           str1, str2;
            string             ent1      = "intp65";
            string             vcn1      = "xiaoyan";
            string             ent2      = "intp65";
            string             vcn2      = "henry";
            SelectStation      sel       = new SelectStation();
            SpeechOperat       spo       = new SpeechOperat();
            List <Common>      listCom   = new List <Common>();
            List <SpeechModel> listSpFa  = new List <SpeechModel>();
            List <SpeechModel> listSpJin = new List <SpeechModel>();
            Speech             sp        = new Speech();

            str1    = sel.SelectFirstStation().Split(',');
            str2    = sel.SelectLastStation().Split(',');
            listCom = sel.SelectComboBoxStation();
            text1   = ",惠而浦冰箱洗衣机提醒您,列车已经由 " + this.dataGridView1.Rows[m - 1].Cells[0].Value.ToString() + " 开出,前方到站 " +
                      this.dataGridView1.Rows[m].Cells[0].Value.ToString();
            text2 = "Whirlpool refrigerator and washing machine remind you,The train has been started from " + this.dataGridView1.Rows[m - 1].Cells[1].Value.ToString() + " Station " +
                    "and next station is " + this.dataGridView1.Rows[m].Cells[1].Value.ToString() + " Station";
            text1 = text1 + ",本次列车为 " + this.textBox1.Text + " 次列车,由 " + this.textBox2.Text + " 发往 " + this.textBox3.Text + ",途径";
            text2 = text2 + ",This train is " + this.textBox1.Text + " train,and is sent from " + str1[1] + " Station to " + str2[1] + " Station,channel ";
            for (int i = 1; i < listCom.Count - 1; i++)
            {
                text1 = text1 + listCom[i].StationName + "、";
                text2 = text2 + listCom[i].StationEnName + " Station,";
            }
            listSpFa  = spo.SelectSp("欢迎提示语");
            listSpJin = spo.SelectSp("禁烟提示语");
            for (int i = 0; i < listSpFa.Count; i++)
            {
                text1 = listSpFa[i].speechContent + text1;
                text2 = listSpFa[i].speechEnContent + text2;
            }
            for (int i = 0; i < listSpJin.Count; i++)
            {
                text1 = text1 + listSpJin[i].speechContent;
                text2 = text2 + listSpJin[i].speechEnContent;
            }
            led.ShowLEDMessage(text1 + "  " + text2 + "                     ", this.textBox1.Text, this.textBox17.Text);
            sp.SpeechTest(text1, ent1, vcn1);
            sp.SpeechTest(text2, ent2, vcn2);
            int RowNum = this.dataGridView1.Rows.Count;

            Thread.Sleep(102000 + (RowNum - 13) * 2 * 1000);  // 停顿秒数
            LedSWShow();
        }
예제 #6
0
        /// <summary>
        /// 途径站下一站为终点站的发车语音播报
        /// </summary>

        public void speechTuZDZ()
        {
            LedShow led   = new LedShow();
            Speech  sp    = new Speech();
            string  text1 = null;
            string  text2 = null;
            string  ent1  = "intp65";
            string  vcn1  = "xiaoyan";
            string  ent2  = "intp65";
            string  vcn2  = "henry";

            text1 = "惠而浦冰箱洗衣机提醒您,列车已经由 " + this.dataGridView1.Rows[m - 1].Cells[0].Value.ToString() + " 开出,前方到站是我们的终点站 " +
                    this.dataGridView1.Rows[m].Cells[0].Value.ToString();
            text2 = "Whirlpool refrigerator washing machine remind you,The train has been started from " + this.dataGridView1.Rows[m - 1].Cells[1].Value.ToString() + " Station," +
                    "The nest station is our terminus station " + this.dataGridView1.Rows[m].Cells[1].Value.ToString() + " Station.";
            led.ShowLEDMessage(text1 + "。 " + text2 + "                     ", this.textBox1.Text, this.textBox17.Text);
            sp.SpeechTest(text1, ent1, vcn1);
            Thread.Sleep(2000);  // 停顿2秒
            sp.SpeechTest(text2, ent2, vcn2);
            Thread.Sleep(27000); // 停顿27秒
            led.ShowLEDMessage(" ", this.textBox1.Text, this.textBox17.Text);
        }