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

Using jp12serial for other chipsets on Windows

 
Post new topic   Reply to topic    JP1 Remotes Forum Index -> JP1 - Software
View previous topic :: View next topic  
Author Message
carsonlittle



Joined: 02 Dec 2012
Posts: 62

                    
PostPosted: Wed Dec 12, 2012 12:25 am    Post subject: Using jp12serial for other chipsets on Windows Reply with quote

It looks like jp12serial is the "API" between other JPx tools and the hardware interfaces.

Since FTDI is "baked in" on Linux, the Linux code path for jp12serial is pretty agnostic to the usb converter used, so I can use any usb converter I like.

However, on Windows, it assumes that FTDI is the usb converter exclusively!

How do I then, make jp12serial work with usb converters that are NOT FTDI (but implement Tx break and RTS/DTR correctly) - for example the CP2102, and coming soon my own PIC18F based interface?

Would it involve creating separate code-paths for each custom driver using a maze of ifdef statements?
Back to top
View user's profile Send private message
3FG
Expert


Joined: 19 May 2009
Posts: 3365

                    
PostPosted: Wed Dec 12, 2012 2:12 am    Post subject: Reply with quote

I do not believe the assertion in bold is correct; in fact JP12Serial has been used with Prolific chipsets for years to communicate with remotes. In principle, any USB serial converter to TTL-type signals should work. The Widgets (as opposed to remotes) I'm aware of all use FTDI chips, and JP12Serial does look for that chipset first, but it doesn't preclude use of other chipsets, I think.

For the 2102, see this comment by Kevin Timmerman. Depending on the remote type, it probably won't work, but the issue is not in JP12Serial.

The Prolific chips are also problematic, in part because the chips are frequently counterfeit, and Prolific has allegedly put traps in their drivers. Additionally, it seems that these chips (at least as implemented in the DIY Gadget cables) don't always recognize both low and high levels while reading from the remotes. We see this especially with JP2 (MAXQ) remotes.

BTW, I think at least some of the comments in JP12Serial.cpp regarding high/low levels on IDC pin numbers are incorrect.
Back to top
View user's profile Send private message
carsonlittle



Joined: 02 Dec 2012
Posts: 62

                    
PostPosted: Wed Dec 12, 2012 11:55 am    Post subject: Reply with quote

3FG wrote:
I do not believe the assertion in bold is correct; in fact JP12Serial has been used with Prolific chipsets for years to communicate with remotes. In principle, any USB serial converter to TTL-type signals should work. The Widgets (as opposed to remotes) I'm aware of all use FTDI chips, and JP12Serial does look for that chipset first, but it doesn't preclude use of other chipsets, I think.


You are correct - this is what I do when I am awake for 12 hour straight and read through dense specs and C code, and then printout the FTDI headers while thinking they are the JP12Serial headers and finish the day with the conclusion.

JP12Serial is pretty agnostic to the underlying chipset and uses FTDI library to enhance port lookups.

My bad.

3FG wrote:
Additionally, it seems that these chips (at least as implemented in the DIY Gadget cables) don't always recognize both low and high levels while reading from the remotes. We see this especially with JP2 (MAXQ) remotes.


More details on the "recognize both low and high levels" please?

3FG wrote:
BTW, I think at least some of the comments in JP12Serial.cpp regarding high/low levels on IDC pin numbers are incorrect.


What confuses me is that there are two separate "enter programming mode" sequence for JP1.3 and JP1.2/JP1.3.

As far as I could make out - the JP1.3 sequence (with RTS low) would work for JP1.2 as well?
Back to top
View user's profile Send private message
3FG
Expert


Joined: 19 May 2009
Posts: 3365

                    
PostPosted: Thu Dec 13, 2012 1:07 am    Post subject: Reply with quote

With the MAXQ processor (JP2), the DIY Gadget (Prolific) JP1.3 interfaces seem to be able to send data to the remote correctly, but the response is generally wrong, and sometimes shorter than expected. I interpret this as the interface can't reliably detect when its Rx line has been driven low (or perhaps high). I don't know any details of the circuitry in these interfaces.

http://www.hifi-remote.com/forums/viewtopic.php?p=106972
Back to top
View user's profile Send private message
carsonlittle



Joined: 02 Dec 2012
Posts: 62

                    
PostPosted: Thu Dec 13, 2012 11:50 am    Post subject: Reply with quote

3FG wrote:
With the MAXQ processor (JP2), the DIY Gadget (Prolific) JP1.3 interfaces seem to be able to send data to the remote correctly, but the response is generally wrong, and sometimes shorter than expected. I interpret this as the interface can't reliably detect when its Rx line has been driven low (or perhaps high)


Sounds like a level shifter issue. The PL2303 specs notify support of 3 voltage levels which should do away this issue but it requires the adapter to implement it correctly (which might not happen in cheap adapters or fake chipsets)

Once I am done with JP1.x, I will look into this (.. and not require FTDI chipset at all)
Back to top
View user's profile Send private message
carsonlittle



Joined: 02 Dec 2012
Posts: 62

                    
PostPosted: Fri Dec 14, 2012 3:06 am    Post subject: Reply with quote

I would like to make some custom changes to the code and recompile this DLL: Will it compile (correctly and run without issues) if I use this: http://mingw-w64.sourceforge.net/

Or is it this that I should be using: http://www.mingw.org/

I am confused.
Back to top
View user's profile Send private message
carsonlittle



Joined: 02 Dec 2012
Posts: 62

                    
PostPosted: Fri Dec 21, 2012 2:52 am    Post subject: Reply with quote

carsonlittle wrote:
I would like to make some custom changes to the code and recompile this DLL: Will it compile (correctly and run without issues) if I use this: http://mingw-w64.sourceforge.net/

Or is it this that I should be using: http://www.mingw.org/

I am confused.


The version packaged so far seems to be built using the toolchain from http://www.mingw.org/.

I am trying to make it work using http://mingw-w64.sourceforge.net/ here:
http://www.hifi-remote.com/forums/viewforum.php?f=9

So far it looks good
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic       JP1 Remotes Forum Index -> JP1 - Software 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
Top 7 Advantages of Playing Online Slots The Evolution of Remote Control