Problems with sending ctrl+v over serial to a device that requires the command-

Hello,

I have a Gilderfluke SD25 audio player that receives commands over its serial port to adjust volume. The SD25 serial port is a 3.5mm TRS connector. I have put together a Nano and a 10k potentiometer to use as a volume knob for the player. After building and coding I connected the SD25 and was not able to control the volume when adjusting the pot. I connected the SD25 to my computers USB port with a cable I made and sent it commands from my keyboard / terminal and it worked, I was able to adjust volume. This is positive because at least I know the SD25 is functioning with serial commands from a source I know is functioning correctly. Here’s the part I am unsure of and could you some guidance with, The Gilderfluke accepts ASCII +ʼVʼ character (0x16), followed by a two digit ASCII Hex number of the level you want to use. Valid levels are ʼ00ʼ to ʻFFʼ I belive my problem is that the ctrl+v is not being sent to the SD25 correctly and therefore not reading the HEX values im sending from the pot. The code I have running reads the pot and maps the value than serial.print as HEX, also added averaging since the pot was jittery. I am able to read it as HEX in a terminal when connected to the tx pin on the Nano. I have tried serial.print 0x16 as stated in the Gilderfluke manual but in a serial monitor it shows the number 32 followed by the HEX value for the pot. I have know idea why 32 shows up in the monitor. What is the proper format for control keys in this case? I have tried switching RX TX pins just to be double sure I had the TRS connector wired correctly. Attached is my code for review. Please any advice would be greatly appreciated, I have no idea what I am doing.

This is a Gilderfluke video explaining the SD25 serial command

10k pot on pin A7 of Nano
Nano TX pin to tip of male 3.5 mm trs, connected to female trs serial port of SD25
Nano RX pin to ring of male 3.5 mm trs, connected to female trs serial port of SD25
Nano ground pin to sleeve of male 3.5 mm trs, connected to female trs serial port of SD25
Nano powered by USB to wall

const int numReadings = 20;
int readings[numReadings];
int readIndex = 0;
int total = 0;
int average = 0;               
int inputPin = A7;
void setup()
{
Serial.begin(9600);
for (int thisReading = 0; thisReading < numReadings; thisReading++)
{
readings[thisReading] = 0;
}
}
void loop()
{
total = total - readings[readIndex];
readings[readIndex] = analogRead(inputPin);
total = total + readings[readIndex];
readIndex = readIndex + 1;
if (readIndex >= numReadings)
{
readIndex = 0;
}
average = total / numReadings;
average = map(average, 0, 1023, 0, 255);
Serial.print(0x16);
Serial.print(average, HEX);
delay(15);
}
Serial.print(0x16);

Instead, use:

Serial.write(0x16);

Serial print sends the numbers as digits. What you want is to send a byte with the value 0x16. You need to use Serial.write function.

Serial.write(0x16);