Your Universal Remote Control Center
RemoteCentral.com
Philips Pronto Professional Forum - View Post
Previous section Next section Up level
Up level
The following page was printed from RemoteCentral.com:

Login:
Pass:
 
 

Topic:
Pronto TSU9600 Communicating w/ AVR3310CI Protocol RS-232c/ Ethernet
This thread has 3 replies. Displaying all posts.
Post 1 made on Wednesday September 22, 2010 at 14:24
bnokes@AAVViD
Long Time Member
Joined:
Posts:
June 2009
31
I would like to start by saying Thank you to all that is willing to help out other coders. This will help any one that is a beginner or a Pro. I am stepping back and going to look at this as a new coder which is true for Pronto Coding. I have some coding history, but it’s been a long time, but looking at this I am starting to understand this a little. With everyone’s help we can all understand better.

I will start by being the beginner working with pros and using Developer Guide ver. 1.1 & 1.3.9 and Denon AVR Guide. I will ask questions that may be dumb to some but it is very important to others.

I think that it is only the ignorant people who don’t ask what maybe dumb questions, to others so we can come to the final solutions of understanding. I would like to believe that no one is offended buy this, but I am only trying to make it clear that we help each other to better our self’s as a group.
OP | Post 2 made on Wednesday September 22, 2010 at 14:53
bnokes@AAVViD
Long Time Member
Joined:
Posts:
June 2009
31
Let’s start by asking is writing the code for RS-232c and Ethernet coding language the same? Let’s us an example: Denon AVR
(COMMAND and PARAMETER list:

COMMAND PARAMETER function example
PW ON POWER ON/STANDBY change PWON
STANDBY PWSTANDBY
? Return PW Status PW?
)

COMMAND and PARAMETER list:

COMMAND – PW, the PARAMETER – ON, and the FUNCTION – POWER ON/STANDBY CHANGE, the EXAMPLE – PWON

COMMAND – PW, the PARAMETER – STANDBY, and the FUNCTION – this is blank, the EXAMPLE – PWSTANDBY

COMMAND – PW, the PARAMETER – ?, and the FUNCTION – Return PW Status, the EXAMPLE – PW?


Connector specification:
Ⅰ. RS-232C
Connector type: DB-9pin female type, slave straight connection (DCE type)
( 1pin : GND , 2pin : TxD , 3pin : RxD , 5pin : Common(GND) ,4,6,7,8,9pin : NC )

Communication format:
Synchronous system : Tone step synchronization
Communication system : A half duplex
Communication speed : 9600bps
Character length : 8 bits
Parity control : None
Start bit : 1 bit
Stop bit : 1 bit
Communication procedure : Non procedural
Communication data length : 135 bytes (maximum)

Ⅱ. Ethernet
Ethernet Cross cable PC to/from AVR/AVC
Ethernet Straight cable HUB PC to/from AVR/AVC
Connector type : RJ-45(10BASE-T/100BASE-TX)

Communication format :

Communication system : A half duplex
Communication speed : 10Mbps/100Mbps
Communication port : TCP port 23 (telnet)
Communication data length : 135bytes (maximum)
Post 3 made on Wednesday September 22, 2010 at 21:29
Lyndel McGee
RC Moderator
Joined:
Posts:
August 2001
12,999
Yes, the command protocol is the same for either 232 or for TCP/IP.

It is the asynchronous coding that differs. For 232, you will be doing serial.send/serial.match() and supporting async data in OnData callback of serial port.

For TCP/IP, you will be doing TCP.send and then getting data in the OnData call.

Note that with 232 OnData callback, you are passed a parameter with the data. for TCP OnData callback, you must call socket.read inside from inside the callback function to pull data from the socket.

WARNING - Caveat Emptor

232 via RFX9600 is not truly full-duplex in that each send/match clears any existing data that might be in the UART's receive buffer. This becomes VERY problematic when doing channel volumes.

It is for this exact reason that most of us programming custom modules steer clear of any type of 232 programming where equipment can send multi-line response or sends asynchronous messages as to handle this, you code must be smart enough to receive/match multiple lines and know when it is safe to send command. You do not have this specific issue with TCP/IP.


Channel Volume example:

You send:
CVC 50\r to set Center volume to 0db

Denon will return a multi-line response containing levels of ALL channels. So, if you are using match and send another command immediately after processing the first response line, you can potentially corrupt the remaining data in the buffer such that you might see:

CVFL 54\r (match returns this value)
CVFR 54\r (Denon continues sending)
CVmissing character54\r (Denon was sending the 'C' which was removed from buffer as you sent next command of MV?\r)
CVSL 40
CFSR 40

This has been discussed several times in this forum. If you'd like to read more about this, search for UART.


The other thing to be aware of is that ONLY 1 remote can connect to Denon AVR via TCP/IP at any time. Other connections will be refused.

You should also write your code such that you await a response from the Denon otherwise, you can blow the TCP/IP stack on the Denon and then have to hard reset the unit. The time specifications such as wait 7 seconds after sending PWON should be honored as well as the wait of 150/200ms after sending a command prior to sending next one. However, if the Denon is in the process of sending a response, you can likely safely send the command.

Note that there is a free version of a Denon TCP module designed for TSU9400 available from www.prontoprojects.com.
Lyndel McGee
Philips Pronto Addict/Beta Tester
Post 4 made on Wednesday September 22, 2010 at 21:33
Lyndel McGee
RC Moderator
Joined:
Posts:
August 2001
12,999
One other thing. There are quite a few threads here that discuss Denon and TCP. Have a look as you might also find other tidbits of information.
Lyndel McGee
Philips Pronto Addict/Beta Tester


Jump to


Protected Feature Before you can reply to a message...
You must first register for a Remote Central user account - it's fast and free! Or, if you already have an account, please login now.

Please read the following: Unsolicited commercial advertisements are absolutely not permitted on this forum. Other private buy & sell messages should be posted to our Marketplace. For information on how to advertise your service or product click here. Remote Central reserves the right to remove or modify any post that is deemed inappropriate.

Hosting Services by ipHouse