mahm150
Full Member level 1
- Joined
- Dec 14, 2010
- Messages
- 98
- Helped
- 1
- Reputation
- 2
- Reaction score
- 1
- Trophy points
- 1,288
- Location
- Cairo, Egypt, Egypt
- Activity points
- 2,001
void arrange_message(unsigned char [B]data_wrtn[/B] , unsigned char data_order);
{ temp1[p]= *( &data_wrtn + p ) ;}
void arrange_message(unsigned char * (???) ,unsigned char data_order);
declare the function
****************
void arrange_message(unsigned char data_wrtn ,unsigned char data_order);
call the function.
**************
arrange_message(THREE[j],1);
definition of function
*****************
oid arrange_message(unsigned char data_wrtn , unsigned char data_order)
{
unsigned char p;
if(data_order==1)
for(p=0;p<=7;p++)
{ temp1[p]= *(&data_wrtn+p);}
}
****************************************
what do u mean ?if you pass a char parameter than you can't use it as an address to get the rest of the array data, the memory position of this variable is not related to the array so you can't read the rest of the array like a contiguous memory space.
Alex
i see it avr simulatorand how do you check the value of temp1?
what was the value of temp1?
Alex
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?