- Can we use const and volatile at the same time?
- const volatile
- difference between union and structure
- Can structures be passed to the functions by value?
- Why cannot arrays be passed by values to functions?
- Advantages and disadvantages of using macro and inline functions
- What happens when recursion functions are declared inline
- Scope of static variables
- Operations involving unsigned and signed — unsigned will be converted to signed ?
- Array of pts to functions
- Which way of writing infinite loops is more efficient than others? there are 3ways
- # error — what it does?
- Who to know whether system uses big endian or little endian format and how to convert among them?
- What is interrupt latency? How can you reduce it?
- What is the difference between hard real-time and soft real-time OS?
- What is the differnce between embedded systems and the system in which rtos is running?
- How can you define a structure with bit field members?
- What are the different storage classes in C?
- What are the different qualifiers in C?
1.
Yes, const means read-only, could not be modified by the code after initialization, volatile tell's compiler do not optimize it using cache. Const Volatile is useful when accessing read-only I/O status register
Bit manipulation
Accessing fixed memory locations // 需要加const关键字吗
complement of integer
https://www.cnblogs.com/qingchen1984/p/7409851.html
reentrant function //可以随时中断,然后再运行的函数称为可重入函数,使用全局变量的函数肯定不是可重入函数
AUOTSAR task 有几种状态 // 就绪、挂起、阻塞、睡眠、运行
Int,short,char在32位平台下各占几个字节?一个结构体含有int、short、char变量各一个,结构体占据的总内存空间多少?
enum枚举
extern
一个变量除以16(不能用*),除以15,如何实现,(<<);
位操作(&,|,~等)
数组定义,指针指向数组,取值操作
指针变量,指针函数,指针数组,指针的指针等;
程序问题,uchar溢出,数据格式问题
一个指针可以是volatile 吗?解释为什么
位操作。给定一个整型变量a,写两段代码,第一个设置a的bit 3,第二个清除a 的bit 3。在以上两个操作中,要保持其它位不变
C语言调用函数过程中,栈是如何变化的?
.Heap与Stack的差别?
在某工程中,要求设置一绝对地址为0x67a9的整型变量的值为0xaa66。编译器是一个纯粹的ANSI编译器。写代码去完成这一任务?
ARM异常有哪些分类?
ARM异常会发生哪些硬件操作?
请简述中断与异常的区别。
引用与指针有什么区别?
什么是bootloader?
哈弗架构 //数据和程序分开
DMA
嵌入式 模拟试题
double float short ?