cancel
Showing results for 
Search instead for 
Did you mean: 

stm32f0 nucleo , no receiving gps data

diegomerida20
Associate
Posted on February 19, 2016 at 23:56

I really need help, This is my first time working with STM32 micro-controllers , I have a gps modulelocosys ls20031, at this point Im only trying to receive data from the gps and display on my terminal (realterm) but im no getting anything. Can anyone please help, I been working on it for days and still no able to receive data. If anyone can tell me what I'm doing wrong, please.

this is my code :

void StartDefaultTask(void const * argument)
{
/* USER CODE BEGIN 5 */
uint8_t in[50];
in[0] = '0';
char * nl = ''Just testing!\n\r'';
uint8_t inSize;
volatile HAL_StatusTypeDef status;
/* Infinite loop */
for(;;)
{
HAL_UART_Transmit(&huart2, (uint8_t *)nl, 6, 0x1000);
// Receive
for (inSize = 0; inSize < 7; inSize++) 
{
status = HAL_UART_Receive(&huart1, &in[inSize], 1, 0x500);
if(in[inSize] == '\n') break;
}
// Send result to PC (opt)
HAL_UART_Transmit(&huart2, (uint8_t *)in, inSize-1, 0x1000);
osDelay(150);
}
}

#no-hablo-hal #gps #selective-cut-n-paste
2 REPLIES 2
Posted on February 20, 2016 at 17:03

Ok, assume we can't see how you have this wired up, or how you have configured the USART or the pins.

PA2/PA3 on most Nucleo's goes to the VCP, and you need to change the solder bridges for the D0/D1 Shield pins.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
LMI2
Lead
Posted on February 23, 2016 at 21:35

Clive1 is right.

They say that every pin in a Nucleo board is accessible, so are the Moon or Mars. There are jumpers below the board, I rather go the Moon and back than find out which jumper is which.  Have you checked that you really have connected your signals to the CPU?