Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

help in c keil ARM uvision

Status
Not open for further replies.

5282604

Full Member level 4
Joined
Dec 19, 2009
Messages
194
Helped
3
Reputation
6
Reaction score
3
Trophy points
1,298
Location
egypt
Activity points
2,404
in this code for at91sam9

Code:
AT91C_BASE_PIOA->PIO_SODR = led_mask[i] ;
i'm beginner in c language AND what is purpose from ->


Code:
  AT91C_BASE_SYS->PITC_PIMR |= AT91C_PITC_PITEN;
in this code

what is purpose from
|=

thank's
 
Last edited:

The assignment to the variable PITC_PIMR is made short by the notation '|='

AT91C_BASE_SYS->PITC_PIMR |= AT91C_PITC_PITEN; is as good as

AT91C_BASE_SYS->PITC_PIMR = AT91C_BASE_SYS->PITC_PIMR | AT91C_PITC_PITEN;
 
The assignment to the variable PITC_PIMR is made short by the notation '|='

AT91C_BASE_SYS->PITC_PIMR |= AT91C_PITC_PITEN; is as good as

AT91C_BASE_SYS->PITC_PIMR = AT91C_BASE_SYS->PITC_PIMR | AT91C_PITC_PITEN;

thank you :-D

but what is purpose from ->

:-D:-D:-D:-D
 

The -> de references the object PITC_PIMR of the structure pointed by the AT91C_BASE_SYS. So you can access the member of the structure object through '->'
I wish you good luck.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top