fosstodon.org is one of the many independent Mastodon servers you can use to participate in the fediverse.
Fosstodon is an invite only Mastodon instance that is open to those who are interested in technology; particularly free & open source software. If you wish to join, contact us for an invite.

Administered by:

Server stats:

8.6K
active users

#arduinouno

1 post1 participant0 posts today
Simple DIY Electronic Music Projects<p><strong>Arduino and SP0256A-AL2 – Part&nbsp;2</strong></p><p>After getting the <a href="https://diyelectromusic.com/2025/08/03/arduino-and-sp0256a-al2/" rel="nofollow noopener" target="_blank">Arduino and SP0256A-AL2</a> working I wondered if I could repeat the trick from the <a href="https://diyelectromusic.com/2025/07/05/arduino-and-ay-3-8910/" rel="nofollow noopener" target="_blank">Arduino and AY-3-8910</a> and have the Arduino generate the required clock signal for the SP0256A-AL2. This post starts to look at that question.</p><p><a href="https://makertube.net/w/paGX4eiCAHgLU9mK2x3uyq" rel="nofollow noopener" target="_blank">https://makertube.net/w/paGX4eiCAHgLU9mK2x3uyq</a></p><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>If you are new to Arduino, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>Parts list</strong></p><ul><li>Arduino Uno</li><li>SP0256A-AL2 speech synthesizer chip</li><li>2x 1KΩ resistors</li><li>2x 100nF capacitors</li><li>1x 1uF capacitor</li><li>1x 3.5mm jack socket</li><li>Breadboard and jumper wires</li></ul><p><strong>The Circuit</strong></p><p>This is basically the same setup as the previous post, but instead of the 3.579345 MHz oscillator, the clock input of the SP0256A-AL2 is connected to the Arduino D10 pin.</p><p>D10 is internally connected to OC1B, or the “B” compare match output of Timer 1 of the ATMega328P.</p><p><strong>The Code</strong></p><p>To get a clock signal of any kind on one of the output pins requires use of the ATMega328’s timers – in this case Timer 1. This is a 16-bit timer.</p><p>To generate an automatic (i.e. with no code driving it once it is set up) square wave signal on the Arduino’s output pin requires the timer to be connected to an output pin to generate a 50% duty cycle PWM signal.</p><p>The PWM peripherals can be configured to toggle an output pin when the timer expires, but that therefore requires the PWM to be running at least twice as fast as the required frequency.</p><p>From the SP0256A-AL2 datasheet, it has this to say about clocks.</p><p>There isn’t a lot to go on here – basically it assumes a 3.12MHz clock with a 48-52% duty cycle for the square wave.</p><p>A typical application circuit would be the following (again from the datasheet):</p><p>And the final word on oscillators is in the pin descriptions:</p><p>The options for creating a 3.12 MHz clock with an Arduino PWM output are pretty limited, due to the following:</p><ul><li>The faster clock for PWM is related to the system IO clock speed of 16MHz, when running with no “prescalar” to drop it down in frequency.</li><li>When running at 16MHz, lower frequencies are obtained by using the “compare match” approach. The timer will reset and the output pin will toggle when a counter match occurs. The counter will count in integer units of the core 16MHz frequency.</li><li>As the output pin will toggle on compare match, the timer must run at twice the frequency of the required clock signal. This allows one period for a HIGH output and one period for a LOW output to generate the required square wave output.</li></ul><p>The PWM square wave frequency is given by the following formula (as per the ATMega328P datasheet for Timer 1,3,4):</p><ul><li>Freq = FreqClk / (2 * prescalar * (OCR1B + 1))</li></ul><p>Given the above, with a FreqClk of 16MHz, the following are the only real options for a PWM-driven square wave as a clock for this application:</p>OCR1B compare valueResulting clock frequency08 MHz14 MHz22.7 MHz32 MHz41.6 MHz51.3 MHz<p>So there isn’t a lot of choice, and nothing particularly close to the required 3.12 MHz, although 2.7 MHz is the closest and would probably do if required.</p><p>To configure the above requires the following code:</p><pre>#define SP0_CLOCK 10 // D10<br>void clockSetup () {<br> pinMode(SP0_CLOCK, OUTPUT);<br> digitalWrite(SP0_CLOCK, LOW);<br><br> TCCR1A = (1 &lt;&lt; COM1B0);<br> TCCR1B = (1 &lt;&lt; WGM12) | (1 &lt;&lt; CS10);<br> TCCR1C = 0;<br> TIMSK1 = 0;<br> OCR1AH = 0;<br> OCR1AL = 1;<br>}</pre><p>This configures Timer 1 in Clear-Timer-on-Compare (CTC) mode with no prescalar, toggling OC1B on compare match with the value in OCR1A.</p><p>Note: even though there are two pin outputs – OC1A on D9 and OC1B on D10 – which is used is determined by the COM1A/COM1B settings. Even when using OC1B, as I am here, it is still the match value in OCR1A that determines when the counter has reached its “top” value.</p><p>I updated the code to try each of the above values for OCR1A in turn and the result is the video at the start of this post.</p><pre>void setClock (int clock) {<br> OCR1AH = 0;<br> OCR1AL = clock;<br>}</pre><p><strong>Closing Thoughts</strong></p><p>It is interesting to note that the Arduino can in fact provide a clock that allows the SP0256A-AL2 to function, even if it is not particularly true to the original at this point.</p><p>But it does mean that there isn’t as much control over the pitch as I’d hoped. If I want to get to more of that granularity between 4 MHz and 2 MHz, I’ll have to find another way.</p><p>Kevin</p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/sp0256a-al2/" target="_blank">#sp0256aAl2</a></p>
Simple DIY Electronic Music Projects<p><strong>Arduino and SP0256A-AL2</strong></p><p>Having had a bit of a play with the <a href="https://diyelectromusic.com/2025/08/02/sp0256a-al2-speech-synthesis/" rel="nofollow noopener" target="_blank">SP0256A-AL2 Speech Synthesis</a> chip, this post looks at how to drive it directly from an Arduio.</p><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>If you are new to Arduino, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>Parts list</strong></p><ul><li>Arduino Uno</li><li>SP0256A-AL2 speech synthesizer chip</li><li>3.579545 crystal oscillator</li><li>2x 1KΩ resistors</li><li>2x 100nF capacitors</li><li>1x 1uF capacitor</li><li>1x 3.5mm jack socket</li><li>Breadboard and jumper wires</li></ul><p><strong>The Circuit</strong></p><p>This is based on several other circuits I’ve found, and reading through the datasheet:</p><ul><li>Arduino + Vintage Speech Chip Instructable: <a href="https://www.instructables.com/Arduino-Vintage-Speech-Chip/" rel="nofollow noopener" target="_blank">https://www.instructables.com/Arduino-Vintage-Speech-Chip/</a></li><li>MG005 Speech Synthesizer for RC2014: <a href="https://jerryfrost1.wixsite.com/tech/blank-page-4" rel="nofollow noopener" target="_blank">https://jerryfrost1.wixsite.com/tech/blank-page-4</a></li></ul><p>Here are the required connections for the SP0256A-AL2 to the crystal, output circuit and the Arduino:</p>GND1: VSSOSC 2: 28GNDRESET2: /RESETOSC 1: 27Crystal OUTN/C3: ROM DISABLEROM CLOCK: 26N/AN/C4: C1/SBY RESET: 255VN/C5: C2DIG OUT: 24Audio FilterN/C6: C3VDI: 235V5V7: VDDTEST: 22GNDD98: SBYSER IN: 21N/CN/C9: /LRQ/ALD: 20D8GND10: A8SE: 195VGND11: A7A1: 18D2N/C12: SER OUTA2: 17D3D713: A6A3: 16D4D612: A5A4: 15D5<p>The datasheet suggests a PWM filter comprising 33K resistors and 22nF capacitors. This creates a significant amount of filtering but results in a very low output signal. The datasheet pushes the output of the filter into an amplifier as shown below.</p><p>But for my messing around, I was happy to compromise a little on the filter in order to have a stronger output signal. So I used two 1K resistors and two 100nF capacitors in my filter stage and then connected it directly to a 3.5mm jack socket.</p><p>I’m also using a square, 3.579545 crystal oscillator connected to OSC 2, with OSC 1 connected to GND. The pinout of the oscillator is often listed as if it was the four corner pins of an 8-pin DIP package, so pins 1, 4, 5 and 8, with a “dot” next to pin 1, when oriented with the dot to the top left. The pin usage is as follows:</p><ul><li>Pin 1: squared corner next to the dot: not connected</li><li>Pin 4: GND</li><li>Pin 5: Oscillator output</li><li>Pin 8: VCC</li></ul><p>As I’ve fixed A7 and A8 to GND, A1 to A6 can map directly onto D2 to D7 which are the 6 higher bits of PORTD on an ATMega328P. Recall that D0 and D1 are the UART, so I’ll be leaving those free.</p><p>I originally had /RESET tied permanently to 5V but I was finding the chip wouldn’t always start properly and sometimes got stuck, so I tied it directly to RESET on the Arduino and it seemed to work a lot more reliably at that point.</p><p><strong>The Code</strong></p><p>The code is relatively straight forward. I need a list of the allophones, which I provide via a series of <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/define/" target="_blank">#define</a> statements, and a list of the corresponding delays between them, which I provide in an array of 16-bit values, using the allophone number as the index.</p><p>I’m using direct PORT IO to access the data/A lines of the SP0256A-AL2. This involves shifting the allophone number left by 2 bits to avoid clashing with the UART on D0/D1, whilst preserving the values in D0/D1.</p><p>I’ve written two macros, one to handle a write via PORTD and one to check for the STBY signal via D9 on PORTB.</p><pre>#define pinALD 8<br>int pinA[6] = {2,3,4,5,6,7}; // Use direct PORT IO<br>#define SP_OUT(addr) {PORTD = (PIND &amp; 0x03) | ((addr)&lt;&lt;2);}<br>#define pinSTBY 9<br>#define SP_CHK() ((PINB &amp; 0x02)!=0x02)</pre><p>The algorithm required to set an allophone is determined from the datasheet as follows:</p><pre>WAIT for STBY signal to go HIGH<br>Set the data on A1-A6 (A7 and A8 are left at GND)<br>Toggle the /ALD line LOW for between 0.2 and 1.1mS<br>Wait for the allophones allotted delay</pre><p>Once again, a sequence of allophones can be determined using the methods described previous in <a href="https://diyelectromusic.com/2025/08/02/sp0256a-al2-speech-synthesis/" rel="nofollow noopener" target="_blank">SP0256A-AL2 Speech Synthesis</a>.</p><p><a href="https://github.com/diyelectromusic/sdemp/tree/main/src/SDEMP/ArduinoSP0256A-AL2" rel="nofollow noopener" target="_blank">Find it on GitHub here</a>.</p><p><strong>Closing Thoughts</strong></p><p>It is great to get this working with an Arduino. One thing I’d like to try, is to see if I can clock the chip using the PWM output of the Arduino, in the same way as I did with the AY-3-8910. If so, then I might be able to experiment with varying the clock, which might have some interesting results.</p><p>I’d also like to get all this onto a shield PCB at some point too and then I get on to those musical ideas.</p><p>Kevin</p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/define/" target="_blank">#define</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/sp0256a-al2/" target="_blank">#sp0256aAl2</a></p>
Simple DIY Electronic Music Projects<p><strong>Arduino with Multiple Displays – Part&nbsp;2</strong></p><p>As I mentioned in my last post on <a href="https://diyelectromusic.com/2025/07/19/arduino-with-multiple-displays/" rel="nofollow noopener" target="_blank">Arduino with Multiple&nbsp;Displays</a> I’m going to look at other microcontrollers too. This post takes a wander through my <a href="https://diyelectromusic.com/2025/02/17/waveshare-zero-pimoroni-tiny-and-neopixels/" rel="nofollow noopener" target="_blank">Waveshare Zero and similar</a> format boards that each support one of the RP2040, ESP32-C3 or ESP32-S3.</p><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>These are the key Arduino tutorials for the main concepts used in this project:</p><ul><li><a href="https://diyelectromusic.com/2025/07/19/arduino-with-multiple-displays/" rel="nofollow noopener" target="_blank">Arduino with Multiple&nbsp;Displays</a></li><li><a href="https://emalliab.wordpress.com/2025/07/19/small-microcontroller-displays/" rel="nofollow noopener" target="_blank">https://emalliab.wordpress.com/2025/07/19/small-microcontroller-displays/</a></li></ul><p>If you are new to microcontrollers, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>Parts list</strong></p><ul><li>A Waveshare Zero format board or similar</li><li>2x 0.96″ ST7735 60×180 SPI TFT displays.</li><li>Breadboard and jumper wires.</li></ul><p>Once again I’m using displays that look like this – note the order of the pins.</p><p><strong>The Circuit</strong></p><p>All circuits are a variation on the above, requiring the following ideal connections:</p>DisplayFunctionRP2040ESP32-C3ESP32-S3BLKBacklight control<br>(not required)N/CN/CN/CCSChip select<br>One per display.5 or any SPI0 CS1010DCData/Command888RESReset1499SDAData (MOSI)3 or any SPI0 MOSI6 or 711SCLClock (SCLK)2 or any SPI0 SCLK4 or 612VCCPower3V33V33V3GNDGroundGNDGNDGND<p>For the explanations of the pin choices, and what it means for the code, see the following sections.</p><p><strong>ESP32-S3 Zero</strong></p><p>In the Arduino IDE, using board ESP32-&gt; Waveshare ESP32-S3-Zero.</p><p>There are several SPI buses on the ESP32-S3, but they have fixed uses as follows (see the ESP32-S3 Technical Reference Manual Chapter 30 “SPI Controller”):</p><ul><li>SPI 0: Reserved for internal use.</li><li>SPI 1: Reserved for internal use.</li><li>SPI 2: General purpose use – often called FSPI in the documentation.</li><li>SPI 3: General purpose use – often called SPI or SPI3.</li></ul><p>Sometimes the two SPI buses are called VSPI and HSPI but I think that is really terminology from the original ESP32 rather than the ESP32-S3.</p><p>The ESP32 Arduino core for the <a href="https://github.com/espressif/arduino-esp32/blob/master/variants/waveshare_esp32_s3_zero/pins_arduino.h" rel="nofollow noopener" target="_blank">Waveshare ESP32-S3 Zero variant</a> defines the following:</p><pre>// Mapping based on the ESP32S3 data sheet - alternate for SPI2<br>static const uint8_t SS = 34; // FSPICS0<br>static const uint8_t MOSI = 35; // FSPID<br>static const uint8_t MISO = 37; // FSPIQ<br>static const uint8_t SCK = 36; // FSPICLK</pre><p>By default the Adafruit libraries will use the boards default SPI interface, as defined in the variants.h file – i.e. the above.</p><p>When it comes to assigning SPI devices to GPIO there are a few considerations (see the “ESP32-S3 Technical Reference Manual, Chapter 6 “IO MUX and GPIO Matrix”):</p><ul><li>In general, any GPIO can be mapped onto any SPI function. However…</li><li>Some GPIO have special “strapping” functions so are best avoided.</li><li>Some GPIOs have a default SPI function that bypasses the GPIO MUX routing, so allows for better performance (see section 6.6 “Direct Input and Output via IO MUX”).</li></ul><p>From my reading of the reference manual I believe the following are default “non-MUX” SPI connections:</p><p>In the previous table, where SPI3 is mentioned, then the entry for “Direct IO via IO MUX” is set to “no”, so I’m guessing that isn’t available.</p><p>But now we can see why the Arduino core is using GPIO 34-37, but we can also see that GPIO 10-13 would be an alternative (fast) option too.</p><p>The problem is that not all of GPIO 34-37 are broken out on a Waveshare ESP32-S3 Zero, so I need to use the alternative pinouts. Aside: this makes no sense to me that these are the defaults in the Waveshare ESP32-S3 Zero’s “variant.h” file, but anyway…</p><p>To use a different SPI interface requires using a constructor that passes in an initialised SPI instance. There is an example in the ESP32 core for setting up multiple SPI buses here: <a href="https://github.com/espressif/arduino-esp32/blob/master/libraries/SPI/examples/SPI_Multiple_Buses/SPI_Multiple_Buses.ino" rel="nofollow noopener" target="_blank">https://github.com/espressif/arduino-esp32/blob/master/libraries/SPI/examples/SPI_Multiple_Buses/SPI_Multiple_Buses.ino</a></p><p>This leads to the pins as defined in the previous table, and the code below to setup one of the displays.</p><pre>#include &lt;Adafruit_GFX.h&gt; // Core graphics library<br>#include &lt;Adafruit_ST7735.h&gt; // Hardware-specific library for ST7735<br>#include &lt;SPI.h&gt;<br><br>#define SPI_SS 10<br>#define SPI_MOSI 11<br>#define SPI_SCLK 12<br>#define SPI_MISO 13<br>SPIClass MySPI(FSPI);<br><br>#define TFT_CS SPI_SS<br>#define TFT_RST 9<br>#define TFT_DC 8<br>Adafruit_ST7735 tft = Adafruit_ST7735(&amp;MySPI, TFT_CS, TFT_DC, TFT_RST);<br><br>void setup() {<br> MySPI.begin(SPI_SCLK, SPI_MISO, SPI_MOSI, SPI_SS);<br> pinMode(SPI_SS, OUTPUT);<br> tft.initR(INITR_MINI160x80_PLUGIN);<br>}</pre><p><strong>ESP32-C3 Zero</strong></p><p>In the Arduino IDE, using board ESP32-&gt; ESP32C3 Dev Module.</p><p>Again there are several SPI buses on the ESP32-C3, with the same fixed uses as follows (see the ESP32-C3 Technical Reference Manual Chapter 30 “SPI Controller”):</p><ul><li>SPI 0: Reserved for internal use.</li><li>SPI 1: Reserved for internal use.</li><li>SPI 2: General purpose use – sometimes called GP-SPI in the documentation.</li></ul><p>The ESP32-C3 also has a very similar SPI arrangement to the ESP32-S3, in that whilst any pin can be configured for SPI usage, there are certain hard-wired optional arrangements that bypass the GPIO routing matrix.</p><p>The faster (direct to IO MUX) pins are as follows (<a href="https://docs.espressif.com/projects/esp-idf/en/latest/esp32c3/api-reference/peripherals/spi_master.html#gpio-matrix-and-io-mux" rel="nofollow noopener" target="_blank">more here</a>):</p><ul><li>CS0 – 10</li><li>SCLK – 6</li><li>MISO – 2</li><li>MOSI – 7</li></ul><p>Curiously, the <a href="https://github.com/espressif/arduino-esp32/blob/master/variants/esp32c3/pins_arduino.h" rel="nofollow noopener" target="_blank">general ESP32-C3 Arduino variant</a> defines them as follows:</p><pre>static const uint8_t SS = 7;<br>static const uint8_t MOSI = 6;<br>static const uint8_t MISO = 5;<br>static const uint8_t SCK = 4;</pre><p>From the Technical Reference manual, we can see that the default Arduino definitions above, do not support the non-routed, direct-to-IO MUX pin mappings, which from the table below do indeed map onto GPIO 2, 6, 7, 10.</p><p>In terms of using a Waveshare ESP32-C3 Zero, both combinations would be supported on the broken out GPIO, so from a software point of view, the Adafruit libraries could be used “as is” with the default mapping, or with a custom SPI definition (as shown above) with the more bespoke, but faster, mapping.</p><p><strong>RP2040 Zero</strong></p><p>This is using the (unofficial) RP2040 core from here: <a href="https://github.com/earlephilhower/arduino-pico" rel="nofollow noopener" target="_blank">https://github.com/earlephilhower/arduino-pico</a>, where this is an entry: RP2040 -&gt; Waveshare RP2040 Zero.</p><p>The RP2040 has two SPI peripherals and the SPI functions are mapped onto specific sets of GPIO pins. This gives a range of flexibility, but not arbitrary flexibility. The board definition file for the Waveshare RP2040 Zero provides this as a default:</p><pre>// SPI<br>#define PIN_SPI0_MISO (4u)<br>#define PIN_SPI0_MOSI (3u)<br>#define PIN_SPI0_SCK (2u)<br>#define PIN_SPI0_SS (5u)<br><br>#define PIN_SPI1_MISO (12u)<br>#define PIN_SPI1_MOSI (15u)<br>#define PIN_SPI1_SCK (14u)<br>#define PIN_SPI1_SS (13u)</pre><p>Note that the SPI1 pins for the Waveshare RP2040 Zero are not all on the standard header connections, some are on the additional pin headers across the bottom.</p><p>Using a bespoke configuration is possible using a series of calls to set the SPI pins as shown below.</p><pre> SPI.setRX(SPI_MISO);<br> SPI.setCS(SPI_SS);<br> SPI.setSCK(SPI_SCLK);<br> SPI.setTX(SPI_MOSI);<br> SPI.begin(true);</pre><p>To use pins for SPI1, replace SPI above with SPI1. As long as this happens prior to the call to the Adafruit libraries, everything works fine.</p><p><strong>A Common Option</strong></p><p>It would be nice to find a set of physical pin connections that I know would always work regardless of the board in use: RP2040, ESP32-S3 or ESP32-C3.</p><p>With careful noting of the RP2040 limitations, I think that is largely possible with the following. Even though the GPIO numbers are different, the physical pins are common on all three boards.</p>DisplayFunctionWS PinRP2040ESP32-C3ESP32-S3BLKBacklight control<br>(not required)N/CN/CN/CCS1Chip select<br>Display 1H2 P6GP5GP9GP10DCData/CommandH2 P5GP4GP10GP11RESResetH2 P9GP8GP6GP7SDAData (MOSI)H2 P8GP7GP7GP8SCLClock (SCLK)H2 P7GP6GP8GP9VCCPowerH1 P33V33V33V3GNDGroundH1 P2GNDGNDGNDCS2CS Display 2H1 P9GP14GP5GP6CS3CS Display 3H1 P8GP15GP4GP5CS4CS Display 4H1 P7GP26GP3GP4<p>A couple of notes:</p><ul><li>I’ve avoided pins 1-4 on header 2, as the ESP32-C3 can’t use them for SPI and they support either the UART or USB.</li><li>I’ve had to include a MISO (SPI RX) pin in each configuration too, so I’ve just picked something that can be ignored. For RP2040 that has to be one of GP0, GP4 or GP16 however, which could clash with either the UART, the above configuration for DC pin, or the onboard WS2812 LED, but there isn’t much that can be done.</li><li>I’ve allowed three consecutive pins on the first header for optional additional CS pins for displays 2 to 4.</li></ul><p>Here is the full set of configurable code for the above:</p><pre>#include &lt;Adafruit_GFX.h&gt; // Core graphics library<br>#include &lt;Adafruit_ST7735.h&gt; // Hardware-specific library for ST7735<br>#include &lt;SPI.h&gt;<br><br>//#define WS_RP2040_ZERO<br>//#define WS_ESP32C3_ZERO<br>#define WS_ESP32S3_ZERO<br><br>#ifdef WS_RP2040_ZERO<br>#define SPI_SS 5<br>#define SPI_MOSI 7<br>#define SPI_SCLK 6<br>#define SPI_MISO 4 // Not used<br>#define SPI_BUS SPI<br>#define TFT_CS1 SPI_SS<br>#define TFT_CS2 14<br>#define TFT_CS3 15<br>#define TFT_CS4 26<br>#define TFT_RST 8<br>#define TFT_DC 4<br>#endif<br><br>#ifdef WS_ESP32C3_ZERO<br>#define SPI_SS 9<br>#define SPI_MOSI 7<br>#define SPI_SCLK 8<br>#define SPI_MISO 0 // Not used<br>SPIClass MySPI(FSPI);<br>#define TFT_CS1 SPI_SS<br>#define TFT_CS2 5<br>#define TFT_CS3 4<br>#define TFT_CS4 3<br>#define TFT_RST 6<br>#define TFT_DC 10<br>#endif<br><br>#ifdef WS_ESP32S3_ZERO<br>#define SPI_SS 10<br>#define SPI_MOSI 8<br>#define SPI_SCLK 9<br>#define SPI_MISO 1 // Not used<br>SPIClass MySPI(FSPI);<br>#define TFT_CS1 SPI_SS<br>#define TFT_CS2 6<br>#define TFT_CS3 5<br>#define TFT_CS4 4<br>#define TFT_RST 7<br>#define TFT_DC 11<br>#endif<br><br>#ifdef WS_RP2040_ZERO<br>Adafruit_ST7735 tft1 = Adafruit_ST7735(TFT_CS1, TFT_DC, TFT_RST);<br>Adafruit_ST7735 tft2 = Adafruit_ST7735(TFT_CS2, TFT_DC, -1);<br>#else<br>Adafruit_ST7735 tft1 = Adafruit_ST7735(&amp;MySPI, TFT_CS1, TFT_DC, TFT_RST);<br>Adafruit_ST7735 tft2 = Adafruit_ST7735(&amp;MySPI, TFT_CS2, TFT_DC, -1);<br>#endif<br><br>void setup() {<br>#ifdef WS_RP2040_ZERO<br> SPI_BUS.setRX(SPI_MISO);<br> SPI_BUS.setCS(SPI_SS);<br> SPI_BUS.setSCK(SPI_SCLK);<br> SPI_BUS.setTX(SPI_MOSI);<br> SPI_BUS.begin(true);<br>#else<br> MySPI.begin(SPI_SCLK, SPI_MISO, SPI_MOSI, SPI_SS);<br> pinMode(SPI_SS, OUTPUT);<br>#endif<br><br> tft1.initR(INITR_MINI160x80_PLUGIN);<br> tft2.initR(INITR_MINI160x80_PLUGIN);<br> tft1.setRotation(3);<br> tft1.fillScreen(ST77XX_BLACK);<br> tft2.setRotation(3);<br> tft2.fillScreen(ST77XX_BLACK);<br>}<br><br>void loop() {<br> unsigned long time = millis();<br> tft1.fillRect(10, 20, tft1.width(), 20, ST77XX_BLACK);<br> tft1.setTextColor(ST77XX_GREEN);<br> tft1.setCursor(10, 20);<br> tft1.print(time, DEC);<br> delay(100);<br><br> time = millis();<br> tft2.fillRect(10, 20, tft2.width(), 20, ST77XX_BLACK);<br> tft2.setTextColor(ST77XX_MAGENTA);<br> tft2.setCursor(10, 20);<br> tft2.print(time, DEC);<br> delay(400);<br>}</pre><p><strong>Closing Thoughts</strong></p><p>It is a little annoying that these great boards don’t share a re-usable, common pinout in terms of naming and positions, but I guess that isn’t the main focus for these systems.</p><p>Still, it seems that a common hardware pinout can be made that supports many displays, which is great, as I’d really like to get a number of them onto a PCB!</p><p>Kevin</p><p></p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/esp32c3/" target="_blank">#esp32c3</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/esp32s3/" target="_blank">#ESP32s3</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/rp2040/" target="_blank">#rp2040</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/st7735/" target="_blank">#st7735</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/tft-display/" target="_blank">#tftDisplay</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/waveshare-zero/" target="_blank">#WaveshareZero</a></p>
Simple DIY Electronic Music Projects<p><strong>Arduino with Multiple&nbsp;Displays</strong></p><p>A while back I tried to use several SSD1306 displays with an Arduino (see <a href="https://diyelectromusic.com/2020/10/30/oled-midi-display-part-2/" rel="nofollow noopener" target="_blank">OLED MIDI Display – Part&nbsp;2</a>) and got into trouble with memory. I have another need for multiple displays coming up, so thought I’d revisit the idea to see what could be done.</p><p>This shows use to use several cheap SPI-based displays together with an Arduino.</p><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>These are the key Arduino tutorials for the main concepts used in this project:</p><ul><li><a href="https://learn.adafruit.com/adafruit-mini-tft-0-dot-96-inch-180x60-breakout/overview" rel="nofollow noopener" target="_blank">Adafruit Mini TFT 0.96″ 160×80</a></li><li><a href="https://github.com/adafruit/Adafruit-ST7735-Library" rel="nofollow noopener" target="_blank">Adafruit ST7735 GFX Library</a></li><li><a href="https://emalliab.wordpress.com/2025/07/19/small-microcontroller-displays/" rel="nofollow noopener" target="_blank">https://emalliab.wordpress.com/2025/07/19/small-microcontroller-displays/</a></li></ul><p>If you are new to Arduino, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>Parts list</strong></p><ul><li>Arduino Uno.</li><li>2x 0.96″ ST7735 60×180 SPI TFT displays.</li><li>Breadboard and jumper wires.</li></ul><p>I’m using displays that look like this – note the order of the pins.</p><p><strong>The Circuit</strong></p><p>The display pins are connected to the Uno as follows:</p>BLKN/CBacklight control – not requiredCSD10/D7Chip select – one for each display.DCD8Data/CommandRESD9ResetSDAD11Data (MOSI)SCLD13Clock (SCLK)VCC5VPowerGNDGNDGround<p>Notes:</p><ul><li>I’m using the Arduino Uno’s hardware SPI peripheral so the use of D11/D13 is fixed and can’t be changed.</li><li>All signals apart from CS are shared between both boards.</li><li>However – need to ensure that the boards are only reset once!</li></ul><p><strong>The Code</strong></p><p>There are several software libraries that could be used for these kinds of displays. I’m using the Adafruit libraries:</p><ul><li>Adafruit_GFX</li><li>Adafruit_ST7735_Library</li></ul><p>These aren’t always ideal for generic no-name displays as they are geared up to support Adafruit products directly.</p><p>A case in point: there is no generic initialisation for a ST7735 display, but rather a number of bespoke initialisations that relate to Adafruit’s range of displays only. I was looking for some means of setting the display size (160×80) but that isn’t possible.</p><p>But as it happens, there are two initalisation options that map onto the above boards:</p><pre>#include &lt;Adafruit_GFX.h&gt; // Core graphics library<br>#include &lt;Adafruit_ST7735.h&gt; // Hardware-specific library for ST7735<br>#include &lt;SPI.h&gt;<br><br>#define TFT_CS1 10<br>#define TFT_CS2 7<br>#define TFT_RST 9<br>#define TFT_DC 8<br><br>//#define TFT_TYPE INITR_MINI160x80<br>#define TFT_TYPE INITR_MINI160x80_PLUGIN // Inverted display<br><br>Adafruit_ST7735 tft1 = Adafruit_ST7735(TFT_CS1, TFT_DC, TFT_RST);<br>Adafruit_ST7735 tft2 = Adafruit_ST7735(TFT_CS2, TFT_DC, -1);<br><br>void setup() {<br> tft1.initR(TFT_TYPE);<br> tft2.initR(TFT_TYPE);<br>}</pre><p>Notes for this initialisation code:</p><ul><li>The use of pins D11 and D13 for SPI is assumed, and RST and DC are common.</li><li>I’m using the “INITR_MINI160x80_PLUGIN” initialisation option which is the same as “INITR_MINI160x80” but with the colours inverted. Without this, the built-in colour options aren’t correct for my boards.</li><li>Notice how in the second initialisation I’m using “-1” as the RESET pin so that the first display isn’t reset again after being initialised.</li><li>Both instances have their own CS pin defined.</li><li>The resolution and display size is fixed at 160×80.</li></ul><p>In my case I also used setRotation(3) to rotate the displays by 180 degrees.</p><p>Here is my complete test code that prints the current millis() count to each display in a different colour.</p><pre>#include &lt;Adafruit_GFX.h&gt; // Core graphics library<br>#include &lt;Adafruit_ST7735.h&gt; // Hardware-specific library for ST7735<br>#include &lt;SPI.h&gt;<br><br>#define TFT_CS1 10<br>#define TFT_CS2 7<br>#define TFT_RST 9<br>#define TFT_DC 8<br><br>//#define TFT_TYPE INITR_MINI160x80<br>#define TFT_TYPE INITR_MINI160x80_PLUGIN // Inverted display<br><br>Adafruit_ST7735 tft1 = Adafruit_ST7735(TFT_CS1, TFT_DC, TFT_RST);<br>Adafruit_ST7735 tft2 = Adafruit_ST7735(TFT_CS2, TFT_DC, -1);<br><br>void setup() {<br> tft1.initR(TFT_TYPE);<br> tft2.initR(TFT_TYPE);<br> tft1.setRotation(3);<br> tft1.fillScreen(ST77XX_BLACK);<br> tft2.setRotation(3);<br> tft2.fillScreen(ST77XX_BLACK);<br>}<br><br>void loop() {<br> unsigned long time = millis();<br> tft1.fillRect(10, 20, tft1.width(), 20, ST77XX_BLACK);<br> tft1.setTextColor(ST77XX_GREEN);<br> tft1.setCursor(10, 20);<br> tft1.print(time, DEC);<br> delay(100);<br><br> time = millis();<br> tft2.fillRect(10, 20, tft2.width(), 20, ST77XX_BLACK);<br> tft2.setTextColor(ST77XX_MAGENTA);<br> tft2.setCursor(10, 20);<br> tft2.print(time, DEC);<br> delay(400);<br>}</pre><p><strong>Closing Thoughts</strong></p><p>This is a really good start. What I’d like to do is see how far I can push it, see how many displays it is possible to hook up, and what the overheads of updating them might be.</p><p>Then depending on where that leaves me, I can have a think about if I need an alternative microcontroller, like a RP2040 or ESP32 – something with several cores might be particularly useful for this – and see how things go.</p><p>Then I can start to think about the musical uses I have in mind.</p><p>Update: It seems to work with four displays too. I’ve attached two 1.8″ ST7735 displays just to try it (these are “INITR_18BLACKTAB” displays). See photo below!</p><p>Kevin</p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/include/" target="_blank">#include</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/st7735/" target="_blank">#st7735</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/tft-display/" target="_blank">#tftDisplay</a></p>
Blort™ 🐀Ⓥ🥋☣️<p>QUICK PAID OPPORTUNITY HELPING ANSWER A BASIC ARDUINO QUESTION</p><p>My friend is desperately trying to finish making their kids birthday present based on an Arduino project found online.</p><p>They're offering $20 USD per 10 minutes ($120/hr!) for someone to get on a quick Jitsi call with them asap and just tell them what wire needs to be attached where.</p><p>They're basically on step 2 of building this:<br><a href="https://www.instructables.com/Rat-Operated-Vehicle/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://www.</span><span class="ellipsis">instructables.com/Rat-Operated</span><span class="invisible">-Vehicle/</span></a></p><p>...inspired by <span class="h-card" translate="no"><a href="https://io.mwl.io/@mwl" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>mwl</span></a></span> 's <a href="https://ratoperatedvehicle.com" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="">ratoperatedvehicle.com</span><span class="invisible"></span></a>.</p><p>It's using an Arduino Uno compatible board (from an Elegoo Robot Car v4).</p><p>Please DM me so I can put you in touch, or forward / boost to help reach someone who can help. :)</p><p><a href="https://social.tchncs.de/tags/Arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Arduino</span></a> <a href="https://social.tchncs.de/tags/Maker" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Maker</span></a> <a href="https://social.tchncs.de/tags/RatCar" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>RatCar</span></a> <a href="https://social.tchncs.de/tags/PetRats" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>PetRats</span></a> <a href="https://social.tchncs.de/tags/Electronics" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Electronics</span></a> <a href="https://social.tchncs.de/tags/Elegoo" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Elegoo</span></a> <a href="https://social.tchncs.de/tags/ArduinoUno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoUno</span></a> <a href="https://social.tchncs.de/tags/FOSS" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>FOSS</span></a> <a href="https://social.tchncs.de/tags/BoostOK" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>BoostOK</span></a></p>
Simple DIY Electronic Music Projects<p><strong>Atari 2600 Controller Shield PCB Revisited – Part&nbsp;3</strong></p><p>Following on from <a href="https://diyelectromusic.com/2025/06/22/atari-2600-controller-shield-pcb-revisited-part-2/" rel="nofollow noopener" target="_blank">Atari 2600 Controller Shield PCB Revisited – Part&nbsp;2</a> someone on Mastodon made the point that the reason they tended to use RC circuits to read paddles “back in the day” was due to the expense of ADCs.</p><p>Which triggered a bit of an “oh yeah” moment.</p><p>The whole point was not to worry about the analog levels at all, and just measure the time it takes for the pin to read HIGH again.</p><p>So this looks back at removing the whole ADC thing with a simple “if (digitalRead(pin))” condition!</p><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>If you are new to Arduino, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>The Code</strong></p><p>The overarching principles are the same as for <a href="https://diyelectromusic.com/2025/06/22/atari-2600-controller-shield-pcb-revisited-part-2/" rel="nofollow noopener" target="_blank">Atari 2600 Controller Shield PCB Revisited – Part&nbsp;2</a> but instead of all the bespoke code to read the analog to digital converter, I’m relying on the following:</p><ul><li>A digital input pin has a threshold for which the input is considered HIGH.</li><li>We can wait for the input reading to register as HIGH instead of looking for absolute thresholds of an analog value.</li><li>For an ATMega328P the threshold is 0.6 x VCC or around 3V. This is equivalent to just over 610 on a 0 to 1023 scale of an equivalent analog reading.</li></ul><p>Taking this into account and using largely the same ideas as before, I can reuse most of the code but with the following timing and threshold values instead:</p><ul><li>Start scaling (the 0 point): 10</li><li>End scaling (the 1023 point): 350</li></ul><p>The timer TICK is still 100uS and the “breakout” point is still 1000.</p><p>When it comes to reading the digital INPUT, I’m using PORT IO once again for speed and expediency.</p><pre>for (int i=0; i&lt;4; i++) {<br> if ((PINC &amp; (1&lt;&lt;i)) == 0) {<br> // Still not HIGH yet<br> }<br>}</pre><p>Here is the complete, now greatly simplified, basic code:</p><pre>#include &lt;TimerOne.h&gt;<br><br>#define RAW_START 10<br>#define RAW_END 350<br>#define RAW_BREAK 1000<br>#define RAW_TICK 100<br><br>unsigned padState;<br>unsigned padCount[4];<br>unsigned atariValue[4];<br><br>void atariAnalogSetup() {<br> Timer1.initialize(RAW_TICK);<br> Timer1.attachInterrupt(atariAnalogScan);<br> padState = 0;<br>}<br><br>void atariAnalogScan (void) {<br> if (padState == 0) {<br> DDRC = DDRC | 0x0F; // A0-A3 set to OUTPUT<br> PORTC = PORTC &amp; ~(0x0F); // A0-A3 set to LOW (0)<br> padState++;<br> } else if (padState == 1) {<br> DDRC = DDRC &amp; ~(0x0F); // A0-A3 set to INPUT<br> for (int i=0; i&lt;4; i++) {<br> padCount[i] = 0;<br> }<br> padState++;<br> } else if (padState &gt; RAW_BREAK) {<br> for (int i=0; i&lt;4; i++) {<br> atariValue[i] = 1023 - map(constrain(padCount[i],RAW_START,RAW_END),RAW_START,RAW_END,0,1023);<br> }<br> padState = 0;<br> } else {<br> for (int i=0; i&lt;4; i++) {<br> if ((PINC &amp; (1&lt;&lt;i)) == 0) {<br> padCount[i]++;<br> }<br> }<br> padState++;<br> }<br>}<br><br>int atariAnalogRead (int pin) {<br> return atariValue[pin-A0];<br>}<br><br>void setup() {<br> Serial.begin(9600);<br> atariAnalogSetup();<br>}<br><br>void loop() {<br> Serial.print(padState);<br> Serial.print("\t[ ");<br> for (int i=0; i&lt;4; i++) {<br> Serial.print(atariAnalogRead(A0+i));<br> Serial.print("\t");<br> Serial.print(padCount[i]);<br> Serial.print("\t][ ");<br> }<br> Serial.print("\n");<br>}<br></pre><p><strong>Closing Thoughts</strong></p><p>Sometimes one really can’t see the “wood for the trees” and this was one of those occasions. I was so took up with thinking about how a modern system might think about a problem without thinking about the original reason for the particular solution.</p><p>It makes so much more sense thinking about it in these terms now. All it took was an observation from another, namely:</p><p><em>“So I know the RC timer is the classic way to sense analog paddles but they also didn’t have cheap ADCs back then.”</em></p><p>Many thanks “Chip” for that observation 🙂</p><p>Kevin</p><p></p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/atari/" target="_blank">#atari</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/atari2600/" target="_blank">#atari2600</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/include/" target="_blank">#include</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/potentiometer/" target="_blank">#potentiometer</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/ticks/" target="_blank">#TICKs</a></p>
Simple DIY Electronic Music Projects<p><strong>Using a Cheap 5V MIDI Interface at&nbsp;3V3</strong></p><p>I had a query about using one of the common Arduino MIDI Shields with an ESP32 and when I looked into it, this is where I got to.</p><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>If you are new to Arduino, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>Parts list</strong></p><ul><li>Arduino Uno MIDI Shield</li><li>ESP32 or other 3V3 microcontroller</li><li>1x 22KΩ, 1x 33KΩ resistors for MIDI IN</li><li>1x 10Ω, 1×30Ω resistors for MIDI OUT</li><li>Breadboard and jumper wires</li></ul><p><strong>Arduino MIDI Shield</strong></p><p>These shields are available very cheaply and designed to plug directly onto an Arduino Uno. They are a variation of an original Olimex open source design (<a href="https://www.olimex.com/Products/Duino/Shields/SHIELD-MIDI/open-source-hardware" rel="nofollow noopener" target="_blank">details here</a>) but details of the specifics of this shield seem pretty sparse. But it isn’t too complex to figure out.</p><p>Essentially it is a 6N139-based 5V MIDI IN circuit and a non-buffered 5V MIDI OUT and THRU. The boards include a switch to cut off RX from MIDI to allow for sketch uploading. There is often a footprint for a button for RESET which may or may not be populated, and there is a block of breakout connectors for all the Arduino’s IO pins.</p><p>I did eventually happen upon an uncredited schematic in a random online cloud service file storage, so I’ve copied it over here.</p><p>And mapping this over to the board itself I found this PCB diagram. Note this has a URL for “soliddigi” on it, but that doesn’t seem to exist (or do anything) that I could see.</p><p>But whilst on the topic of this board, we can map out the IO pin breakouts for future reference too by simply examining the underside of the board:</p><p>From this we can see the following pinouts for the board.</p><p>Anyway, back to MIDI…</p><p><strong>Converting MIDI IN</strong></p><p>The output (to the Arduino) from the MIDI IN circuit of this board is a UART RX connection pulled high to 5V. The easiest way to drop that to 3V3 for use with a 3V3 logic system is to use a resistor divider as shown below.</p><p>The MIDI shield will still need to be powered by 5V but the output from the RX pin will now be dropped by the ratio 33K/(22K+33K) which is approximately 0.6. So 5V x 0.6 = 3V.</p><p>The choice of resistor for this specific application is relatively arbitrary as it is the ratio that is important, but it should be remembered that this is connecting both the optoisolator’s output (RX) and the microcontrollers IO pin (GP19 above) to GND so there will be limits on the amount of current that can be sourced from the two IO pins and that can be sunk into GND.</p><p><strong>Converting MIDI OUT</strong></p><p>Converting MIDI OUT isn’t quite so easy unfortunately. If the MIDI interface had included a buffer, like the 74HCT14 I’ve used in the past, then no conversion would be necessary – a 3V3 logic signal can drive that directly and the output would be a 5V signal to the rest of the MIDI circuit.</p><p>But it doesn’t – it is a directly connected 5V-expecting MIDI OUT circuit involving two 220Ω resistors. If this is driven from a 3V3 level then it is unlikely that there would be enough current to drive the optoisolator at the other end of the MIDI link.</p><p>The basic calculation goes as follows (see my <a href="https://diyelectromusic.com/2021/05/29/midi-connections-cheat-sheet/" rel="nofollow noopener" target="_blank">MIDI Connections Cheat&nbsp;Sheet</a> for details of the circuits) – this assumes one 220Ω resistor on the receiving side and two on the sending side as per the MIDI spec, and a typical 1.7V drop across the optoisolator.</p><p>For 5V operation, from Ohm’s law: Current = (5 – 1.7) / (220+220+200) = 5mA</p><p>For 3V3 operation: Current = (3.3 – 1.7) / (220+220+200) = 2mA</p><p>This is why the MIDI spec recommends 10Ω and 30Ω resistors for a 3V3 logic OUT circuit:</p><p>For proper 3V3 operation: Current = (3.3 – 1.7) / (220+30+10) = 6mA</p><p>Really, the easiest method, assuming the MIDI connectors/hardware are required to be used “as is” would be to include a 74HCT14 (the HCT variant, not the HC version) as a buffer by passing the 3V3 signal through two of the inverters.</p><p>But at this point, as this is just a couple of resistors, I’d probably look to remove the two 220Ω resistors in the OUTPUT circuit and attempt to patch in a 10Ω and 30Ω instead with the 30Ω pulling up to 3V3 rather than 5V.</p><p><strong>Patching the Shield</strong></p><p>Given all the above, I believe it is possible to patch this shield to support 3V3 logic operation by performing the following:</p><ul><li>Remove R3 and R4.</li><li>Cut the track to the RX Pin.</li><li>Add 10Ω between MIDI OUT R3 connector and TX.</li><li>Add 33Ω between MIDI OUT R4 connector and 3V3.</li><li>Add 22KΩ between RX and the centre pin of the ON/OFF switch (check this with a meter though – it was the middle pin for me!).</li><li>Add 33KΩ between RX and GND.</li></ul><p><strong>WARNING: <em>All of this is theoretical. I’ve not actually done it myself.</em></strong></p><p>Step 1: Remove R3, R4, cut RX track.</p><p>Step 2: Add resistors.</p><p>Note: I don’t believe that anything has to be done to the THRU as it is taken directly off the RX side of the 6N139, so that will continue to work (as I understand things) off the 5V circuit directly.</p><p><strong>Closing Thoughts</strong></p><p>Given the number of off-the-shelf 3V3 MIDI boards now available, I suspect in most cases acquiring one directly would be the better option to the above.</p><p>But having said that, these boards are available so cheaply and widely that it is worth considering. Also, there are 3V3 logic level boards in Uno form factor, so having a 3V3 version of the shield would be useful in any case.</p><p>But I repeat, other than testing the resistor divider on RX, I’ve not tested any of the modifications to the board itself. Do let me know if you’re brave enough to give it a go 🙂</p><p>At some point I might make my own 3V3 Uno format shield PCB…</p><p>Kevin</p><p></p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/esp32/" target="_blank">#esp32</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/midi/" target="_blank">#midi</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/midi-shield/" target="_blank">#midiShield</a></p>
Pyrzout :vm:<p>Building a 3D-Printed Strandbeest <a href="https://hackaday.com/2025/01/16/building-a-3d-printed-strandbeest/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2025/01/16/buildi</span><span class="invisible">ng-a-3d-printed-strandbeest/</span></a> <a href="https://social.skynetcloud.site/tags/3dPrinterhacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>3dPrinterhacks</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoHacks</span></a> <a href="https://social.skynetcloud.site/tags/strandbeest" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>strandbeest</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoUno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoUno</span></a> <a href="https://social.skynetcloud.site/tags/3dprinted" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>3dprinted</span></a> <a href="https://social.skynetcloud.site/tags/robot" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>robot</span></a></p>
IT News<p>Building a 3D-Printed Strandbeest - The Strandbeest is a walking machine, a creation of the celebrated artist Theo Jan... - <a href="https://hackaday.com/2025/01/16/building-a-3d-printed-strandbeest/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2025/01/16/buildi</span><span class="invisible">ng-a-3d-printed-strandbeest/</span></a> <a href="https://schleuss.online/tags/3dprinterhacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>3dprinterhacks</span></a> <a href="https://schleuss.online/tags/arduinohacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinohacks</span></a> <a href="https://schleuss.online/tags/strandbeest" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>strandbeest</span></a> <a href="https://schleuss.online/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://schleuss.online/tags/3dprinted" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>3dprinted</span></a> <a href="https://schleuss.online/tags/robot" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>robot</span></a></p>
in_sympathy<p>Finally had some fun with my Arduino Uno R4 WiFi that I bought to learn some of this stuff and make an environment analyzer. </p><p><a href="https://mastodon.social/tags/ChatGPT" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ChatGPT</span></a> wrote the code, I soldered and connected sensors - modern day teamwork 😆. </p><p>Had to find my old DS18B20 for temp reading because temperature sensors got way too hot on both BME280 and AHT21. </p><p><a href="https://mastodon.social/tags/arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduino</span></a> <a href="https://mastodon.social/tags/arduinocloud" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinocloud</span></a> <a href="https://mastodon.social/tags/smarthome" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>smarthome</span></a> <a href="https://mastodon.social/tags/coding" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>coding</span></a> <a href="https://mastodon.social/tags/chatgpt" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>chatgpt</span></a> <a href="https://mastodon.social/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://mastodon.social/tags/bme280" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>bme280</span></a> <a href="https://mastodon.social/tags/DS18B20" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>DS18B20</span></a> <a href="https://mastodon.social/tags/ENS160" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ENS160</span></a> <a href="https://mastodon.social/tags/AHT21" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>AHT21</span></a></p>
Pyrzout :vm:<p>All Aboard the Hack Train: Nottingham’s LED Revival <a href="https://hackaday.com/2025/01/04/all-aboard-the-hack-train-nottinghams-led-revival/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2025/01/04/all-ab</span><span class="invisible">oard-the-hack-train-nottinghams-led-revival/</span></a> <a href="https://social.skynetcloud.site/tags/nottinghamhackspace" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>nottinghamhackspace</span></a> <a href="https://social.skynetcloud.site/tags/ReverseEngineering" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ReverseEngineering</span></a> <a href="https://social.skynetcloud.site/tags/departureboard" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>departureboard</span></a> <a href="https://social.skynetcloud.site/tags/SoftwareHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SoftwareHacks</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoHacks</span></a> <a href="https://social.skynetcloud.site/tags/Hackerspaces" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Hackerspaces</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoUno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoUno</span></a> <a href="https://social.skynetcloud.site/tags/Nottingham" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Nottingham</span></a> <a href="https://social.skynetcloud.site/tags/LEDHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>LEDHacks</span></a> <a href="https://social.skynetcloud.site/tags/Discord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Discord</span></a> <a href="https://social.skynetcloud.site/tags/railway" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>railway</span></a> <a href="https://social.skynetcloud.site/tags/News" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>News</span></a> <a href="https://social.skynetcloud.site/tags/mqtt" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>mqtt</span></a> <a href="https://social.skynetcloud.site/tags/led" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>led</span></a></p>
IT News<p>All Aboard the Hack Train: Nottingham’s LED Revival - Hackerspaces are no strangers to repurposing outdated tech, and Nottingham Hackspa... - <a href="https://hackaday.com/2025/01/04/all-aboard-the-hack-train-nottinghams-led-revival/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2025/01/04/all-ab</span><span class="invisible">oard-the-hack-train-nottinghams-led-revival/</span></a> <a href="https://schleuss.online/tags/nottinghamhackspace" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>nottinghamhackspace</span></a> <a href="https://schleuss.online/tags/reverseengineering" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>reverseengineering</span></a> <a href="https://schleuss.online/tags/departureboard" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>departureboard</span></a> <a href="https://schleuss.online/tags/softwarehacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>softwarehacks</span></a> <a href="https://schleuss.online/tags/arduinohacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinohacks</span></a> <a href="https://schleuss.online/tags/hackerspaces" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>hackerspaces</span></a> <a href="https://schleuss.online/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://schleuss.online/tags/nottingham" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>nottingham</span></a> <a href="https://schleuss.online/tags/ledhacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ledhacks</span></a> <a href="https://schleuss.online/tags/discord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>discord</span></a> <a href="https://schleuss.online/tags/railway" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>railway</span></a> <a href="https://schleuss.online/tags/news" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>news</span></a> <a href="https://schleuss.online/tags/mqtt" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>mqtt</span></a> <a href="https://schleuss.online/tags/led" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>led</span></a></p>
Pyrzout :vm:<p>Crafting a Cardboard Tribute to Puzzle Bobble <a href="https://hackaday.com/2025/01/02/crafting-a-cardboard-tribute-to-puzzle-bobble/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2025/01/02/crafti</span><span class="invisible">ng-a-cardboard-tribute-to-puzzle-bobble/</span></a> <a href="https://social.skynetcloud.site/tags/Retrocomputing" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Retrocomputing</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoHacks</span></a> <a href="https://social.skynetcloud.site/tags/puzzlebobble" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>puzzlebobble</span></a> <a href="https://social.skynetcloud.site/tags/puzzlebobble" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>puzzlebobble</span></a> <a href="https://social.skynetcloud.site/tags/bust" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>bust</span></a>-a-move <a href="https://social.skynetcloud.site/tags/retrogaming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>retrogaming</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoUno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoUno</span></a> <a href="https://social.skynetcloud.site/tags/ToyHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ToyHacks</span></a> <a href="https://social.skynetcloud.site/tags/arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduino</span></a> <a href="https://social.skynetcloud.site/tags/Games" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Games</span></a> <a href="https://social.skynetcloud.site/tags/mame" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>mame</span></a> <a href="https://social.skynetcloud.site/tags/lua" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>lua</span></a></p>
IT News<p>Crafting a Cardboard Tribute to Puzzle Bobble - What do you get when you cross cardboard, deodorant rollers, and a love for retro ... - <a href="https://hackaday.com/2025/01/02/crafting-a-cardboard-tribute-to-puzzle-bobble/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2025/01/02/crafti</span><span class="invisible">ng-a-cardboard-tribute-to-puzzle-bobble/</span></a> <a href="https://schleuss.online/tags/retrocomputing" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>retrocomputing</span></a> <a href="https://schleuss.online/tags/arduinohacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinohacks</span></a> <a href="https://schleuss.online/tags/puzzlebobble" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>puzzlebobble</span></a> <a href="https://schleuss.online/tags/puzzlebobble" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>puzzlebobble</span></a> <a href="https://schleuss.online/tags/bust" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>bust</span></a>-a-move <a href="https://schleuss.online/tags/retrogaming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>retrogaming</span></a> <a href="https://schleuss.online/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://schleuss.online/tags/toyhacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>toyhacks</span></a> <a href="https://schleuss.online/tags/arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduino</span></a> <a href="https://schleuss.online/tags/games" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>games</span></a> <a href="https://schleuss.online/tags/mame" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>mame</span></a> <a href="https://schleuss.online/tags/lua" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>lua</span></a></p>
Kemal ASLAN<p>GELİŞTİRME KARTI | KEYESTUDIO UNO MAX | DÜRÜST İNCELEME</p><p><a href="https://mastodon.online/tags/arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduino</span></a> <a href="https://mastodon.online/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://mastodon.online/tags/keyestudiounomax" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>keyestudiounomax</span></a></p><p><a href="https://www.youtube.com/watch?v=yRUMDL4PG0o" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://www.</span><span class="ellipsis">youtube.com/watch?v=yRUMDL4PG0</span><span class="invisible">o</span></a></p>
Pyrzout :vm:<p>A Parts Bin MIDI Controller in 24 Hours <a href="https://hackaday.com/2024/10/20/a-parts-bin-midi-controller-in-24-hours/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2024/10/20/a-part</span><span class="invisible">s-bin-midi-controller-in-24-hours/</span></a> <a href="https://social.skynetcloud.site/tags/emergencystop" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>emergencystop</span></a> <a href="https://social.skynetcloud.site/tags/MusicalHacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>MusicalHacks</span></a> <a href="https://social.skynetcloud.site/tags/arcadebutton" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arcadebutton</span></a> <a href="https://social.skynetcloud.site/tags/drummachine" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>drummachine</span></a> <a href="https://social.skynetcloud.site/tags/pelicancase" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>pelicancase</span></a> <a href="https://social.skynetcloud.site/tags/ArduinoUno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoUno</span></a> <a href="https://social.skynetcloud.site/tags/arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduino</span></a> <a href="https://social.skynetcloud.site/tags/drumkit" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>drumkit</span></a> <a href="https://social.skynetcloud.site/tags/music" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>music</span></a> <a href="https://social.skynetcloud.site/tags/midi" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>midi</span></a></p>
IT News<p>A Parts Bin MIDI Controller in 24 Hours - Part of the reason MIDI has hung on as a standard in the musical world for so long... - <a href="https://hackaday.com/2024/10/20/a-parts-bin-midi-controller-in-24-hours/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">hackaday.com/2024/10/20/a-part</span><span class="invisible">s-bin-midi-controller-in-24-hours/</span></a> <a href="https://schleuss.online/tags/emergencystop" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>emergencystop</span></a> <a href="https://schleuss.online/tags/musicalhacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>musicalhacks</span></a> <a href="https://schleuss.online/tags/arcadebutton" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arcadebutton</span></a> <a href="https://schleuss.online/tags/drummachine" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>drummachine</span></a> <a href="https://schleuss.online/tags/pelicancase" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>pelicancase</span></a> <a href="https://schleuss.online/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://schleuss.online/tags/arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduino</span></a> <a href="https://schleuss.online/tags/drumkit" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>drumkit</span></a> <a href="https://schleuss.online/tags/music" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>music</span></a> <a href="https://schleuss.online/tags/midi" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>midi</span></a></p>
Simple DIY Electronic Music Projects<p>I covered all the theory and main functions of the code for my <a href="https://diyelectromusic.com/2024/10/04/arduino-euclidean-gate-sequencer/" rel="nofollow noopener" target="_blank">Arduino Euclidean Gate&nbsp;Sequencer</a> in my previous post. In this one I look a little more at some hardware that hopefully lets me use this to actually control something useful!</p><ul><li><a href="https://diyelectromusic.com/2024/10/04/arduino-euclidean-gate-sequencer/" rel="nofollow noopener" target="_blank">Part 1</a> covered all the theory and main functions of the code.</li><li><a href="https://diyelectromusic.com/2024/10/07/arduino-euclidean-gate-sequencer-part-2/" rel="nofollow noopener" target="_blank">Part&nbsp;2</a> included some hardware suggestions for connecting it to other devices.</li><li><a href="https://diyelectromusic.com/2024/10/27/arduino-euclidean-gate-sequencer-part-3/" rel="nofollow noopener" target="_blank">Part&nbsp;3</a> added a rotary encoder and I2C display and demonstrated by <a href="https://diyelectromusic.com/2024/10/27/arduino-clock-generator-shield-pcb/" rel="nofollow noopener" target="_blank">Arduino Clock Generator Shield&nbsp;PCB</a>.</li><li><a href="https://diyelectromusic.com/2024/10/28/arduino-euclidean-gate-sequencer-part-4/" rel="nofollow noopener" target="_blank">Part&nbsp;4</a> reimplements HAGIWO’s original with a few tweaks and updates.</li></ul><p><em><strong>Warning!</strong> I strongly recommend using old or second hand equipment for your experiments.&nbsp; I am not responsible for any damage to expensive instruments!</em></p><p>All of the key ideas along with a list of references for the main concepts used in this project were listed in my first post here: <a href="https://diyelectromusic.com/2024/10/04/arduino-euclidean-gate-sequencer/" rel="nofollow noopener" target="_blank">Arduino Euclidean Gate&nbsp;Sequencer</a>.</p><p>If you are new to Arduino, see the&nbsp;<a href="https://diyelectromusic.wordpress.com/getting-started/" rel="nofollow noopener" target="_blank">Getting Started</a> pages.</p><p><strong>Experiment 1: Arduino to Arduino to MIDI</strong></p><p>I could add MIDI functionality to my Euclidean clock generator, but instead opted to build a TRIGGER to MIDI converter using a second Arduino. This has several digital inputs setup to receive TRIGGER pulses and on reception will send out a preconfigured MIDI message.</p><p>The configuration is such that a NoteOn is sent for a specific drum on MIDI channel 10 which is typically used for percussion. Which drum corresponds to which input is configurable in the code.</p><p>Full details of this so far can be found here: <a href="https://diyelectromusic.com/2024/10/06/arduino-drum-trigger-to-midi/" rel="nofollow noopener" target="_blank">Arduino Drum Trigger to&nbsp;MIDI</a>. This is how I connected them up and it seems to work pretty well.</p><p><strong>Arduino to GATE or TRIGGER Output</strong></p><p>Here I’m setting up the board to be able to drive an external device.</p><p><em>As always, the standard warning applies – use second hand or disposable equipment for experiments. <strong>I am not responsible for damage to expensive instruments.</strong> Assess what I’m doing, decide for yourself how it will affect your equipment and then use at your own risk.</em></p><p>I’ve followed the design from HAGIWO’s GATE sequencer, which is detailed in full here: <a href="https://note.com/solder_state/n/n17c69afd484d" rel="nofollow noopener" target="_blank">https://note.com/solder_state/n/n17c69afd484d</a></p><p>This recommends the following:</p><ul><li>All outputs clamped to the Arduino’s 5V and GND using BAT43 Schotky diodes.</li><li>470Ω resistor on the output to set an output impedance.</li></ul><p>I’m wanting to plug this into my Korg Volca Sync In.</p><p>With an oscilloscope I examined the Sync Out signal and confirmed that it is a 5V pulse of 15mS. As I’m only plugging a 5V Arduino into the 5V accepting Korg, I’ve not bothered with the clamping diodes for my simple experiments, but if I build this up into a PCB then I’ll probably add them in to make it a little more universal.</p><p>The TRS jack is wired to be compatible with the Korg Volca Sync In port – i.e. using just the tip and shield. A stereo or mono 3.5mm jack to jack cable (as comes supplied with a Volca) can then be used to connect it up.</p><p>The blue jumper wire can be used to select which of the Euclidean clock outputs to use.</p><p>The code is built for TRIGGER mode, so each output is a single 10mS pulse. This is shorter than that produced by the Volcas but generally seems to work.</p><p>When first connected or when the tempo is changed I sometimes hear some spurious or irregular triggering, but once it has settled down it seems to work fine for my Volca Keys, Volca Modular, and Volca FM2.</p><p><strong>Arduino to ESP32 Synth Thing Baby8</strong></p><p>The <a href="https://diyelectromusic.com/2024/09/01/baby8-cv-step-sequencer-part-4-in-use/" rel="nofollow noopener" target="_blank">“Baby8” CV Step Sequencer</a> has an option to be driven by an external clock. If the INT_CLK jumper is removed then it will trigger off whatever is plugged into the CLK header pin (third down from the top of the header).</p><p>This means that, assuming the Baby8 is powered off 5V, then any of the Arduino GPIO clock outputs (D8-D13) can be directly connected as shown below.</p><p>This is directly connecting the Arduino’s GPIO OUTPUT pins (the clock) to the Baby 8’s 4017 timer CLK pin. As in general terms directly connecting an OUTPUT to an INPUT is deemed an ok thing to do (INPUTs are high impedance as I understand things), i.e. the output of a microcontroller, 555 timer, or NAND oscillator and so on are often set up to drive the CLK pin directly, then connecting it directly to an Arduino GPIO OUTPUT should be fine.</p><p>It is also possible to drive the actual <a href="https://diyelectromusic.com/2024/05/07/educational-diy-synth-thing/" rel="nofollow noopener" target="_blank">Educational DIY Synth&nbsp;Thing</a> itself as it includes 5V tolerant GATE and TRIGGER inputs, but having a regular clock pulse with no pitch CV information is somewhat limited.</p><p>But using the Baby8 as shown above with the Synth Thing too should work fine, although if the Baby 8 is powered off 5V then the top of the potentiometer’s range will be slightly too high for the Synth Thing which will top-out at around 3V3. It won’t damage the Synth Thing as the CV inputs are clamped to the 0 and 3V3 power rails.</p><p><strong>Closing Thoughts</strong></p><p>Naturally getting the logic signal doing the right thing on a GPIO port is only part of the equation. That is only useful if it is able to control something else.</p><p>This post looked at some options, from the hacky “quick and dirty” versions through to what ought to be done to do things properly.</p><p>I’m still chewing over the idea of some kind of trigger shield or similar PCB.</p><p>Kevin</p><p><a href="https://diyelectromusic.com/2024/10/07/arduino-euclidean-gate-sequencer-part-2/" class="" rel="nofollow noopener" target="_blank">https://diyelectromusic.com/2024/10/07/arduino-euclidean-gate-sequencer-part-2/</a></p><p><a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/arduino-uno/" target="_blank">#arduinoUno</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/baby8/" target="_blank">#baby8</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/euclidean/" target="_blank">#euclidean</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/gate/" target="_blank">#gate</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/midi/" target="_blank">#midi</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/step-sequence/" target="_blank">#stepSequence</a> <a rel="nofollow noopener" class="hashtag u-tag u-category" href="https://diyelectromusic.com/tag/synth-thing/" target="_blank">#synthThing</a></p>
mirobo Technology<p>It's freebie Friday!!</p><p>Hey teachers, check out our free electronics and <a href="https://techhub.social/tags/Arduino" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Arduino</span></a> programming resources here: <a href="https://mirobo.tech/electronics" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="">mirobo.tech/electronics</span><span class="invisible"></span></a></p><p><a href="https://techhub.social/tags/STEMEducation" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>STEMEducation</span></a> <a href="https://techhub.social/tags/electronics" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>electronics</span></a> <a href="https://techhub.social/tags/ArduinoUNO" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ArduinoUNO</span></a> <a href="https://techhub.social/tags/robotics" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>robotics</span></a></p>
Kemal ASLAN<p>Ben de biraz sevineyim!</p><p>Raspberry Pi 5'te ilk defa Arduino çalıştırdım!</p><p>PyCharm ile PyGame oyun çalıştırdım, ama Arduino çalıştırmamıştım.</p><p>İlkler bir başka oluyor. ツ</p><p>Elbette ki ilk kart olarak Arduino UNO ve kod olarak da "blink" çalışıyor ツ</p><p>Kısa bir video çektim, ama 92MB videoyu mastodon'a yükleyemedim.</p><p>Birkaç gün sonra arşivimi alınca sileceğim facebook hesabıma yükledim!</p><p>Linkini eklesem mi?<br><a href="https://www.facebook.com/aslankemalaslan/videos/2447929172063698/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://www.</span><span class="ellipsis">facebook.com/aslankemalaslan/v</span><span class="invisible">ideos/2447929172063698/</span></a></p><p><a href="https://mastodon.online/tags/raspberrypios" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>raspberrypios</span></a> <a href="https://mastodon.online/tags/raspberrypi5_8gb" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>raspberrypi5_8gb</span></a> <a href="https://mastodon.online/tags/arduinoide" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinoide</span></a> <a href="https://mastodon.online/tags/arduinouno" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>arduinouno</span></a> <a href="https://mastodon.online/tags/blink" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>blink</span></a></p>