Ejemplo n.º 1
0
void board_userled(int led, bool ledon)
{
  if (led == BOARD_LED1)
    {
      stm32l4_gpiowrite(GPIO_LED1, ledon);
    }
   else if (led == BOARD_LED2)
    {
      stm32l4_gpiowrite(GPIO_LED2, ledon);
    }
}
Ejemplo n.º 2
0
void board_autoled_off(int led)
{
  if (led == 1)
    {
      stm32l4_gpiowrite(GPIO_LD2, false);
    }
}
Ejemplo n.º 3
0
void board_autoled_on(int led)
{
  if (led == 1)
    {
      stm32l4_gpiowrite(GPIO_LD2, true);
    }
}
Ejemplo n.º 4
0
void stm32l4_usbhost_vbusdrive(int iface, bool enable)
{
  DEBUGASSERT(iface == 0);

  if (enable)
    {
      /* Enable the Power Switch by driving the enable pin low */

      stm32l4_gpiowrite(GPIO_OTGFS_PWRON, false);
    }
  else
    {
      /* Disable the Power Switch by driving the enable pin high */

      stm32l4_gpiowrite(GPIO_OTGFS_PWRON, true);
    }
}
Ejemplo n.º 5
0
void board_userled_all(uint8_t ledset)
{
  stm32l4_gpiowrite(GPIO_LED1, !!(ledset & BOARD_LED1_BIT));
  stm32l4_gpiowrite(GPIO_LED2, !!(ledset & BOARD_LED2_BIT));
}