LED counter

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

iNVERTED
Route Supervisor
Route Supervisor
Posts: 387
Joined: 24 Apr 2005 21:21
Location: Torquay, England
Contact:

Re: LED counter

Post by iNVERTED »

Back to more practical things, after being inspired by Tjark's setup I've made a rather more aesthetically pleasing load distributor, using two NOT gates of my own design:
circuitry.png
The one in the bottom right is exactly the same, just using minimal space at the cost of a tiny bit of symmetry.

My idea was to ensure that, once a train enters one of the "presignal blocks" (two possible routes past the entry double combo signals on the mainline), that signal should stay red and the signal for the alternate block should go green ASAP. The processing is just fast enough to make this happen before the mainline train gets into the next block - I originally had the two presignal blocks only two squares long, but at that length it was JUST possible (depending on when the train arrived) for the signals to not switch over. Thankfully, the processing is also fast enough to make the main signal green in time for the next train.

Now all I need is a three-way load distributor as well (though thinking about it, it shouldn't be too hard...)
Vitus
Traffic Manager
Traffic Manager
Posts: 157
Joined: 11 Mar 2009 15:15

Re: LED counter

Post by Vitus »

Sorry to say that, but you didn't come up with something new. :) Those kind of splitters (called flip-flops) are pretty common on #openttdcoop servers. Actually, one whole game was based on them - alongside with other "train" logic (PSG#180).

If you wish to learn more about that, I suggest you to read this blog entry.

On topic:
I was playing with some LED counters few weeks ago and came up with this. It's newer version of my calculator, but now with LED input and output. I was also thinking about including something kind of binary->decimal converter, but I guess it's not really effective when you operate with numbers from 0 up to 18 (and I'd have to design the converter, that's it :D ). If you have any questions, don't hesitate to ask.
Attachments
calc2.sav
Calculator v2
(84.3 KiB) Downloaded 190 times
Radicalimero
Engineer
Engineer
Posts: 23
Joined: 02 Dec 2009 17:06

Re: LED counter

Post by Radicalimero »

CharlyHRO wrote:I'm impressed. And I'm waiting for the day, someone made a working x86 virtual machine with MGA graphics, at least one serial port, a parallel port and ... we call it the "OpenTTD Workstation". Well, what mapsize do we need for a complete x86 machine? And how fast would it be?

Or, wait. I see the headline of a newspaper in some years. "AMD sponsored 5 million USD for the development crew of OpenTTD". Somewhere in the text it says, AMD uses OpenTTD to plan the layout of future CPUs :D
i have made a "simple" calculator, it can only add 4 bits with 4 bits, but it is posible to expand it... but it will take some time to do it. It is really compact, but i think if you want to expand it further you should make it less compact so inserting trains will be easier.

it would be nice if we could have the 5 million USD for development :wink:

EDIT: used latest nightly 19783
Attachments
4 bit add.sav
openTTD calculator
(45.08 KiB) Downloaded 180 times
Image
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: Amazon [Bot] and 7 guests