This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DATA RATE IN TIMAC (is it really 100kbps?)

Other Parts Discussed in Thread: TIMAC, MSP430F5438, CC2520

Hi,

I have doubt regarding data rate in TIMAC.

In documents it is given that effective data rate for TIMAC is 100kbps

100 kilo bits per sec = 100/8 kilo bytes per sec

                                      = 12.5 kilo bytes per sec ( kBps)

But in TIMAC sample program

In msa.h file

MSA_WAIT_PERIOD (  Time between each packet )  can be taken as 1ms

MSA_PACKET_LENGTH (Min = 4, Max = 102)

Since there are four bytes for header, so maximum number of data bytes can be taken as 98 bytes

Using  maths one can easily say,

number of maximum data bytes per second  = 98 kilo bytes per second

But as per the documents the effective data rate = 12.5 kilo bytes per second


Where am I going wrong in this calculation?

One more doubt,  MSA_WAIT_PERIOD ( Time between each packet ) 

Is this time the time required for one packet to be completely sent or is it as written just the time between two packets.

If it is indeed the time between two packet then how much time does it really takes to send one packet?

Thanks

Yuvraj Sahni

  • You only need to insure that the data is transmitted before sending the next packet, so instead of using an OSAL timer you can send the next packet from the MAC_MCPS_DATA_CNF callback.

    Regards, TC.

  • Hi TopCat,

     Thanks for the answer.

    I got what you explained.

    But my doubt is not about that. It is that how much signal frequency can I send using TIMAC that can be properly reconstructed at the receiver side. So for that to properly work  I need to have proper calculation.

    So, what settings ( MSA_WAIT_PERIOD and MSA_PACKET_LENGTH) should I choose in order to transmit a 500Hz sine wave from end device to coordinator using TIMAC.

    I am using MSP430F5438 experimenter board and CC2520 as transreceiver.

    Thanks

  • Sorry, I am a little lost with this question. For a 500hz sign wave or any data you would embed the timing information in the transmission, so it can be reconstructed. Maximum BW will vary with first CSMA backoff and any subsequent backoff if there is a channel access failure to some other 2.4G signal.

  • Hi TopCat,

    Can you please explain me what you meant by

    Maximum BW will vary with first CSMA backoff and any subsequent backoff if there is a channel access failure to some other 2.4G signal.


    And what is the mathematical relationship between Maximum BW and first CSMA backoff

    Thanks

  • The 802.15.4 Spec states that there must be a random Backoff before the first CCA. This first backoff will be a random value between

    [0 – (2^Be)-1]*320uS

    Where Be (Backoff Exponent) is for MinBe = 3 for the first backoff.

    For each subsequent CCA failure Be will increase by 1 up to MaxBe = 5.

    1st attempt = [0 – (2^3)-1]*320uS = 0 – 2.24mS

    2nd attempt = [0 – (2^4)-1]*320uS = 0 – 4.8mS

    3nd attempt = [0 – (2^5)-1]*320uS = 0 – 9.92mS

    4th attempt = [0 – (2^5)-1]*320uS = 0 – 9.92mS

    5th attempt = [0 – (2^5)-1]*320uS = 0 – 9.92mS

    These backoff's will take up "air time", you can use above to give a min and max for the time taken to be able to transmit depending on channel availability. Things like Bluetooth or WiFi devices in close proximity and causing CCA failure would cause a backoff.

    Regards, TC.

  • Hi TopCat,

    Thanks for the explanation.

    I understand now that CSMA backoff period will affect my transmission.

    Can you tell me one more thing that for TIMAC how much signal frequency can one expect to send so that it can be completely reconstructed at the receiver side?

    I have trying really hard to improve signal frequency and I am not able to go higher than 100Hz. Is it the limitation with TIMAC  or is there something wrong with my calculations.

    If I am doing something wrong can you please suggest where would it be?

    Thanks again for the reply and waiting for your answer.

    yuvraj

  • I have assigned this thread to our MAC specialist. Hopefully he can answer this question.

    Regards, TC.

  • Hi TopCat,

    I have not received any reply .

    My doubt regarding the transmission rate using TIMAC protocol is not yet cleared.

    I am using MSP EXP430F5438 experimenter board and  CC2520 as trans receiver.

    My doubt is what is the transmission rate. How much time does it takes for a packet to reach receiver i.e. from start of sending to its confirmation to transmitter. 

    I need this calculation to determine the exact transmission rate. Although it is given in documents that the transmission rate is 100kbps effectively but I have read in many documents that it is not because some overheads and other reasons. But I do not have a exact number.

    Waiting for your reply.

    Thanks

  • Hi Yuvraj,

    Please see my comments below to your original question:

    Hi,

    I have doubt regarding data rate in TIMAC.

    In documents it is given that effective data rate for TIMAC is 100kbps

    100 kilo bits per sec = 100/8 kilo bytes per sec

                                          = 12.5 kilo bytes per sec ( kBps)

    But in TIMAC sample program

    In msa.h file

    MSA_WAIT_PERIOD (  Time between each packet )  can be taken as 1ms

    MSA_PACKET_LENGTH (Min = 4, Max = 102)

    Since there are four bytes for header, so maximum number of data bytes can be taken as 98 bytes

    Using  maths one can easily say,

    number of maximum data bytes per second  = 98 kilo bytes per second

    But as per the documents the effective data rate = 12.5 kilo bytes per second


    Where am I going wrong in this calculation?

    One more doubt,  MSA_WAIT_PERIOD ( Time between each packet ) 

    Is this time the time required for one packet to be completely sent or is it as written just the time between two packets.

    If it is indeed the time between two packet then how much time does it really takes to send one packet?

    [] The time between sending two packets is not the time to send the packet over the air. As you know for IEEE 802.15.4 at 2.4 GHz Packet is sent at 250 kbps by the radio (so you can calculate the total transmission time based on the number of bytes you are transmitting) and it involves CSMA-CA prior to sending each packet. For typical calculations you can take the average value of the CSMA-CA duration to be an average of 1 msec. But note that this value may increase depending on the RF noise in the vicinity of your devices. Then there is stack processing time. And there is time to receive the mac acknowledgement. I would recommend to write a small application to test the through put. What you can do is write an application to send the data as soon as you receive a confirmation of successful data send you can send another packet. or you can send two packets to the MAC and as soon as you get one confirmation you can send another one. and keep that process going. On the receiver you can then determine based on a fixed time interval for which you will transmit the packet - how many packets did you receive. You can then calculate the practical throughput of your system as you know number of packets (giving you total number of application bytes transmitted) and total time.  Hopefully this provides you with enough information.