<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/22700/is-there-a-way-to-check-if-the-beacon-transmission-is-continuing</link><description>When running ble_peripheral\ble_app_uart example..... Of course I am a little bit 
 corrected..... 
 Beacons occasionally stop. 
 Despite the following settings:
#define APP_ADV_TIMEOUT_IN_SECONDS 0x0000 // 0 
 If I could check the beacon transmission</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 21 Jun 2017 09:05:24 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/22700/is-there-a-way-to-check-if-the-beacon-transmission-is-continuing" /><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89241?ContentTypeID=1</link><pubDate>Wed, 21 Jun 2017 09:05:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b6cf5826-64ff-4f04-9933-172939329f6b</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;To transfer the error code to the PC, you can use the log module. If UART is already in use, you should use RTT instead. RTT is also supported by the LOG module.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89244?ContentTypeID=1</link><pubDate>Wed, 21 Jun 2017 04:54:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a6ceee8e-d35a-4504-bca5-f70709a192eb</guid><dc:creator>chchoi</dc:creator><description>&lt;p&gt;The main function is to advertise the beacon in general and perform the serial communication when the uart connection is made, and advertise the beacon again after the communication is finished.
Probably it is caused by a part of APP_ERROR_CHECK (err_code2) code. Currently, it is not observed that the beacon is terminated because it has been completely modified.
I am deeply grateful for your advice.
..
How can I leave an error number? In case uart connection or usb connection is not available, how can I get error number to pc when error occurs? Do you know a good way?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89240?ContentTypeID=1</link><pubDate>Tue, 20 Jun 2017 12:53:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:98027c4d-2980-4bd8-ba18-fe6b03354eea</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;What else than advertising does the device do?
If it is only advertising, it shouldn&amp;#39;t be any difference between being in the field and debugging at a desk. An alternative to debug mode is logging over UART.&lt;/p&gt;
&lt;p&gt;Approximately, how often does the error occur? I&amp;#39;m a little confused: &amp;quot;It happens very rarely..... It is hard to find in debug mode...... &amp;quot; and &amp;quot;We are constantly observing that beacons are going down. &amp;quot;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89243?ContentTypeID=1</link><pubDate>Tue, 20 Jun 2017 00:58:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cda2a13d-49c5-4ad3-b191-399f438aeee5</guid><dc:creator>chchoi</dc:creator><description>&lt;p&gt;It happens very rarely.....  It is hard to find in debug mode......&lt;br /&gt;
This is an error that occurs when using the actual field ... Debugging is hard to observe....
However, as of now, it is assumed that .....
at  power_manage(void)  function  ....  APP_ERROR_HANDLER(err_code);
It is estimated that the correction has been made because there is less complementary correction.   ... APP_ERROR_HANDLER(err_code);
so.... We are constantly observing that beacons are going down.
Thank you very much for your response.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89245?ContentTypeID=1</link><pubDate>Mon, 19 Jun 2017 13:10:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ad3bba02-9c05-430f-8b74-d4ab417602a0</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;If you run the chip in debug mode and set a breakpoint in the error handler, you can find the error code and use the callstack to find where the error occurred.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89242?ContentTypeID=1</link><pubDate>Fri, 16 Jun 2017 23:11:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d7bc7b29-7523-48bb-812b-00b26ce9f67c</guid><dc:creator>chchoi</dc:creator><description>&lt;p&gt;I have not found it yet....   Because sometimes it happens ...&lt;br /&gt;
so   I set it to reset when an unexpected error is detected.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89239?ContentTypeID=1</link><pubDate>Fri, 16 Jun 2017 14:23:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9cc306d7-a6a9-43ec-a365-aee1eb8b0af0</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;Which error code do you get?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89247?ContentTypeID=1</link><pubDate>Fri, 16 Jun 2017 10:25:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3dee3124-57c7-433a-8f32-6f600f5d0dac</guid><dc:creator>chchoi</dc:creator><description>&lt;p&gt;thanks answers about my question..... my error handler code is below.....&lt;/p&gt;
&lt;p&gt;// Build advertising data struct to pass into @ref ble_advertising_init. memset(&amp;amp;advdata, 0, sizeof(advdata)); advdata.name_type = BLE_ADVDATA_FULL_NAME; advdata.include_appearance = false;
// advdata.flags = BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE;
advdata.flags = BLE_GAP_ADV_FLAGS_LE_ONLY_GENERAL_DISC_MODE;
// sleep모드 끄기&lt;/p&gt;
&lt;p&gt;memset(&amp;amp;scanrsp, 0, sizeof(scanrsp));
scanrsp.uuids_complete.uuid_cnt = sizeof(m_adv_uuids) / sizeof(m_adv_uuids[0]);
scanrsp.uuids_complete.p_uuids  = m_adv_uuids;&lt;/p&gt;
&lt;p&gt;ble_adv_modes_config_t options = {0};
options.ble_adv_fast_enabled  = BLE_ADV_FAST_ENABLED;
options.ble_adv_fast_interval = APP_ADV_INTERVAL;
options.ble_adv_fast_timeout  = APP_ADV_TIMEOUT_IN_SECONDS;&lt;/p&gt;
&lt;p&gt;err_code = ble_advertising_init(&amp;amp;advdata, &amp;amp;scanrsp, &amp;amp;options, on_adv_evt, NULL);&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89238?ContentTypeID=1</link><pubDate>Fri, 16 Jun 2017 10:20:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:87368e0d-c057-4431-91c5-42e3e6c5e413</guid><dc:creator>chchoi</dc:creator><description>&lt;p&gt;thanks answers about my question..... my error handler code is below.....&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;void APP_ERROR_CHECK2( uint32_t err_code2) {

if ((err_code2 != NRF_SUCCESS) &amp;amp;&amp;amp; // (err_code2 != NRF_ERROR_INVALID_STATE) &amp;amp;&amp;amp; // 8 (err_code2 != 12292) &amp;amp;&amp;amp; // 0x3004 BLE_ERROR_NO_TX_BUFFERS (err_code2 != 13313) &amp;amp;&amp;amp; //0x3401 13313 // BLE_ERROR_GATTS_SYS_ATTR_MISSING (err_code2 != NRF_ERROR_NOT_FOUND) &amp;amp;&amp;amp; // 5 NRF_ERROR_NOT_FOUND 가비지값읽을시 발생 (err_code2 != 0 )) { printf( &amp;quot;%d, %X ,%c \n&amp;quot;,err_code2,err_code2 ,err_code2); printf( &amp;quot;Error Check reset! \n&amp;quot;);
 // 예상외 에러발생시 리셋 코드 추가====================================
       NVIC_SystemReset();  // reset     


 // APP_ERROR_CHECK(err_code2);  
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;}&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89236?ContentTypeID=1</link><pubDate>Fri, 16 Jun 2017 10:19:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:93462dd4-78d1-4958-8678-e2b8311dc617</guid><dc:creator>chchoi</dc:creator><description>&lt;p&gt;thanks  answers  about my question.....
my error handler code is  below.....&lt;/p&gt;
&lt;p&gt;//에러체크코드 점검
void APP_ERROR_CHECK2( uint32_t   err_code2) {&lt;/p&gt;
&lt;p&gt;if ((err_code2 != NRF_SUCCESS) &amp;amp;&amp;amp;    //
(err_code2  != NRF_ERROR_INVALID_STATE) &amp;amp;&amp;amp;  // 8
(err_code2  != 12292) &amp;amp;&amp;amp;   //   0x3004   BLE_ERROR_NO_TX_BUFFERS
(err_code2 != 13313) &amp;amp;&amp;amp;   //0x3401   13313   // BLE_ERROR_GATTS_SYS_ATTR_MISSING
(err_code2 != NRF_ERROR_NOT_FOUND) &amp;amp;&amp;amp;   //  5 NRF_ERROR_NOT_FOUND  가비지값읽을시 발생
(err_code2 != 0 ))
{
printf( &amp;quot;%d,  %X  ,%c \n&amp;quot;,err_code2,err_code2 ,err_code2);
printf( &amp;quot;Error Check reset!  \n&amp;quot;);&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;	   // 예상외 에러발생시 리셋 코드 추가====================================
	   NVIC_SystemReset();  // reset	 
	 
	 
 // APP_ERROR_CHECK(err_code2);	 
	 
	
 }
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;//=============================================================&lt;/p&gt;
&lt;p&gt;// Build advertising data struct to pass into @ref ble_advertising_init.
memset(&amp;amp;advdata, 0, sizeof(advdata));
advdata.name_type          = BLE_ADVDATA_FULL_NAME;
advdata.include_appearance = false;
// advdata.flags              = BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE;
advdata.flags                =  BLE_GAP_ADV_FLAGS_LE_ONLY_GENERAL_DISC_MODE;   // sleep모드 끄기&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;memset(&amp;amp;scanrsp, 0, sizeof(scanrsp));
scanrsp.uuids_complete.uuid_cnt = sizeof(m_adv_uuids) / sizeof(m_adv_uuids[0]);
scanrsp.uuids_complete.p_uuids  = m_adv_uuids;

ble_adv_modes_config_t options = {0};
options.ble_adv_fast_enabled  = BLE_ADV_FAST_ENABLED;
options.ble_adv_fast_interval = APP_ADV_INTERVAL;
options.ble_adv_fast_timeout  = APP_ADV_TIMEOUT_IN_SECONDS;

err_code = ble_advertising_init(&amp;amp;advdata, &amp;amp;scanrsp, &amp;amp;options, on_adv_evt, NULL);
APP_ERROR_CHECK2(err_code);
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;=========================================================&lt;/p&gt;
&lt;p&gt;but  form time to time.... occasionally....... sometimes......
just stop beacon advertisement.............&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89246?ContentTypeID=1</link><pubDate>Tue, 13 Jun 2017 13:13:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3dfa8765-692a-47e4-9193-30a5c72fcc64</guid><dc:creator>erltot</dc:creator><description>&lt;p&gt;Did you change &lt;code&gt;advdata.flags&lt;/code&gt; in &lt;code&gt;advertising_init()&lt;/code&gt; to &lt;code&gt;BLE_GAP_ADV_FLAGS_LE_ONLY_GENERAL_DISC_MODE&lt;/code&gt; instead of &lt;code&gt;BLE_GAP_ADV_FLAGS_LE_ONLY_LIMITED_DISC_MODE&lt;/code&gt; ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Is there a way to check if the beacon transmission is continuing?</title><link>https://devzone.nordicsemi.com/thread/89237?ContentTypeID=1</link><pubDate>Tue, 13 Jun 2017 11:14:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cfb5f1ab-dde5-4aa2-bbef-092e607bb612</guid><dc:creator>FormerMember</dc:creator><description>&lt;p&gt;Unfortunately, there is no way for the application to check if a device is currently advertising. If the advertising timeout is set to &amp;#39;0&amp;#39;, there is no advertising timeout. It therefore has to be another reason why the device stop advertising.&lt;/p&gt;
&lt;p&gt;Does your device at some point gets connected to another device?&lt;/p&gt;
&lt;p&gt;How do you do error handling? If an error is caught by APP_ERROR_CHECK() and the &amp;quot;DEBUG&amp;quot; flag is set, the error handler will go into a infinite loop.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>