This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Reason for no Bluetooth signal?

I'm trying to finish a handmade custom board I started. I had previous problems with the crystals, and a few others, but right the thing seems to be working ok. At least I checked with UART that the board is running the hole code. I'm trying a simple Beacon example. But with the nRF Beacon application for Android I'm not seeing any signal. Even with the telephone touching the board. The board has a nRF51822FAAG0 with the balun BAL-NRF01D3, and a Johanson 2450AT43A100 chip antenna. I'm really lost here, I have a series of reasons in mind why the Bluetooth signal it's measing:

  1. A soldering problem with the balun. I had resolder the compoment a couple of times, I'm almost sure that it's in his right position, but it's very tricky to solder.
  2. The shunt capacitor of the antenna. I have a 1.5pF capacitor there, when the recommended it's 0.8pF. I'm trying to get the 0.8pF one.
  3. The 16Mhz crystal. I have this crystal with 18pF capacitors with 5% tolerance (the crystal load capacitance is CL = 12pF). The frecuency tolerance it's ok? Really don't sure because the datasheet it's not very clear.
  4. The design of the board and the code used it's from the OpenBeacon proyect. So, it's suppose to be a working proyect.

Can you help to understand where can be the problem? What can I try next? Thank you so much.

I leave here the schematics of the board, and a Photo of the proyect. image description image description

Update: And also the scope of the VDD_PA I got. image description

OpenBeacon.PDF OpenBeacon2.PDF

UPDATE: This is the code of my advertisment function.

static void radio_send_advertisment(void)
{
	const TMapping *map;
	int My_tasks_txen;

	/* transmit beacon on all advertisment channels */
	map = &g_advertisment[g_advertisment_index];

	/* switch frequency & whitening */
	NRF_RADIO->FREQUENCY = map->frequency;
	NRF_RADIO->DATAWHITEIV = map->channel;

	/* BLE header */
	g_pkt_buffer[0] = 0x42;

	/* add MAC address */
	g_pkt_buffer[2] = (uint8_t)(g_uid>>24);
	g_pkt_buffer[3] = (uint8_t)(g_uid>>16);
	g_pkt_buffer[4] = (uint8_t)(g_uid>> 8);
	g_pkt_buffer[5] = (uint8_t)(g_uid>> 0);
	g_pkt_buffer[6] = 0;
	g_pkt_buffer[7] = 0;

	/* No BT/EDR - Tx only */
	g_pkt_buffer[8] = 2;
	g_pkt_buffer[9] = 0x01;
	g_pkt_buffer[10]= 0x04;

	/* append beacon packet */
	g_pkt_buffer[1]= BLE_PREFIX_SIZE+g_beacon_pkt_len;
	if(g_beacon_pkt_len)
		memcpy(
			&g_pkt_buffer[BLE_POSTFIX],
			g_beacon_pkt,
			g_beacon_pkt_len
		);

	/* set packet pointer */
	NRF_RADIO->PACKETPTR = (uint32_t)&g_pkt_buffer;

	NRF_RADIO->EVENTS_END = 0;

	/* start tracker TX */
	NRF_RADIO->TASKS_TXEN = 1;
	My_tasks_txen = NRF_RADIO->TASKS_TXEN;
	debug_printf("\n\rTasks_TXEN = %d\n\r", My_tasks_txen);
}

void POWER_CLOCK_IRQ_Handler(void)
{
	/* always transmit proximity packet */
	if(NRF_CLOCK->EVENTS_HFCLKSTARTED)
	{
		/* acknowledge event */
		NRF_CLOCK->EVENTS_HFCLKSTARTED = 0;

		/* start advertising */
		radio_send_advertisment();
	}
}
  • Hi Daniel,

    Given that "VDD_PA" toggles, and your CLOCK source is started, the radio will have a stable clock for generating the carrier. You should be able to get a couple of centimeters of range, even if the BALUN is not soldered properly. Have you tried to use nRF Master Control Panel for Android to try to pick up the advertisement? Place the phone more or less on the chip and see if you can pick up anything.

  • Hi Håkon. This is taking a lot of problem. But I can feel the end so close... Yes, I have tried the nRF Master Control panel with Android. I have a Galaxy 3 mini with Android 4.3 (I did the upgrade for myself, maybe the problem it's in the phone?). I will try with the phone on the chip like you say. I had tried it before, and I always put the phone very cose, almost touching the beacon. But maybe if I put it on the chip like you say.... So, what do you thing about the external antenna? There is any possibility to check the signal on the ant1 and ant2 pins? I haven't check that. Which kind of signal I might expect? Which frecuency? When you say me that I should be able to get a couple of centimeters of range I start to think that the problem can be in the code? Why, when I tried the softdevice code, didn't run completed? Thanks again for your help!

  • Hi Håkon. I tried what you suggested. Not signal even with the phone on the chip. Then I started to check the code, and I noticed something very strange with the advertisment function. I added the code and the problem like an update of the original question.

  • You cannot read any TASKS_X register, as this is a write-only register. Instead, you should check the NRF_RADIO->STATE register to see if the radio is running. Do you have any other boards to test on, and see if the behavior is equal?

  • No, I don't. :( Ok, that's a good reason. You think that there is no sense to try the external entenna? I did the antenna circuit of this example

Related