AVReceiver
Home
Up
Analyze602
AVReceiver
FreeSpace
Home Automation
Irrigation Control 1
ISP Performance
PantryTech/Pod
QuizManager
RandomPix
SlideShow
Web Extraction
Web Path Analyzer
Web Tool
WxPatch
After getting my hands on a new Yamaha AVR model RX-V2400, I thought it was time to plug into the serial port. Those that know me will not be surprised to learn that the speaker wires are still strung across the floor. But they'll be hidden in a day or so. After a web search to see if somebody else wrote this program, and coming up empty handed, I wrote this as a quick experiment. This command line program connects to this receiver, and possibly other models, and provides some rudimentary monitor and control. It also acts as a YAC listener, so can route Caller ID information to the monitor connected to the AVR. 

Here's the process:

  1. Caller ID information is extracted from a home PC with a caller ID modem,
  2. A desktop program (YAC) on that PC serves it to designated network nodes,
  3. Another PC on the network acts as the YAC listener, parses the information, and
  4. Passes it to the Yamaha RX-V2400 via the RS-232 port where
  5. The RX-V2400 overlays the information on-screen.

I have the concept for an embedded appliance counter-part to this program. Take a look in my Hardware forum for AVR Caller ID. [You must of course have Caller ID service for this to work.]

Download avrcvr.zip and give it a go, and after you tried it, be sure to send me feedback, and since this seems to be a unique creation (so far), please consider using the PayPal link at the bottom of this page. 

The interface is primitive, but I justify this as the experiment. I also coded a lot of commands and responses, but not 100% of them. Perhaps in the next revision I'll add more. I hope to reuse some of the code, and the knowledge at the very least, in an embedded interface to this receiver. Time will tell. If I had a PC stationed near the AVR, then I'd convert this to a "service" so it could run regardless of the active login. In the mean time, if your PC is near your AVR and you choose to use it this way, you can put a shortcut to this program in your startup folder with the command line option -YAC to activate the listener feature.

As with most of my command line programs, I put [hopefully] more than enough built-in documentation into the code. You can access some of this by appending "-?" to the command line. Then, you should see this:

C:\>avrcvr -?

AVRcvr [Options]                                 v0.3   by D.Smart

    This program connects to a Yamaha AVR model RX-V2400, and possibly
        other models, and provides some rudimentary control.
    It also acts as a YAC listener, and can route Caller ID information
        to the AVR on screen display.

    Options:
       -Com #            Set to read Com port # [defaults to 1]
       -YAC              Activate YAC listener mode for OSD
       -NoHeader         Suppress this startup banner
       -Verbose          Makes the program more chatty
       -Instructions     Show more instructional detail
       -History          Shows the program version history and more
                         operational details.

    Return codes:
       0       Normal program termination
       1       Command line error, or History, Errata requested
       2       Failed to open com port
       3       Failed to get heap for YAC

    Pinouts  Direction   Signal [Just some handy info]
       3  2    -->>      Transmit Data
       2  3    <<--      Receive Data
       7  4    -->>      RTS  - Request To Send
       8  5    <<--      CTS  - Clear To Send
       6  6    <<--      DSR  - Data Set Ready
       4 20    -->>      DTR  - Data Terminal Ready
       1  8    <<--      DCD  - Data Carrier Detect
       9 22    <<--      RING - Ring Indicator
       5  7    ----      GND  - Signal Ground

More Info:

    For more information on this or other home automation concepts,
        http://www.smart-family.net or mailto:info@Smart-Family.net

    YAC:          http://www.sunflowerhead.com/software/yac
    Win32 Serial: http://home.ict.nl/~ramklein/Projects/Serial.html

There are two web resources I used. You may want to look them up yourself.

  • YAC is the caller ID utility I leveraged into this project. You can learn more about this utility at their web site.
  • Win32 Serial port control is pretty new to me. So, after a browse I found sample code. You can learn more about that at their site.

Running the Program

The best way to run this program is to open a console shell (DOS box) that you've set to perhaps 50 or 60 lines rather than the default 25. Then, when you run the program you may see this:

C:\Projects\AVRcvr\Release>avrcvr

Yamaha AVR Interface Menu (?):
  Command    Description                Command    Description
  +          Zone 1 Volume Up           -          Zone 1 Volume Down
  2+         Zone 2 Volume Up           2-         Zone 2 Volume Down
  3+         Zone 3 Volume Up           3-         Zone 3 Volume Down
  FM         Tuner FM                   AM         Tuner AM
  <          Tune Down                  >          Tune Up
  Tuner A    Tuner Page A               Tuner B    Tuner Page B
  Tuner C    Tuner Page C               Tuner D    Tuner Page D
  Tuner E    Tuner Page E               Tuner 1    Tuner Preset 1
  Tuner 2    Tuner Preset 2             Tuner 3    Tuner Preset 3
  Tuner 4    Tuner Preset 4             Tuner 5    Tuner Preset 5
  Tuner 6    Tuner Preset 6             Tuner 7    Tuner Preset 7
  Tuner 8    Tuner Preset 8             Gray 1     Gray back auto
  Gray 0     Gray back off              Hello      Hello
  info       Info Request               Inp Phono  Zone 1 Input Phono
  Inp CD     Zone 1 Input CD            Inp Tuner  Zone 1 Input Tuner
  Inp CDRom  Zone 1 Input CD Rom        Inp Tape   Zone 1 Input Tape
  Inp DVD    Zone 1 Input DVD           Inp TV     Zone 1 Input Dig TV
  Inp Cable  Zone 1 Input Cable/Sat     Inp Sat    Zone 1 Input Sat
  Inp VCR 1  Zone 1 Input VCR 1         Inp VCR 2  Zone 1 Input VCR 2
  Inp VCR 3  Zone 1 Input VCR 3         Inp Aux    Zone 1 Input Aux
  Inp2 Phono Zone 2 Input Phono         Inp2 CD    Zone 2 Input CD
  Inp2 Tuner Zone 2 Input Tuner         Inp2 CDRom Zone 2 Input CD Rom
  Inp2 Tape  Zone 2 Input Tape          Inp2 DVD   Zone 2 Input DVD
  Inp2 TV    Zone 2 Input Dig TV        Inp2 Cable Zone 2 Input Cable/Sat
  Inp2 Sat   Zone 2 Input Sat           Inp2 VCR 1 Zone 2 Input VCR 1
  Inp2 VCR 2 Zone 2 Input VCR 2         Inp2 VCR 3 Zone 2 Input VCR 3
  Inp2 Aux   Zone 2 Input Aux           Inp3 Phono Zone 3 Input Phono
  Inp3 CD    Zone 3 Input CD            Inp3 Tuner Zone 3 Input Tuner
  Inp3 CDRom Zone 3 Input CD Rom        Inp3 Tape  Zone 3 Input Tape
  Inp3 DVD   Zone 3 Input DVD           Inp3 TV    Zone 3 Input Dig TV
  Inp3 Cable Zone 3 Input Cable/Sat     Inp3 Sat   Zone 3 Input Sat
  Inp3 VCR 1 Zone 3 Input VCR 1         Inp3 VCR 2 Zone 3 Input VCR 2
  Inp3 VCR 3 Zone 3 Input VCR 3         Inp3 Aux   Zone 3 Input Aux
  OSD        On Screen Display          Mute 1     Mute On
  Mute 0     Mute Off                   Nite 1     Night Mode On
  Nite 0     Night Mode Off             Report 1   Report Cmd on
  Report 0   Report Cmd off             Power 1    Power on
  Power 0    Power off                  Zone1 1    Zone 1 On
  Zone1 0    Zone 1 off                 Zone2 1    Zone 2 On
  Zone2 0    Zone 2 off                 Zone3 1    Zone 3 On
  Zone3 0    Zone 3 off                 ShowUse    Show Usage
  ShowInst   Show Instructions          ShowHist   Show History
  ShowMenu   Show Menu +                SetEcho 1  Command Echo On
  SetEcho 0  Command Echo Off           quit       quit program
>

At this stage, you're operational. 

The Command Line

The case sensitive command line interface is probably unlike any other, including others I've made. If the command you wish to run is absolutely unique in the list (by first character match), then it will run it with a single keystroke. If the command requires two or more characters to be recognized, then when you have typed enough to be uniquely identified, it will fill it in for you. But, because it was not unique, you now have to press <Enter>.

What Can You Do

What you can do depends on the state of the AVR. If it is off, you can't do much but to turn it on. A quick test is with the "OSD" command, which sends a message to the connected monitor. I made bold what I typed. This AVR can only show up to 16 chars at a time. So, if you type a longer message, it will send each group of 16 chars, with about a 5 second delay between them.

>O

                                    1234567890123456                     
Enter your brief (16 char) message: This is a test !

 

If I want to get some information from the AVR, there are several ways. When I was coding the "Info" command, I think I found an error in the AVR software. Take a look

>i
Tuner Freq.   105.1                                                      
Master Vol.  -48.0dB
Input Name   DTV
Zone 2 Vol.     MUTE
Zone 2 Name  TUNER
Zone 2 Vol.    -B3dB
Zone 2 Name   DVD

 

It says Zone 2 Vol. and Zone 2 Name twice, but the data is different. Based on some experiments, the second set appears to be for Zone 3. Also, not the 'B' in the Zone 2 Volume level...

A more interesting query is with the "Hello" command.

>H
             S/W R0161E               dlc 8A                 fixed @E01900
            busy 0                  power 1                  input 6
            6 ch 0               inp mode 0                   mute 0
          zone 2 2                 mute 2 0                 volume 88
      zone 2 vol 00                   pgm 17                effect 1
       es status 3                    OSD 1                  sleep 4
        Tuner Pg 2                Tuner # 3                  Night 0
           ????? 0                 Spkr A 1                 Spkr B 0
        Playback 1                     Fs 0                  Ex/Es 0
      Thr Bypass 0                Red DTS 0                 Headph 0
      Tuner Band 0            Tuner Tuned 1        DC1 Control Out 1
           ????? 02         DC1 Trig Ctrl 1              dis 96/24 0
   DC2 Trig Ctrl 1               DC2 Trig 1             Spkr B Set 0
   Zone 2 SP out 0                 Main R 2B                Main L 29
          Center 23                Rear R 2D                Rear L 28
        Sur Bk R 20              Sur Bk L 20               Front R 28
         Front L 28                   Sub 28                 ????? 000000
          LFE SP 14                LFE HP 14           Audio Delay 00
           ????? 0000        Inp Mode Set 0                 Dimmer 4
         OSD Msg 1              OSD Shift 05             Gray Back 1
      Video Conv 1             D Range SP 0             D Range HP 0
  Zone 2 Vol out 0                  ????? 0           Memory Guard 0
   SP set center 0            SP set main 0        SP set rear L/R 0
  SP set rear ct 4           SP set front 0        SP set LFE/Bass 1
     6 ch center 0               6 ch sub 0             Main level 0
       Test Mode 0                  ????? 0        Lvl 6 ch main L 29
 Lvl 6 ch main R 2B       Lvl 6 ch center 23           Lvl 6 ch sl 28
     Lvl 6 ch sr 2D          Lvl 6 ch sbl 20          Lvl 6 ch sbr 20
Lvl 6 ch front l 28      Lvl 6 ch front r 28         Lvl 6 ch swfr 2D
      Zone 3 Inp 5            Zone 3 Mute 0             Zone 3 Vol 77
           ????? 0         MultiCh Select 0       MultiCh Surround 0
      SP Set SW1 0       SP Set Crossover 2          Component OSD 1
    PB/SB Select 1                  CKSUM 29

There's a lot of information buried in there, most of which I didn't decode, I just posted the Hex-ASCII values.

Reference Information

Yamaha AVR RX-V2400: Homepage, Manual, RS-232 Codes Web site, Standard, Extended, IR Standard, IR Extended
YAC: Yet Another Caller id
Win32 Serial: Tutorial with basic drivers for serial ports


License Agreement

This program is Webware. You may install it, test it for a reasonable period of time, and even modify it, but if you elect to keep it in use, whether in original form or in a modified form, you are then obligated to pay on a scale based on the value you receive from it. You are not allowed to redistribute any modified copy.

As with other license agreement, this program is supplied as is, and is not guaranteed free from defects. You assume all risk for problems you may incur as a result of the use of this program.

 

 

You can use this secure payment system to tell me how you like these programs. If you feel you've acquired a $1 program, then please, send only a single dollar. If you feel it is worth more, then fill in the amount that matches the value you've received.