#include<intrins.h> contains the function description

Publisher:GoldenDreamLatest update time:2022-04-20 Source: eefocus Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

Functions included in #include:

_crawl_

Characters rotate left

Shift the char type variable to the left by the specified number of bits and return it (fill the high bit with the low bit)

_cror_

Characters rotate right

Shift the char type variable rightward by the specified number of bits and return it (fill the low bits with the high bits)

_irol_

Rotate left integer

Shift the int variable to the left by the specified number of bits and return it (fill the high bits with the low bits)

_iror_

Rotate right integer

Shift the int variable rightwards by the specified number of bits and return it (fill the low bits with the high bits)

_lrol_

Circular left shift of long integer

Shift the long type variable to the left by the specified number of bits and return it (fill the high bits with the low bits)

_lror_

Long integer circular right shift

Shift the long variable rightwards by the specified number of bits and return it (fill the low bits with the high bits)
_nop_ No operation 8051 NOP instruction
_test piece_Test and clear bit 8051 JBC instruction

Function name 

_crol_,_irol_,_lrol_

Prototype

unsigned char _crol_(unsigned char val,unsigned char n);
unsigned int _irol_(unsigned int val,unsigned char n);
unsigned int _lrol_(unsigned int val,unsigned char n);

Function_crol_, _irol_, _lrol_ shift val left by n bits in bitwise form. This function is related to the 8051 "RLA" instruction. The above functions differ in the parameter type.

Function name 

_cror_,_iror_,_lror_

Prototypeunsigned char _cror_(unsigned char val,unsigned char n);
unsigned int _iror_(unsigned int val,unsigned char n);
unsigned int _lror_(unsigned int val,unsigned char n);
Function_cror_, _iror_, _lror_ shift val right by n bits in bitwise form. This function is related to the 8051 "RRA" instruction. The above functions differ in parameter type.
_testbit_: Equivalent to JBC bitvar to test the bit variable and jump and clear at the same time.
_chkfloat_: Test and return the source point state.

Function name 

_nop_

Prototypevoid _nop_(void);
Function_nop_ generates a NOP instruction, which can be used for time comparison in C programs. The C51 compiler does not generate a function call during the operation of the _nop_ function, that is, the NOP instruction is directly executed in the program.

Function name 

_test piece_

Prototypebit _testbit_(bit x);
Function_testbit_ generates a JBC instruction that tests a bit and returns 1 if it is set, otherwise 0. If the bit is set, it resets the bit to 0. The 8051 JBC instruction is used for this purpose. _testbit_ can only be used on directly addressable bits; it is not allowed in expressions.

 



Reference address:#include<intrins.h> contains the function description

Previous article:#include<stdlib.h> contains the function description
Next article:#include<math.h> contains the function description

Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号