[Background on] [Frames on]

Leviticus 2002 - Divine Software

The AHI home page




NOTE: This is not the current site!

This is an archived site, kept for reference and, er, historical interest. The current site is here.


AHI v4 - Hardware independent audio for Amiga

PowerPC status Last update 2002-04-11

The PPC version of AHI is sponsored by

[AHI logo]
Logos designed by Johan Otterström, Örebro Videoreklam. Click on it for a bigger version.

Index

User information
Developer information
Downloadable software
Donations
Recent changes
FAQ


User information

Even if this page is mainly for developers who are using the AHI audio system in their own products, a short introduction of AHI may be appropriate.

[AHI compatible logo] AHI is for sound cards what CyberGraphX is for graphic cards. A common way of talking to sound cards, and even the internal audio chip (Paula), makes it possible for programmers to make their music and audio programs work with all supported sound cards - without even owning one. Furthermore, special features of more advanced sound cards (like DSP and effect chips) will automatically be used by AHI applications. The system is designed to be easy to use, fast, efficient and future safe.

AHI User's Guide is available on-line, if you're interested.

Currently supported sound hardware

Planned support or in works

Reporting bugs

Just telling me that AHI crashes won't help. I need to know what you do to make it crash, if it is repeatable or random, what system you use, what patches you haev running, if it still crashes after a clean boot etc. I will also need Segtracker, Enforcer and Mungwall log files. If you don't have these tools, you can download them right here. Instructions are inside the archive. You'll need a CPU with a working MMU to use it.

Developer information

For a more technical description of AHI, please read the ahidev.readme file or the AHI Developers's Guide. You can also have a quick look at the device and driver functions in the autodocs. Comments are welcome! Write me!

What people has said about AHI version 4

AHI is the first retargetable system that support almost all cards, as well as the native hardware. Now programmers and users no longer need to worry about anything, except the music and sounds.
- Roger Hågensen / Msi Software

The first time I heard about AHI was from the news group. Then I downloaded the user and developer package from Martin's homepage and played with it at home. I was very impressed. The first thing which come into my mind was: "This would be the new audio standard" and look how it's going now :). I started immediately to make a NotePlayer to APlayer with AHI and it took me only a few days before the first version was finished.
If I have some problems or bug reports, I contacted Martin and he is very helpful. Thanks for all your help :)

- Thomas Neumann / The APlayer-Team

AHI is the greatest thing since sliced toast, finally our DraCo is no longer a mute! When people realise what AHI is about it will be as big as CybergraphX. It's time we got rid of the 8-bit audio limit! Great work Martin!
- Johan Otterström / Örebro Videoreklam (DraCo reseller)

AHI is the easiest way for programmers to implement support for various audio cards. No more messing up with hard-to-figure-out outdated or non existing programming documentations. Just use AHI for it and relax.. Best general purpose Sound API for Amiga ever!
- Pauli Porkka / Digital Audio Systems Designs (author of D.A.S. Module Player)

Finally there's a powerful retargetable audio standard for Amiga!
- Thomas Wenzel, A.C.T. (designers of the Prelude soundcard)

Major changes since last release

What has changed since the last release? Here are some things worth to be mentioned.

For details, see Recent changes below.

Mailing list

Traditionally, the Delfina mailing list have been used for AHI support as well. This list has recently moved to Yahoo! Groups

Official logo

By placing the "AHI compatible" logo on your WWW support page or directly on your product, the user will immediately recognize that your product works with all major sound cards on the market. Click on the logo below for a larger version.
[AHI compatible logo]

On a WWW page, you can use the following code to link to this page:

 <a href="http://www.lysator.liu.se/ahi/v4-site/"><img
    src="ahi-compatible.tiny.jpg" border=0 width=121 height=79
    alt="[AHI compatible]"></a>

I need your help!

There are several things that I have in mind for AHI, but I will probably not have enough time to implement them in the near future. Perhaps you can help?


Downloadable software

AHI is available to you as freeware. This means that you does not have to pay anything to use AHI for neither personal nor commercial use, but it is still copyrighted. You may not modify the files or archives in any way. For more information, see AHI User's Guide.

The latest updates:

Here are some extras, too:


Donations

While I have yet to make any money on AHI, I no longer ask for donations. I just do AHI for fun, and earn my living elsewhere.


Recent changes

This web page

1997-10-11
ahi.device version 4.164 is available for download.
1997-10-16
ahi.device version 4.165 is available for download.
1997-11-08
New AHI archives (v4.16) are available.
1997-11-22
New filesave driver (2.9) and a beta paula driver (4.15) available.
1998-01-18
New paula driver (4.17) available for download.
1998-04-02
I'm terrible sorry, I forgot to release the latest paula.audio driver (4.19)! It's from 1998-02-19... Enjoy, it fixes the full-duplex recording problem some might have encountered.
1998-04-02
Oh, by the way.. You didn't miss yesterdays AHI Enterprise Edition announcement, did you? DejaNews has it. [Actually, DejaNews is no more, but Google does have it.]
1998-04-04
Thanks, Amiga-Sweden, for the AAA Award 1997. Pretty cool!
1998-04-16
Alright, enough. The AHI Enterprise Edition announcement was, of course, an April Fools joke. You can stop asking now.
1998-05-02
New E modules available for download.
1998-05-02
Added the FAQ the FAQ section. It includes information about the PowerPC version, AHI version 5 and more.
1998-05-05
Added Speak Freely to the FAQ.
1998-06-28
A new Paula driver version is available.
1998-06-29
...this time with a correct version number. Sorry about that.
1998-12-11
Added a new User's archive, containing the latest driver and documentation. No new version of the actual device has been release, they'll have to wait until the PPC version is finished.
1999-05-12
ahi.device version 4.509, a "trailer" of the PPC version, is available for download. Use with care!
2000-08-13
Updated the link for Melody.
2002-04-12
Removed broken links, obsolete paragraphs and updated the list of supported sound cards. Added a link to the beta directory as well.
2003-07-09
Updated the list of supported sound cards.

AHI

For detailed revision history, see the History file found in the AHI User's and Developer's archives.


R4.14
     Bug fixes.
     The Paula driver can now be told to swap left and right channel.
     Toccata driver updated, should work fine on Draco Motion again.
     Added Melody to the distribution.

R4.16
     Bug fixes in the device code.
     Updated documentation.
     New translation (hrvatski).
     Added driver for Maestro Pro to the distribution.
     Added driver for Concierto to the distribution.


Frequently Asked Questions about AHI

Welcome to the FAQ section. Please, make sure you have searched this page before you ask me directly.

Index

PowerPC
AHI and AmigaOS 4.0
The Paula driver and >28 kHz sample rates
Low volume
Speak Freely

PowerPC

A PowerPC version of AHI (version 5, will be bumped to 6 when stable) has been available since August 2000, the day of the first public release of MorphOS. Although still considered beta, it works just great for a number of people (and not so great for some, but I'm working on it).

Unfortunately, my Cyberstorm/PPC died in late 2001, so until I can get my hands on a Pegasos system, I'm basically coding "in the blind". Don't expect miracles.

There will be no AHI version for neither PowerUp or WarpUp, since both systems lack the required capabilities.

AHI and AmigaOS 4.0

Hyperion is planning to ship AHI with AmigaOS 4.0. Since I have no system capable for running AmigaOS 4, they will handle the porting themselves.

The Paula driver and >28 kHz sample rates

First of all, for general questions regarding the Paula driver read the documentation. That's why I wrote it. The Paula driver documentation can be found in the AHI User's Guide, in the System description/System Files/The Drivers/paula.audio section.

Now, in order to enable higher sample rates than 28 kHz, you need to make sure that the native Amiga video output is a VGA mode. If you're not using a graphic card and only have a PAL/NTSC monitor, you're simply out of luck. If you're using a VGA or multisync monitor, all you have to do is to select one of the VGA modes (not the Super72 mode, it's not a VGA mode!), and then you should be able to select sample frequencies up to 48 kHz.

If you're using a graphic card, things become a little more complicated. Let's take the easiest case first. If you use Picasso 96, all you have to do is to set the environment variable Picasso96/AmigaVideo to 31kHz. Example:

SetEnv Picasso96/AmigaVideo 31kHz
SetEnv EnvArc:Picasso96/AmigaVideo 31kHz

If you're a CyberGraphX user, the matter is a little more complicated. CyberGraphX "remembers" the last used Amiga video mode, which means that if you open a Amiga VGA screen and then close it, you will still be able to select frequencies up to 48 kHz. One way to open and close such a screen is to use the AddAudioModes program, like this:

AddAudioModes DBLSCAN

See the documentation of AddAudioModes for more information (AHI User's Guide, in the System description/AddAudioModes section).

Naturally, you need an Amiga that can output VGA frequencies (read AGA Amiga), and have the appropriate monitor driver in Devs:Monitors.

Low volume

AHI always performs sound mixing in order to be able to play several sounds at the same time. In order to avoid distortion, each time the number of channels are doubled, the volume is halved. But there are ways around this, at least when using programs that offer an audio mode requester. Many of these programs also offer the setting of volume boosting, which will raise the volume but can introduce distortion. To minimize this distortion, the user should select Master volume with clipping from the advanced page in the preference program. This will enable saturated arithmetics when mixing, at the expense of 128 kB large table.

If you have problem with a program that does not offer an audio mode requester but uses one of the four "units" instead, all you can do it lowering the number of channels for the used unit. Often, it is not neccessary to have more than one or two channels enabled.

Speak Freely

My port of Speak Freely seem to be causing trouble for many. Since it's almost a direct Un*x port, it requires ixemul.library. The latest release is available from ftp.ninemoons.com (gzipped tar file!), but some of you might prefer to get it from Aminet as a lha file instead:

 ixemul-000n.lha      util/libs  138K+Ixemul V47.2 library 68000 notrap
 ixemul-000s.lha      util/libs  127K+Ixemul V47.2 library 68000
 ixemul-000t.lha      util/libs  130K+Ixemul V47.2 library 68000 trace-version
 ixemul-020f.lha      util/libs  125K+Ixemul V47.2 library 68020/030 + FPU
 ixemul-020s.lha      util/libs  126K+Ixemul V47.2 library 68020/030 w/o FPU
 ixemul-040f.lha      util/libs  125K+Ixemul V47.2 library 68040 + FPU
 ixemul-040s.lha      util/libs  126K+Ixemul V47.2 library 68040 w/o FPU
 ixemul-bin.lha       util/libs   78K+Ixemul V47.2 binary utilities
 ixemul-doc.lha       util/libs   52K+Ixemul V47.2 documentation
 ixemul-sdk.lha       util/libs  917K+Ixemul V47.2 includes, libs, manpages
 ixemul-tz.lha        util/libs  258K+Ixemul V47.2 timezone-utilities (all CPUs

You just need the library itself to use Speak Freely. Get the approptiate library version and put it in LIBS:. Then, you need a termcap file in your ETC:. You can use mine, if you'd like. If you don't already have an ETC: assign, create one and move the file termcap to that directory. And, as a last step, you need to set the environment variable TERM to Amiga. You can do this by typing:

1> SetEnv TERM Amiga
1> SetEnv ENVARC:TERM Amiga

There you go! That should be enough to start the program. However, you probably have to configure AHI, too. Speak Freely uses Unit 0 as default device. You can change this by setting the environment variables SPEAKFREE_PLAY_UNIT and SPEAKFREE_RECORD_UNIT to the desired unit. There are three possible configurations:

No sound card
If you have no sound card, you have to make sure you're using a full duplex mode, and SPEAKFREE_PLAY_UNIT and SPEAKFREE_RECORD_UNIT must be set to the same value! The default is 0. A good mode here is Paula: Fast 8 bit mono, 8000 Hz, 1 channel. Don't forget to set the input source to the correct sampler type.
Half-duplex sound card
Speak Freely really needs full duplex. You can pretend you have it, by using the sound card to record and Paula to play. For example, set Unit 0 to Paula: Fast 8 bit mono, 8000 Hz, 1 channel, and set Unit 1 to [SoundCard]: Fast 8 bit mono, 8000 Hz, 1 channel. Then ask Speak Freely to play to Unit 0 and record from Unit 1:

1> SetEnv SPEAKFREE_PLAY_UNIT 0
1> SetEnv ENVARC:SPEAKFREE_PLAY_UNIT 0
1> SetEnv SPEAKFREE_RECORD_UNIT 1
1> SetEnv ENVARC:SPEAKFREE_RECORD_UNIT 1
Don't forget to set the input source to the correct desired input (mic, probably).
Full duplex sound card
Just like if you had no sound card, you have to make sure that SPEAKFREE_PLAY_UNIT and SPEAKFREE_RECORD_UNIT is set to the same value. The default is 0. A good mode here is [SoundCard]: Fast 8 bit mono, 8000 Hz, 1 channel. Don't forget to set the input source to the correct desired input (mic, probably).

Oh, don't forget to mount AUDIO: before you start sfmike or sfspeaker.

(This was written from memory, so please let me know you find anything wrong. I don't use Speak Freely myself, I have no mike....)


Powered by Roxen Challenger! Lynx enhanched! This page has been accessed 31621 times since November 2019.
Last update: Stardate 39006.5 (October 2006).

Martin Blom <lcs@lysator.liu.se>