Questions tagged [arm]

This tag is used for questions related to the ARM (Advanced RISC Machine) family of computers; that is machines or electronics running on ARM processor cores or systems using an ARM core.

0
votes
0answers
10 views

Why is my function not looping? And how would I create this function in ARM Assembly?

Click for question description This code is implemented using ARM assembly and there is a main function calling the magic number function inputting the 'Yusuf Ozturk' /* * AssemblyFunctions.S * */...
4
votes
1answer
76 views

Optimized handling of tag (empty struct) function parameters

In some circumstances, we use tags to discriminate between functions. A tag is usually an empty struct: struct Tag { }; Suppose that I have a function, which uses this tag: void func(Tag, int a); ...
0
votes
1answer
13 views

Relationship between U-boot CONFIG_SYS_TEXT_BASE and SDRAM

At present, my understanding of u-boot is as follows ROM Code load SPL SPL initialize RAM, and load u-boot to CONFIG_SYS_TEXT_BASE RAM address u-boot relocates itself Boot the kernel I check my u-...
-1
votes
1answer
36 views

Compiler Baremetal (arm-none-eabi) - Compiler Implementation

It is common practice to declare stack variables (variables allocated on the excecuting stack rather than dynamically or statically) at the entrypoint of the function rather than mixed with ...
0
votes
0answers
21 views

IAR Teminal IO not logging printf output

I am building an embedded application project using the IAR Embedded Workbench Arm 8.30.1. I used printf statement to log output to the Terminal IO. However, i can't see the output logged to the ...
-1
votes
1answer
50 views

Problem with time() function in embedded application with C

I am Using time() function in programming my ARM controller. The processor restarts as soon as it reaches this function. Thats strange that when I m in debug mode the code work perfect but as soon as ...
2
votes
0answers
29 views

How to patch Eigen 3.3.7 to workaround a GCC 8.2.1 bug (arm-none-eabi 8-2018q4-major toolchain)?

I was trying to compile Eigen 3.3.7 with Arm's bare metal 8-2018q4-major toolchain and see the very same error (see the x86_64 variant question). It was just plain unlucky for ARM to pick an affected ...
0
votes
1answer
21 views

Position independent binary for Atmel SAM Cortex-M0+

I am trying to create a position independent binary for a Cortex-M0+ using the ARM GNU toolchain included with Atmel Studio 7 (arm-none-eabi ?). I have looked many places for information on how to do ...
0
votes
2answers
39 views

ARM assembly appending multiple bits

The aim of my program is to take the value in register 0 and copy it in the form '1011' into register 1. EDIT I did not initially make this clear, not to be achieved with a simple mov, the goal was ...
1
vote
0answers
48 views

Thread on ARM processor [on hold]

I'm currently working on a project with a Reach M+ (which is a GPS combine to an IMU). This device works with a light Linux version on a ARM processor. With this Linux version, I don't have "apt-get", ...
0
votes
0answers
12 views

arm_cmplx_mag_q31 return all zeros

The result of arm_cfft_q31 is all right, but the arm_cmplx_mag_q31 returned all zeros, what happended? I should not be overflow here, since the fft results is too small. ...
1
vote
1answer
23 views

SegFault when calling function in asm

I started to learn calling a function in assembly. I followed much tutorial in the internet and make some modification to it. But it doesnot really work as expected. .data hello: .ascii "hello ...
0
votes
0answers
36 views

ARM vs. i686 different memory behaviour on Android [on hold]

As testing my (NDK-included) application, I've realized that memory allocation(C-malloc/calloc) differs depending on the processor. On Intel(emulator), I can see the allocated object in the same ...
0
votes
1answer
28 views

GPU ARM Mali and OpenCL driver

I have my TinkerBoard powered by an ARM-based Mali™-T764 GPU. I am running Debian linaro v2.0.8 strech. I am looking for an OpenCL support, how can I enable the GPU MALI with OpenCL 1.2 FP? If you ...
0
votes
0answers
27 views

Relocation out of range; R_AARCH64_ADR_PREL_PG_HI21; Variable via Linker script;

I got an linker relocation error relocation R_AARCH64_ADR_PREL_PG_HI21 out of range: 8556371968 is not in [-4294967296, 4294967295] There is a code which uses this relocated symbol (simplified, not ...
0
votes
1answer
34 views

chip erase via SWD on M0+

I want to flash a M0+ device via SWD. This is realized by a host processor instead of a programmer. Im already able to write and verify into RAM but not into flash. It seems to be a bit different ...
0
votes
2answers
32 views

Different between Systick and Timer in ARM M4

I completed a basic microprocessor with 8051. In this course I learned using a timer to trigger an event. After a semester, I learned programming Embedded System with ARM Cortex M4 (Tiva C launchpad) ...
2
votes
1answer
45 views

GPRbuild: compiler switch being passed to linker

I'm building a simple program for ARM. GPRbuild outputs the following: gprbuild -p -P avocado_test.gpr (in directory: /home/rodeo/Projects/AvocadoTest) Bind [gprbind] run_avocado_test.bexch ...
0
votes
1answer
35 views

How do I instruct ARM cortext to do tail chaining of interrupts or stack pop pre-emption?

Is there any special mode or registers I need to set so that the ARM processor having NVIC uses tail chaining and stack pop pre-emption of interrupts.
0
votes
0answers
67 views

Reverse engineering a compression algorithm to decompress ASCII text [on hold]

I'm trying to decompress a very long text block from an ARMv5t powered Gameboy Advance ROM, which was compressed using some kind of custom LZ-esque compression algorithm. The decompression algorithm, ...
0
votes
0answers
27 views

Makefile (xcrun): file was built for x86_64 which is not the architecture being linked (arm64)

I created a project that I've "finished" but the fact is that is NOT an Xcode project so I compiled it for x86_64 and not for ARM.. when I saw that it was the wrong arch., I modified the makefile ...
2
votes
1answer
32 views

Line numbers in GCC output object file not preserved when linking to ELF

I am trying to build a basic project for ARM with symbols and associated line numbers, so that I can easily debug the project from GDB Multiarch while it is running in QEMU. I have two files, a C ...
0
votes
1answer
29 views

IAR fails to compile mutex library for ARM AM3357, Fatal Error Pe035

I'm trying to implement the EtHash algorithm in the AM3357 microcontroller, but when I try to include the mutex library it shows the following error: Fatal Error [Pe035]: #error directive: "IAR ...
2
votes
1answer
25 views

GDB automate commands after symbols have been loaded

I'm debugging a microcontroller with GDB remote. I have multiple build targets and I would like to have one generic .gdbinit file for flashing and/or debugging all the different targets. I'm ...
-3
votes
0answers
32 views

HEX to ASCII conversion algorith

I am trying to convert HEX digit to ASCII. I have a max of 32bit HEX digit. I am using 4 bit LCD and trying to write assembly code to display decimal values where I have values in hex. I have a large ...
0
votes
1answer
31 views

Problems using branching in Arm Assembly

So my code just displays both outputs like it is not branching to the then statement. I just started learning arm and I cant figure out what is going on and why it won't branch. Any help would be ...
0
votes
1answer
24 views

STM32L0 Freeze on setting NVIC/GPIO

I'm working with an STM32L073RZ CPU running MbedOS 5.11.2. Eventually I aim to get this working in a very low-power mode (STOP mode) that will be awoken with either an RTC interrupt or an interrupt ...
-1
votes
1answer
30 views

Linux on Arm Cortex- M1 [closed]

I am new on embedded programming. Now I am a bit confused about ARM Cortex M1 series. I need to know, can I run Linux on ARM Cortex-M1 based fpga system. When I search the web I couldn't find any ...
1
vote
0answers
15 views

How to use thrift on arm

I'm trying to use thrift for C++ and javascript running on my ARM device, and the project is built on a Linux host machine with a IDE for this ARM device. My question is that when and how should I ...
1
vote
1answer
40 views

Confusion about `ldmdb` in ARM assembly

The ARM docs for the ldmdb instruction seem to contradict themselves. Under the description of addr_mode, the docs state that the DB address corresponds to "Decrement address Before each access". ...
1
vote
0answers
49 views

LCD interfacing with ARM cortex M0+ lpc845

I'm trying to interface 8x2 lcd using parallel interfacing[4 bit mode], Display used - 8x2 lcd [PC 0802--A] ST7066U--Dot Matrix LCD Controller/Driver Since i'm trying to interface using GPIO pins, ...
0
votes
0answers
17 views

Access to unaligned memory location in ArmSim

I have the following piece of code : .data space: .asciz " " var1: .skip 4 var2: .skip 4 msg1: .asciz "Enter lower limit : " msg2: .asciz "Enter upper limit : " .text .global main main: mov r0, #...
-1
votes
1answer
37 views

Package not found after apt-get install

I have a problem, I just installed debian linux on my netgear stora and I try to sudo apt-get install [some-package]. It installs but when I run it, it says Command not found. Here is my uname -a: ...
1
vote
1answer
48 views

How to get a hard fault exception with a simple or instruction on arm

Currently we are hunting a phantom, which is in the form that when we compile in some code (without calling it) one specific call to memset generates an hard fault exception. The address and length ...
0
votes
0answers
27 views

fatal error when compile linux kernel 5.0 on board exynos4412

hope i could explain the question i have a board- exynos4412, i try to run linux kernel 5.0 on my board. when i compiled the kernel, a error i can't understand occured. arch/arm/boot/dts/exynos4....
0
votes
3answers
102 views

:lower16, :upper16 for aarch64; absolute address into register;

I need to put a 32-bit absolute address into a register on AArch64. (e.g. an MMIO address, not PC-relative). On ARM32 it was possible to use lower16 & upper16 to load an address into a register ...
2
votes
2answers
80 views

What are assembler section directives used for?

I'm trying to learn ARM assembly. After writing this small Hello World program: .global _start .text _start: ldr R1,=msgtxt mov ...
1
vote
1answer
32 views

Deploy an Azrue VM from an ARM template via Powershell Runbook without downloading template

This article shows a tutorial how to deploy some resources from ARM templates in a powershell runbook. And as I understand, it will download the template and the parameters files in the specific path. ...
3
votes
0answers
3k views

My program is crashing at 0x16 even with my ROP chain

So I recently started working on my binary which is vulnerable to Use-After-Free. I found it too easy to just jump to secret(). So I added a variable to the _DATA section and set its value to 0. and ...
2
votes
1answer
48 views

why does ld finds an undefined reference in another function than the one having the reference

as a hobby I'm trying to learn ARM assembly after briefly seeing it years ago in College. I modified a little pseudo Hello World program (found in a book) this way : .global _start ...
0
votes
0answers
31 views

ARM - Link register in exception

I have this code for an IRQ exception for my raspberry pi: push {r0-r12, lr} mov r1, r11 str r1, [r0, #GPIO_EVT_STAT0] ldr r5, =State ldr r2, [r5] tst r2, #0x01 streq r12, [r0, #GPIO_OUT_CLR0] strne ...
1
vote
1answer
102 views

Pharo on RaspberryPi: Module not found at startup

I am on a raspbian stretch system with the spur32 VM for ARM and a Pharo 7 image. At Startup I always get an exception: Error - Module not found. It seems to have to do with lgitlibrary. I really ...
2
votes
1answer
35 views

Data overriden when branch to PendSV

I have a little "os" for an arm cortex m4. I implemented a wait function. But since then somehow, the context switch is corrupted. When stepping through the instructions i noticed, that for whatever ...
0
votes
0answers
15 views

trigger pendsv from svc || trigger systick manually cortex m4

i am currently working on an arm cortex m4. I implemented a simple context switch by triggering PendSV (which does the switch) from the SysTick interrupt. I tried to implement a void delay(int ms) ...
-1
votes
1answer
53 views

c++ Segmentation fault when do list.push_back(), correct on the host, error on the arm

Program received signal SIGSEGV, Segmentation fault. 0x400741e0 in std::_List_node_base::hook(std::_List_node_base*) () from /mnt/yaffs2/Cdatabox/lib/libstdc++.so.6 (gdb) bt #0 0x400741e0 in std::...
1
vote
4answers
97 views

Where does the DMA store ADC values in STM32?

I enabled DMA peripheral to memory tranfer for ADC1 in CubeMX and generated the code. However I'm confused as to where the data from the ADC will be written to? Should I explicitly define a variable ...
0
votes
1answer
44 views

signed double to unsigned byte: ARM64 versus Win64

For some legacy reasons I have code that casts a double to unsigned byte and we are seeing much difference between the two platforms. Short of doing - "don't try to stuff a signed value into unsigned ...
1
vote
0answers
36 views

Is NHibernate 5.x compatible with ARM architecture?

We are developing a .net core 2.0 background application for Raspberry PI 3 with Windows 10 IoT. We want to use NHibernate 5, Fluent NHibernate 2.1.2 and SQLite core. Is NHibernate 5.x compatible ...
0
votes
1answer
42 views

qemu-system-arm -redir invalid option

Trying to follow https://azeria-labs.com/emulate-raspberry-pi-with-qemu/ to set up the lab. The following command is giving an error qemu-system-arm -kernel '/root/Documents/Raspbian qemu/qemu-rpi-...
-1
votes
0answers
17 views

Has anyone tried building impala on ARM/aarch64?

I am trying to build Impala on ARM/aarch64, But I did not find any useful guide/document to read. I noticed that there are some assembly code in Impala and third-party code, Has anyone tried building ...

http://mssss.yulina-kosm.ru