New USB-Loconet interface

Moderator: Moderators

Postby Liviu M » 09.03.2013, 21:34

Hello Peter,

I've just done a small test with a MGV/GCA50 (the only one I have) and I have no problem to detect it (query), to read all ports (get all) and to reprogram all ports at once (set all after changing some parameters).
For other problems I'll keep searching.

Regards,
Liviu

PS As I already said, I'm using the ULNI controller type.
Liviu M
 

Postby Liviu M » 09.03.2013, 22:23

Sorry, wrong post.
Liviu M
 

Postby phg » 10.03.2013, 13:29

Hello Liviu,

I do not know what went wrong yesterday.
My suspect is that startup of the processor is bit unstable.
But, it seems all is working fine with IB setting.
Reading, programming, power up, power off (also at Rocrail exit) everything is doing exactly as expected.
This is all tested with IB connected.
Great Job ! :goodjob:

to be continued............
Best regards, herzliche Grüße, chaleureuses salutations, saludo cordial, migliori saluti, hjärtliga hälsningar, hartelijke groet,

Peter Giling (Rocrail - LNet(GCAxxx) - Fiddle Yard control GCA145 - CBUS (CAN-GCx)- RocNet (Raspberry Pi GCA-PIxx)
phg
 

Postby rjversluis » 10.03.2013, 13:31

Hi Peter,

did you test also with the DCS200?
Best Regards, Rob.
:!: PS: Do not forget to attach the usual files.
:!: PS: Nicht vergessen die übliche Dateien an zu hängen.
[ macOS - Linux] - [ N: CBus - CAN-GCA ] - [ 0: RocNetNode - GCA-Pi ]
rjversluis
Site Admin
 

Postby Liviu M » 10.03.2013, 14:38

Hello Peter,

I'm glad it works better, but you are right, there is enough place for improvements. I'm working on, but it takes time.
Please posts any problems/comments you may have.

Have a nice day,
Liviu
Liviu M
 

Postby phg » 10.03.2013, 15:25

Hello Liviu,

The next test with Digitrax DCS200 :

Power on off ok, but Locs do not respond.
From Rocrail I get the info :
Could not get slot for loco addr=1611. (no response...)

The same counts for all locs .
Best regards, herzliche Grüße, chaleureuses salutations, saludo cordial, migliori saluti, hjärtliga hälsningar, hartelijke groet,

Peter Giling (Rocrail - LNet(GCAxxx) - Fiddle Yard control GCA145 - CBUS (CAN-GCx)- RocNet (Raspberry Pi GCA-PIxx)
phg
 

Postby Liviu M » 10.03.2013, 19:42

Hello Peter,

This is strange, because the interface should be transparent.
That means, after length & chk checks it passes the incoming messages unmodified to the output. I should check the loconet documentation to see if I'm missing something.

Thanks for the feedback,
Liviu
Liviu M
 

Postby Liviu M » 11.03.2013, 22:38

Hello Peter,

may you please test if the attached firmware is more robust than the previous ones? I've changed a little bit the receiving part and in my tests seems to be better.
On the other hand, I still don't have any real idea why DCS200 is not working (or is working only partial).

Kind regards,
Liviu
You do not have the required permissions to view the files attached to this post.
Liviu M
 

Postby rjversluis » 11.03.2013, 22:57

Liviu M wrote:On the other hand, I still don't have any real idea why DCS200 is not working (or is working only partial).

That is a bit timing issue; The longer the packet the larger the impact.

I used a scope for developing the CAN-GCLN to get a clean 60us bit size.
If the tolerance is too big you only detect small packets, but the long packets are mangled.

Very important also is the collision detection as I wrote before; You must pull down the Loconet data line for at least 12 bits or so.
Best Regards, Rob.
:!: PS: Do not forget to attach the usual files.
:!: PS: Nicht vergessen die übliche Dateien an zu hängen.
[ macOS - Linux] - [ N: CBus - CAN-GCA ] - [ 0: RocNetNode - GCA-Pi ]
rjversluis
Site Admin
 

Postby Liviu M » 11.03.2013, 23:13

Hello Rob,

Thanks for the info.
After you told me about problems with DCS200, I've checked both of the interfaces (soft-uart & hard-uart) with an oscilloscope and the the timing for the hard one was very close to 60us.
I was, also, trying to implement the break sequence (15 zeros) in case of transmission fail (detected by receiving back each byte and comparing it with the sent one).
I'm still searching for the problem.

Kind regards,
Liviu
Liviu M
 

Postby phg » 18.03.2013, 13:13

Hello Liviu,

Finally I am back on track again and had a chance to check your latest firmware.
I had to reinstall drivers, but after that, I am still facing the same problem: communication with DCS200 seems to limit itself only to power on and off.
No locs can be controlled with it.
After some extra testing, all communication failed.
Best regards, herzliche Grüße, chaleureuses salutations, saludo cordial, migliori saluti, hjärtliga hälsningar, hartelijke groet,

Peter Giling (Rocrail - LNet(GCAxxx) - Fiddle Yard control GCA145 - CBUS (CAN-GCx)- RocNet (Raspberry Pi GCA-PIxx)
phg
 

Postby Liviu M » 18.03.2013, 17:25

Hello Peter,

Unfortunately I'm not able to make this interface to work as needed :(, in the moment I'm using the soft version.
I'm still hoping (I have few ideas) to make it better, but in the moment I don't have the time for it. I'll post any news when I'll have some. Sorry for any inconvenience.

Kind regards,
Liviu
Liviu M
 

Postby phg » 19.03.2013, 17:14

Hello Liviu,

Thanks for all your troubles.
But I am running out of GCA85 pc-boards, so a new batch will be ordered now.
This will make the GCA172 much less interesting, so I will skip that plan.
Best regards, herzliche Grüße, chaleureuses salutations, saludo cordial, migliori saluti, hjärtliga hälsningar, hartelijke groet,

Peter Giling (Rocrail - LNet(GCAxxx) - Fiddle Yard control GCA145 - CBUS (CAN-GCx)- RocNet (Raspberry Pi GCA-PIxx)
phg
 

Postby Liviu M » 19.03.2013, 21:31

Hello Peter,

Once again, sorry for any inconvenience.

Kind regards,
Liviu.
Liviu M
 

Postby Liviu M » 18.04.2013, 17:33

Hi all,

Should someone still being interested in my USB-Loconet interface, :oops: I'm attaching *) a version about which I'm thinking is working well.
It is a "light" version of the interface, because it just passes the bytes between the Loconet & the PC, without any other check than "Loconet free" (CD_BACKOFF_TIME).
The "handshake" is done by echoing-back the byte it just sent - it reads the byte and send it to the PC (so for full functionality it shoud be used with ULNI setting in Rocrail).
I hope this simplicity makes it more robust.

*) In the attached .zip file are the firmware versions for the Microchip's PIC18F4550, PIC18F2550 & PIC18F15K50. I've tested (a little) the PIC18F4550 & PIC18F14K50 versions (I don't have any PIC18F2550).
The schematics used are the USART versions.

Best regards,
Liviu

PS @Peter: I know you are not more interested in this interface, but if you still having the test board you previously used, I'll appreciate if you'll find some time to test it with the DCS200.
@Rob: same appreciation if you'll find the time to made the test. :)
@both of you: is not a problem if you can't do the test, it's just curiosity. :)
You do not have the required permissions to view the files attached to this post.
Liviu M
 

PreviousNext

Return to DIY Hardware