pub type usbd_cfg_callback = Option<unsafe extern "C" fn(dev: *mut usbd_device, cfg: u8) -> usbd_respond>;
Expand description

USB set configuration callback function

called when SET_CONFIGURATION request issued

Returns:

  • TRUE if success

Arguments

  • dev - [Direction: In] pointer to USB device
  • cfg - [Direction: In] configuration number.

Notes

  • if config is 0 device endpoints should be de-configured