New USB-Loconet interface

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 10.12.2012, 21:02

Hello Peter,

I've just seen in the documentation for the "Low Pin Count USB Development Kit" the 18F14K50 needs a 12MHz oscillator, not 20MHz as the 18Fx550 does.

phg
Posts: 337
Joined: 23.02.2008, 20:55
Location: Deventer Niederlande
Contact:

Post by phg » 11.12.2012, 16:00

Hello Liviu,

In the mean time, I want to drop the 14K50 idea.
What I specificly do not like about it , is the fact that USB datalines are the same as PGMData and PGMClk lines.
This will seriously conflict while USB remains connected during programming.
Therefore, I need to put up jumpers and/or serious warning about the use of the ICSP connector.
That won't do.

So I wll remain on 2550 chip.

phg
Posts: 337
Joined: 23.02.2008, 20:55
Location: Deventer Niederlande
Contact:

Post by phg » 11.12.2012, 17:34

Hi Liviu,

Here is the -almost- final design.
Pc-board has been shrinking again.
I skipped the 5V on board, after conclusion that power consumption of total 5V circuit is extremely low.

Schematic follows in next message.
Attachments
GCA172_silkscreen.pdf
(141.28 KiB) Downloaded 67 times
Last edited by phg on 11.12.2012, 17:39, edited 1 time in total.

phg
Posts: 337
Joined: 23.02.2008, 20:55
Location: Deventer Niederlande
Contact:

Post by phg » 11.12.2012, 17:38

and her is schematic.
Attachments
SCAN.ZIP
(868.79 KiB) Downloaded 72 times

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 11.12.2012, 18:53

Hello Peter,

The schematic looks good, I think it will work OK. And yes, the current consumption is low, I'm supplying my interface from my PC's USB port.
The version you'll use at the end is your choice. Please test it thoroughly and inform me if you encounter any problem.

Regards,
Liviu

phg
Posts: 337
Joined: 23.02.2008, 20:55
Location: Deventer Niederlande
Contact:

Post by phg » 12.12.2012, 20:02

Hello Liviu,

After a first nice success for GCA172 ln2USB interface, there is something wrong now.
The board reacts on the LN side with a flashig led on communication.
So far OK.
But in Windows it will not load anymore the USB Com emulator.
Win7 only shows in Hardware > other hardware : LN-USB interface.
But nothing in Ports(com&LPT1).
Driver MCP2200_v1.2 is installed.
What can go wrong ?
Nothing has changed, except that computer has been powered off.

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 12.12.2012, 21:05

Hello Peter,

Unfortunately I'm a little bit clueless.
When you disconnect/reconnect the interface to PC complains Windows about bad USB devices? If yes, there are problems with the firmware/the interface hardware. If not, I bet a driver problem.

In my WinXP, in the driver section I have only
Driver Provider: Microchip Technology, Inc.
Driver Version: 5.1.2600.2

If you disconnect and reconnect the interface from/to PC (with the Loconet cable connected to interface), the problem remain?
When I connect the interface to different USB ports in my USB-Hub, the COM-Port number changes also (and first time when I connect the interface in one port Windows install the driver once again). What happens when you change the port?

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 12.12.2012, 21:22

Hello Peter,
to be sure we are using the same driver I've changed the driver information file to show the interface as "Ports(COM&LPT) ->LN2USB Interface" (this is what WinXP shows me, I hope the Win7 configuration is similar).
May you please try with this driver?
Attachments
LN2USB_driver.zip
(5.03 KiB) Downloaded 76 times

phg
Posts: 337
Joined: 23.02.2008, 20:55
Location: Deventer Niederlande
Contact:

Post by phg » 12.12.2012, 21:40

Hello Liviu,

Thanks for your reply.

It does not make any difference how I start it.
Windows never announces me any error, just sometimes that a driver need te be installed.
I did that multiple times, but the result is always the same.
No com emulator is indicated, just LN-USB Interface.
Before the computer has been switched off, I had COM27 as emulator for GCA172. That time it did not matter which of the multiple USB connections I used, it always remained Port 27.
On your last message, I do not know what to do with that file.
I downloaded it und unzipped, but then I only get a screen with a securitycatalogue, with version, usd items, list id etc.
I am sorry , I always seem to have troubles with this driver stuff.

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 12.12.2012, 22:06

Hi Peter,

In the .zip file are 2 other files: mchpcdc.cat & mchpcdc.inf. They are the driver files. Unzip the files somewhere in a known place.
In the hardware manager, please uninstall the MCP2200 drivers (with the interface connected, right click on the interface name in device manager -> uninstall), remove and reconnect the interface.
In this moment the windows will ask after drivers. Instruct it to let you choose the drivers and browse to the place you unzipped the files.
Selecting this directory, you will be able to install the LN2USB Interface.

But before any change maybe you can try to reboot your PC without the interface connected. After the PC is up and running, connect once again the interface (Loconet should remain connected all the time).

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 12.12.2012, 22:46

Hello Peter,

me again. :)
I was trying to use the interface with the MCP2200_v1.2 drivers and windows refuse to accept this driver for the interface.
Even if I installed the driver in the system using the Microchip's utility, the windows refuse to "connect" my interface with this driver.
Are you sure that in your system the interface uses this driver? You can find out in the Hardware Manager.

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 15.12.2012, 12:17

Hi all,

after some messages changed with Peter, we've decided the missing flow control can be a problem for big layouts.
Till I'll find a flow control method (the CTS seems unimplemented in the CDC driver), I don't recommend any use of my interface for other purposes than small layouts or tests/further development.

Regards,
Liviu

rjversluis
Site Admin
Posts: 41736
Joined: 10.04.2006, 08:48
Location: Speyer, Germany
Contact:

Post by rjversluis » 15.12.2012, 12:23

Hi Liviu,

I would suggest to use the same method as:
http://wiki.rocrail.net/doku.php?id=int ... #type_ulni
If the chip can handle this baudrate.

Liviu M
Posts: 941
Joined: 03.12.2011, 20:44

Post by Liviu M » 15.12.2012, 13:08

Hello Rob,

I was trying but it doesn't work in the moment.
If I implement an echoing, I can see the LN commands coming back to the PC using the normal, LocoBuffer setup in Rocrail, but I receive echo time out (or something similar) for the ULNI setup. I'm still trying, but right now my spare time is a little bit low.
What I fount till now indicate that sending a NAK as long as the buffer is full will stop the host to send data to the interface and as I know, the microchip's stack I've modified send this NAK.
So, maybe I shouldn't search anymore, but as long as I can't test it on large enough layouts, I can't say anything for sure.

Regards,
Liviu
Last edited by Liviu M on 15.12.2012, 19:34, edited 1 time in total.

phg
Posts: 337
Joined: 23.02.2008, 20:55
Location: Deventer Niederlande
Contact:

Post by phg » 15.12.2012, 14:04

Hello Liviu,

So far, also echo2 does not give me any communication.
I am still back on act_led2, which works fine.
At the moment I too do not have any possibility to test on large setup.
That setup (from MGV) is now partly showed in a Garden_shopping_center, and will not be available before January.
So do not feel sorry for everything, it can wait until you can spare some more time on it.
It is a hobby, do not forget that!

Post Reply

Return to “DIY Hardware”