NerdKits - electronics education for a digital generation

You are not logged in. [log in]

NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.

Basic Electronics » RFB12B ... what are all this terms? >_<

January 05, 2011
by Hexorg
Hexorg's Avatar

Hey guys, I'm trying to send data over a little radio RFM12B module. It has an SPI interface that's pretty easy to understand, however, I don't quite understand what the command parameters mean. Here in the programming guide for this little thing... in the Configuration Setting Command it asks to choose crystal load capacitor... >_< what is that? Also, in Frequency Setting Command, it asks to choose operating frequency... What's the difference between the band and operating frequency? I really feel like i need to read a little more but I can't seem to google anything useful.

January 05, 2011
by Hexorg
Hexorg's Avatar

Idk if anyone ever tried to work with this chips, But I'll keep you all posted on what is my progress.

Right now i'm using this settings in the transmitter:

1
2
3
4
5
6
7
8
9
10
11
12
13
rf_command(0x80D8); // enable TX, FIFO buffer, 433MHz, 12.5pF
rf_command(0x8209); // !er, !ebb, !et, !es, EX, !eb, !ew, DC
rf_command(0xA640); // frequency select
rf_command(0xC647); // 4.8kbps
rf_command(0xCC77); // PLL
rf_command(0x94A0); // VDI, FAST, 134kHz, 0dBm, -103dBm
rf_command(0xC2AC); // AL, !m1, DIG, DQD4
rf_command(0xCA83); // FIFO8, SYNC, FIFO fill, no high sensitivity reset
rf_command(0xC48B); // no range restriction
rf_command(0x9850); // !mp, 9810=30kHz, MAX OUT
rf_command(0xE000); // NOT USE
rf_command(0xC800); // NOT USE
rf_command(0xC000); // 1,0Mhz, 2.2V

and almost the same in receiver:

1
2
3
4
5
6
7
8
9
10
11
12
13
rf_command(0x80D8); // enable TX, FIFO buffer, 433MHz, 12.5pF
rf_command(0x82D9); // ER, EBB, !et, ES, EX, !eb, !ew, DC
rf_command(0xA640); // frequency select
rf_command(0xC647); // 4.8kbps
rf_command(0xCC77); // PLL
rf_command(0x94A0); // VDI, FAST, 134kHz, 0dBm, -103dBm
rf_command(0xC2AC); // AL, !m1, DIG, DQD4
rf_command(0xCA83); // FIFO8, SYNC, FIFO fill, no high sensitivity reset
rf_command(0xC48B); // no range restriction
rf_command(0x9850); // !mp, 9810=30kHz, MAX OUT
rf_command(0xE000); // NOT USE
rf_command(0xC800); // NOT USE
rf_command(0xC000); // 1,0Mhz, 2.2V

rf_command() is here:

1
2
3
4
5
6
7
8
9
uint16_t rf_command(uint16_t cmd)
{
    RFCS_L();
    uint16_t result;
    result = SPI((uint8_t) cmd>>8)<<8;
    result |= SPI((uint8_t) cmd);
    RFCS_H();
    return result;
}

and i'm trying to broadcast data like this:

1
2
3
4
5
void rf_send(uint8_t data)
{
    while (PIND & (1<<nIRQ));
    rf_command(TRANSMIT_WRITE | data);
}

but when sending, nIRQ never goes low for some reason >_<. Any suggestions why?

January 08, 2011
by n3ueaEMTP
n3ueaEMTP's Avatar

Hexorg, I can only answer one of your questions:

What's the difference between the band and operating frequency?

The simplest way to put it, a band is a grouping of frequencies that are adjacent to one another. The most recognizable is the broadcast FM band (in the US anyway). In the United States the FM broadcast band is between the frequencies of 87.8–108 MHz. For example, I listen to FM97 who's frequency is 96.900Mhz.

Chris B.

N3UEA

January 08, 2011
by Hexorg
Hexorg's Avatar

Oh ok, well with "FM band" that's understandable as range, in the datasheet what confused me was "433MHz band" because that's not a range, it's a specific frequency.

January 09, 2011
by mrobbins
(NerdKits Staff)

mrobbins's Avatar

Hi Hexorg,

I believe that "433MHz band" is just a convenient short name to reference the frequency range of 433.05 to 434.79 MHz, which is one of the reserved Industrial, Scientific, and Medical frequency bands.

Mike

Post a Reply

Please log in to post a reply.

Did you know that you can connect a computer keyboard to your microcontroller? Learn more...