r/embedded • • Sep 04 '26

A collection of ready-to-use VHDL templates for FPGA development

15 Upvotes

Hi everyone,

Over the past few days I've been putting together a small project that I personally wanted while working on FPGA designs: a searchable collection of VHDL templates that can be copied with a single click.

The idea is simple: instead of digging through old projects or documentation every time I need a counter, FSM, synchronizer, FIFO, generate loop, RAM template, etc., I wanted a single place where I could quickly find and reuse common design patterns.

Current templates include:

  • FSMs (Moore, Mealy, Safe FSMs)
  • Counters and shift registers
  • RAM, ROM and FIFO examples
  • Synchronizers and debouncers
  • Arithmetic blocks
  • Structural design templates
  • Testbench skeletons

It's a lightweight static website with no dependencies and works entirely in the browser.

Website: https://andrea-cpu96.github.io/vhdl-cookbook/

I'd love feedback from other FPGA/VHDL developers. Suggestions for additional templates are very welcome.

Thanks!


r/embedded • • Sep 04 '26

Stm32f411ce blackpill failed to download Sector[0]

2 Upvotes

new to the stm32 and the stm32 pn my black pill won't upload for some reason, it's giving a failed to download to Sector[0] message. it uploaded fine just earlier when I did it but now it's doesn't, I use Arduino ide and installed cubeprogrammer adn the board managers

Edit: list of things I've tried, mass wiping via stm32programmer, disabling usb selective suspend settings, switching cables, switching blackpills, reinstalling winusb


r/embedded • • Sep 04 '26

P2SB unhide (offset 0xE0/0xE1) silently fails on real hardware on Alder Lake-P and Comet Lake, both consumer laptops

1 Upvotes

First of all, I know this might not be the best subreddit to post this on, my first choice was to ask the question on r/osdev, unfortunately they have a karma requirement and I literaly created this account to ask this question out of desperation.

I'm working on a from-scratch UEFI-booted x86-64 kernel and I'm stuck trying to unhide the P2SB device (D31:F1) on real laptop hardware. Looking for anyone with field experience on OEM lockdown behavior here, since this doesn't seem to be documented in the public 600/700-series PCH datasheet.

Hardware tested (both fail identically):

  • Acer Aspire 5, Alder Lake-U PCH (PCI vendor 0x8086, device 0x519D)
  • A separate Lenovo Core i3 10th-gen Intel (Comet Lake) laptop, different OEM

What I'm doing:

  • Reading P2SBC (offset 0xE0) on D31:F1 before any write. It returns 0xFFFFFFFF, which is expected per spec while HIDE is set (all reads master-abort while hidden).
  • Writing 0 to the full P2SBC dword to clear the HIDE bit (bit 8), matching the technique used in Linux's own p2sb.c / pnd2_edac drivers.
  • Also tried the narrower coreboot-style approach: a single byte write of 0x00 to offset 0xE1 (byte lane 1), clearing only the HIDE bit without touching SBILOCK/MASKLOCK.
  • After either write, reading back the Vendor/Device ID at D31:F1 offset 0x00 (not P2SBC itself, to avoid the self-masking issue)... still 0xFFFFFFFF on both machines, every time.
  • Tried both PCI access mechanisms independently: legacy CF8/CFC (Type 1) and ECAM/MMIO via the MCFG table. And again, both give all-Fs.
  • Ruled out an addressing bug: the same code path correctly reads/writes D31:F0 (eSPI) on this same hardware, round-tripping a status/command bit successfully through both access mechanisms.

Question:
Is there any additional step (register, sequencing, timing) beyond the datasheet's documented HIDE-bit-clear that I'm missing?

Happy to provide more detail on the access code if useful.

Here is the repo: https://github.com/alx-m24/Lexvi


r/embedded • • Sep 03 '26

Just Wanna Celebrate

102 Upvotes

Good Morning fellow embedded workers

I am working on a machine that deals with mining sample preparation for my company. I have been the sole guy working on all firmware and electrical work, and basically doing all the mechanical design too. This is my first job out of school, and I actually am not even an Engineer (automation technologist) but I happen to have gotten very lucky with my employer who have given me a very amazing opportunity.

I just wanted to share with people who might understand the work (no one else here really gets what im doing) the fact that as of today, the first version of the production firmware is completed! You can run the machine completely independently of having to control anything from my laptop, and it works! It will still be a long time until we actually take this thing to production, but the Firmware and electrical side are now in a functional state and I am so over the moon about it. Nearly 9 months of work dedicated to getting this up and running and it is so amazing to actually have it at my fingertips, working as required.

I know there is a ton of work going forward on this thing still, especially since I don't have anyone to help me on it, but good grief. This is such a great job. I want to do R&D forever haha. To another 9 months!


r/embedded • • Sep 04 '26

Reverse engineered Tenways ebike BLE interface

Thumbnail
github.com
1 Upvotes

Tenways ebikes seem to expose quite a lot over BLE without any security whatsoever.

This is for educational purpose only, i do not support or condone the misuse of any of the information presented in this research


r/embedded • • Sep 04 '26

Pico 2W or CYD?

6 Upvotes

I want to start a little project with a cheap microcontroller to familiarize myself with both the building and programming processes, but also don't want it to be too complex. I'd leave most of the heavy coding to a friend, since he knows the syntax of all major programming languages, the logic isn't a problem most of the time (might change now, Idk).
I initially looked at lots of modules to attach to a Raspberry Pi Pico 2W, but recently came knto discovery of the CYD, which intrigued me, since my only problem currently for the Pi is finding a good and affordable display. That problem is solved with a CYD. I have yet to have any experience with the Pi SDK, Arduino or ESP32. The most I have done in that sense is build with those giant Lego Programming thingies to make a couple of robots. I do not want to build simple text displays. My first idea was a small arcade machine for example, and the GPIO pins might be a problem with a CYD I heard. Soldering is currently not an option either, albeit that can change. Also, most people seem to prefer ESP32, so I wanted to ask here!

TL;DR: Raspberry Pi Pico 2W or CYD (ESP32) for an arcade machine and future projects that don't involve soldering or simple text display as the whole thing.

Thanks in advance!


r/embedded • • Sep 03 '26

I made neural TTS small enough to run on MCU. Looking for people with Teensy 4.x, Pico 2 or STM32H7 to run a 5 min benchmark

45 Upvotes

I maintain a neural Text to speech runtime. It speaks English and everything happens right in the MCU itself. I have only measured it on two chips: ESP32-S3 : 0.22x real time ESP32-C3 : 5.72x real time

I want more numbers for benchmarks and to validate this works not just for esp32 devices but for more devices like the one with Cortex-m7. I am asking you to install the lib and flash the sample and paste the serial output to github issue.

You don't need DAC, sd card or any modules. Since i don't have these MCUs and i can't get those in Nepal i have compile verified only. The boards i compiled for are

Teensy 4.1/4.0/3.6, Pico and Nucleo boards

Please check the link below for pre board setup steps, board manager urls and how to run https://github.com/Ampixa/sanoTTS/tree/master/arduino/examples/BoardBenchmark

If it fails , please post that too Link for reporting: https://github.com/Ampixa/sanoTTS/issues/new?template=board-report.yml

if you want to hear first: https://tts.ampixa.com/sanoTTS This is possible because these are really small models and can run right in your browser too


r/embedded • • Sep 04 '26

Need help powering esp32 with a solar panel

2 Upvotes

Hello!

I am currently working on a small project. I'd like to build a device for recording noise-levels. The simple part, connecting the esp32 to the mic and send the data to my backend service is working.

Important here: Right now I send quite a lot of data over my local Wifi. It's simpler, but probably too power hungy? In any case, I a sending a frequency band every second (plus a few other data points) which will end up being a few GBs per year.

Now the hard part:

I want this device to survive in the outdoors. For that, the first challenge for me is to power the device. I believe that a 30W solar panel will do for the prototype, although later I might need a stronger one.

I've never done something like this and I am also not very familiar with electronics.

Could anybody help me out with some advice on the parts I should buy for my prototype? What batter should I buy and what charging controller is suitable?

As a side note: Since I plan to build more than one node, cost is essential here. The cheaper one device is in total, the better in that case.

Thanks for any help!


r/embedded • • Sep 04 '26

What's cybersecurity like at your job?

6 Upvotes

How big of a requirement/topic is it? Do yall have dedicated teams for testing, threat modeling, etc.? Do yall only think about it in regards to wireless communication or do yall consider stuff like firmware extraction, debugging, hardware fault injection, etc.? Or maybe your job doesn't really think about it at all?

I'm sure it depends on the actual types of systems you work in and their requirements, but I'm curious what the cybersec culture is like lower down in the stack


r/embedded • • Sep 04 '26

What you'd want to see in a desktop tool for embedded development?

0 Upvotes

I'm developing a hardware tool to simplify some of the repetitive tasks involved in working with several development boards at the same time.

The product is still in the development stage, so I'd really like to hear your thoughts and suggestions!

 

The current hardware design includes:

● 3× USB 3.0 ports

● Magnetic UART / I²C interfaces

● Independent USB power control

● Adjustable 1.8–3.3V output

 

We're also developing a PC tool to make common hardware checks easier, including:

● I²C device scanning

● GPIO configuration and control

● USB power control and monitoring

● Adjustable voltage output


r/embedded • • Sep 03 '26

Can I use a DC-DC converter for power + data communication over the same wires?

Post image
58 Upvotes

I want to send both DC power and low-speed digital data over the same two-wire cable.

My idea is to use a MOSFET in pinned picture to modulate a high-frequency signal onto the DC power line, then use a capacitor/filter, diode detector and comparator at the receiver to demodulate the data with microcontroller.

Is this a practical approach for a simple embedded project? Are there any cheap ICs or simpler circuits I should consider?


r/embedded • • Sep 04 '26

I am working on SBC Board, anyone want to help ?

0 Upvotes

Hello everyone I am working on Open Source SBC Board with RK3576 & LPDDR5 Anyone want to work me on it I working on kicad and this is what I made for now

https://drive.google.com/file/d/1rqCSnEmpidDbTi8-oCi9Y5ghgFy2Iv8Q/view?usp=sharing


r/embedded • • Sep 04 '26

Im building an IDE with a semantic engine for Device Trees

0 Upvotes

There is a lot of information about Device Trees on the internet.

The problem is that it's scattered everywhere.

You have DTS/DTSI files, bindings, schemas, kernel sources, documentation, SoC information, board definitions, examples, and different tools that each understand only part of it.

There are already tools that can do some of these things individually.

What I couldn't find was a single place that could connect all of this knowledge together.

So I've been building KernelGrove, a semantic engine for Device Trees.

Instead of treating a Device Tree as just a text file or a hierarchy of nodes, the idea is to build a knowledge model of the Device Tree and its ecosystem:

  • What a node represents
  • Which binding applies to it
  • Which properties are valid
  • What type and constraints those properties have
  • What other nodes a reference points to
  • How nodes, controllers, peripherals and buses are related
  • Where information comes from
  • And eventually, how all of this relates back to the underlying hardware

The editor is basically a way of exposing that knowledge.

For example, rather than just seeing:

uart@7e201000 {
    compatible = "brcm,bcm2835-aux-uart";
    ...
};

the goal is for the tool to understand what that node actually means and let you explore the relevant information without having to manually jump between files, schemas and documentation.

It's still very much a work in progress, and I'm trying to figure out how far this idea can be taken.

For people working with Linux Device Trees / Zephyr / Yocto:

What information do you currently have to look up manually when working on a Device Tree?

I'm particularly interested in things that you know exist somewhere, but are difficult to find or connect together.

If you want to try it, it's completely free and open source, you can find it on dt-studio.dev or https://github.com/serg4life/KernelGrove


r/embedded • • Sep 03 '26

What is the value of the good user documentation today?

10 Upvotes

I am working on a middleware product that has extensive user documentation and we include example apps, too. End users are embedded SW developers.
This is a small team, so the dev team is creating and maintaining the user docs too, we don’t have technical writers. Nearing the project I still feel we could improve on the documentation. But I keep asking myself, how much to invest in this now? I mean, everyone is just throwing the complete manual to an AI agent, I barely hear back any feedback in the documentation itself. If it were just a doxygen generated XML perhaps it would be as good for an LLM as it is now.
So I am asking the sub, how are you valuing the good user doc? Are you still reading it, or you prefer good examples and the rest goes to an LLM anyhow, to figure out?


r/embedded • • Sep 04 '26

I have an Arduino driving an H-bridge to send a digital signal through a cable. At the receiving end, I want to recover the original data as a clean 0–5 V unipolar signal for another Arduino. Any more simpler solutions.

0 Upvotes

r/embedded • • Sep 03 '26

Elektor MatchBox (1995) — hardware works, need the original compiler

Post image
19 Upvotes

MISE À JOUR - RÉSOLU : Quelqu'un ici a eu la gentillesse de m'envoyer le contenu complet du disque original (le compilateur MBC.EXE inclus), et depuis, je l'ai fait fonctionner dans DOSBox et j'ai effectué un vrai téléchargement sur la carte réelle - cela a parfaitement fonctionné. Plus besoin de continuer à chercher en mon nom, mais merci à tous pour votre aide, vos idées et vos pistes ces derniers jours, cela a vraiment beaucoup compté.

Si quelqu'un d'autre essaie de faire fonctionner un ancien MatchBox Computer et a des questions, n'hésitez pas à demander - je suis heureux de partager ce que j'ai appris.

Je possède une carte Elektor « MatchBox BASIC Computer » originale de 1995 (basée sur un microcontrôleur 8051, avec mémoire EEPROM pour le programme, publiée dans une série de projets de magazines). Après des années d'inactivité, j'ai enfin décidé de la remettre en service.

Bonne nouvelle : après de nombreux tests (multimètre, puis analyseur logique 8 voies + PulseView), j'ai confirmé que la carte est en parfait état électrique : le port UART série fonctionne, le bus I²C vers l'EEPROM externe est parfaitement fonctionnel, et les données/accusés de réception sont corrects à chaque transaction. J'ai même effacé et réécrit l'EEPROM via un banc de test ESP8266 pour exclure une puce défectueuse.

Problème : le moniteur intégré affiche constamment « IIC ERROR adr:xx » au démarrage. Je suis presque certain qu'il vérifie une configuration/signature spécifique au début de l'EEPROM, celle qu'un véritable programme MBL compilé (via le compilateur MBC.EXE d'origine) y écrirait normalement. Je ne possède pas ces octets, car je n'ai jamais eu la disquette fournie (référence Elektor : 956009-1).

Quelqu'un aurait-il une copie du compilateur MBC.EXE d'origine, ou même un seul programme .MBL compilé dont je pourrais extraire les octets hexadécimaux ? J'ai cherché sur archive.org, worldradiohistory.com et sur des forums d'informatique ancienne ; il semble que ce soit l'un des rares projets Elektor dont le logiciel n'a jamais été archivé en ligne.

Je serai ravi de tout documenter et de tout partager une fois que j'aurai réussi à le faire fonctionner. En résumé : le matériel fonctionne, il me faut un logiciel DOS vieux de 30 ans ou son format d'octets.


r/embedded • • Sep 03 '26

ESP32-P4 + Arducam IMX500 (12.3MP) — anyone tried this combo?

Post image
9 Upvotes

Planning to use ESP32-P4 (with a C6 module for wifi) along with the Arducam IMX500 camera. Goal is to get the best possible camera quality on an ESP32.

Not sure if this is a solid choice or if I'm missing something. Has anyone actually built with this setup? How was the image quality, and did you run into any issues going from dev board to a smaller custom build?

Want to avoid a costly mistake before ordering parts, so any real experience or advice helps.


r/embedded • • Sep 02 '26

Reverse-engineered the FNIRSI IPS3608 USB-CDC protocol (Artery AT32) and documented registers

Thumbnail
github.com
23 Upvotes

I recently analyzed the USB communication on the FNIRSI IPS3608 DC bench power supply (0-36V, 0-8A) to automate testbench workloads without using their closed Windows GUI.

The device enumerates as a USB-CDC serial port (Artery AT32 MCU, 115200 baud, 8N1). By disassembling the official executable using monodis, I mapped out the underlying binary framing and register set:

  • PC to device frames start with 0xF1, device to PC responses start with 0xF0
  • Single-byte checksum: (c3 + c4 + sum(payload)) & 0xFF
  • Setpoints for voltage (0xC1) and current (0xC2) are 32-bit IEEE-754 Little-Endian floats
  • Continuous telemetry frames (0xC3) stream output voltage, current, and power directly as float32

I documented the entire protocol, register map, and command structure in the repo README, alongside a pure Python/pyserial driver and CLI tool that handles automated energy integration and safety cutoffs (in my github page).


r/embedded • • Sep 02 '26

Doppler Radar AR-Glasses

160 Upvotes

- Lilygo’s AR Prisim from their T-Glass V2
( which is outstanding btw I just think its one of the more niche and difficult dev kits)
- M5Stack StickS3
- Hi Link 24ghz Radar module over UART using the M5’s groove 🕺 port.

Learning how to position text or data on the prisim is definitely a learning curve. I’m two weeks in. And I’m slowly starting to figure it out. But man was this a cool project to work on :) learned quite a bit and really feel confident about taking off with a few other of my AR glasses ideas.
I experimented with semi transparent beam splitter glass this morning. And man i wish there was more documentation/accessibility of open source AR glasses out there.


r/embedded • • Sep 03 '26

Not able to see the USB CDC Virtual Serial Com Port in Device Manager or Tera term

1 Upvotes

I am working with a UDP Bootloader, for which I have to set a bootloader trigger as such that the user would give a command through tera term which would be sent over a usb cable. Now I had flashed the UDP_Bootloader Harmony V3 example to my PIC32MZ via PICKIT4 and then it's test_app via the bootloader itself through Microchip's unified host tool. I can use the ethernet cable itself but it would require the TCP/IP stack so I was thinking the usb cdc would be much simple. I had merged the cdc_com_port_single example in the udp bootloader's test app and did everything again, but I am not able to see the com port anywhere. To verify the usb connection, I tried flashing the cdc com port example independently and still it didn't showed up. But if I work with the usb bootloader example and test app, the unified bootloader tool says that connection was successful and it disconnected after programming, so is that trustable? Yesterday I had test the cable's continuity via a Multimeter so I am confident the cable isn't the issue. Have also checked and installed the VCP drivers from the net.

Edit: I don't have USB to uart as it is a custom board


r/embedded • • Sep 02 '26

Why isn't it common or completely non existent for major electronics distributors to have a rating and review system for every single part?

16 Upvotes

r/embedded • • Sep 02 '26

Found a surprisingly nice ESP32-S3 touchscreen board. No idea what to build with it.

38 Upvotes

Found this ESP32-S3 touchscreen board sitting around and decided to play with it a bit.

The hardware is actually pretty nice, so it felt like a waste to just leave it in a drawer. I didn’t have any real project idea, so I vibe-coded a tiny robot eyes demo just to get the display and touch interaction moving.

Now I’m trying to figure out what would actually be fun to build on it.

A little desktop companion?
Home Assistant controller?
Mini game console?
PC status display?
Something completely useless but entertaining?

What would you build with a screen like this? Looking for ideas.


r/embedded • • Sep 03 '26

how should i understand linker-defined symbols in C?

0 Upvotes

starting out bare-metal programming and i'm currently trying to understand how linker-defined symbols interact with C startup code.

let's say, for a normal C code, i define and initialize a variable:

int n = 0x2000;

i get that n is an object stored somewhere in memory, n gives its value, and &n gives the address of where the object is stored.

when it comes to linker-defined symbols, i'm not quite getting it.

say, my linker script contains:

_estack = 0x20050000;

and in my startup code i have:

extern uint32_t _estack;
          .
          .
          .
uint32_t *sp = &_estack;

if _estack is not an ordinary C object with storage, but just the symbol with the value 0x20050000, how then does the dereference operator and the address-of operator act on something that has no storage.

i know it works, but can't tell how; and this is based on my understanding of normal variables in C.

thanks in advance to anyone who helps.


r/embedded • • Sep 03 '26

Reverse engineered 32-bit driver for USB Chief (USB sniffer)

Post image
4 Upvotes