AnsweredAssumed Answered

STMCUBE mx - STM32F051 IAR EWARM tool chain

Question asked by duggan.robert.001 on Jul 25, 2015
Latest reply on Jul 25, 2015 by duggan.robert.001
I am just getting started with the Cortex (and C.)

I would like to access an entire GPIO port but cannot find a way to address the port(GPIOF.)  I see the HAL functions for addressing the bits but not the entire port.

Here is the code and error message:

  const uint16_t MotorDriveStateTable[8]={0x0040,0x0060,0x0020,0x00A0,0x0080,0x0090,0x0010,0x0050};
  uint16_t MotorDriveStateCount;
  /* Infinite loop */
  while (1)
      HAL_GPIO_TogglePin(GPIOF, GPIO_PIN_4);
(error)      *GPIOF &= 0x0ff0f;
(error)      *GPIOF |= MotorDriveStateTable[MotorDriveStateCount];
  }/*end while (1) */

-Error[Pe031]: expression must have integral type 

Would any one  be willing to help?