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

BLE ACI verification

Hi, i'm kinda a newbie on this, and i'm trying to port the SDK available for arduino to a PIC, i followed the instructions on the SDK and also here

Now i want to verify that my code is alright by running the ble_aci_transport_layer_verification, but the if statement in the loop function never triggers due to "aci_queue_is_empty" always returns true (aci_q->head == aci_q->tail).

On the other hand, the setup funcion calls aci_queue_init (via hal_aci_tl_init), but this function sets aci_q->head and aci_q->tail to zero. I debugged the rest of the program one line at a time and no other function modifies those values.

So, I'm starting to think that maybe there is a bug on the code, i hope somebody could help me pointing out where the aci queue is initialized (or if i should write a call to aci_queue_enqueue somewhere), thanks in advance

Parents
  • I'm also struggling with a similar problem and have started by porting the MSP430 example to a PIC32, the one that only puts it in UART test mode. It does spit out the 0x01 0x04 0x81 0x02 0x00 0x02 start event but followed by 26 bytes of 0x00 then a 0x07 or 0xD7 randomly. I think it's not nabbing the length packet properly (I'm bit swapping LSB in software as there's no HW support). My problem is an aci buffer overflow.

    I'd be very interested in your complete code if you made any headway to build from as I was going to migrate to PIC18.

    On a side note it would be fantastic if nordic provided more than an arduino example to build from

Reply
  • I'm also struggling with a similar problem and have started by porting the MSP430 example to a PIC32, the one that only puts it in UART test mode. It does spit out the 0x01 0x04 0x81 0x02 0x00 0x02 start event but followed by 26 bytes of 0x00 then a 0x07 or 0xD7 randomly. I think it's not nabbing the length packet properly (I'm bit swapping LSB in software as there's no HW support). My problem is an aci buffer overflow.

    I'd be very interested in your complete code if you made any headway to build from as I was going to migrate to PIC18.

    On a side note it would be fantastic if nordic provided more than an arduino example to build from

Children
No Data
Related