Updates
The 3D printable files for RC truck are published!. The link is on project page, and for convenience also here:
The easiest and, seemingly, most widespread DIY way to add audio effects to a layout is with the help of MP3 module with microSD card slot. These cheap modules play mp3 files from uSD card and Next/Play/Stop controls are provided by GPIO pins, so you can control them with buttons or Arduino. They also come with UART so that Arduinos can get a list of files on the card and select the file to be played.
However, this functionality is often not sufficient for advanced sound effects. In particular, 2 features would be very useful for a layout, but are not possible with a MP3 module:
Mixing of several audio tracks together.
Gapless playback of several consecutive sounds. This feature can be used to create looping playback and transition one sound to another.
With these capabilities, we can implement, for example, locomotive engine sound:
Start of an engine
Run with idle engine sound for indefinite duration,
Transition to 1st gear,
Run with 1st gear indefinitely,
Mix with a coupler sound,
Mix with horn,
… and so on
Or, for example, we can play ocean waves sound in loop and mix it with occasional seagulls and wooden screeching.
Or we can play a campfire sound with occasional forest birds, owls, wolf howl.
The library is located here: https://github.com/earlephilhower/ESP8266Audio and it allows you to write a program that will itself read audio data from a defined source, mix and/or process it, and send it to an audio device. Despite the name, it can run on ESP8266, ESP32 and RP2040 MCUs.
It can decode WAV data, in addition to MP3, AAC, MIDI, MOD, and can read files from the firmware itself, internal flash, SD card and even internet. It can send data to an I2S amplifier or to a single-transistor amplifier circuit, which is probably enough for our needs.
For the purposes of a diorama layout, WAV data and internal flash (or SD card) is enough.
The library allows to play several sources simultaneously, setting volume for each source independently.
The idea is that a simple continous sound has a beginning portion, middle portion looping continously and ending portion:
Simplified state machine diagram of this can look like this:
A more advanced continous sound effect can be represented by a more complex state diagram. Here is a simplified diagram of a 2-gear diesel engine. The transitions are controled by current locomotive speed.
Locomotive decoders with sound (such as ESU LokSound) play sounds in a similar fashion, and their sound editors allow users to edit the state diagram and respective samples.
So, we can implement this in code of our MCU and make it play different sounds for each state and move through states according to some input, and we’ll get realistic continous sounds.
The 3D printable files for RC truck are published!. The link is on project page, and for convenience also here:
Continuing on BLE-RC transmitter.
I’ve created a page for the development of the transmitter. Expect updates there. So far I’ve created a breadboard prototype that is able to c...
I finally made a video about RC kit project:
Another issue of "Useful parts", this time about TWS headphones.
BLE-RC firmware
Bodywork
A latest video of state of the project (mid-august):
There were no updates for a long time due to my vacation, but finally here are some.
I’ve recently encountered spring-loaded pogo pins for PCB testing.
The crane mechanics is close to completion
Last time I tried to pur solder into a hand-cut cardboard "mold". The result was as inaccurate as one would expect. My attempts to smooth it out with epoxy...
So, the JLCPCB and LCSC orders were made on April 28.
In portal crane project the hook has to be as heavy as possible, otherwise the threads will not be tightened enough and will skip all the time (and will l...
For some time I’ve wanted to develop a PCB again. Last time I did that was around 2021, when I made LocoNet-equipped decoder and command station for...
Any functional crane model obviously requires a winch (or two).
The functional crane model I’m working on requires a slip ring to rotate superstructure. Currently this is implemented as a 3D-printed casing for bron...
So, here is what I’ve been doing for the past 2 months.
A new project is released on this website and on Printables (thingiverse and cults will follow soon).
So, finally an update on what I am currently doing.
I have finally started to work on assembling 11T750 wagon for Soyuz rocket train.
Making cargo for a gondola ended up being longer than printing the gondola itself. I had some sticks and branches lying around, that I cut to length and g...
This weekend I’ve done a short project, which was printing a gondola (model 12-1592) car in HO scale.
HO scale train bogie for FDM and resin printers.
Flatcar series 13-401 project now has photos of finished objects!
A new project: Flatcar series 13-401. A model of a flat wagon, which is widespread in USSR, Russia and other 1520mm guage countries.
I’ve assembled, primed, sanded and painted second container variant (frame2). Here are the pictures (along with frame1 variant). New variant is in red.
This week I’ve added one more tank into my tank container collection, codename frame2. It turned out to be much more complicated that previous design...
This week I’ve reworked my older tank container into a collection of different options, so they add some variety to the layout. For now, there are 2 ...
A 3D-printed powered chassis for 2-axle locomotives.
Making realistic continuous and polyphonic sound effects