2013-01-20 10:45 PM
Hi is there any way to configure usb_vcp on stm32f103 like usart interrupt mode - just recieve only one byte .
I use function compose_packet(received_byte) in all my USART_IRQHandlers and i want to use same function in USB_LP_CAN1_RX0_IRQHandler. Is there some way to do this ? Thanks for ideas ..... And have a nice day. #usb-vcp-interrupt2013-01-21 03:54 AM
So i got it .....
u8 RX_test [4];
u8 RX_lenght=0;
void USB_LP_CAN1_RX0_IRQHandler(void)
{
USB_Istr();
if ((count_out != 0) && (bDeviceState == CONFIGURED))
{
RX_test[RX_lenght++]=buffer_out[0];
if(RX_lenght>=4){RX_lenght=0;}
count_out = 0;
}
}
:)