Questions tagged [flag]

Programming flag is a bit or value that, a program uses to remember something

0
votes
1answer
14 views

PCA9956A How to set AIF bit

I am using the https://www.nxp.com/docs/en/data-sheet/PCA9956A.pdf chip to control LEDs. To set the autoincrement mode three beets are needed, But the AIF bit is ...
-1
votes
1answer
222 views

Parity flag in 8085 microprocessor

What happens to the parity flag of an Intel 8085 microprocessor when there is no '1' bit in the accumulator? For example, if the following instruction executes, MVI A, 05H MVI B, 05H SUB B the ...
0
votes
2answers
58 views

How to read flag register in datasheet?

I'm having troubles deciphering the datasheet for the DS3231 RTC. The below table shows that 0x02 bit 6 is the flag to operate in 12- or 24-hour mode. But which one correspond to the bit being low or ...
3
votes
1answer
55 views

Are flags strictly related to interrupts or not?

If we want to some flag to be set when true (for example FIFO is full), does that mean that we have to enable the interrupts? Whether it will be set if interrupts are not enabled? Are that flags ...
0
votes
3answers
1k views

Overflow results into wrong sign-flag bit set in 8085 microprocessor .

In case of 8085 microprocessor when the MSB bit of accumulator is 1 then sign flag becomes 1 ( simply copy the result's msb) , my question is that : When we add two positive numbers say 44H(01000100) ...
0
votes
1answer
319 views

Assembler language basics parity flag

I am a beginner in assembler language I was reading some stuff online(belongs to a university) and I saw that the P bit in psw after executing this instruction mov a,#03h A=0000 0011B so P=0 first ...
3
votes
3answers
2k views

How was the Zero Flag implemented on Z80 ALU?

Z80 was a popular 8-bit processor with a 4-bit ALU. Implementing a zero flag for a register should be straight forward, it would be a logical NOR of all the bits ...
0
votes
1answer
2k views

8080 assembly comparing which of the numbers is greater etc

In my 8080 assembly project I need to check if user entered digits and if so do some stuff on it, otherwise display some error and close app. Normally i would do it like that ...
2
votes
1answer
209 views

The same flag for an interrupt

I think I'm mixed up a bit in NVIC of stm32 MCUs. I took a look in the SPI.h of the STM32F10x standard peripheral library. I don't know that why while there is ...