JP1 Remotes Forum Index JP1 Remotes


FAQFAQ SearchSearch 7 days of topics7 Days MemberlistMemberlist UsergroupsUsergroups RegisterRegister
ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in

Commodore Amiga CDTV: new protocol or RCA-38(old)?

 
Post new topic   Reply to topic    JP1 Remotes Forum Index -> JP1 - Protocol Decodes
View previous topic :: View next topic  
Author Message
Barf
Expert


Joined: 24 Oct 2008
Posts: 815

PostPosted: Tue Feb 07, 2017 4:55 am    Post subject: Commodore Amiga CDTV: new protocol or RCA-38(old)? Reply with quote

Please have a look at this issue. It is claimed that this is a new protocol. As I ("bengtmartensson") wrote, decodeir (within IrScrutinizer) identifies the signal as RCA-38(Old) (D=8) However, I get the impression that the timing differences may be significant.

Searching for this device gave me only a Lirc file. This also decodes with IrScrutinizer as RCA-38(old), but with different device number (0), although the timings appear to be off.

This is the C code written:

Code:

#define CDTV_BITS          24
// timing intervals in usec
#define CDTV_HDR_MARK    8850                   // start burst
#define CDTV_HDR_SPACE   4450                   // pause after start
#define CDTV_BIT_MARK     350                   // pulse
#define CDTV_ONE_SPACE   1250                   // receive a '1'
#define CDTV_ZERO_SPACE   450                   // receive a '0'
#define CDTV_RPT_SPACE   2250                   // repeat signal
// message sizes measured in raw pulses
#define CDTV_RAW_REPEAT_LENGTH     4    // CDTV_HDR_MARK + CDTV_HDR_SPACE + CDTV_BIT_MARK
#define CDTV_RAW_SIGNAL_LENGTH     52   // CDTV_HDR_MARK + CDTV_HDR_SPACE + CDTV_BITS * (CDTV_BIT_MARK + CDTV_ZERO_SPACE | CDTV_ONE_SPACE)

//+=============================================================================
#if SEND_CDTV
void  IRsend::sendCDTV(unsigned long data, int nbits) {

        // set IR carrier frequency
        enableIROut(40);

        // send header
        mark(CDTV_HDR_MARK);
        space(CDTV_HDR_SPACE);

        // send data
        for (unsigned long mask = 1UL << (nbits - 1); mask; mask >>= 1) {
                if (data & mask) {
                        mark(CDTV_BIT_MARK);
                        space(CDTV_ONE_SPACE);
                } else {
                        mark(CDTV_BIT_MARK);
                        space(CDTV_ZERO_SPACE);
                }
        }

        // send footer
        mark(CDTV_BIT_MARK);
        // always end with the LED off
        space(0);

}
#endif




Is this a new protocol, or is it RCA-38(old)? Is DecodeIR too tolerant here?
Back to top
View user's profile Send private message Send e-mail Visit poster's website
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 18353
Location: Chicago, IL

PostPosted: Tue Feb 07, 2017 10:24 am    Post subject: Reply with quote

They are both 24 bits but the timings look different.

Leadin:
9063 4434 - CDTV
3680 3680 - RCA

One
0451 1147 - CDTV
0460 1840 - RCA

Zero
0451 0348 - CDTV
0460 0920 - RCA

Leadout:
62323 - CDTV
07360 - RCA

So, they're certainly similar, but I don't know if they're similar enough for an RCA signal to control a CDTV, but you could certainly use the RCA executor as a basis for a new CDTV executor. I don't think we have a 38k frequency RCA executor, so you'd need to take the 56k version and adjust the freq.
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
3FG
Expert


Joined: 19 May 2009
Posts: 3240

PostPosted: Wed Feb 08, 2017 12:16 am    Post subject: Reply with quote

Clearly the decode of RCA(old) is erroneous. I took a quick look at DecodeIR.cpp and from what I can see, if a protocol is recognized as gap with 24 bits, and hasn't been identified as some other protocol, it defaults to RCA. In this case the leadin more closely resembles RCA(old), so that's what DecodeIR calls it.

In truth I've never understood how DecodeIR works, especially the routine that decode gap type signals. I understand/remember even less now. I've handled the 2.42 through 2.45 versions of DecodeIR, but I am no longer willing to work on it, partly because it is pretty difficult and partly because I am close to providing a public version of a Java program which decodes IR signals using a single decoding engine which takes descriptions of IR protocols from an ASCII file. For me, it is much easier to understand, and should allow anybody to add protocols. However, it is not a direct plug-in replacement for DecodeIR.
Back to top
View user's profile Send private message
Barf
Expert


Joined: 24 Oct 2008
Posts: 815

PostPosted: Wed Feb 08, 2017 3:45 am    Post subject: Reply with quote

3FG, thank you very much for the answer. So you support considering it as new protocol?

Regarding DecodeIR, I have responded in a new thread.

Thanx also to Rob.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 18353
Location: Chicago, IL

PostPosted: Wed Feb 08, 2017 8:48 am    Post subject: Reply with quote

Do you own a CDTV Bengt, and if so, do you need a JP1 upgrade for it?
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
Barf
Expert


Joined: 24 Oct 2008
Posts: 815

PostPosted: Wed Feb 08, 2017 8:59 am    Post subject: Reply with quote

Thanx Rob, but the answer is "no". My interest is purely academic, in the context of the issues linked in the first post.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic       JP1 Remotes Forum Index -> JP1 - Protocol Decodes All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

Powered by phpBB © 2001, 2005 phpBB Group
Get Smart! the band's official homepage Rockabilly Central