TX/RX with CC1101 Texas - Page 2


+ Reply to Thread
Page 2 of 2 FirstFirst 12
Results 16 to 21 of 21

Thread: TX/RX with CC1101 Texas272 days old

  1. #16
    Member keytapper's Avatar
    Join Date
    Jun 2019
    Posts
    149
    Thumbs Up
    Received: 6
    Given: 3
    Total Downloaded
    329.46 MB

    0 Not allowed!

    Default Re: TX/RX with CC1101 Texas

    Sorry, Giuseppe,
    Which library are you referring to ?
    Is the Elechouse one ?
    I suppose that the only answer is to imitate closely the way the library developer has done. So it would take to use the same hardware and example to see whether what is published is really working as it's claimed to be.
    So for your testing you should have both hardware for the transmitter and the receiver too.

  2. Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  3. #17
    Junior Member Giuseppe's Avatar
    Join Date
    Jul 2019
    Posts
    31
    Thumbs Up
    Received: 0
    Given: 0
    Total Downloaded
    437.99 MB

    0 Not allowed!

    Default Re: TX/RX with CC1101 Texas

    Hi Fulvio, the library is just that.
    Now the part of the tx is well advanced.
    The Rx module is giving me problems.
    As for the original hardware, I have already done the logical analyzes of both rx and tx.
    We see that it comes out
    Last edited by Giuseppe; 27th December 2019 at 08:10.

  4. Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  5. #18
    Member keytapper's Avatar
    Join Date
    Jun 2019
    Posts
    149
    Thumbs Up
    Received: 6
    Given: 3
    Total Downloaded
    329.46 MB

    0 Not allowed!

    Default Re: TX/RX with CC1101 Texas

    I wish you that somebody else will get intrigued to study the case. I hardly find the solution because of no hardware to test and a bit it is no my need to use such modules.
    Basically, as I mentioned, it will take to follow the steps as the Arduthing doing. Perhaps that will imply to use the MSSPI rather than the softSPI, currently used. But I doubt it's that the issue, as long as the communication is synchronous.
    Anyways, the libraries (we found two) use the hardware SPI, but I don't recall whether the basic has this command embedded.

  6. Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  7. #19
    Junior Member Giuseppe's Avatar
    Join Date
    Jul 2019
    Posts
    31
    Thumbs Up
    Received: 0
    Given: 0
    Total Downloaded
    437.99 MB

    0 Not allowed!

    Default Re: TX/RX with CC1101 Texas

    Hi as said by Fulvio the problem may lie in the communication of spi software. From the logical analysis I have seen that the same clock is not used by both transmission and reception but the shout command generates its own clock and subsequently shin generates another. This way I have 2 more sets of clock pulses.
    Below a piece of code that does not go :
    ----------------------------------------------------------------------------
    CC1101_SpiReadStatus:
    Low SS_PIN
    While MISO_PIN = 1 : Wend
    SHOut MOSI_PIN,SCK_PIN,MsbFirst_L,[addr_SWR|READ_BURST,0]
    High MOSI_PIN
    SHIn MISO_PIN,SCK_PIN,MsbPre_L,[value_SRR,value_srr1]
    High SS_PIN
    Return
    -----------------------------------------------------------------------------
    the spi communication I need to have is full duplex I can't get this with the Shout and Shin commands. How can I solve the problem ?

  8. Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  9. #20
    Fanatical Contributor top204's Avatar
    Join Date
    Feb 2002
    Posts
    3,515
    Thumbs Up
    Received: 319
    Given: 152
    Total Downloaded
    1.99 GB

    0 Not allowed!

    Default Re: TX/RX with CC1101 Texas

    A bit-bashed (software) SPI procedure is quite easy to create and maintain, and it also eliminates any quirks and differences when using the MSSP peripheral.

    Below is an SPI full duplex procedure that reads from the SPI while it writes to it, which is standard with SPI:

    Code:
    $define SPI_SCK_Pin PORTB.0
    $define SPI_SDO_Pin PORTB.1
    $define SPI_SDI_Pin PORTB.2
    $define SPI_CS_Pin PORTB.3
    
    
    '-----------------------------------------------------------------------------------
    ' Write and read a single byte (8-bits) to the SPI bus
    ' Input     : pData holds the byte to transmit to the SPI bus
    ' Output    : Returns the byte read from the SPI bus
    ' Notes     : 
    '
    Proc SPI_WriteRead(pData As Byte), Byte
       Dim bLoop As Byte
    
    
       Low SPI_SCK_Pin                     ' Make the SCK pin output low before entering the loop
       Low SPI_SDO_Pin                     ' Make the SDO pin output low before entering the loop
       Input SPI_SDI_Pin                   ' Make the SDI pin an input before entering the loop
    
    
       For bLoop = 7 To 0 Step -1          ' Single byte SPI loop
           SPI_SDO_Pin = pData.7           ' Put the current outgoing bit on SPI_SDO_Pin
           pData = pData << 1              ' Shift the next bit into MSB
           Set SPI_SCK_Pin                 ' Set the SCK pin high
           DelayUS 1                       ' A small delay between clock pulses
           Result.7 = SPI_SDI_Pin          ' Capture the current bit on SDI_Pin
           Clear SPI_SCK_Pin               ' Pull the SCK pin low
           Result = Result >> 1
       Next
    EndProc

    The code within the procedure may need to be tweaked to suit the SPI interface required, so that the data is read before, during or after the clock, or the delay may need to be increased or it may be OK to remove it altogether. Or the bits loaded and read for MSB or LSB. But as you can see, it is a simple thing to do because the code is a simple loop with pin toggling and reading.

    The $define directives can be placed at the top of the program so the procedure knows which pins to read and toggle. This makes it a whole lot faster than setting the pins as parameters.

    To use the procedure, it is as simple as:

    Low SPI_CS_Pin
    MyByte = SPI_WriteRead(123)
    High CS_Pin
    Last edited by top204; 7th March 2020 at 19:35.

  10. Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  11. #21
    Junior Member Giuseppe's Avatar
    Join Date
    Jul 2019
    Posts
    31
    Thumbs Up
    Received: 0
    Given: 0
    Total Downloaded
    437.99 MB

    0 Not allowed!

    Default Re: TX/RX with CC1101 Texas

    Thanks Top204 for the support. I have tried the routine and it seems to be going. With the same watch I transmit and receive simultaneously.
    Congratulations to you really a great job
    now I'm trying to solve other problems on the program.
    I am making logical comparisons with Arduino I still have problems. I have to try to understand what's wrong

  12. Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. Replies: 5
    Last Post: 16th February 2010, 18:11

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts