Jump to content
 

eldavo

RMweb Premium
  • Posts

    1,258
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by eldavo

  1. The analogue ports can be used as digital ports. If I recall correctly you can simply refer to them by symbolic names i.e. digitaRead(A1) to access analogue 1. I have come across some peculiarities (sorry can't remember the details) in using them but generally they work fine. If you run into problems using them as digital you can wire in a pullup to 5volts and then have the switch connect to 0volts and use a simple comparison to see if the analogue value is less than some magic number like 300. In fact thinking about it you probably have to use an external pullup if you use them as digital ports. Cheers Dave
  2. That's a bit of a b*gg3r Big G. At least you are missing golf while it's cold, wet and muddy! Hang in there buddy and we'll see you on the fairways in the spring sunshine. Cheers Dave
  3. There are non-blocking servo libraries, precisionServo is one (I think), that allows you to issue an instruction to a servo then go off and do something else. Cheers Dave
  4. Work has progressed on the electrical plumbing and fitting of servo control boards and relay modules. Of course that means I have to set up a production line for the 17 odd control boards I need. Initially I've used a technique I've used several times before i.e. printing the board layout onto glossy paper then heat transferring the image onto the copperclad then etching. The example in the previous post was made in this way but was a pretty poor job. So how many ways are there to create a circuit board? If you search with Google you find several... When you get the laser toner transfer technique right the results are very good with even pretty tiny text coming out. It's a bit of a hit and miss process though and I probably only get 75% first time results. The holes also have to be hand drilled. So how about using a cheapo Chinese 3 axis CNC machine to mill out the tracks directly and drill the holes. As I have one of these machines I had to have a go. Several folks have published helpful stuff on the net and there are some pretty impressive results on display. It's not simple! There are quite a few settings to get right and you need to ensure the machine can "probe" the copperclad surface and adjust for tiny variations in the Z height. You would think that looking at a bit of copperclad only 30x30mm that it's flat but it isn't. I'm trying to mill off just 0.1mm so a tiny bit of bend in the copperclad and it won't work. Luckily although the machine I have doesn't have a Z probe the control board has the necessary connections for one. A couple of bits of wire and a pair of crocodile clips and we are in business. A handy bit of software, openCNCpilot, has a built in capability that can probe the surface you are going to use then adjust the gcode used for cutting the tracks to take into account the height differences. Cool or what? So I had to give it a try. This example was created using a 60 degree 0.1mm V cutter and is usable, just! The cutter has gone too deep especially when cutting the pilots for the holes. I think I know what setting I had wrong so I may well give it another try. I did produce 2 usable boards in this way after wrecking a lot of copperclad and breaking a few milling tools. Thinking about the main problem of the original etching process, transferring the ink to the copper reliably, I looked for a better way. Of course somebody else had already investigated something interesting, etching the barrier layer with a laser. My CNC machine has a 6 watt laser attachment so this needed trying out. I cleaned up a bit of copperclad and sprayed it with Matt black paint, just ordinary rattle can stuff. I then used a modified version of the milling gcode to blast it with the laser. After washing off the burnt paint the board was etched and produced the result at the top below. Usable but not great. The drilling marks didn't come out so drilling was a bit pot luck. Next attempt I exported the board layout as an image then opened it in LaserGRBL and set up to raster etch with the laser. This produced a fairly good result and this etched pretty well, even some of the text came out. Spot the deliberate mistake... ... it's a mirror image. Doh! I redid this without the mirroring and it's a perfectly usable board. Not sure I've found a "best" way of producing these things but I now have 11 working boards so I have made some progress and learned quite a lot. Cheers Dave
  5. For those that need the details here is the the schematic for the servo driver using the ATtiny85... The 5 volt supply and switch input connector on the left, the servo connector is on the right and the 2 pin connector bottom right is the 2 pins that need to be shorted to reverse the direction of throw. On the left you can see the 2 LEDs and their current limiting resistors. The 10uF capacitor provides a modicum of filtering/smoothing on the power supply to the chip though as these boys can run on as little as 2.7 volts hopefully it should be fairly stable. The only other component is a 10k resistor pulling up the servo control signal to help with resilience to electrical noise. Prototype number 2 has been duly etched. It's not pretty! Drilled and soldered up it doesn't look much better... It looks ok from the top though and it works! Cheers Dave
  6. I've used OpenSCAD for a few things and as a programmer I find it fairly simple to use. I haven't attempted to use it for complex items like rolling stock but for bits of buildings etc. it's good. I would expect things to start getting pretty messy with larger things as everything tends to get nested. You can break things into components though and it has a very useful feature for extruding a 2D drawing. My current favourite is Designspark Mechanical which is available from RS components for free. Never have managed to get my head round Blender despite many tries. I suspect I'm just too impatient and hate going through tutorials. :-) Cheers Dave
  7. Slow progress as ever, getting distracted by other stuff. I have knocked together some very basic underframe details for the Clayton coach.... It needs footboards making and fitting now which is just about my least favourite job so don't expect it to get done anytime soon! Of course stalling on that project meant I actually made some progress on other things I had been putting off. It's decision time on how to control the point servos. On previous layouts I've made extensive use of Arduino boards and experimented with fancy communications busses etc. This time I've decided to take a slightly simpler approach and I don't really need a full-blown Arduino. I've been experimenting with the ATtiny85 chip. These are smaller relatives of the chip at the centre of an Arduino board that have just 8 pins and much less memory. To drive a single servo you really don't need much so they are fully up to the job. You can use the Arduino development environment to write the program but as the chip has no bootloader code on it you have to use a programming device to actually get code installed. Luckily you can use an Arduino and a few wires to do this. I knocked up a prototype on a bit of veroboard to test out the idea... It's pretty simple, 2 resistors and a small capacitor. One of the resistors is actually redundant as I can use a built-in pullup resistor. The polarised input connector and servo connector take up a good chunk of the board. The device will be fed from a 5volt supply and to switch the servo a control wire is clamped to 0 volts. I tested this board with the servos I have mounted on the baseboards and it seems to work just fine. Bouyed by the success I cracked on and created a circuit board layout using Eagle CAD and etched up a prototype. This has a couple of extra features to make installation and fault finding easier. There is a red LED to indicate the board has power and a green LED to indicate the control wire is activated. Also you can reverse the direction of throw of the servo by momentarily shorting two pins. Here is the prototype mounted under a baseboard along with a relay unit for switching the frog polarity of the turnout. Conveniently the relay unit operates from the same 0 volt control line. Anyone would think there was a plan! I'm not going to show the underside of the board as I made a couple of mistakes in the design so it's lash-up with jumpers! I've revamped the layout so will produce another one to see if I've got it right this time. I've increased both the size of the tracks and the separation of them so I might be able to produce this version on my 3 axis CNC machine rather than having to etch and hand drill. We shall see. Cheers Dave
  8. If you search for "Arduino relay shield" you will find a number of options including both "shield" modules that plug onto an Arduino Uno and also very cheap relay units that can be driven from any Arduino with the minimum of wireing. Cheers Dave
  9. Still not really cracking on with layout things but still fiddling with 3D printer bits. The 12 ton open wagon body has now received a printed underframe, or at least most of one... It's not a great fit to the wagon body but that is due to some distortion that came about because of the way I printed the body. I could have simply reprinted the body but where's the challenge in that. It'll just have to be finished as a rather battered example. The coach has gained a basic printed underframe along with printed bogeys... The bogeys are pretty simple without too much detail and are printed as just 3 parts. As with most things I build, these are mostly an example of the capabilities of modern adhesives rather than examples of engineering excellence! I really must get on and do some work on the trackwork and/or wiring... maybe. Cheers Dave
  10. Mr. Philarding, you have books on Midland things?!! Of course I'll give them a good home if you're still fixated on those green wheel slippy things. Must meet up sometime when we are allowed out to play again. ;-) Cheers Dave
  11. The new 3D printer has inspired me to sort out my turnout operating issues. A bit of searching on the interweb revealed a number of servo mounts and other bits that almost provided a solution but not quite. So in my normal way I've picked up on other people's ideas and modified them to do what I want. Initially I was looking for a servo mount that converted the rotary motion of the servo into linear to drive the cable conduit TOUs. I still need that sort of scheme for a couple of the turnouts but I decided to build something that does the whole job. An hour or so with my favourite CAD program, Design Spark Mechanical, and I have something that seems to do the job. The servo mount is made up of 3 parts that are printed straight onto the build plate of the printer. There is a base which holds the servo, a slider and a lid. A little bit of light filing to remove the "elephants foot" (the extra width of the first few layers of the print) from the slider, drill our the screw holes and we are ready to go. The servo is fitted with a single ended crank which in turn has a 12BA screw fitted through the first hole. A smidgeon of copper tube is dropped over the end of the screw to reduce friction. The servo then simply clips into the base with the screw/tube bit slotted into the slider... The two mounting screws that come with the servo are then used to secure the lid which holds everything together... To operate the turnout there are two holes in the slider unit which are opened out and lengths of copper tube fitted and secured with the merest spot of superglue. All is now ready to go.. Finally a shot of one fitted under the baseboard... It works fine when attached to my servo tester so I think I may be moving forward again at last. Cheers Dave
  12. Been a bit quiet on this thread as I rather lost my mojo for the project after having some problems with my turnout operating bits. A break from the project was needed and per chance somebody asked me to do some programming for some train simulator bits. This also had the benefit of putting some cash in my hand which led me to upgrade my 3D printing arsenal. I've acquired an Anycubic Mono and a curing station. I have to say I'm very impressed with it and it was up and running 10 minutes after being unpacked. I've been using the Wanhao Duplicator 7, on the right of the picture above, for a year or two with pretty good results but it's never been the easiest device to use and has become less and less reliable and now has an intermittent fault with the HDMI display leading to unrecognisable lumps of resin instead of clean models! The Anycubic printer is on the left with the 'wash and cure' machine in the middle. The latter is not essential but it certainly makes life easier and less messy. The first proper model railway item off the printer is a complete 7mm wagon body. Not surprisingly it's a Midland prototype. Can't really print anything much bigger on this machine. This was printed in Eryone water washable resin and I am very impressed with the sharpness of the print and lack of any kind of lines or dips due to Z wobble. Bolstered by this success I embarked on printing some bits for a 7mm coach. The Midland very conveniently built whole ranges of coaches with standard sized compartments so a while ago I created the CAD files for Clayton bogey coaches from the 1880s to 1890s. These have printed quite well though you can't see that as they are in clear resin! Each compartment is complete with floor and interior and locating lugs so, after a little cleaning, simply glues to it's neighbour. In the background the wagon body has had a blast of primer. Below is the complete D502 brake third coach body assembled and after a little bit of filling and filing of joints and a blast of primer. In the background is a Slater's kit version of an all third from the same family. A bit more work on the joints required and some handrails before it goes for a coat of red oxide then some red topcoat. I printed the end steps but these are far too brittle so I need to do some work and replace with some brass bits. Also need gas pipes etc. Onwards Cheers Dave
  13. LED battens would be my choice Gordon. We used them on the Winchester club's Redbridge layout hung about 3'6" above the boards and they give very good even lighting. Cheers Dave
  14. This layout is going to need a name soon. Unfortunately some of the wonderful ideas I came up with have already been used by others so I may have to resort to awful puns! Could end up being "Pandemdale" or "Covidale". I'm still pushing on with track building and have now completed the 3 point complex on the exit curve. Again severe treatment with a razor saw was required to deal with board joints and application of suitable weights while glue dried. I've also been looking at how to operate the pointwork and have hacked together some turnout operating units (TOUs) from stuff in the workshop. Basically I've used two sizes of cable conduit, some lengths of brass tube and a bit of wire... The smaller section sits inside the larger one and can slide from side to side... The point blades each have an interestingly bent piece of wire soldered to them. This provides a stub to which I can afix a stretcher bar and also extends down below the baseboard. The bends cause the wire to sit underneath the stock rail to stop the switch rail lifting. The brass tubes on the TOU fit over the wires and the outer part of the TOU is glued to the underside of the baseboard. A servo can the be arranged in another section of cable conduit with a bit of scrap brass etch providing a fulcrum for a length of spring wire. Sophisticated or what? Above the baseboard a length of wire insulation is glued to the stub ends of the actuator wires to act as a stretcher bar. The mechanism is pretty inconspicuous... As always all these ideas have been ripped off from others. Lots still to do. Cheers Dave
  15. Progress is slow but there is some. I still haven't finished fitting stretcher bars to the double slip so that hasn't been laid yet. Nothing like a bit of prevarication. I have built an enclosure for the CNC machine so I don't have to be wearing fetching green dark glasses all the time it's busy doing stuff. I included an extractor fan system so the workshop doesn't fill up with smoke which helps considerably! The laser is not overly powerful and doing multiple pass cuts was causing a lot of charring and a wider than desirable kerf so I've added a rudimentary air assist jet which seems to help. I knew rescuing that old Proxon compressor from the skip was a good move 5 years ago. The machine has now helped produce quite a lot of point timbers and the permanent way team has been busy building a curved crossover and the point that forms one end of the only runround loop. These O gauge point complexes are awfully big and use a scary amount of materials. Still a lot to do but I'm having a rest from Butanone fumes for a while. Cheers Dave
  16. Apart from being distracted by other things like golf, bowls and drinking beer I have managed to complete the double slip, almost! It still needs stretcher bars which is a job I have carefully been putting off. I should get on and sort this job out so the beast can be stuck down to the baseboard and I can move on to the next challenge. Unfortunately I have to build another one which will sit to the right of the loco in the picture above. Ho hum there is nothing like a challenge. Cheers Dave
  17. Guest operators? I thought that was only a myth when it came to ET! Very smart panel. Cheers Dave
  18. Thanks for the help Martin. I'll see what I can sort out when I next need some point timbering i.e. when I've finished the double slip on my workbench! Cheers Dave
  19. That looks very interesting Martin. I looked at the DXF export but couldn't see a way of using it for what I'm trying to do. The DXF as it stands has the sleeper outlines in the positions, and at the angles, they will be laid. Also it looks as if the sleeper end lines are longer than the width of the the sleeper. What I would like to do is get the number off and length of sleepers in a template, as you have it in your post, so that I can programmatically generated a DXF, or other format, file where they are laid out to efficiently cut from an A5 or A4 sheet of ply with a laser cutter. I could do this from the existing DXF with some juggling around but it's a bit fiddly. If I could get hold of the raw data it would make the job much much easier. Cheers Dave
  20. I've been pushing on with track building. The next turnout on the build list was a tandem which took several hours of work to build. After carefully getting everything right it's just a tad scary to fix it down on the baseboards and then cut it in half with a razor saw! I carefully considered the position of all the turnouts with respect to the baseboard framing but of course some of them were bound to fall across baseboard joints. While building this I realized just how many chairs and sleepers are involved. I've exhausted my initial order of chairs and have just one pack of point timbering left. The tandem turnout took 2 complete packs of turnout timbers due to its length. It dawned on me this was going to be an expensive game if I bought in all the components. A "back of a fag packet" calculation led me to investigate buying a laser cutter to produce my own 1.5mm sleepers. I ended up buying a cheapo Chinese generic 3 axis CNC machine with a 5.5watt laser attachment. I need to build an enclosure for it with an extractor fan but I believe it will work out cheaper doing it this way and of course I'll have a laser cutter to use for creating buildings etc. I bought a pack of 10 A5 sheets of 1.5mm laser friendly ply. Cutting a sheet into 7mm strips was the first test. Cutting up one sheet has given me enough timbers for the next turnout building challenge, a 1 in 8 double slip. If I could figure out a way of extracting the timber sizes from a Templot template I could save materials and time. All good fun. Cheers Dave
  21. Thinking some more it probably needs a bit of fiddling as Martin suggested to take into account of the case where there is no route selected through P1 i.e. traffic is running from for 1 through P2. Hmmm Cheers Dave
  22. My initial thought was I would put 4 LEDs along P1 section wired as 2 pairs. I would feed each pair from the normal and reverse LED feeds of the points at the relevant end. If you include a diode in each feed it will stop it feeding back into the uppowered output. After writing that though I realize it's complete rubbish and all that will do is give you 4 LEDs permanently lit. Doh! The simple solution is to wire 3 or 4 LEDs in series and feed them 12 volts. You should probably include a 1K ohm resistor to limit the current further and dim them down a bit. Cheers Dave
×
×
  • Create New...