Questions tagged [assembly]

This is a programming language that is at a low level that corresponds with the instruction set of the machine being programmed.

Filter by
Sorted by
Tagged with
-1 votes
0 answers
21 views

Best way to LED module depanelling & handling in LED lamp assembly?

Can someone suggest me a better way to handling & depanelling LED modules during LED lamp assembly in mass production? Current process have direct hand contact with module and have pressure on ...
user avatar
1 vote
2 answers
62 views

How do I exit (Microchip Pic18fxxxx rs232 BTFSS PIR1,RCIF) Loop when no data is present (Assembly Mplab Mpasm)

...
user avatar
  • 552
1 vote
0 answers
42 views

Is 35g/in^2 a good "rule" to use for upside down reflow surface tension?

I have one assembler that gave me their "rule" of 35g/in^2 for reflow parts falling off upside down or successfully hanging on. Are there any sources that point to this being any more than ...
user avatar
2 votes
1 answer
82 views

Strange ATmega32 behavior with assembly code

I posted a kind of similar question recently, but it was not that organized, so here I am trying again :) I wrote this short assembly code to blink an LED at different intervals depending on the state ...
user avatar
-1 votes
1 answer
94 views

12 bit vs 10 bit ADC PIC18f [closed]

Convert 12 bits adc to 10 bit adc. We know that the resolution of the step size for a 12 bit is 1.22, different than the step size of 4.88 of the 10 bit. We need to take into account the extra 2 bits. ...
user avatar
  • 127
0 votes
2 answers
36 views

Problem interfacing stepper motor with Atmega 32

I have been trying to interface a bipolar stepper motor with an ATmega32 controller using AVR assembly, but it just keeps clicking without movement or just move back and forth in the same step. Here ...
user avatar
0 votes
3 answers
113 views

8051 seven segment 1-9, and reset to 0

This is a university assignment, last part of 3. I cannot find any useful notes describing looping in the 8051 assembly language in the course resources, and the lecturer isn't replying to questions. ...
user avatar
0 votes
1 answer
72 views

Programming an old school microcontroller (MSM80C49 from OKI semiconductor)

I've read the whole datasheet, there's no typical guidance on programming procedure/setup/circuitry. It just mentions a few steps on how to order pre-programmed chips. (I guess) on page 18. On a ...
user avatar
2 votes
2 answers
64 views

How to draw detailed assembly outline

How do you draw this detailed mechanical/assembly outline? I saw this at this pdf from Altium https://resources.altium.com/sites/default/files/uberflip_docs/file_1195.pdf
user avatar
0 votes
1 answer
68 views

How do we specify the signal frequency while interfacing DAC 0800 with 8086?

I am relatively new to Microprocessors and just started with my uni course on the same. My faculty while discussing the question: gave us the following solution: What I don't understand here is how ...
user avatar
4 votes
1 answer
137 views

How to minimize microcode complexity in 8-bit home-brew CPU

tldr; I built and later extended Ben Eaters 8-bit breadboard computer. After the initial build I integrated 16-bit program counter and memory address registers, redesigned the instruction set and ...
user avatar
1 vote
2 answers
78 views

An Assembler for STM32 and compatible with Ubuntu [closed]

I'm new to STM32. I want to learn the architecture of STM32 using assembly language. but Keil microVision MDK-ARM is not Linux compatible. What is the alternative of Keil to write an assembly code for ...
user avatar
0 votes
2 answers
291 views

ARM asssembler: rotation of bits in immediate value

Consider MVN r3,#0xFFFF807F Is this an invalid instruction from ARM? Since MVN is simply the complement, it equates to ...
user avatar
  • 335
-1 votes
3 answers
340 views

ARM How to invoke branching?

Was looking through a code with regards to loop. ...
user avatar
  • 335
3 votes
1 answer
184 views

ARM Assembly Code

Here's an assembly program given to me, and I'm not sure how the program goes through. ...
user avatar
  • 335
1 vote
1 answer
158 views

Frequency counting program - Timers in 8051

...
user avatar
  • 699
10 votes
3 answers
2k views

How does an operating system or program detect the CPU model name? [closed]

What kind of binary compatibility is present for 2 processors sharing an Instruction Set?. I had asked a question on Computer Science Stack Exchange, to which I got an answer which said: As a trivial ...
user avatar
  • 2,401
1 vote
1 answer
939 views

Store byte instruction in RISC-V assembly

I have a short snippet of RISC-V assembly that I'm having trouble understanding. I'm not sure if I'm interpreting the instructions wrong, from my interpretation it seems as if the branch (BNE) will be ...
user avatar
  • 13
-1 votes
1 answer
47 views

Solar tracking using a helicopter blade control [closed]

I've been trying to build a dual-axis solar tracker but the ones I saw needed linear actuators. I'm thinking how about using SG100 servos with the concept of blade control in helicopters to build the ...
user avatar
0 votes
0 answers
48 views

Battery made of Li-ion cells assembly

Do you see any issue (feasability, safery, ...) about assembling a battery pack with 10 Li-ion 3.7V 2600mAh cells (put in parallel) having their own individual protection circuits (overcharge and over ...
user avatar
0 votes
0 answers
48 views

Read after Write and Write after write dependencie at the same time

Assuming the following pseudo-code down bellow: 1)r1 = 4 2)r2 = 5 3)r3 = r1 + 5 4)r4 = r2 + r1 5)r4 = r4 + r3 6)r1 = 10 7)r7 = r1 - 1 the r4 on line 5 is both name ...
user avatar
1 vote
3 answers
129 views

4-bit mode of LCD-1602 using 8052 µc

I try writing "NO" in the LCD using 4-bit mode. So, I programmed the AT89S52 to send the upper nibble first to the last 4 data inputs of the LCD. I used AND operation to eliminate the lower ...
user avatar
0 votes
0 answers
110 views

Indirect addressing on an assembly program with RAM locations

Here, I have written a indirect addressing assembly program (with PIC18) to copy following to RAM locations 10H to 16H. (It says MERHABA in turkish (means hello) But, I am not sure that the part of my ...
user avatar
  • 31
0 votes
2 answers
55 views

AVR "OUT" function. addressing port without constant

I am currently writing some assembly code that needs to address different I/O ports at certain times in my code. For example, at one point I may want to address PORTD4, and at another point I may want ...
user avatar
1 vote
1 answer
86 views

Is the following 8085-based design I/O mapped or memory mapped?

The above picture is an 8085-based system schematic used for undergrad courses at the laboratory. Now at first sight it seems that the 8085 in the circuit is isolated mapped IO since it uses the IO/M' ...
user avatar
0 votes
1 answer
29 views

ST instruction of avr in microchip stuio (avr studio) nor working as expected

I am trying to understand indirect addressing in avr and tried the following code : ldi r31, 0x28 ldi r26, 0x2c ldi r27, 0x00 st X+, r31 when r26 and r27 are ...
user avatar
0 votes
0 answers
107 views

Offset of bnez in RISC-V program

I came across a question about assembly that I was confused on. We are given the following table for addresses and instructions: The question says: replace the labels of PC-relative targets with ...
user avatar
  • 9
0 votes
1 answer
202 views

Going below the bottom of the stack in ATmega328P

I'm working with an AVR based project and just have one curiosity. The ATmega328P has total 2kB of SRAM. The lowest address of the stack can be 0x8FF. Now suppose the stack pointer is at 0x8FF. What ...
user avatar
2 votes
2 answers
129 views

Microchip's pic-as throws syntax error on macro define

I have a file with a name like xxxx.asm in it I have: InitPORTA MACRO pic-as throws a syntax error on this line. The code ...
user avatar
  • 224
0 votes
0 answers
33 views

AVR Assembly - Operations with two 8-bit registers in 16-bit two complement negative values

I have this code in which I try to multiply the given number by 4. I have two variants and that is that it is negative and positive, but it doesn't work for negative values, you don't know why? ...
user avatar
  • 101
0 votes
1 answer
94 views

AVR Assembly - Operations with two 8-bit registers in 16-bit

...
user avatar
  • 101
-5 votes
1 answer
126 views

Hi everyone, do somebody have experience with usb on assembly level for stm32? [closed]

Need a help with enumeration process, can't receive set_address from hub (PC). when answering to get device descriptor, getting reset but no set_address request only zero-length PKTSTS_SETUP_COMP->...
user avatar
  • 19
1 vote
2 answers
56 views

BANKSEL problem with PIC16F18855

I'm working with PIC16F18855 and have some problem with select memory bank via BANKSEL. In listing I see strange message and it's not working properly. ...
user avatar
  • 17
0 votes
1 answer
216 views

Help in understanding Store Word (SW) instruction in Risc-V

So this is what I understood from what my professor said, but I don't think it's the right answer. What am I doing wrong? I'm sure It's just some small thing that I'm getting mixed up. Given ...
user avatar
0 votes
1 answer
70 views

Help understanding ARM Cortex-M4 SBC instruction

Page 88 of the ARM Cortex-M4 Generic User Guide says "The SBC instruction subtracts the value of Operand2 from the value in Rn. If the carry flag is CLEAR, the result is reduced by one." Why ...
user avatar
0 votes
0 answers
59 views

Why the assembly code does not match the number of cycles of ARM M4?

I ran the following C program on STM32F405 (ARM Cortex-m4). I tried to comprehend its computation period instruction-by-instruction. ...
user avatar
  • 13
1 vote
1 answer
4k views

What is the difference in RISCV between JAL and JALR?

I'm kinda confused on what the difference is between the two instructions and would love a comparison of the two!
user avatar
  • 11
-6 votes
1 answer
91 views

Two microprocessors with same machine language and different assembly language [closed]

I need to find two microprocessors that have same machine language but different assembly language.
user avatar
0 votes
1 answer
486 views

PIC10F200 - blinking LED (pic-as) - Assembly

The code below worked for my 10F206, but now I use a 10F200 and for some reason the led does not blink anymore. (compiler: pic-as 2.30, IDE: MPLAB X IDE 5.40) It compiles but the led stays off. ...
user avatar
0 votes
1 answer
2k views

RISC-V assembly lui?

In RISC-V assembly I wrote: addi s0,x0,0x20000 Is this legal such that the assembler will prove the command and make it work right or I'm forced to change it to: <...
user avatar
  • 11
0 votes
0 answers
61 views

Why we can't do forward in RiscV?

While studying forwarding in RiscV cpu I saw the following claim: But I can't understand why we can't do forward in this case, why in different conditions we were able to do this and now we can't? It ...
user avatar
  • 11
7 votes
1 answer
239 views

ARM Cortex-M4 VFMA (fused multiply-add) performance? 3, 2 or 1 clock? Forwarding?

I am working on some performance-critical DSP code destined to run on an ARM Cortex-M4. One particular section of the code (a sinc interpolation function) is dense with multiply-accumulate operations ...
user avatar
-2 votes
1 answer
314 views

RiscV assembly, function arguments

I learnt that in RiscV assembly we save function arguments in registers s0,...,s7 but what if I had more that 8 arguments? Plus what about the case where I have more than 32 arguments (let's say 40) ...
user avatar
  • 5
-1 votes
4 answers
163 views

Why is bool type typically 1 byte long?

I was reading: https://www.quora.com/Why-is-the-bool-type-typically-8-bits-long And the answer was: Because it’s the smallest type that has an individual memory address so that you can take a pointer ...
user avatar
  • 5
0 votes
0 answers
61 views

How to assess worst case runtime and correctness of an assembly implementation?

Set off by a question on CodeReview, I revisited "8-bit AVR unsigned division". Trying much the same as for below 8 bit/8 bit → Q, R implementation, I found assessment of cycle counts of an &...
user avatar
  • 101
3 votes
1 answer
99 views

How can I improve my LED display code so that it reacts in real time

This is a carry on question from my previous one and I was wondering how I can go about improving my code, which currently has an extreme delay in outputting the numbers to the display and also not ...
user avatar
  • 511
1 vote
0 answers
47 views

How can I exit my lookup table routine with the desired value?

How can I get my code to work correctly when I include ADC conversion in it? I have a working code that displays two digits on 2 LED displays using a p16f1829. However, a problem arises when I try to ...
user avatar
  • 511
-3 votes
1 answer
77 views

Use 3 buttons on PIC16f877a assembly

...
user avatar
1 vote
0 answers
108 views

How can I improve my buzzer application using a PIC16F1829

I am trying to improve my assembly code (see below) for PIC16F1829 by using a macro to set up the parameters to play an audible sound. My previous attempt had used a macro BEEP, which has now been ...
user avatar
  • 511
14 votes
2 answers
2k views

Fiducial marks: Do they need to be a pad or is it okay if I use the top silk layer?

I have been advised by a more experienced engineer to integrate fiducial marks on my designs for P&P automatic assembly referencing, but he didn't say how to do it exactly. I googled it, and I see ...
user avatar

1
2 3 4 5
9