Am I right in thinking that >>>print "\a" should sound the system, 'bell'?
B
--
Computer says, 'no' 9 12245
Try:
import os
os.system('\a')
[Baza wrote] Am I right in thinking that >>>print "\a" should sound the system, 'bell'?
It works on the shell on Windows for me (WinXP).
Trent
--
Trent Mick Tr****@ActiveSt ate.com
Matt wrote: Try: import os os.system('\a')
Ta, that's got it.
B
[Mr6 wrote] Matt wrote:Try: import os os.system('\a' )
Ta, that's got it.
I suspect that you are misinterpreting failure as success here. This is
probably only resulting in a bell from the shell when it complains that
it doesn't know of any command called "\a" to run.
Trent
--
Trent Mick Tr****@ActiveSt ate.com
Trent Mick wrote: I suspect that you are misinterpreting failure as success here. This is probably only resulting in a bell from the shell when it complains that it doesn't know of any command called "\a" to run.
Contrarily, \a is in fact the escape sequence for, as the OP put it,
the system "bell" . I can only speak as a Windows user however; I'm
unaware of the prevalence of this feature across operating systems.
--
Daniel Bickett
dbickett at gmail.com http://heureusement.org/
Trent Mick wrote: [Baza wrote]
Am I right in thinking that >>>print "\a" should sound the system, 'bell'?
It works on the shell on Windows for me (WinXP).
Trent
Interesting. From a Cygwin bash shell I got an elegant little dingish
sort of a beep (my volume control was set kind of low). I then ran the
same code in a Windows shell and nearly deafened myself. It appears that
the volume control doesn't affect the Windows XP commans shell beep -
even muting the Windows audio output doesn't stop it (though it does
stop the Cygwin beep). This could cause heart attacks!
regards
Steve
--
Steve Holden +1 703 861 4237 +1 800 494 3119
Holden Web LLC http://www.holdenweb.com/
Python Web Programming http://pydish.holdenweb.com/
On Fri, 01 Apr 2005 02:06:07 -0500, Steve Holden <st***@holdenwe b.com> wrote: Trent Mick wrote: [Baza wrote]
Am I right in thinking that >>>print "\a" should sound the system, 'bell'?
It works on the shell on Windows for me (WinXP).
Trent Interesting. From a Cygwin bash shell I got an elegant little dingish sort of a beep (my volume control was set kind of low). I then ran the same code in a Windows shell and nearly deafened myself. It appears that the volume control doesn't affect the Windows XP commans shell beep - even muting the Windows audio output doesn't stop it (though it does stop the Cygwin beep). This could cause heart attacks!
Another couple of data points:
Running python 2.3/MSVC6 or python 2.4/MinGW in an NT4 console window,
print '\a' beeps via the PC internal speaker (like winsound.Beep).
Running the bash shell of msys, echo -e '\a' also beeps via the PC speaker.
These are not affected by any volume control that I know of.
But running py2.3 idle, print '\a' displays a square empty box (which I
take to be the symbol for "unprintabl e" characters). That seems like an
oversight in terminal emulation.
Regards,
Bengt Richter
Serves me right for blindlyrunning things from IDLE.
This does work (tested on WinXP only):
import os
os.system('echo \a')
Bengt Richter wrote: On Fri, 01 Apr 2005 02:06:07 -0500, Steve Holden <st***@holdenwe b.com> wrote:
Trent Mick wrote:
[Baza wrote]
Am I right in thinking that >>>print "\a" should sound the system, 'bell'?
It works on the shell on Windows for me (WinXP).
Trent
Interesting . From a Cygwin bash shell I got an elegant little dingish sort of a beep (my volume control was set kind of low). I then ran the same code in a Windows shell and nearly deafened myself. It appears that the volume control doesn't affect the Windows XP commans shell beep - even muting the Windows audio output doesn't stop it (though it does stop the Cygwin beep). This could cause heart attacks!
It's a weird thing. But if I run print "\a" from idle it does not work.
But if I save as a file, say, sound.py. Then run that with python
sound.py it does.
Why is that?
B This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Steve Drake |
last post by:
All,
Sorry if this is the wrong group, but I could not find a good group for this
question, so I chose a busy developer group.
When you receive an alert from SHAREPOINT, the ICON shows a BELL on it, I
want to-do the same when sending an email from .NET.
Sharepoint does use SMTP to send, the same as .NET does (with
system.web.mail), I have tried to add the correct headers :
|
by: Dave Hammond |
last post by:
You'd think this was an occasionally asked question, but a search for
previous related posts only turned up one from 1999, and that one was
never anwered. So...
When handling a keypress event, the terminal bell always rings (at
least with Internet Explorer). While it's not a show-stopper, it can
become annoying. Anyone have any tricks to silence the bell?
Thanks in advance!
|
by: MLH |
last post by:
This question, I apologize, is more of a math question than it is
an Access question - I'm almost certain.
The bell curve is another name for the normal distribution, which is a
common type of graph that has more or less the shape of a bell. "The
Bell Curve" was also the title of a book, a controversial book back in
1994. It was about intelligence. If you graph scores on an IQ test on
the horizontal axis, and number of people who got...
|
by: Blue Bell Trading |
last post by:
Hi,
I need to create a database so I can track my customers more easily. The
list of customers comes from a csv file that I download from Paypal (that
includes address, item id, ebay id etc data). But I want to be able to add
notes to each record.
I have done some vba in college but that was a year ago...
If anybody can give me any links or point me in the right direct I'd be very
|
by: Fred Nelson |
last post by:
Hi:
I have a vb.net web application running on an IIS server that has a
sound card and VERY cheap speakers.
I would like to know if there is a way to cause the speakers to make
noice in the event that an event occurs that I want to be notified of.
I don't care if they beep or play music.
Any suggestions would be GREATLY appreciated!
| |
by: Csaba Gabor |
last post by:
Is there a way in Mozilla/Firefox to ring the bell? For example, in
Emacs or Notepad (on my Win XP Pro system) if you enter certain
shortcuts (e.g. ^g or ^q, respectively), you get a sound to let you
know that from the app's point of view, something unexpected happened.
Can I accomplish something similar in FF with javascript or via the
keyboard?
Thanks,
Csaba Gabor from Vienna
|
by: Josh |
last post by:
I want to get the ASCII Bell character (7) as a string. How? I'm pulliing
my hair out over the stupid little task. HELP!!!!!!!!! ARRRAGGH!
--
#####-----#####-----#####
POV Tips and Hints at ...
http://povman.blogspot.com/
|
by: bluesteel |
last post by:
I was asked to make a program which rang a bell at certain at certain moments. The one way i can think of making it is by using a loop, but i should try to avoid using it and i don't have any idea. I thought of looping, and when the time matched with the specified one, it rang the bell. I do not have it clear how to make it ring. They told me that i had to think of how to develop the program and they would think of how to make the bell ring when...
|
by: fadger07 |
last post by:
Hello,
I have a packard bell laptop and when i turn it on the windows loading screen comes on for about 3mins and then goes to the packard bell screen, then reboots and starts all over again.
i really need help anybody?
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |