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

Issue: CONFIG_ACCEL_CALIBRATE is NOT generated for PCA20035

Hi, 

I would like to read accelerometer value from orientation_detector_calibrate()  (in asset_tracker/src/orientation_detector/orientation_detector.c). 

But from main.c (in asset_tracker/src/main.c). it has a dependency on "CONFIG_ACCEL_CALIBRATE", which is defined like below. 

#ifdef CONFIG_ACCEL_USE_SIM
#define FLIP_INPUT CONFIG_FLIP_INPUT
#define CALIBRATION_INPUT -1
#else
#define FLIP_INPUT -1
#ifdef CONFIG_ACCEL_CALIBRATE
#define CALIBRATION_INPUT CONFIG_CALIBRATION_INPUT
#else
#define CALIBRATION_INPUT -1
#endif /* CONFIG_ACCEL_CALIBRATE */
#endif /* CONFIG_ACCEL_USE_SIM */

After some debugging, I got to know that, these CONFIG_ macro values should be automatically generated and must be in "ncs\nrf\applications\asset_tracker\build\zephyr\include\generated\autoconf.h

But unfortunately, I didn't see them in "autoconf.h" for the PCA20035 thingy91    (west build -b nrf9160_pca20035ns) device. 

Please guide me the correct way to get generate them in order to access the orientation detector

Thank you. 

Parents Reply
  • Dheeraj said:
    Basically, I would like to know the interface between the nRF52840 ad nRf9160 on the  (Thingy91) PCA20035 device. 

    The nRF52840 is made to serve the nRF9160 in terms of UART/USB connections, and to be able to program the nRF9160 device over UART as well (using mcuboot)

    The physical interface between the two nRF's are a set of GPIOs, and they are used for UART communication (RXD, TXD, CTS, RTS). What specifically are you looking for?

     

    Kind regards,

    Håkon

Children
  • Hi,

    Thanks for your reply.

    I am specifically looking for RSSI implementation using the BLE module on nrf52840 SOC. How to obtain the RSSI values for asset tracker application on Nordic Thingy:91(nRF9160 SiP)?

    I want to perform a BLE scan based on the timeout values and sort the result by RSSI implementation with nRF52840 for PCA20035 and pass the BLE_SCANLIST_ENTRIES over UART.

    Looking forward to your help. Please guide me the correct way and let me know how to proceed to start the RSSI measurement.

    Thanks

  • Dheeraj said:
    I am specifically looking for RSSI implementation using the BLE module on nrf52840 SOC. How to obtain the RSSI values for asset tracker application on Nordic Thingy:91(nRF9160 SiP)?

     In order to use the BLE part of the nRF52840 SoC on the thingy:91 board, you'll have to reprogram the nRF52840 with hci_uart, then run lte_ble_gateway on nRF9160 device, but; this will cause the USB-UART bridge to be overwritten. We do not have an example that combines the usb_uart + hci_uart sample, unfortunately; but I have provided this feedback to the thingy:91 team so that they are aware of this scenario.

     

    Kind regards,

    Håkon

  • Hi Hakon, 

    As suggested, I have compiled hci_uart for nrf52840_pca20035 and lte_ble_gateway for nrf9160_pca20035ns. and flashed the respective Images by using nRF9160 DK (PCA10090) on Thingy91.

    After flashing the above Images, I am NOT able to observe any logs from Thingy91. 

    I have tried reconnecting the board by disconnecting the USB, but still, the system is NOT able to detect the Thingy91 Ports (COM).

    I have tried adding the DTS overly files for hci_uart, but no luck. 

    Please help me out, how can I get it done as this is a roadblock for me.  

    For your info: 

    I have tried the same on nRF9160 DK (10090), I am able to get the RSSI values from nRF52840 SoC to nRF9160 SiP without any issues. 

    Thank you.

  • Dheeraj said:

    As suggested, I have compiled hci_uart for nrf52840_pca20035 and lte_ble_gateway for nrf9160_pca20035ns. and flashed the respective Images by using nRF9160 DK (PCA10090) on Thingy91.


    After flashing the above Images, I am NOT able to observe any logs from Thingy91. 

    I have tried reconnecting the board by disconnecting the USB, but still, the system is NOT able to detect the Thingy91 Ports (COM).

    I have tried adding the DTS overly files for hci_uart, but no luck. 


    Please help me out, how can I get it done as this is a roadblock for me.  


    For your info: 

    I have tried the same on nRF9160 DK (10090), I am able to get the RSSI values from nRF52840 SoC to nRF9160 SiP without any issues. 

    When you flash hci_uart to the nRF52840 on the thingy, you will overwrite the firmware already present on it, and you will lose the USB-UART bridge functionality.

    You can try to use Segger RTT to get print out, via the SWD debug interface, by adding this line:

    CONFIG_USE_SEGGER_RTT=y

     

    Kind regards,

    Håkon

  • Hi Hakon, 

    I understand.

    Could you please let me know, where can I find the USB-UART bridge code changes to reflash the nRF52840 on Thingy91 (PCA20035) to bring back to Normal. 

    Due to this, I did NOT get the nRF9160 SiP logs as well. 

    Thank you. 

Related