Sorry I did not elaborate on that. I am still confuse as to what type of data you are sending to your device. Binary data? is this serial data sent thru RS232? I am going to assume that when you press that momentary switch, the PIC reads that the switch was pressed and sends a string "Hello", as an example.
So you want to accomplish the same with the SitePlayer (SP). You first have to connect your pic straight to the SP pin7 (SP receive) and pin8 (SP transmit). On pin8 you MUST have a 4.7K resistor pulled down ( this is because a problem there is with the SP board, not able to pull the line completely down). That straight connection with the pic means that you are going to send and receive information from the SP in a true mode. I am going to guess that you are using a MAX232 since you were able to send data to the PC. You will no need the MAX232 to connect to the PIC, but if you do then all the data received from the Siteplayer will be inverted and you will have to account for that on your program. The good think of having a MAX232 is that you can connect to your computer as well. Since you sent some data to the SP already I am going to skip what to do so that the SP sends serially.
On the PIC side you are going to have to match the baudrate you program in the siteplayer. And you are going to have to match if TRUE or INVERTED mode is needed. So our task is to send the string "Hello", when the SP tell us to do so. Then we must come up with a way of having the SP tell us to send such command. For personal preference I always use the "ESC + a number" as my commands. ESC if you look at a ASCII table is decimal 27. So lets say that to simulate the momentary switch pressed down we are going to send a ESC + A (decimal 27, 65). So you tell the SP to send this thru the serial port when a link is presses or whatever your interface might be.
The PIC will then have a program that checks for a ESC + A (decimal 27, 65), Make sure is capital A and not a(who's ASCII value is different). How do you do that? With the Serin command
Assume: PIC receiving on PortB.1, Baudrate 9600 and no MAX232.
Code:
Include "modedefs.bas" 'Definitions used with serin and other commands
COMMAND VAR BYTE
Loop:
SERIN PortB.1, T9600,[27],COMMAND ' Wait until the character “ESC” is received serially on Pin1
'and put next character into COMMAND variable
If COMMAND = 65 then
'Send binary data or as the example
Serout PORTB.2, T9600, ["Hello"]
endif
If COMMAND = 66 then
'Send binary data or as the example
Serout PORTB.2, T9600, ["Bye"]
endif
Goto Loop
What this does is allow you for more than one command. So if you were to send a ESC + B, you could have the PIC send something else.
I hope it helps you some.
Ivancho