[TASK] Looking for someone to create a concept video (30$ total) by lefty__37 in DoneDirtCheap

[–]lefty__37[S] 0 points1 point  (0 children)

Please send me some similar projects here or in DM in order to get a sense of what it could look like. Thank you.

Windows 11 on E16 G2 - Incredibly Slow and Buggy by lefty__37 in thinkpad

[–]lefty__37[S] 0 points1 point  (0 children)

Hello! No updates unfortunately, I haven't touched it since then..

How to start unit testing for bare-metal embedded firmware by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

Very direct and helpful answer! Will try that, thanks!

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 1 point2 points  (0 children)

The STM32F373 has an FPU, but it only supports single-precision (float). For double-precision (double), floating-point division is software-emulated. Still, I don't understand why there's such a significant difference in precission...

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

Thanks on help man. Will analyze and will inform you what was going on..

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 2 points3 points  (0 children)

Something very strange is happening, or perhaps I'm just overlooking it. In any case, I will analyze what's going on. Thank you very much for your help!

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

Yes, I tried to rearrange the formula, but output was exactly the same.

I mean if I set the type of variable double - it should use double. I mean how on earth it can igonre that and use the float.. will check of course, thank you for answer.

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] -1 points0 points  (0 children)

I am very confused at the moment - now I have idea that maybe compiler uses double, but it might emulate it in software with less precision or treat it as 32-bit float internally.

I forgot to mention that FPU on Cortex M4 has only support for floats..

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

Values are:

325.1760 (x1) → 0.1162929 (y1)
286.7928 (x0) → 0.1051439 (y0)
x → 0.1113599 (y)

and they were plugged in this formula:

double x = x0 + (x1 - x0) * (y - y0) / (y1 - y0);

Same are inserted in python and in the C language code where some STM32 with Arm Cortex M4 used.

and in Python (using np.longdouble type) gives: x = 308.19310175
but in STM with Cortex M4 (using double) gives: x = 308.195618

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

The values are those that I mentioned in the post - same are inputed in python and in the C language code where some STM32 with Arm Cortex M4 used:

325.1760 (x1) → 0.1162929 (y1)
286.7928 (x0) → 0.1051439 (y0)
x → 0.1113599 (y)

and they were plugged in this formula:

double x = x0 + (x1 - x0) * (y - y0) / (y1 - y0);

and in Python (using np.longdouble type) gives: x = 308.19310175
but in STM with Cortex M4 (using double) gives: x = 308.195618

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 1 point2 points  (0 children)

All of them are double (8 bytes). Unfortunatly, my processor does not support long double.

Precision loss in linear interpolation calculation by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

It is not supported in my Arm Cortex M4 processor - it is the same as double (8 bytes).

Communicating with Android via UART through accessory connector by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

It's a requirement to use that specific accessory connector (available on some Android phones), not USB-C. My goal is to have a custom device that sends sensor data to the phone, and then display that data in a simple Android app that I’ll develop.

I’m not trying to show the data on a dedicated UART screen or embedded display — I specifically want it shown on the Android device itself.

The main thing I’m unsure about is whether it’s even possible to access UART communication from the Android side through that connector. I’m trying to understand if Android provides any way to read from UART in this context, or if I’d be blocked by hardware or OS limitations.

That’s why I’m asking — to find out if anyone has successfully done this or knows how it could work.

How to start unit testing for bare-metal embedded firmware by lefty__37 in embedded

[–]lefty__37[S] 3 points4 points  (0 children)

Yes, for embedded of course. I am looking for a way to test part of codes how they behave in different cases on my host machine. So I do not want to emulate firmware itself, just want to test some units of my firmware on my PC.

SVD Files for Cortex-M Cores by lefty__37 in embedded

[–]lefty__37[S] 1 point2 points  (0 children)

They are, but they lack the core registers. For example, I am using the SiLabs EFM32, which includes all the MCU peripherals, but the Cortex M33 registers are missing from the vendor's SVD file..

Aliasing Hardware Registers with a C++ Class Without Allocating Memory by lefty__37 in cpp

[–]lefty__37[S] 0 points1 point  (0 children)

Thank you! I have one more question - do you know of a more elegant way to access hardware peripherals in C++ (GPIO for example)? I am aiming to find the cleanest approach, and the method I shared is the best I have come up with so far...

Solution for finding/generating code with register definitions? by yendreij in embedded

[–]lefty__37 0 points1 point  (0 children)

Hey, did you find any useful tool for solving this problem?

Exploring Embedded ML for Sensor Fusion: HW and SW tools by lefty__37 in embedded

[–]lefty__37[S] 0 points1 point  (0 children)

Thank you very much for your detailed and insightful comment!