Author Topic: Next Steps!! - Denon RS232 Rcvr Issues (Solved Slightly)  (Read 4139 times)

rodercot

  • Guest
Re: Next Steps!! - Denon RS232 Rcvr Issues
« Reply #15 on: August 11, 2008, 12:19:48 am »
Pete,

 How ironic is that, I just stumbled onto that as well while I finally found the log files. I saw that error. Now I am getting a compile error while ruby is trying to compile the codes.

 
Code: [Select]
295:end297:01 08/10/08 18:00:05.150 Failed loading code: Error loading code: error: (eval):295: compile error(eval):78: syntax error, unexpected tIDENTIFIER, expecting kENDsleep(2) conn_.Send("MUOFF\r")              ^(eval):295: syntax error, unexpected kEND, expecting $end, line: 295. <0xb583db90>
 
Code: [Select]
74:#### 192 ####################################################################  75:def cmd_192(pk_pipe, pk_device_pipes, cmd=nil)  76:@returnParamArray.clear  77:conn_.Send("PWON\r")  78:sleep(2) conn_.Send("MUOFF\r")  79:  80:  81: @mute = false   82:  83:end  84:return @returnParamArray  85:end

 rgds,

 Dave

rodercot

  • Guest
Re: Next Steps!! - Denon RS232 Rcvr Issues
« Reply #16 on: August 11, 2008, 01:57:54 am »
 Well I have communication finally. I have all the commands if I use the UI and goto advanced - ir codes. Pretty much all the commands work. I have no volume from the MCE remote, it is sending a command but the USBUirt is not receiving it by the looks of it, I get a flash from the USBuirt once in a while. The mute command does not work off that remote either. So at this point it looks like the lmce will power on the rcvr and set it too the hdp input. If I try the Tuner - OtaRadio it does nothing, I need to use the UI and resend the AV codes then it waits about 15 seconds and switches to the tuner for about 10 seconds and then swtches back to LMCE's input.

 The error from the last post was improper formatting of the original command

 It was <"$PWON\r"> sleep(2) <"$MUOFF\r">

 @mute=false


 end

 it needed to be

 <"$PWON\r">
 sleep(2)
 <"$MUOFF\r">
 @mute=false

 no spaces and tight to the left of the command box with no end command.

 So how do we go about formatting the child devices. There were no Child device commands in the device data for the AVC template. Once that is done I take it I can setup a scenario to control the OTAradio and XMSatradio - I have not put in any command for skip ahead or skip back for the tuner portion yet, as I am hoping to find some info on doing that.

 rgds,

 Dave

rodercot

  • Guest
Re: Next Steps!! - Denon RS232 Rcvr Issues (Solved Slightly)
« Reply #17 on: August 11, 2008, 12:51:14 pm »
So I thought I would make a little note for you all here. I spent two days and 100$ on USB-Serial Cables as well as null modem cables and gender changers.

 First I created a RS232 template for the Denon AVR-988 - Write down your template # you will need it later

 Inputs

 I set the tuner to OTAradio
 I set the XM Input to Satellite Radio Neither of these work yet. I have a feeling I will have to change them both to live-tv and modify the scenario for each.
 The Ext 7.1 - Input works on this template for DVD-Audio and SACD. I have mine set to Pure direct mode.

 Modes - Use what is listed - There are issues with Denon Modes and rs-232 - Some modes need a parent mode sent first then a child mode IE DTS Surround - DTS Neo Cinema to end up at DTS Neo Cinema. I have been following a few threads on Remote Central and this seems to be a common issue with Denon Modes. I will figure this out and update when completed I also plan on Adding the DTS-HD master and Dobly Digital + and DD True HD modes to the list. When I can get an answer about adding the command in and in fact a mode is an AV Command. But for now all the modes are in the that normally will be used.

 Cables

 Prolific USB-RS232 (Radio Shack Nexxtech) detected the rcvr HAS TO BE A DIRECT CONNECTION, you cannot use the usb-serial and then plug another male to female null cable in it will not detect the device it just runs through all the scripts looking but no device found. In order to do a direct connection you need to remove the stand-offs from the male db9 end on usb-serial cable

 Cheap China made device (well 27$) No dice - Light comes on for power but no detection - In the garbage now.

 Trendnet - same as above with prolific device - it is working and the one I am using now again a DIRECT connection to the rcvr.

 Once your USb-Serial is installed you will need to launch a shell to the core and run lsusb abd get the tty number for your device (this being the USB-serial device) and not the rcvr for mine it is ttyUSB2 but the system is using pci000 ______  _____ +7 you will know what I mean when you see it in your ports listing. Ideally I think if your system detects the rcvr it is USING the right port anyhow, making this step not really required.

 Denon PNP script - You will need to modify this and in the last line change the Device template #, likely will be 71 on your local machine ( There is no logic in the script for Device ID) Also could be a denon issue as it looks like all there receivers use the same command sets with just more or less of them. If you do not edit your script it will detect the AVC-A1SA all the time.

 Device Template # 1931. You can set yours up the same way as this.

 Make note - Stop and Parity Bit need to be N81 not 8N1. I also set the baud rate to 9600 but the more templates I see B9600 in the default value. Mine is working so I am not sure if it matters. 

 The receiver only needs Standard Receiver Commands at this point to function (from a gyro remote) Also I have not figure out how to toggle the Mute Command, I can mute it but then issue the PWON command to unmute it currently.

 Now the issues - My whole problem was two things.

 One the 8N1 which I found by looking in webadmin - advanced - device - core - avr-988 (rs232) then click on View Log Errors. This is the key you can view errors, whole log and tail the device from the webadmin. This is how I located the problem and was able to fix it.

 I fixed the 8N1 by changing it to N81. then in viewing the whole log - I found that Ruby could not compile the command set due to the errors in the PWON Command Formatting. I fixed that and voila. Now I had to regen the orbiter, and then recheck the log to make sure all the errors were gone. Then I removed (deleted) the rcvr and had it redetect and setup again then reload router and then tested some commands from the webadmin page and they worked.

 I still have no volume from the MCE remote for some reason I will figure out later. I reloaded my .Xmodmap from KDE terminal and got the ambience controls working with my Gyration again and I now have volume from the gyration at least. but the LMCE is turning the rcvr on and off with the TV now which is good.

 Zaerc - I will add this too the WIKI as soon as I get it completely formatted with the system.

 A note when setting up devices - How I screwed up. When I got to the IR/Codes group I chose denon avc protocol. I should have made a new group at that point. As the Denon AVC has a lot of modes and different inputs than the AVR-988. So I chose to delete code from that page thinking it would remove that mode from the list it did not it went to the web and deleted ALL the codes from the master template. I have added them all back in except for a couple inputs and some THX modes which I do not have the commands for.

 So In retrospect I would have created a new IR codes template and the same thing will happen if you try to setup a 2808, 3808, 4806, 5808Ci Denon rcvr, you must create a new code group for those. the Denon code group that is there now works with the AVR-988. I am going to go back in a create a AVR-988 code group later and fix the AVC protocol template as well.

 Regards,

 Dave

 

 

 

 
« Last Edit: August 11, 2008, 01:04:34 pm by rodercot »

hari

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 2420
    • View Profile
    • ago control
Re: Next Steps!! - Denon RS232 Rcvr Issues
« Reply #18 on: August 11, 2008, 02:37:02 pm »
I submitted a mantis change for a bug in the Denon template.  The serial parameters don't match the format that the GSD plugin is looking for.  See http://mantis.linuxmce.org/view.php?id=4267

You should be able to do this on your local machine until the batch is approved.

The denon template worked like a charm on the LinuxTAG booth (4306)

what did you change?

br, hari
rock your home - http://www.agocontrol.com home automation

rodercot

  • Guest
Re: Next Steps!! - Denon RS232 Rcvr Issues
« Reply #19 on: August 11, 2008, 04:37:33 pm »
I submitted a mantis change for a bug in the Denon template.  The serial parameters don't match the format that the GSD plugin is looking for.  See http://mantis.linuxmce.org/view.php?id=4267

You should be able to do this on your local machine until the batch is approved.

The denon template worked like a charm on the LinuxTAG booth (4306)

what did you change?

br, hari

 Hari,

 Not sure if this was for me or Pete but in my case. I setup the new template for the 988 rcvr and basically copied all the device commands directly from the current AVC template in the system. When I finally stumbled onto the logs in the webadmin - and under log errors, I was getting a 8N1 not supported. In My Template I changed that to N81 and reloaded and the error went away.

 The 8N1 is still in the AVC template on the system I believe.  I did not change anything on the AVC-A1SA template.

 rgds,

 Dave

PeteK

  • Guru
  • ****
  • Posts: 408
    • View Profile
Re: Next Steps!! - Denon RS232 Rcvr Issues (Solved Slightly)
« Reply #20 on: August 12, 2008, 07:10:13 am »
Hari--

This was on the AVC template (#71).

Here is my error log:

Error log
Device Denon Receiver, # 108    
Device Template AVC-A1SRA (RS232), device category Amps/Preamps/Receivers/Tuners, manufacturer Denon.   
    

01   08/11/08 19:26:07.970      Paritybit/Stopbit 8N1 NOT supported. <0x42164950>
01   08/11/08 19:26:07.978      IOPool::handleStartup Open() failed <0x42965950>
01   08/11/08 19:26:07.978      Failed Opening serial port: ttyS_55_0. <0x42965950>
01   08/11/08 19:26:07.978      IOPool::handleStartup Open() failed <0x42965950>


However, I tried it again tonight and noticed that this error does not stop the device from working.  I guess the fix is not needed after all?  Is  N81 the default when an invalid value is used?

Thanks,
PeteK