#### Questions on using CV 51.15 System Pitch Shift

Bruce

My questions are in Brackets [ ].  Page 113 of the August 5, 2015 NMRA Quantum Technical Reference Manual, available for pdf download on the web, provides the following:
CV 51.15  System Pitch Shift. This CV shifts the system sound sample rate from the normal samples per second. (Version 9 firmware is 15,625 per second.)  Default Value = 0.  [Is 0 the default for CV 51.15 or for Bit 7?]

Bit 7: sign; Bit 6: D6; Bit 5: D5; Bit 4: D4; Bit 3: D3;  Bit 2: D2; Bit 1: D1; Bit 0: D0 [I assume bit 7 "sign" mean put a 0 for positive and "1" for negative?   What do the D's mean?  I assume we leave 0's in all but bit 7].

- CV 51.15 can have any value from -127 to +127 where positive values will increase the pitch and negative values will decrease the pitch.  A positive value is indicated by a 0 in bit 7 while a "1" indicates a negative value.
- To specify a negative pitch shift, add 128 to the unsigned pitch shift value.  For example, to specify a pitch shift down of 60 samples per second, add 128 to 60 to obtain 188.
- Each unit represents a shift of 4 samples per second.  For example, a value of 10 increases the pitch by 40 samples per second.
- Use CV 51.15 to change the pitch of similar locomotives in a consist so that each locomotive produces a distinct sound.

Example:  Pitch shift the system sample rate down 60 samples per second:
1.  Set CV 49 to 15 to select the system pitch shift register.  [Can you use a similar command to shift just the horn pitch?  Someone mentioned a "slider" in version 9 - not sure where that is and how you get to that.]
2.   Set CV 51 to 188 to specify the pitch shift.  [In this example, they don't explicitly say, put a "1" in bit 7 to indicate a negative or decrease in pitch, but I assume that's what you do?]

Anyone have any enlightenment on this process?  I tried to change CV 15 bit  7 to a "1" in my NCE Pro-cab but it didn't seem to take.

Dave Robinson

Bruce,
The "D"s mean "data". That is, one bit of sign and seven bits of data, typical of byte-size computer numbers.

> [Is 0 the default for CV 51.15 or for Bit 7?]

Default for the whole byte is zero including the sign bit 7.  If only the sign bit defaulted to zero, well what would be the default for the other 7 bits?

> [Can you use a similar command to shift just the horn pitch?

No, there is no pitch shift for individual sounds, only for the overall sound system.

> 2.  Set CV 51 to 188 to specify the pitch shift.  [In this example, they don't explicitly say, put a "1" in bit 7 to indicate a negative or decrease in pitch, but I assume that's what you do?]

As explained in the book's example, a value of 188 equals data(60) + sign(128), 60+128=188.  So 188 implies the sign bit =1 meaning 'decrease'.  You don't have to "explicitly" set sign bit to 1, you've already done that with "188".
"188" is simply the number you see/set on your keypad while programming the CV.  You don't have access to individual bits when programming CVs so you have to figure out the necessary 8-bit value to accomplish what you want; that's the 188.

> I tried to change CV 15 bit  7 to a "1" in my NCE Pro-cab but it didn't seem to take.

You tried to change "CV 15"?  Wrong!
QSI's CV notation is 'CV # <dot> Primary Index value [and if needed, <dot> Secondary Index value]'.
So CV51.15 is nothing to do with CV15; it's CV49(the Primary Index) gets a value of 15, then CV51(the desired CV) gets the pitch shift value you want (in that order, NOT 51 then 49).

Dave in Edmonton,AB

kjlovesya

Bruce,

Dave's answer is correct.   I would like to add a little clarification to the bit 7 issue.

Please bear with me.  I'll try to write this for everyone to understand - even those who have no idea how a computer operates (your decoder is a miniature computer).

Bits and Bytes:   A bit is a simple switch (On or Off).  On is equal to logic 1 and Off is equal to logic 0.

e.g.   Bit 0 = 0 means the bit is turned Off.   Bit 0 = 1 means the bit is turned On.

If one arranges 8 Bits together that equals one Byte.    Engineers always start counting from number 0 so the first bit is labelled Bit 0.

In a Byte we write Bit 0 at the extreme right and call it the least significant bit.

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (0 - 7 remember we start counting at 0)

The value of each bit is either logic 1 or logic 0.   Binary means counting by twos.   Each bit's weight is twice the weight of the bit to it's right.
The weight of Bit 0 is 1.  The weight of Bit 1 is double the weight of the preceding bit, therefore the weight of Bit 1 is 2.   The weight of Bit 2 is double that of the preceding Bit.  The weight of Bit 2 is 4. etc.

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
weight     128     64        32       16        8         4          2          1

Add up all the weights and you get 255.   The value of the Byte is the sum of the Bit weights.   That's why many of the C.V. values are between 0 - 255.      Many C.V.s are  basically the value of one Byte.

If a value of the CV 3 = 0  then all the bits will be written as logic 0.

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
value          0        0         0         0         0         0          0         0

If the value of the C.V. 3 = 2   then Bit 1 will be written as a logic 1

weight     128     64        32       16        8         4          2          1

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
value          0        0         0         0         0         0          1         0

If the value of CV 3 = 17  then Bit 0 is logic 1 and Bit 4 is logic 1.

weight     128     64        32       16        8         4          2          1

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
value          0        0         0         1         0         0          0         1

Add the weights of the bits with a value of logic 1 to determine the value of the Byte.

Negative numbers:
If required, some C.V.s need a positive or a negative value.  Picture a balance control on a stereo where the center is 0.   Left speaker is less than 0 (negative) and Right speaker is greater than 0.
In order for engineers to get negative numbers they simply use the most significant (left most) Bit as a negative sign.   In our example if Bit 7 is 0, the sum of the bits the the right are positive.     If Bit 7 is 1, the sum of the bits to the right are negative.

A value of zero is zero so the sign (negative or positive) doesn't matter.  Therefore 0 is the same as 128.

However, numbers between 128 up to and including 255 have logic 1 for Bit 7.   Therefore each number above 128 is a negative value.

Since Bit 7 is logic 1,  In order to determine the negative value of this type of C.V. we simply add the weight of the less significant bits (bits 0 - 6).

weight     128     64        32       16        8         4          2          1

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
value         1       0         0         0         0         0          0         0           = indicates negative number in this case

If we write the weight of 129 to our CV:

weight     128     64        32       16        8         4          2          1

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
value          1       0         0         0         0         0          0         1

Then our CV has a value of - 1.

If our CV has a weight of 138

weight     128     64        32       16        8         4          2          1

e.g.         Bit 7    Bit 6    Bit 5    Bit 4    Bit 3    Bit 2    Bit 1    Bit 0      = 8 Bits (remember we start counting at 0)
value          1       0         0         0         1         0          1        0

Our CV now has a value of - 10. (the sum of Bits 0 - 6)

I hope this helps.

Best regards,
KJ

Bruce

Thank you Dave and kjlovesya (is it Steve?)  I think this is starting to make sense.  Am I correct to say the extent to which the pitch is decreased or increased is a function of whether the value you set CV 51, when added to the sum of weights of the lesser bits, is >= 128, or is <128.  Am I saying that right, in layman's terms?

kjlovesya

Whew!   Yes, I think you have it.   :-)

Best regards,
KJ

P.S. The K is for Ken not Steve.

Dave Robinson

Yeah, more or less.  Since one bit in the byte is taken by the sign, then the largest number the rest of the bits can hold is 127 (yeah that's close to 128), so the most pitch shifting you can get is + or - 127.

Dave in Edmonton, AB

peteski7

Unfortunately this example shows that the manual is written for people familiar with low-level computer "speak". Things like bits, bytes, and signed and unsigned binary numbers.  Then all the indexed CVs do not make things easier to understand things either.  While many of the QSI users are computer-literate, and we take understanding all that for granted, there are QSI users out there who do not have this "computer speak" mastered.

Looking at this thread, it makes it painfully clear to me how someone like that would see the QSI manual as bunch of gibberish.  But QSI is not the only company with this problem. Other companies' manuals also often require a computer science degree to understand.

Peteski

Greg Elmassian

DCC is an old standard, when memory was expensive, so things are in binary instead of ASCII characters.

The indexing system to get more "variables" is again an old limitation.

Nowadays this could all be done in normal characters.

Of course the solution is to use a high level graphic interface program like CVManager. Many of the decoder manufacturers who have complex functions have a nice computer program to set things for the non computer science people.

I'm surprised no one suggested CVManager here.

Greg

Nick

Greg,

I've been involved with DCC since we had to use HEXADECIMAL on throttles that used "knob-fiddling" to program a 2-digit decoder address. The company I chose for my DCC system actually made an interface for a serial port for programming their decoders but never produced any computer software (and still don't) to use it with. When QSI came out with their programmer, I was asked to be a BETA tester for both the new Version 7 chip and the programmer and software. I was already using the very early version of DecoderPro at the time and one of our group members created a buffered computer interface kit to interface with our command stations. Keep in mind, Windows 95 was the software we used or DOS / COBOL / or other "dead" languages. (Yep, I'm OLD) . CV manager and Q1 Upgrade were like magic. We were able to completely remake our OEM decoders into literally anything. I once had a FM Trainmaster with an SP Cab-Forward sound file in it that I used at club open houses. It got a LOT of grins. We are blessed with software from both QSI, although a bit dated and proprietary usable only with their programmer, and FREE JMRI DecoderPro software that works with almost every DCC hardware and OS out there. I use both when programming decoders. Sound decoders , with all of their complex indexing CVs make using software almost mandatory. As one that still has his Hex conversion tables by his programming station, I am truly grateful that we no longer have to figure out which "bit" goes where. New users should be required to go "back to the future" I started in to be thankful they no longer need to be "techies" to use their equipment.

Pete Hendel

Greg,
The name CVManager sounds familiar.  Who developed it and where can one get more info on the capabilities and features.
Thanks.

Pete

Kevin Strong

CV Manager is QSI's software interface for their decoders. You used to be able to download it from their website. It may be in the files section of this list now. You'll also need the programming interface (little black box) to go with it, though it may (don't quote me) work through something like plugging your PC into the NCE system if you have one. I don't remember if that worked or not. I have the little black box.

That's the good news. The bad news is that the software kinda works with Windows 10, it kinda doesn't. More to the point, the driver for the little black box may or may not work with windows 10. Folks here have had varying degrees of success. I'm among the "not successful" camp. I've got an old XP laptop which I use with this, so there's always that approach.

I will say that if you have QSI decoders and you want to make changes to them, CV Manager is THE way to do it. It is by far simpler than making changes to individual CVs, etc., and more importantly, you can use it to reprogram the sounds to suit your needs.

Later,

K

On 12/12/2020 3:04 PM Pete Hendel <pete@...> wrote:

Greg,
The name CVManager sounds familiar.  Who developed it and where can one get more info on the capabilities and features.
Thanks.

Pete

kjlovesya

You make a good point.  However, it is a challenge to make user friendly a sophisticated device, such as a QSI Titan sound decoder.  The complication is of necessity.   I think QSI has done a very good job in conveying the information.   Before reading the QSI manual I knew nothing about specific CV manipulation.    Not everyone learns at the same speed and this forum is all about addressing specific questions.  The original post was asking specific questions, clarifying issues that some users have no desire to learn.

Fortunately, we are able to manage C.V.s relatively easy using CV Manager or JMRI Decoder Pro.

JMRI Decoder Pro will work on current QSI Titan version 9 firmware.   When opening a new file, you merely select either the Titan Steam or Titan diesel (unless it's an early EMD hood unit you don't get to select the correct model) but all of the correct relative C.V.s become available.   JMRI will simply incorrectly label the locomotive type in it's file.  Not a big deal!

QSI's free download, CV Manager, may be run using either the QSI programmer (black box).  Alternately, CV Manager can be run through an NCE command station connected to the computer or Powercab with USB interface connected to the computer.

Best regards,
KJ

Greg Elmassian

The driver for the programmer works fine on windows 10, you just need to follow the instructions. I have instructions on my site.

The program itself CVManager and CVUpdate work perfectly on all versions of Windows.

There are some poor driver installation instructions out there, and windows 10 can be a pain to convince it to allow the driver, but the driver is a one time install.

And take note of KJ's comment that the NCE command station can run CVManager (but you need the QSI programmer to load sound files)

Greg

 1 - 13 of 13