35,409 questions with no answers
0
votes
0
answers
34
views
IOCTL_ATA_PASS_THROUGH Returning ERROR_ACCESS_DENIED When Calling DeviceIoControl
I am trying to retrieve the SMART Data of an external SATA SSD
wchar_t path[64];
swprintf_s(path, _countof(path), L"\\\\.\\PhysicalDrive%d", 0);
HANDLE hDrive = CreateFile(path, GENERIC_READ ...
4
votes
0
answers
73
views
Optimized Assembly Generation for Unsigned Multiplication Leads to Unexpected Result for Cortex-M0+
I was experimenting with some fixed-point arithmetic on the Cortex-M0+ in Godbolt's compiler explorer and came across an interesting behaviour with respect to the optimisation of a multiplication ...
3
votes
0
answers
82
views
Cross-compiling GLIBC for ARM
I am tying to cross-compile GLIBC_2.36 from source for ARM. I am using arm-linux-gnueabihf toolchain to do this. The command I am passing from my build directory is below:
../glibc-2.36/configure --...
2
votes
0
answers
39
views
I can't figure out why my stm32 spi peripheral is not working
So i am learning the stm32f103c8t6 board, and after having used the hal, i am trying to create my own peripheral driver, but i can't seem to get the spi working, I am trying to communicate with an spi ...
2
votes
0
answers
50
views
How to display a label as message window in Motif MainWindow
I want to use the Motif MainWindow using:
A container as work region
A label as message window.
But the label is not shown.
My expectation is that it would be shown below the container (work region)....
2
votes
0
answers
103
views
How do I properly use Libwebsockets' JSON parser (LEJP)?
Trying to figure out how the built-in JSON parser in libwebsockets works. From my understanding of the documentation, you're supposed to call lejp_parse(), giving it a JSON-formatted string and a ...
0
votes
0
answers
36
views
SNMPv3 requests sent to an STM32/LwIP agent time out, v2c works fine
I am implementing an SNMP agent on an STM32H563 using LwIP. SNMPv2c works perfectly, but SNMPv3 requests with the authPriv security level time out.
On the manager's side, a request is sent with net-...
5
votes
0
answers
320
views
+50
When should I use name resolution vs. RegisterNatives in JNI?
In System.c, the JVM function corresponding to Java’s System.currentTimeMillis() is registered using RegisterNatives.
In contrast, System.identityHashCode(Object) calls a JVM function directly based ...
1
vote
0
answers
104
views
Writing to a NOR flash chip from a C application
I am doing bare-metal development and interfacing a microcontroller with a SPI NOR flash chip for storing NVS key-value data. My NVS key-value struct takes up 160 bytes and looks like this:
typedef ...
1
vote
0
answers
65
views
Excel UI thread freezes on async function invocation
I am kind of confused, I was following the "Excel 2013 SDK" documentation, and bein interested in User defined Asynchronous functions. Here is my simplest example, it doesn't even do ...
2
votes
0
answers
176
views
how to execute x64 ABI assembly code on heap from C
I am creating heap allocated memory with execute rights using windows.h VirtualAlloc and VirtualProtect.
void* write_into_executable(uint8_t code[]) {
SYSTEM_INFO info;
GetSystemInfo(&info)...
2
votes
0
answers
64
views
DS3234 incorrect value on STM32
I am trying to use a DS3234 with a STM32. (on STM32CubeIDE)
Is answer me with some value but for some reason,
Every value is divided by 2 except for the month.
Second are updated every two (real)...
2
votes
0
answers
68
views
How to stop Background Worker?
I have my extension and start background worker in the PG_init proc
BackgroundWorker worker;
/* set up common data for worker */
memset(&worker, 0, sizeof(worker));
snprintf(worker.bgw_name, ...
0
votes
0
answers
93
views
Trying to add rounded rect with cairo inside dwm (fails horribly)
i was trying to make a drw_rect_rounded function inside drw.c using cairo to make it not jagged and have antialiasing
but everytime i to run it the dwm it just give me Segfault
Expected Result:
i can ...
0
votes
0
answers
35
views
"arm-none-eabi-gcc: fatal error: no input files" PlatformIo x STM32
I am trying to use platformIo with vsCode on Windows. I managed to compile it twice, but now I get the same error, even after cleaning everything or deleting the .pio file. I also tried the command ...