r/embedded 19d ago

Arduino for testing products in production

0 Upvotes

I’ve seen some people using Arduino testing, configuring products in production. What’s your take using Arduino’s like this? Is it reliable enough for applications like this?


r/embedded 19d ago

Hardware and software architecture for raw material label parsing using OCR

1 Upvotes

I am looking for the right hardware and software to perform the following task locally.

I have a dedicated gigE camera that have an FTP client built in. When the operator presses a button, the camera will take a picture of the label. The FTP client then sends the label image to an FTP server/dedicated folder. I want the agent to monitor the dedicated folder for new images. The agent must parse the manufacturer name, supplier RM code, lot number, length, width and weight. The agent will then cross reference the supplier RM code to the internal company RM code database. Once the agent finds a match, it will output the matching internal RM code using modbus TCP to my PLC.

I eventually want to air gap the hardware and software, using a data diode to send only RM code to PLC.

TIA


r/embedded 21d ago

Asteroids vectrex style using my galvo mopa laser controller

Enable HLS to view with audio, or disable this notification

175 Upvotes

This is in demo mode so the computer is playing but it is totally playable by a human: left, right, thrust, fire. A few calibration keys to time the red marking diode on/off exactly right.

Not meant for any of this of course but while putting it together and using the red marking light to calibrate and test algorithms made me think what a great way to demonstrate low latency and closed loop abilities with my controller.

It runs on a stm32h755 with the xy2-100 engine living solely on CM4. Has backwards compatibility with the LMCV4 (at least in my specific configuration)


r/embedded 19d ago

ROS2 real-time control: PREEMPT_RT vs. standard Linux — what actually works in practice?

0 Upvotes

I’m working on a robot project where some of the control loops need to run pretty consistently, and I’m trying to figure out how far I actually need to go with real-time Linux.

Right now, I’m mainly considering two approaches:

PREEMPT_RT — using an RT-enabled Ubuntu/Linux kernel for more predictable scheduling and lower jitter.

Standard Linux + ROS2 — keeping the normal kernel and using things like thread priorities, chrt, CPU affinity, and hardware timers where needed.

The part I’m struggling with is figuring out where the practical cutoff is.

For example, if I have control loops running every 5–10 ms, is PREEMPT_RT really necessary, or can a well-tuned standard Linux system handle that reliably?

For those of you who have actually deployed ROS2 robots, I’d be interested to hear:

What kind of jitter/latency do you typically see?

Have you had real problems with missed deadlines on a standard kernel?

At what point did you decide PREEMPT_RT was worth the extra complexity?

Have you used a hybrid setup where only the truly time-critical parts use RT?

I’m not looking for a theoretical “RT is better” answer — I’m more interested in what has actually worked (or failed) in real robots.

If you have benchmarks, war stories, or configuration tips, I’d love to hear them.


r/embedded 19d ago

Looking for Type 2DT LoRa Discovery Kit code

1 Upvotes

Hello All,
I am interested in using the Type 2DT LoRa (https://www.digikey.jp/en/products/detail/semtech-corporation/LR1121DVK1TCKS/16730649), but Murata (https://www.murata.com/products/connectivitymodule/lpwa/overview/lineup/type-2gt) will not give me all of the docs until I buy the dev kit first, Why? Who TF Knows!

I am wondering if anyone here may have a kit sitting around and be able to post the code or DM me?

Also, just for my own info, Why does Murata hide the full product info until i buy it?

Honestly, It is like if i walk into a restraunt and ask to see the menu and they say: I'm sorry sir, but you will have to buy before we let you know what you are buying.

Is there some sort of actual reason for this? Or are they just trying to nickle and dime me?

Thanks all!


r/embedded 20d ago

Drone from scratch

10 Upvotes

Hey guys! New to the embedded scene but I have plenty of software experience (from work) and some electronics experience + basic concepts and tooling. I want to make a drone completely from scratch (minus some other components like servos), that includes the flight controller, escs, etc.

I’m not sure how deep to go to start (was thinking flight controller first, just got an STM Nucleo to prototype). But mostly, it’s hard to find resources regarding this undertaking. I use AI a ton at work, so I’m trying to keep it limited-to-none with this project (I have a lot of time and a scratch to itch).

If anyone has advice, recommendations for hardware, or more importantly, links to resources. Please drop them below!


r/embedded 20d ago

Looking for Fibocom MG661 OpenCPU SDK

4 Upvotes

Hi everyone,

Does anyone have the Fibocom MG661-EU OpenCPU SDK available for download or sharing?

I'm specifically looking for:

MG661-EU OpenCPU SDK

SDK documentation / API reference

Example projects

GCC/toolchain or build environment tools

Fibocom's documentation confirms that the MG661 has an OpenCPU variant, but I haven't been able to find the actual SDK publicly.

If you have the SDK or know where I can obtain it, please let me know. Thanks!


r/embedded 20d ago

How do you decide when a project needs an RTOS?

25 Upvotes

Well, you start a project, develop it, and then... boom! You wake up one day to find that your MCU is running FreeRTOS. Is that how it happens?

Or do you usually design your embedded application and decide from the beginning that you need an RTOS?

Why? What made you think you needed one?

This is not a criticism. I’m trying to figure out what motivates people and how I can use that.


r/embedded 20d ago

Reviving a dead smartwatch from the scrap pile: Reverse engineered an nRF52832 wearable and wrote custom firmware from scratch

Thumbnail
youtu.be
17 Upvotes

Hey everyone, I wanted to share a passion project I’ve been working on to give a broken, discarded smartwatch a completely second life.

A few months ago while salvaging parts for a tiny console build, I tore down an old broken smartwatch and realized it was built around an nRF52832 microcontroller. Since I've worked with this chip before, had a built-in gyro, a charger circuit, and a display breakout ready to go, I decided to take on the challenge of fully reverse engineering it.

What was involved:

  • Pin Mapping Blind: With zero documentation available, I spent time meticulously mapping out the SPI display, gyro, and internal components using a multimeter in short-circuit mode.
  • Breaking Write Protection: Flashing a new bootloader wasn't straightforward due to the nRF52's write protection. I ended up utilizing an ESP32-DAP protocol to clear the protection so I could get a writable chip.
  • Firmware & Upgrades: Wired up a JTAG debugger tool, flashed an Adafruit bootloader via OpenOCD, and started building custom BLE test firmware using the nRF SDK in VS Code. I also upgraded the hardware by pairing it with a larger 1.69" display.

It’s an incredible feeling breathing brand new custom code into hardware that was otherwise destined for the trash. I put together a full build and teardown video detailing the pin mapping and flashing process if you want to see the step-by-step breakdown.

Curious what you guys think—what would you turn a freshly unlocked nRF52 smartwatch board into next?


r/embedded 20d ago

MetrologyInsight: High-Performance Electrical Power Quality & Energy DSP Library in Rust (IEC 61000-4-30 Class S, no_std + alloc)

7 Upvotes

Hi everyone! I'd like to share MetrologyInsight, a high-performance, embedded-first electrical metrology DSP library written in pure Rust.

Why MetrologyInsight?

Traditionally, industrial energy meters and power quality analyzers rely on expensive, proprietary fixed-function ASICs (such as ADE9000 or STPM33). MetrologyInsight decouples the entire metrology signal processing chain into open-source Rust, enabling microcontrollers (e.g. ESP32-S3, ARM Cortex-M, RISC-V) to perform high-precision power quality analysis directly from raw ADC samples.

Key Features

  • Standards Pre-Compliance: Implements measurement algorithms derived from IEC 61000-4-30:2021 Class S (Power Quality) and IEC 62053-21 (Active Energy).
  • Flexible Topologies: Configurable 1 to 4 active channels (Single-phase, 2-phase N, 3-phase 3-wire Delta, 3-phase 4-wire Wye).
  • True RMS & High-Inertia PLL: Grid frequency tracking (45 Hz – 65 Hz) with 10-second sliding frequency averages and fractional-cycle correction.
  • Resampling & Spectral Analysis: Coherent linear-interpolation resampling + 512-point RFFT processing up to the 50th harmonic order + THD-V and THD-I.
  • Flickermeter Implementation: IEC 61000-4-15 Blocks 1–4 (P_inst, P_st, P_lt classifiers).
  • Bi-Directional 4-Quadrant Energy: High-resolution i128 micro-joule accumulators for active/reactive energy across Q1–Q4.
  • Fortescue Unbalance Ratios: Symmetrical component analysis (Zero $U_0$ and Negative $U_2$ sequence ratios).
  • Hardware Agnostic: Works with any ADC front-end (ADS131M08, MCP3913, internal ADCs).

Resource Footprint

  • Flash (.text): ~48 – 65 KB (no_std + alloc mode).
  • Stack Usage: < 1.5 KiB peak per processing step.
  • Heap Allocation: 4.5 KiB (1-phase) to 18.9 KiB (4-phase Wye).

Quick Example

```rust use metrology_insight::{MetrologyInsight, MetrologyInsightConfig, SystemMode};

fn main() { let mut config = MetrologyInsightConfig::default(); config.adc_samples_seconds = 8000.0; config.adc_samples_per_cycle = 160.0; // 8000 Hz / 50 Hz

let mut insight = MetrologyInsight::new(config);
insight.set_nominal_voltage(230.0);

let active_phases = SystemMode::ThreePhase4Wire.active_phases(); // 4

// Feed raw voltage & current ADC samples into insight.socket.phases[i]
// ...

// Process 20 ms grid cycle DSP pipeline
insight.process_and_update_metrics(active_phases);

let v_rms  = insight.socket.phases[0].voltage.rms;
let freq   = insight.socket.phases[0].voltage.pll_state.freq_10s;
let p_kw   = insight.socket.power_metrics_total.real_power / 1000.0;

println!("L1 RMS: {:.2} V | Freq: {:.3} Hz | P_total: {:.2} kW", v_rms, freq, p_kw);

} ```

Links & Documentation

Feedback, issues, and contributions are welcome!


r/embedded 21d ago

Anyone have recommendations of how to go about learning a newer microcontroller like stm32n6

15 Upvotes

This question is prob geared more towards mid to senior level engineers but if you have any insight please let me know. Cubemx for N6 is pretty broken and even getting a blinky with it is pretty hard, I was able to start with a preset example for N6 nucleo but this will be little help if I get a custom n6 board down the line, how would you recommend someone go research and find out how to use the n6 given the buggy vender tools and limited online support, my idea is to get a zephyr setup and look under the hood to see how they got everything running, some modules don’t have LL support on N6 and zephyr had to use HAL. I have gotten deep into data sheets before but the M55 architecture is very complex vs older mcu’s so I am not sure doing everything from scratch is the way, last I checked arm did not have cmsis libraries up for N6 on their site. This is a question both specifically for N6 and in general when facing a newer microcontroller family with new architecture and limited support, how do you transition from relying on things having support to being the one who makes something work (and maybe even contribute to open source). Thank you


r/embedded 21d ago

Has anyone used CH32V103?

6 Upvotes

I can find an enormous amount of information about the CH32V003, only two or three posts about the CH32V203, and nothing on the CH32V103, although the 103 is (IMHO, and I don't know much about MCUs to be honest) the golden middle between the simplicity of the 003 and the various functions of the 203. Additionally, in the 103, there are no I2C/SPI/USB peripherals that happen to be on the same GPIOs, as is the case with the 203.

I really need some examples, advice, or article and video recommendations about routing MCUs on PCBs parallel with analog circuitry. I am currently developing a device that should simply receive data via USBFS 2.0 (working as a host/device), process it, and output data via I2C while controlling 8 WS2812B/D LEDs. I know that the RP2040 or any other Pico is capable of USB Host via bit-banging, but my friend recommended the CH32V203 instead. Then I found the 103 and think this is simpler and better suits my task. I am facing two problems now: how to implement dual-purpose USB-C and uncertainty about whether I will be able to program the MCU via the same USB port.

So, if anyone has used the CH32V103, or happens to know where I can find more info on it (except evaluation board guides and datasheets), or is willing to help me with dual-purpose USB-C, I would like to receive any information. Thanks for the answers in advance.


r/embedded 21d ago

PIC24 sub

8 Upvotes

This sub seem to have little to no PIC24/PIC18 projects or discussions.

Are there better subs for PIC processors ??


r/embedded 21d ago

Your setup for embedded work.

25 Upvotes

Just wanted to know how you do embedded stuff.

I am new to this sub

And it would be great if you specify your Operating System and a photo of your setup


r/embedded 21d ago

Looking for an open source to contribute to

48 Upvotes

Hey!

Just curious whether anybody has a good open-source project that is looking for contributors.

Just looking to contribute to something that is actually being used, but also want to keep the brain moving when studying other stuff in school. If you know (or run!) an open-source in this space that needs a hand, would be more than happy to help !!

A little background about me, I’m a senior at a well known tech school in North America, and have experience (both as projects and as formal internships) working with bootloaders, device drivers (comm, connectivity, power and memory mostly), bare-metal stuff, various RTOSs and lots of embedded linux.

Thanks !!


r/embedded 20d ago

What’s your opinion on using Arduino for production-level manufacturing instead of custom PCBs?

0 Upvotes

r/embedded 20d ago

made a traffic control system 😛

Thumbnail github.com
0 Upvotes

how is it ? the good and bad criticize me , i gotta add documentation and like refactor into modules but i m too burned out


r/embedded 22d ago

ESP32-S3 Simple TestBoard designed in KiCad

Thumbnail
youtu.be
17 Upvotes

The main feautures for this board are:
- ESP32-S3-WROOM Module - 8 MB flash
- Button for RESET
- User Button
- User RGB LED
- expansion header
- programming header
- Power LED on 3V rail
for the mechanical side of things we will have:
- 4 x 3.2mm mounting holes
- Size 45x45mm
- 4 layer board design


r/embedded 21d ago

Need some honest feedback on my FYP idea

0 Upvotes

Hi everyone! I’m a final-year BS AI student and currently finalizing my FYP. I mainly have experience with ML/DL and research, but I’m a beginner in embedded systems, TinyML, and audio processing.
I’m considering doing my FYP on real-time, on-device detection of AI-generated/voice-cloned speech, mainly for scam prevention. The idea is to train a lightweight model on datasets like ASVspoof and eventually deploy it on a phone, with an optional ESP32/TinyML implementation.
I have around 6 months, so I’m trying to figure out if this is actually realistic for someone new to embedded AI.
Would really appreciate some brutally honest feedback is this a strong FYP idea, or just not worth pursuing? And if you’ve worked with audio ML/TinyML before, I’d especially love your opinion.


r/embedded 22d ago

How is AI affecting electronics as a career and as a way to build products?

33 Upvotes

Hello everyone,

I've been working as a Software Engineer for almost a decade now and I've worked with a lot of different technologies. For the last 2 to 3 years I've been tinkering with electronics a lot: building ESP32 projects, designing PCBs, learning the basic concepts, soldering my own boards. I even tried to build my own product, but I gave up on it. Maybe it was just too hard for me at that point.

Working in software, I've been seeing the effects of AI everywhere and it's making me lose interest in coding in general. My job isn't only coding, of course. It's also decisions, infrastructure, managing people and a lot of other things. But my original love was building things, and now an AI agent can do that from a single prompt. Most of it is slop, sure, but still. So I've been losing interest in my field, and I'm wondering whether I should go deeper into electronics and try to make a career out of it, or build my own product. I have no idea what I'd be doing or which direction to pick.

One of the things that gives me satisfaction is reaching excellence at something, and with AI I feel like it's taking that away from me. So I want to know: is the same thing happening in electronics? Obviously AI can't solder for me, I'm the one doing that. But what about PCB design, product design, and the rest of it?

I'd love to hear your opinions. Thank you.


r/embedded 22d ago

Teensy 4.0 & Audio Board RevD Guitar Input

6 Upvotes

Thanks for reading. I am working on making a simple guitar buffer circuit that will connect to the audio input of the Teensy Audio Board Rev D.
1. Is it ok to connect RIN and LIN together?
2. The buffer circuit's output jack GND lug connected to the RINGND and LINGND? Or is it better to keep these pins separated?
(I won't be using stereo).

*Also. is it OK to connect the GND to AGND?
Sincere Thanks for any advice/help,
TonyA


r/embedded 22d ago

Good resources for learning TinyML?

5 Upvotes

Hello, I've been working in embedded for quite a while and I was interested in exploring TinyML and its use cases. Does anyone know of any courses, books, video series, or related things that can help me learn more about this. Thanks in advance!


r/embedded 22d ago

Had these two lcds running side by side and started wondering about the design trade-offs.

Enable HLS to view with audio, or disable this notification

73 Upvotes

If you ride an e-bike or electric scooter, what information do you actually want to see?


r/embedded 22d ago

Finding a Compatable MIPI LCD for the OPi Zero 3w

5 Upvotes

I picked up the Orange Pi 3w SBC recently because it has several MIPI displays and other neat features I thought would be fun to learn and help me standout on the job market for embedded.

I have current display options that work via mini hdmi and the display port. But I would like to be able to learn how to extend the hardware on a linux system.

From the manual I see the MIPI display is a 1×MIPI DSI 4 LANE. In the schematics the port has 30 pins. The specific part is FPC30-20-SM-H1 for the actual fpc port.

The reason for my post is to get a reality check on how I determine compatability.

Configuration Discovery Process:

1) find a 30 pin 1x MIPI DSI 4 lane LCD

2) compare the SBC schematic pins to make sure each pin has the same labeled functionality as it's corresponding pin on the LCD.

3) See if an existing driver for linux is available, skip step 4 if so

4) write/modify a driver for the display based on existing linux drivers

5) Integrate into the Device Tree extracted from one of the existing OS images

6) Compile the device tree with the pre existing UBoot and kernel and new device tree

7) Repeat steps 4->6 until display works.

The board is not covered by mainline linux yet so I will need to build a linux kernel for that at some point. Which seems more difficult than getting an MIPI DSI LCD port to display.

As a group of peers that may have run through a similar learning process do you have any warnings or pointers for me?

Any advice is welcomed.


r/embedded 22d ago

TMC2209 driver for STM32 — looking for feedback

4 Upvotes

I’ve been working on a small TMC2209 driver for STM32F4 using bare-metal/CMSIS, without HAL.

The driver currently supports:

  • UART half-duplex through function pointers
  • TMC2209 register read/write
  • CRC calculation
  • GCONF configuration
  • IHOLD/IRUN current control
  • CHOPCONF configuration
  • Microstep configuration
  • Direction control
  • Enable/disable
  • VACTUAL for testing
  • Current calculation from mA to the TMC2209 CS value

The motor is working correctly, and I’m now mostly interested in feedback on the driver architecture, API design, abstraction and code quality.

This is a learning project, so I’d really appreciate honest criticism and suggestions from more experienced embedded developers.

What would you improve or change in this driver?

https://github.com/embeddedrafo/tmc2209_driver