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

dtm data sent

Hi,

I'm using pca10040 and prebuild hex with s132 from sdk 12. Now I'm wondering how can I get number of sent data? If I set it as transmitter - send via uart 0x8094 i get response 0x0000 and when i stop test with 0xc000 i get success status 0x8000 - how could i get number of bytes that were sent out?

On the receiver side, I start receiver test with cmd 0x4094 and also get response 0x0000. When I stop test with 0xc000 i get response 0x87e7...

So after py code check I guess that rcv get 0x07e7 packets, but how should i found out how many was it sent on transmitter side?

Thank you for info.

BR, Matej

  • FormerMember
    0 FormerMember

    For the transmitter test, there is no report of the number of transmitted packets. The number of transmitted packets is calculated based on the time the test is running and the interval between the packets. That method will result in a small error, but if the test is running for some time, that error can be discarded.

  • Thank you for reply Kristin! What about an idea to add counter to dtm_wait function in ble_dtm.c file? (Incrementing it before for loop - in case that m_state is equal to STATE_TRANSMITTER_TEST)

  • FormerMember
    0 FormerMember in reply to FormerMember

    For the transmitter test, the packet error rate is calculated in the upper + lower tester only, based on the duration of the test time and the number of packets received. In the python script, the packet error rate is calculated the following way:

    def _calculatePER(self, receivedPackages):
    	"""Calculates the PER"""
    	maxpackages = int (round(self.runtimeinms / self._calculateTimeForPackage ()))
    	lostpackages = maxpackages - receivedPackages
    	lostpackages = max(0, lostpackages)
    	self._debug("Received: %s Max: %s Lost: %s" % (receivedPackages, maxpackages, lostpackages))
    	per = int (round((float(lostpackages) / float(maxpackages)) * 100))
    	return per
    
  • Kristin, thank you for rsp... but this self._calculateTimeForPackage function in py always returns 0.625 so I'm on the same if I count number of calls for dtm_wait() - which returns each 0.625 ms... Now I'm wondering if it is possible that for some reason transmitter could not send out a packet? Then maxpackages would be a higher, then a number of packets that were sent out... In that case we can't detect if problem is in transmiter of receiver - but we should trust the golden sample and thats it... Now I get it ;) Thank you once again Kristin!

  • I have one more question - about testing multiple boards - at the same time... If golden sample is transmiter, then all testers are receivers - then in theory all of testers should have the same number of received packets right? But if receiver works fine - we can not conclude that also transmiting works fine... What do you advise to test multiple boards at the same time? if it's even possible

Related