DCC Topics

Links

April 22 2012

Today I could make a perfect PCB for the 7 inch LCD module. This module will be the user interface for my future command station or Walkarround Cab.

Here is a picture of the 0.5mm pitch connector with 0.3mm wide tracks.

This was achived with a Samsung ML1675 Laser Printer and Epson Glossy Photo Paper.

You can see a video before etching the PCB here

http://www.youtube.com/watch?v=LfW6xtzn7Ck

 

April 15 2012

This has been more than a year I didn't update this site but there was 2 important reasons for that:

The first and most important is that my daugher was born last year and I like to be a dedicated father as my father was! and the second is that I was working on a side project to make 2 grahpics LCDs work. The main goal is to have a walkarround cab for my train control with a graphical interface.

It has been very hard because I had to learn about RGB and backlight circuits to make those lcd's work.

I want to share with you where I am right know with a 4.3 inch TFT driven by a PIC24FJ256DA206. Here you can see 2 videos where this LCD is working in some demos and some testing program. It hasn't any train control yet and I think this is going to take more time :)

http://www.youtube.com/watch?v=fAMdj_11A2c

http://www.youtube.com/watch?v=4pDBSaJ-xS8

 

March 26 2011

I've updated two of the most visited pages of this site thanks to Ray West from the UK that helped me to translate the Command station and Mobile DCC decoder.

You can visit the english version of those pages here

Command Station in english

Mobile dcc decoder in english

Thank you Ray for your efforts.

January 1st -2011

Hello all and happy new year!!!!

I began the year very very happy because I finally succeded in the RF circuits. My first goal was to build a remote controlled switch to turn on and off my outside lights that I had to turn on and off manually from outside.

In this project I had different obstacles like making to work a BIFA antenna that is printed on the PCB. I've never done that but following the instructions in the Silicon Laboratories website. It finally worked yesterday so my new year was very happy.

I will continue developing a more complex wireless protocol to comunicate tha base command station with the walkarround cabs. I will also work on driving a 2.4" color TFT display with 240x30 resolution to equip the cab control with brilliant graphics.

For any of you interested in the MRF49XA transceiver from Microchip please visit this link where I have the firmware for transmiter and reciver with their respective hardware. If you need more information or help please send me an email in the Contacts link.

Sept 06 - 2010

Hello all, I have succeded on the autoreverse and cutout module using the same principles of the www.merg.org.uk and now my loops are working good. I had to adjust the over current resistors (R5,R6, R16 and R17). The initial design is a 0.2 ohms resistor on each DCC line but the track impedance and long conection cables turned the circuit "insensible" and was unable to detect the short circuit. I canged it for a 0.5 Ohms and it's working fine now.

Download the PCB schematic here and read about the autoreverse project here.

August 31 2010

This is one of the most exciting day of my life after my marrige and my son's birth. I always wanted to comunicate 2 devices wirelessly and today I could send 3 bytes over the sxannmms 915 MHz band with my own circuit. I used the microchip MRF49XA that is a transmiter/receiver chip that can work on datarates up to 115 kbps. This is the first step to build a wireless control cab for my trains. I have a 4'x8' table and I wouldnt need that cab to work wireless but I wanted to so it was worth the 2 months working on that!.

If some one is interested on that project (simple at this moment) just send me an email.

July 27 2010

It´s been a long time I don't update this site but I've been working on the circuit to allow autoreverse in my two loops. I was trying to make an electronic circuit that was capable of reversing the loop in DC and DCC but it was unsuccesfull.

After making the decision of not working my layout in DC mode (for some old engines that will be dificult to install the decoder), I began to copy the MERG autoreverser and the last weekend I could test it successfully.

Here you can find information about the circuit and download the schematics in PDF.

February 14 2010

The progress of this project has been slowed down because of my new son that is 9 months old now. It's been very dificult to find time to work on this project as much as I would like but some progress have been made.

I'm working on a Radio Frecuency module using the MRF49XA from Microchip.com as a base for a wireless walkarround cab control. I have designed the PCB and soldered the components but havent tested the firmware yet.

Also I'm working on a serial LCD of 128x64 pixels to work with the wireless cab. I have the LCD working right now after a week or so trying to find a problem. The problem was because the datasheet didnt say if the chip enable pin had to be High or Low level.

 

October 25 2009

I finally could make my first SMT (Surface Mount Technology) PCB in my home using toner Transfer method. Here is a sample picture and you can read more in the PCB Link.

October 12 2009

This weekend I made the PCB (Printed Circuit Board) for an DC - DCC Autoreverser and block detector for my layout. The circuit should work like this :

  • It has a DC or DCC input from DC power pack or a DCC booster
  • It has 3 outputs for each one of my layout's blocks. The blocks are (main, loop 1 and loop 2)

  • When operating in DC mode ( I wanted backward compatibility for my layout because I still have lots of DC engines that I wont convert but I like to play with), the circuit is monitoring in which block is the engine running (only one for DC mode). When it detects a short circuits is because the train is entering or leaving a reverse loop and the receiving block must change the track polarity for the train to continue in the same direction as it was.
  • When operating in DCC, it is much simpler, because there is no need to check which block the train is entering and there is only needed to change one block polarity and the trains will always go in the same direction it was coming because direction is controlled by DCC decoder inside the engine.
  • This circuit also monitors a short circuit and keeps trying to reconnect the track for short periods of time until the short is corrected.

You can download the schematics here.

Here are some pictures of the PCB i just made using the Toner Transfer method. I used magazine paper instead of photo paper. I needed my board to be double side and it was really simple to align the both sides.

 

 

October 1 2009

After many many hours working with the DC and DCC reversing unit I came up with a design that should work. In DCC is very easy to implement a reverser unit because the dcc decoder is controlling the direction digitally. In DC is the polarity of the track what determines the direction of the engine so I had to divide my layout into 3 sections (one main track and 2 reversing loops) and detect what block is entering the engine and wich one is leaving. With that information, and an instant short will change the polarity of the receiving block. It can change the polarity also of the main block. The disadvantage is that I can only run one engine at a time in DC mode but in DCC there is no restriction for that.

I will post the schematics here in the next few days, but if anyone is interested on those files before I post them just write me to my email in the contact link.

September 28

I'm very happy because today a friend from England sent me pictures of the command station that he built using my schematics and firmware. Richard helped me correct somethings in the hardware schematics and software I haven't detected yet.

Also my friend Javier, from Argentina is working on a Command Station and he has it working now! He also taught me a method to build my own PCB (printed Circuit board). I havent build my first one but I hope do it soon.

Thank you Javier and Richard!

August 23 2009

I've been working on a DC - DCC autoreverse, cutoff and block detector circuit because I want my track to be able to operate in DC as well. There are some engines I wont be able to convert to DCC so I want to operate in DC mode. The circuit had taken me a lot of time because now I have to take care of my 3 months son. I found another hobby then!

I will be posting the circuit here when I have all the testing ready.

It is intended to control a 3 block DC - DCC layout. In DC mode it detects in wich block is the engine (only works with one engine in DC mode at this time and that's fine for my layout) and senses an electric short circuit. In that moment the controller changes the polarity of the receiving block allowing the engine to go in the same direction as it was.

 

I also worked on a timber trestle I always dremt to have. I wanted a big trestle in my layout but I didnt want to expend US$50 or more in a kit so I bought a book and builted this.

I have the plans for this curved trestle so if you want it please ask for it by e-mail.

July 8 2009

I've been working slow on the layout construction because I can only work on weekends.

Here is a video I took this weekend of the layout progress.

I've been also experimenting with sound. Now I've been able to record and reproduce digitally a horn for a diesel train. I hope I can share with you the DCC sound decoder once finished.

Youtube link : http://www.youtube.com/watch?v=Lm2FlSJtqpk

April 4 2009

I've been working a lot this months but on weekends I've worked on the track laying. It is almost done. The only thing I don't have yet laid down is the reversing loops of the track.

I will post photos the next week I hope.

I had some virus in this web pages. Thanks to Aoki Mioko from Japan I could find it and cleaned all the website files.

January 31st 2009

After one month away from my trains I finally started laying the roadbed and some track.

The roadbed is home made from a material used in the shoes industries and is called in spanish "Yumbolón". It's a 5 mm height foam sheet 1mt x 1mt. I cut strips about 2.5 inches wide and the edge was about 45 degrees like any commercial roadbed. The cost of all the roadbed for my layout was about US$2.

Here are some pictures of the layout:

 

24 december 2008 to 04 january 2009

I will be off for the next fifteen days due to hard work (until late january).

This holidays I've been working hard on the base assembly for my layout. It's been hard for me because all this wood work is new.

The bench work now has all the legs installed and the wheels are also in place. Now here comes the hard work!!! (i think!)

Dec 24:  
December 25: Cut the playwood modules and built some of the raisers
First day of 2009 : Installing the raisers
   
04 january : All the raisers are in place now. The height clearance is more than 3"
 

 

21 December 2008

It's almost Christmas and I'm still working hard in different approaches (Electronics, benchwork construction, scenery and many more)

Benchwork:

This weekend I finally assembled the wheels to the legs of the wood grid structure that will support my 4'x8' layout.

Scenery: I built the Old Coal Mine. This is Kit 316 from Model Power. Here are some pictures

I'm also making a Tunnel portal mold in latex. The portal is a Woodland Scenic HO portal that I'm trying to cast. This is my first mold ever so I hope it casts very good!!!!

This is the second coat of latex This is the fifth coat with a cheesecloth (gauze)
j

19 December 2008

I made some improvements to the Auto reverse unit to make it more "automatic" and now It will require less human attention. Here are the improvements:

  • The circuit can detect when the train enters the loop and the direction where it is heading with two optical sensors
  • It can throw the switch points to match the outgoing direction of the train when it reaches the other optical sensor.
  • The user can override the automatic control of the switch by throwing it with a Normal Open Switch.

The basic circuit is now on protoboard and is working good. The improvements hasn't been downloaded to the circuit yet. I hope Christmas brings more time!!!! jejeje.

I have to upload the software but if you need it just write me.

13 December 2008

I went to the home supply store and bought the playwood that will support my layout. I draw a 6" square grid on the playwood and followed the blueprint of my layout and here are some pictures of the track over the playwood just to mark it to cut it later with the saber saw.

 

30 November 2008

Now I have the Auto reverse and cutout module ready for testing. The microcontroller software is available if you send me an email to epareja @ dcctrains.xf-s.com. View the Auto reverse module description here.

 

 

22 November 2008

I started the final layout construction. It was hard to decide which layout I wanted and the benchwork planning was also hard to begin. Here are some pictures of the first step in benchwork construction.

You can see the process here

15 November 2008

It's been a month now that I have a double main track with yards to test the DCC command station and decoders. I've experienced the problems pointed in every DCC site: It's very important to have a good electrical contact between the rails for proper DCC operation. When I had electrical gaps, the decoders some times changed some of the Configuration Variables (CVs).

This is the layout I had:

Here are a video compilation of the DCC operations in this layout http://www.youtube.com/watch?v=gIDkDpzbB78

 

11 November 2008

Finally the server is up and running again. It was down since october 31. I setup another parallel web site: www.dcctrains.f-snet.com

 

3 November 2008

This weekend I worked on some improvements of the decoder:

  1. Implemented a motor PWM recalculation every valid packet received regardless if it was addressed to the decoder. This prevents some runaways I've had.
  2. CV6 implementation for setting up the motor. It only works on 128 speed step for now.
  3. Changed the PWM frequency (decreased it from 78Hz to 34 Hz) but have more PWM resolution (Before was 128 now 256). The motors I have seem to run smoother than before.

There are some things I'm planning but I need more information:

  1. I want to implement light effects like MARS, Dim, Strobe, etc but I need information on how they work in real life. Are they applied to the directional light or are applied to the additional function outputs? If you have information please send it to me at epareja @ dcctrains.xf-s.com
  2. Speed table discrete programming
  3. Implement a CV9 (PWM frequency configuration)
  4. Implement a Service Lock Decoder instruction as the R.P 9.2.4 Apendix B (www.nmra.org)

Also, with the changes I did to the software in October 28 the decoder isn't loosing its address and none of the EEPROM and RAM data anymore!!!. ALLELUYA!!!!

28 October 2008

I've been trying to find the hardware or software problem in the decoder but I haven't had a lot of success!!!! Sometimes the Decoder by itself changes some data in the Flash Memory, mostly the loco address. This weekend I almost threw my trains out of the windows but yesterday I was in better mood. I made some changes in the software and I haven't had any loco to loose its address but I can recall victory for now... I need a lot of more track testing but I'll keep you informed.

The software isn't updated in the download page. If you wish to take a look into it just email me at epareja (@) dcctrains . xf-s . com

05 October 2008

This weekend I converted other 2 engines. One is a Life Like diesel engine labeled GT, and the other is a Bachmann 4-4-0 American. It was a difficult to setup the decoder into the steam locomotor and other problem I had was to isolate the front light and connect it to the decoder. I had to use 2 black wires to camouflage with the engine pipes to be able to light the train. If you want more details you can contact me.

Here is the video I took with other 2 Bachmann DCC diesel engines.

01 October 2008

The Command Station had a problem with the startup when the DCC power supply was On. The microcontroler seemed to be blocked because some kind of short in the Mosfet Bridges. It happened if there was more than one loco on the track at the startup but if I added more engines to the track after booting there was no problem.

I tried to solve this problem in software adding some delays in the startup process but I couldn't solve it that way so I had to use some hardware aid that worked perfectly and will help to shut off the power to the track if the Mosfet bridge fails.

I added one N Channel mosfet between the H bridge and the power ground and it is enabled just after doing some dummies DCC cycles. Maybe it discharge the Mosfets gates.

This is the modification to the Booster Section of the Command Station. To download the complete schematic click here.

Booster

22 Sept 2008

After completing the layout track plan this weekend I got back to the DC problem for my decoder and today I finally got the problem solved. The problem was that when applied a DC signal, the decoder only responded in one direction. If the DC signal was inverted the decoder became acting with very fast intermittence. I found that when the DC signal ground was applied to the input resistor to the Microcontroller (RB3), the capture interrupt for detecting a DCC signal were triggered and the PIC became going from DC to DCC and back.

The solution was very simple (but It was hard to find). In the capture interrupt (CCP1), I placed an additional check to see if the capture time was much more than DCC timing. If it was more than DCC timing, including the 0 time, the interrupt won't take any DCC action and the DC routine will handle the Light and motor control.

I updated the software in the download section.

20 Sept 2008

I left apart the DCC stuff for a while because I'm having some sporadic problems I cant resolve for now, so I decided to plan the track I'm going to build. My first layout had to be with a lot of tracks in a small space for running my DCC when ready. You can see the track plan here

8 Sept 2008

I made some mayor improvements to the decoder software:

- Prevent the decoder from blocking when the engine pass through a dirty track

- Function 1 now implemented to drive another light or the steam tank if desired.

There is another video in this link http://www.youtube.com/watch?v=lEeTEkZlzrk

3 Sept 2008

This is the first trip of the Tyco Chatanogga now powered with DCC. I had to place extra rail pickups for better performance.

This is my Alco 420 Spirit with the DCC decoder installed.

1 Sept 2008

I built the first decoder and IT WORKED!!!!!! It was difficult to solder Surface Mount Devices but I made it.

Here are some pictures:

 
 
 
 

 

25 August 2008

I just received the printed circuit board I designed. I'm so excited about it!!!!!!! I can't wait to build one and test it. Hope it works!!!!

Here are some pictures

Bottom Side
Top Side

 

May - 2008

I finally built the first mobile decoder that works. It was a little big but fitted on my Life - Like Alco 420 as you may see in the pictures below. This circuit uses the approach of a L272 (Dual Op Amp) described in the Loco Decoder page.

 

This circuit uses a processor base for prototyping and was a little over height so I made another approach soldering the processor directly to the board. To do this I had to place a SIP connector for programming In Circuit (ICSP - In Circuit Serial Programming). The connector is in the left side of the picture.