Thank you very much Giovanni!
This has solved the problem, the code now looks like this:
static msg_t Thread6(void *arg)
{
(void)arg;
chRegSetThreadName("GPSdata");
// Activates the Serial driver 2, PA2(TX) and PA3(RX) are routed to USART2, 9600 8N1.
palSetPadMode(GPIOA, 2, PAL_MODE ...
Search found 2 matches
- Sat Sep 07, 2013 8:47 am
- Forum: STM32 Support
- Topic: Reading serial port with event handler
- Replies: 10
- Views: 12406
- Fri Sep 06, 2013 1:34 pm
- Forum: STM32 Support
- Topic: Reading serial port with event handler
- Replies: 10
- Views: 12406
Reading serial port with event handler
Hello!
I am trying to read NMEA data from a GPS using serial driver 2 on the STM32F4 Discovery.
My event listener thread looks like this:
tatic msg_t Thread6(void *arg)
{
(void)arg;
chRegSetThreadName("GPSdata");
static char charbuf; // character buffer
// Activates the Serial driver 2, PA2 ...
I am trying to read NMEA data from a GPS using serial driver 2 on the STM32F4 Discovery.
My event listener thread looks like this:
tatic msg_t Thread6(void *arg)
{
(void)arg;
chRegSetThreadName("GPSdata");
static char charbuf; // character buffer
// Activates the Serial driver 2, PA2 ...