In part 1 of this limited “How To” series we discussed how
to add startup and shutdown sounds to a version 5 LokSound decoder. In this continuation
we will talk about what to do if the sound file we’re working with does not
have a particular sound we want to use. We’ll be working with the 76467-LSV4.0-Diesel-MLW-12cyl-251B-FT-V1-R1
located here and we will continue with the startup alarm as an example. I emphasize again that this procedure will work with v4 and v5 decoders. It will not work with Select type decoders as you have no access to the sound file.
The prerequisites for this exercise are the same as in part 1
with the following addition; you will need to be a member of the groups.io
forum. It’s free and easy to sign up. Go to groups.io and in the upper right corner of the
page click on Sign Up. Fill in the information and you're in. If you are
working with LokSound decoders, or any other for that matter, and you are not a
member of this forum you are really missing out. The experts are there!
Since there is no alarm bell sound in the project we’re
working with we will have to supply one. The author has created a set of
startup alarm files and located them in the groups.io forum Files section
located here.
There are three files you will need to download to a directory on your local
hard drive, alarmStart16.wav, alarmLoop16.wav and alarmEnd16.wav for v5 decoders and alarmStart8.wav, alarmLoop8.wav and alarmEnd8.wav for v4 decoders. It will not hurt a v4 decoder to use the xxx16.wav files but the author has been told there may be file burning problems. Try what you are comfortable with.
Once you have the alarm files downloaded open your
LokProgrammer software and load the 76467 sound file. Click on the sound pane
and in the sound project overview you should see the following:
Figure 1 Templates, Desktop and project sound
files
Displayed are the installed templates files (hopefully you
have these installed, if not, they are located here),
the Desktop and the individual .wav sound files in the project. In the lower
left Desktop window navigate to the directory where you downloaded the alarm
files from the forum. You should see something like this depending on where you
downloaded the files to:
Figure 2
Downloaded alarm files
Now drag and drop each of the alarm files one at a time from
the left window to the right sound files window. Each time you drop a file
there it will ask you if you want to replace a certain file. Reply NO! After
you have all three files dragged to the sound files window scroll it down to
the bottom and you’ll see this:
Figure
3 Transferred sound files
The files are grayed out because they are not in use in the
project…yet! Now let’s get back to familiar ground. As we did in part 1 let’s
open the prime mover file MLW-12cyl-25iB-FT by double clicking on it and
reducing the drawing size to 50% so we can see what we need to. Now the fun
begins!
With the Mute to MS containers displayed click on container in the upper left. You’ll see
a container element appear in the upper left of the drawing. Drag it somewhat
near the MS container as displayed in
fig 4 and enlarge it a little by dragging boundaries.
Figure 4 A new
Container
Now double click the new container and you’ll see a screen
appear with a green arrow (the container entry point) on the left and a blue
box (the container exit point) on the right. Drag the right side of the box a
little to the right to make room. Also you will be in a new tab
MLW-12cyl-25iB-FT.Container. On the left side of the diagram you’ll see a window
labeled Container. Enter ”Startup Alarm” in the text box and press Enter. The tab will also change. Now
drag and drop the three sound files you transferred earlier from the sound
files window on the right to the container and you’ll have fig 5.
Figure 5 Alarm
states
Next connect each of the sound “states” with transitions. Click on Transition in the upper left. Click and
hold on the entry point. Drag to the alarmStart16, let go of the button and
then click. It’ll take a little practice! Now do the same for the other sound
states until you have what is shown in figure 6 (you will have to click on Transition each time).
Figure 6
Transitions
Now
switch back to the prime mover tab. You’ll see that the container has also
changed to ”Startup Alarm”. Refer to fig 4. The Transition from Mute to MS has to be moved to point from Mute to the Start Alarm container you created. Grab the arrow side of the transition and connect it to the alarm
container and click. Reconnect the tail of the transition to the Mute
container (you may have to do this or it may reconnect itself). You’ll know you
have it properly connected if you move the alarm container around and the
transition follows it. Finally, connect the alarm container with a transition
to the MS container. Click on the Validate button at the top to make sure
there are no mistakes in your layout. You are almost done!
Return to the Startup Alarm tab (you will see fig 6 again).
Using the simulator, test your alarm. Kind of short don’t you think? Let’s make
it longer. Stop and exit the simulator completely (you’ll need to do this
anytime you want to make a change). Click on the alarmLoop16 state. On the left side of the diagram under State Properties you’ll see a section
entitled Loop. Leave the Loop box unchecked
but increase the Min and Max settings to 5. Again, test this change with the
simulator. It’s now an alarm of decent length. Increase/decrease this until you
get what you want. Save your sound file.
You’re done!
Conclusion
You can use any sound files you find and implement them the
same way. The advantage of this method of adding sound is you can test it with
the simulator. Remember, you had to burn the file to the decoder to hear
changes utilizing the method in part 1. There are pros and cons to each method.
Download a copy of the Unofficial
LokProgrammer Manual if you don’t already have one. Instructions for this are
located here. It will explain a lot of what we did in this article and give you a lot more
information on manipulating sound files. Just enjoy experimenting.
In part 3 of this series we will continue using the alarm
bell paradigm and you will see how to create a sound slot file and save it to a
personal template directory. This one is also not that difficult!
If you have an idea for a blog post here, let me know. If I can comment on it, I will or I'll see if someone else can and post it.