China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-07-02 14:57
中国DOS联盟论坛 » DOS疑难解答 & 问题讨论 (解答室) » Making sounds with DOS commands View 1,722 Replies 10
Original Poster Posted 2008-05-30 13:13 ·  中国 广东 阳江 阳春市 电信
初级用户
Credits 72
Posts 27
Joined 2007-04-02 08:27
19-year member
UID 83702
Gender Male
Status Offline
I have a server that is scheduled to power on and off every day. I want the buzzer to beep a few times when it powers on or off. I wonder if there is a command in DOS for this and how to use it.
Floor 2 Posted 2008-05-31 03:49 ·  加拿大 Primus
系统支持
★★★★★★
“新DOS时代”站长
Credits 27,736
Posts 10,521
Joined 2002-10-09 12:00
23-year member
UID 9
Status Offline
Wengier - 新DOS时代

欢迎大家来到我的“新DOS时代”网站,里面有各类DOS软件和资料,地址:
http://wendos.mycool.net/

E-Mail & MSN: wengierwu AT hotmail.com (最近比较忙,有事请联系DOSroot和雨露,谢谢!)

Floor 3 Posted 2008-05-31 23:40 ·  中国 广东 阳江 电信
初级用户
Credits 72
Posts 27
Joined 2007-04-02 08:27
19-year member
UID 83702
Gender Male
Status Offline
Originally posted by Wengier at 2008-5-31 03:49 AM:
ECHO ^G

Reply to the second floor, enter CMD, open the command window, copy ECHO ^G in, but there is no sound; after careful testing, type ECHO, then space, then press the ctrl+g key, press enter, finally there is sound!
But what to do in the bat? I tried and it didn't work, so I ask for advice!
Floor 4 Posted 2008-06-01 10:14 ·  法国
高级用户
★★
Credits 783
Posts 268
Joined 2006-12-26 17:18
19-year member
UID 74627
Gender Male
Status Offline
```
for /l %%i in (1 1 5) do more +1 %~s0|debug
e100 B2 07 B4 02 CD 21 CD 20
g
q
```
菩提本无树,明镜亦非台,本来无一物,何处惹尘埃.
Floor 5 Posted 2008-06-02 08:57 ·  中国 山东 电信
初级用户
Credits 28
Posts 9
Joined 2008-03-08 16:38
18-year member
UID 112397
Gender Male
Status Offline
Type "edit" in the command prompt window and press Enter, then enter the edit editing window. First, press Ctrl + P, then you can input Alt + 07 or Ctrl + G. Then, save as a.txt document in "file". After that, you can copy the generated symbol into the batch command code for use.
Floor 6 Posted 2008-06-03 22:58 ·  中国 广东 阳江 电信
初级用户
Credits 72
Posts 27
Joined 2007-04-02 08:27
19-year member
UID 83702
Gender Male
Status Offline
What the 5th floor said is quite right. The so-called ctrl+G doesn't work in Notepad; it turns out it has to be used in Edit.

In cmd, it can also be done like this:
echo echo ^g>s.bat
Enter ^g in cmd using ctrl+g.
Double-click s.bat to hear two beeps.
Floor 7 Posted 2008-06-03 23:05 ·  中国 广东 阳江 电信
初级用户
Credits 72
Posts 27
Joined 2007-04-02 08:27
19-year member
UID 83702
Gender Male
Status Offline
There is still a problem that hasn't been solved. When booting up, automatically run a.bat. One of the statements in a.bat is:
at 22:30 shutdown -s ---Shut down at 22:30
I want to make the buzzer sound when shutting down (at 22:30). How to do it?
Floor 8 Posted 2008-06-07 20:44 ·  中国 山东 聊城 电信
系统支持
★★★
Credits 1,010
Posts 434
Joined 2007-02-08 00:00
19-year member
UID 78999
Gender Male
Status Offline
007 cannot be entered within the w32 program
Floor 9 Posted 2008-06-19 01:49 ·  中国 山东 青岛 阿里云
版主
★★★
操作系统爱好者
Credits 1,113
Posts 392
Joined 2002-11-11 00:00
23-year member
UID 228
Gender Male
Status Offline
Copy the beep file from http://upload.cn-dos.net/img/523.rar to the c:\ or a specified directory, and run in CMD:
at 22:30 cmd /c type c:\beep
DOS之家 http://doshome.com 站长 葛明阳
Floor 10 Posted 2008-07-22 19:19 ·  中国 四川 成都 电信
高级用户
★★★
据说是李先生
Credits 609
Posts 400
Joined 2008-04-23 15:55
18-year member
UID 116706
Gender Male
Status Offline
You can use vbscript:

set ching=wscript.createobject("wscript.shell")
ching.run "cmd /c echo "&chr(7),0
Floor 11 Posted 2008-07-23 21:38 ·  中国 山东 聊城 电信
系统支持
★★★
Credits 1,010
Posts 434
Joined 2007-02-08 00:00
19-year member
UID 78999
Gender Male
Status Offline
Originally posted by qinchun36 at 2008-7-22 07:19 PM:
You can use vbscript:

set ching=wscript.createobject("wscript.shell")
ching.run "cmd /c echo "&chr(7),0

It's all similar
Forum Jump: