微波EDA网,见证研发工程师的成长!
首页 > 研发问答 > 微波和射频技术 > 天线设计和射频技术 > How to declare Array in the form of Hex and string

How to declare Array in the form of Hex and string

时间:04-05 整理:3721RD 点击:
how to declare string and hex value in the c array

Code C - [expand]
1
char array[]={0x61,0x62,0x63};

Code C - [expand]
1
char array[]={'A','B','C'};

Code C - [expand]
1
char array[]="ABC"; // In this case a extra /0 will be added as 4th element

the size of the array will number of elements given..

#include<stdio.h>
#include<string.h>

void main()
{
char string_[10];
while(1)
{ }
}

Thank you so much

but,
i need to declare string and hex value in the single array

Example:

char arrry[] = {"AD01", 0xD3, 0xFE};// This statement true or else

You can do like this

Code C - [expand]
1
char arrry[] = {'A', 'D', '0', '1', 0xD3, 0xFE};

it work,

explain about the ADS1232 with any controller

What is your requirement with the ADC....

Explain how to access the bit-banging in the serial SPI ADC

software SPI is comparatively easy you have to generate 3 signals and poll one signal..
You have to generate
SS - slave select
MOSI - Master out slave input
SCLK - serial clock

after that you have to get the input
MISO

first of all you have to understand how SPI works and then you can learn Soft_SPI.

上一篇:broadband noise source
下一篇:最后一页

Copyright © 2017-2020 微波EDA网 版权所有

网站地图

Top