This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

sending something else and receiving something else!

Im sending an 8 bit int using my AVR controller as follows:

 static uint8_t* dummy_heart_rate = 6;

  aci_loop();
  
  if (lib_aci_is_pipe_available(&aci_state, PIPE_UART_OVER_BTLE_UART_TX_TX))
  {
	  lib_aci_send_data(PIPE_UART_OVER_BTLE_UART_TX_TX, dummy_heart_rate, 1);
	  aci_state.data_credit_available--;
      PORTD |= (1 << PORTD6);
  }
  
  _delay_ms(100);
  PORTD &= ~(1 << PORTD6);

but im reciving wrong data back in the nordic app , I get 0x00 and when I send 65 I get @ in the nordic toolbox app , then again if I send something else like an 8 then I receive something else instead of an 8 on nodic app I get 0x00? whats happening ?

If I send 45 as a char variable then I get � character with 0xC0 which is correct in the Ascii table, what Im doing wrong?

Related