Holtek BA45F56 Series Parts list manual

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 1 / 14 November 5, 2020
BA45F56xx Wireless Transceiver Application
D/N: AN0571EN
Introduction
In traditional smoke detector RF applications, as well as a master MCU, an additional RF IC is also
required. With this in mind, Holtek has designed the BA45F56xx series of MCUs, which include
an integrated smoke detector AFE as well as a Sub-1GHz RF Transceiver, allowing designers to
develop related products using a minimum of external components. This application note introduces
the BA45F56xx series of MCUs, which includes an explanation of the Sub-1GHz RF Transceiver
control flow and programming examples. For smoke detector AFE instructions, refer to the Holtek
application note AN0540EN “BA45F5xxx Smoke Detector Integrated Analog Front End
Application Notes”.
Function Description
Application Circuit
VDD
A0PI
ISINK1
VDD
VDD
VSS
RFIN
RFOUT
RF
Matching
EXTLP
EXTLN
VSSRF
XO
XI
V_LNA
V_SX
V_DIG
V_XO
CLDO
VDD
VDD
A0NI
ISINK0
Buzzer
VDD
PWM
I/O
Figure 1. BA45F56xx Series Application Circuit

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 2 / 14 November 5, 2020
ISINK0/1 provide a constant infrared emission current, A0PI and A0NI process the infrared
received signal
ISINK0/1 constant current output is adjustable
Two sets of ISINK for use by different types of smoke – white/black smoke
RF circuit includes the antenna and input/output matching circuit
Time-division duplex (TDD) method must be used for RF signal transmission and reception -
only transmission or reception can be performed at a time
RF transmission
Digital packet regulator →Gaussian filter →ΣΔ Modulator →Frequency synthesis →High
power amplifier →Antenna
RF reception
Antenna →Low noise amplifier →Intermediate frequency(IF) →Intermediate frequency
composite band-pass filter →Signal strength detector →Digital packet demodulator
Operating Principles
Communication Pin Description
NC
NC
CLDO
GIO4
NC
PA0/SCK/SCL/ICPDA/OCDSDA
SDIO
PA2/SDI/SDA/RX/ICPCK/OCDSCK
PB0/INT0/SCS/STP/A0PB
A0PI
A0NI
PA5/STCK/A1O
XO
V_XO
EXTLP
EXTLN
V_SX
V_DIG
PB3/PLRX/SDI/SDA/RX/GIO2
NC
V_LNA
RFIN
VSSRF
RFOUT
PA6/PTP/SDI/SDA/RX/VREF
PA7/STPI/PTPI/SCK/SCL/AN1
PA3/SDO/TX/PTPB/AN3
PB4/SCS
NC
NC
ISINK0
NC
ISINK1
PB2/PLI S/SCK
( *)
/SCL
CSN
GIO1
CLDO
XI
PA4/PTCK/STPB/AN0/A0O
PA1/INT1/SCS/AN2/A1PI
NC
PB1/PLTX/SDO/TX
VSS
NC
VDD
VSS
BA45F56 40
BA45V56 40
46 QFN-A
1
2
3
4
5
6
7
8
910 11 12 13 14 15 16 17 18 19 20 21 22
343536373839
23
24
25
26
27
28
29
30
31
32
3340414243444546
Figure 2. BA45F5640 Pin Assignment

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 3 / 14 November 5, 2020
Sub-1GHz RF Transceiver supports 3-wire and 4-wire SPI interfaces. The 3-wire SPI only
requires CSN, SCK and SDIO while the 4-wire SPI requires CSN, SCK, SDIO and SDO. The
pin-shared function settings are shown in Table 1. The pull-up control for the RF Transceiver
communication pins are shown in Table 2.
When using either the 3-wire or 4-wire SPI to communicate with the RF Transceiver, users only
need to setup PB2 to be SCK to communicate with the RF Transceiver SCK. The SCK of other
I/O pins does not have this function. The PB2 pin is connected internally to the RF Transceiver
in the MCU, therefore no external connection is required.
The red frame in Figure 2 shows the RF Transceiver pins, SCK and GIO2. Note that they are
pin-shared with other pins. The remaining pins, such as GIO1 and GIO4, are dedicated RF
Transceiver pins.
For detailed register information, refer to the datasheet.
3-wire
4-wire
CSN
CSN
CSN
SCK
SCK(PBS0[5:4]=10)
SCK(PBS0[5:4] = 10)
SDIO
SDIO
SDIO
SDO —
GIO2: PB3(PBS0[7:6] = 00 or 11), GIO2S[2:0] = 001
GIO1: GIO1S[2:0] = 001
GIO4: GIO4S[3:0] = 0001
Table 1. Communication Pin Settings
Register
Name
Description
SPIPU
3-wire SPI pull-up control: 0: Disable (output), 1: Enable (input)
GIOPU[4:1]
GIO pin function pull-up control: control the pull-up function of the GIO4~GIO1
pins respectively; 0: Disable (output), 1: Enable (input)
Tabl e 2. Communication Pin Pull-up Control
Wireless Transmission Modes
There are two main wireless transmission modes in the wireless transceiver. These are the direct
mode, where the data to be transmitted and received is implemented on GIO1/GIO2 and the other
mode is the FIFO Mode, where data access is implemented using an internal FIFO register.
Direct Mode
The device will automatically load the default values after RF power on after which it will enter the
Deep Sleep Mode. To use the Direct Mode to transmit or receive data, use the following steps.
Step 1. Setup Parameters: Use the SPI interface to program the internal control registers. For example,
frequency (D_N, D_K), modulation parameter (FSCALE), data rate (DTR), etc. For parameter
setting details refer to the datasheet.
Step 2. Setup the synchronisation characters: Program the TXPMLEN and RXPMLEN registers to
setup the length of the preamble signal to be transmitted or received. This is implemented
using the SPI command, Write SYNCWORD (0x10) to set the synchronisation character.

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 4 / 14 November 5, 2020
Step 3. Setup the GIO pins: Use the SPI interface to set the GIOxS internal registers. For the setup
values, refer to the datasheet. In most cases, GIO1 will be setup as the TX/RX data output/input,
GIO2 as the interrupt output and GIO3 as the transmit data bit clock. GIO4 will be the received
data bit clock. (GIO1S = 0b010, GIO2S = 0b101, GIO3S = 0b1000, GIO4S = 0b1001).
Step 4. Wake-up the RF: Use the SPI command Light Sleep Command(0x0C) to force the RF to
enter the Light Sleep Mode.
Step 5. Wait for the crystal to stabilise then check whether XCLK_RDY = 1.
Step 6. Setup the Direct Mode: Set DIR_EN to 1.
Step 7. Start the transmit or receive mode: First set RTX_SEL (0: receive, 1: transmit), and start the
frequency synthesiser (SX_EN = 1) and automatic calibration function (ACAL_EN). After
the automatic calibration process has completed (about 300μs), then start the transmit and
receive function (RTX_EN = 1).
Step 8. Output/read data: Finally, the GIOx (determined by the setup value) can be used to transmit
or receive data. Here it should be noted that after transmitting or receiving the preamble,
synchronisation characters and trailer, the correct data can be determined according to the
data bit clock, TBCLK/RBCLK. For the TX and RX related timing diagram refer to the
datasheet.
The Direct Mode state switching process is shown in Figure 3. Here the Idle Mode can force the
RF to use the internal low-frequency oscillator which will effectively reduce the wake-up time. The
following modes must be executed in the process sequence of this state switching diagram. For
example, after entering the Idle Mode, it is necessary to return to the Light Sleep Mode, after which
jump to the Standby Mode and then execute the TX or RX program.

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 5 / 14 November 5, 2020
Power Down
Power On
Deep Sl eep
Light Sleep
Standby
TX RX
Idle Calibrations
Light
Sleep
Deep
Sleep
Idle
Deep Sl eep
Idle
OM[2:0]=000bOM[2:0]=000b
OM[2]=1
OM[1:0]=00b
OM[1:0]=01b (RX)
OM[1:0]=11b (TX)
(wai t~35μs)
Aut o (calibration completed)
Calibration
enabled
OM[2]=1
Figure 3. Direct Mode State Diagram
FIFO Mode
The device will automatically load the default values after RF power on after which it will enter the
Deep Sleep Mode. To use the FIFO Mode to transmit or receive data, use the following steps.
Step 1. Setup parameters: Use the SPI interface to program the internal control registers. For example,
frequency (D_N, D_K), modulation parameter (FSCALE), data rate (DTR), etc. For parameter
setting details refer to the datasheet.
Step 2. Setup the synchronisation characters: Program the TXPMLEN and RXPMLEN registers to
setup the length of the preamble signal to be transmitted or received. Use the SPI command
to write the SYNCWORD Command (0x10).
Step 3. Setup the data format: Program the PKT1~PKT9 registers.
Step 4. Setup the FIFO Mode: Set DIR_EN to 0.
Step 5. Reset the FIFO index to zero: Use the SPI command TX/RX FIFO Address Pointer Reset
Command (0x09/0x89) and then set TXFFSA to 0.
Step 6. Write the data to be transmitted into the FIFO: Use the SPI command TX FIFO Write
Command (0x11) to write the data to be transmitted into the FIFO. If data is to be received
do not execute this step.
Step 7. Start the transmit/receive mode: Use the SPI shortcut command TX/RX Mode (0x0E/0x8E)
to enable this mode.

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 6 / 14 November 5, 2020
Step 8. Wait for data transmit/receive operation to complete: Determine whether T/RXCMPIF is 1.
Step 9. Read the FIFO data: Use the SPI command RX FIFO Read Command (0x91) to read the
received data from the FIFO. If data is to be transmitted do not execute this step. For the
TX and RX related timing diagram refer to the datasheet.
After enabling transmit/receive (Step 7) the complete state switching flow is shown in Figure 4.
Here the Idle Mode can force the RF to use the internal low-frequency oscillator which will
effectively reduce the wake-up time. The following modes must be executed using the process
sequence of this state switching diagram. For example, after entering the Idle Mode, it is necessary
to return to the Light Sleep Mode, after which jump to the Standby Mode and then execute the TX
or RX program.
Power Down
Power On
Deep Sleep
Light Sleep
Standby
TX RX
Idle Calibrations
Light
Sleep
Deep
Sleep
Idle
Deep Sleep
Idle
Aut o (TX completed)/
Light Sleep
Aut o (RX completed)/
Light Sleep
TX/(Aut o)RX/(Auto)
Light Sleep Standby/
RX/TX(~35μs)
Aut o (calibrat ion comp leted)
Calibration
enabled
Fig.4 FIFO Mode State Diagram
The FIFO Mode is divided into the Block FIFO Mode, Extern FIFO Mode and Infinite FIFO
Mode. For other modes of operation, refer to the datasheet.

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 7 / 14 November 5, 2020
Program Example Description
This program example utilises the function library to execute the TX/RX inter transmission function.
The FIFO Mode is selected as the transmission mode for which the operation flowchart is shown
in Figure 7. For TEST_SNIFF_RX, it is a continuous RX mode. The difference between the
continuous RX mode and the general RX mode is that when the receiving process has completed,
the RX mode should be started again ready for following use. The continuous RX mode will
automatically receive subsequent packets until the software transmits the Light Sleep command to
stop reception.
For the RF_MODE, users can select TEST_ITEM=TX or RX or SNIFF in the project settings. The
setting mode is shown in Figure 5 and Figure 6 below.
Figure 5
Figure 6

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 8 / 14 November 5, 2020
Operating Flowchart
Modify TX power
(Default 433.92MHz)
Call RF_InitWrite SYNCWORD
Power on
MCU initialisation
Write the data to be
transmitted
Modify TX power
(Default 10dBm)
Mode selection
RF_Mode=?
Receiving data mode
TEST_RX
Transmitting data mode
TEST_TX
Timed receiving data
mode
TEST_SNIFF_RX
Write the data to be
transmitted
Call RF_Se ndData to
transmit data
Wait IRQ s ig na l
Call RFGetClrRFIrq to
query RF State
Call
RF_EntryRxMode to
enter RX receiving
mode
Wait IRQ s ig na l
Call RFGetClrRFIrq to
query RF state
Call RF_ReadRxDta to
read data
Call
RF_EntrySniffMode
Wait IRQ s ig na l
When mRFRdDta.0 is
high, the transmit
process is completed
According mRFRdDta
to determine whether
the receive process is
completed and the data
is corre cted
Call RFGetClrRFIrq to
query RF state
According mRFRdDta
to determine whether
the receive process is
completed and the data
is corre cted
Call RF_ReadRxDta
to read data
Figure 7. Program Example Operating Flowchart

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 9 / 14 November 5, 2020
Function Description
Name
RF_Init
Function
RF initialisation, FSK data rate is 50kbps, power is 10dBm, after the program has
completed, the RF will enter the Sleep Mode
Input
--
Output
--
Name
RF_EntryRxMode
Function
After the program has executed, the RF will enter the RX Mode
Input
--
Output
--
Name
RF_EntrySniffMode
Function
After the program
has executed
, the RF will enter the WOR Mode and automatically enter
RX mode to receive for 9.5ms after every 4s wake-up. During program execution, if the
Preamble signal is detected, the RX receiving time will be extended to the end of the packet
reception (up to 250ms) and will then enter the Light Sleep Mode after completing data
reception. If the Preamble is not detected, return to the IDLE Mode and wait for the next
wake-up action
Input
--
Output
--
Name
RF_SendData
Function After the program has executed, the RF will enter the TX Mode and transmit the data in the
mRFBuf. After transmitting, the RF will enter the Light Sleep Mode
Input
RF data = mRFBuf[0:18]
Output
--
Name
RF_ReadRxData
Function After the program has executed, the RF data will be read from FIFO and stored in the
mRFBuf variable
Input
RF data = mRFBuf[0:18]
Output
--
Name
RFGetClrRFIrq
Function After the program has executed, the IRQ Flag is read into mRFRdDta and the IRQ is cleared
Input --
Output
IRQ Flag = mRFRdDta
Name
RF_GetOpMode
Function
After the program has executed, the current RF state data will be transmit to the ACC, thus
determining the current RF mode.
Input --
Output
Option Mode = ACC
Name
RFSleepMode
Function
After the program has executed, the RF will enter the Deep Sleep Mode
Input
--
Output --
Name
RFIdleMode
Function
After the program has executed, the RF will enter the Idle Mode
Input
--
Output
--
Name
RFLightSleepMode
Function
After the program has executed, the RF will enter the Light Sleep Mode
Input
--
Output
--

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 10 / 14 November 5, 2020
Name
RFXtalReady
Function
After the program has executed, the RF will wait for the crystal to start oscillating and then
jump out of the function until the crystal is stable
Input
--
Output
--
Name
RFCalibration
Function
After the program has executed, the RF will start the automatic calibration function and jump
out of the function until the calibration has completed
Input
--
Output
--
Name
RFSetPower
Function
After the program has executed, the value in the ACC is set as the RF TX transmitting power
Input
TX Power = ACC
Output
--
Name
RFWriteSyncword
Function After the program has executed, the data in mSync is set as the RF communication preamble
data
Input
SYNC = mSync[0:3]
Output
--
Name
RFReadRegCmd
Function After the program has executed, the data in mRFAddr is set as the RF register address and
the read data will be stored in mRFRdDta
Input
Register Address = mRFAddr
Output
Register Data = mRFRdDta
Name
RFWriteRegCmd
Function After the program has executed, the data in mRFAddr is taken as the RF register address and the
mRFRdDta data is written into the RF register.
Input
Register Address = mRFAddr, Register Data = mRFWrDta
Output
--
RF Input/Output Matching Circuit
When receiving high-frequency signals, in addition to the antenna, an impedance matching circuit
needs to be added before the signal is input to the device. Good impedance matching will reduce
the amount of noise thereby improving reception sensitivity. When adjusting the impedance
matching values, it is necessary to use a network analyser to make measurements. Select high-Q
capacitors and inductors, which will effectively improve reception sensitivity.
Antenna
RFOUT
VDD
L5
C5
L2
L1
C8C6 C7
L3 RFIN
C9
C9
C4
L4
Figure 8. Input/Output Matching Circuit

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 11 / 14 November 5, 2020
315MHz
433MHz
470MHz
868MHz
Unit
C4
1.5
1
1
N.C.
pF
C5
100
100
100
100
pF
C6
12
10
8
N.C.
pF
C7
24
22
15
3.3
pF
C8
15
12
8
5.6
pF
C9
100
68
68
68
pF
C10
N.C.
N.C.
N.C.
N.C.
—
L1
18
15
15
0R
nH
L2
18
15
15
8.2
nH
L3
18
8.2
5.6
3.3
nH
L4
82
68
47
18
nH
L5
100
82
82
82
nH
Tabl e 3. RF Impedance Matching Component Values
Antenna Type Selection
A commercially available 50Ω SMA connector Dipole or Patch can be used as shown in Figure 9.
Figure 9. Dipole Antenna
Or a λ/4 length single core copper stranded wire can be used as shown in Figure 10.
Figure 10. Spring Antenna
If it is required to etch an antenna directly onto the circuit board, refer to the notes in the next
chapter.
PCB Layout Note
Component Placement
When locating components, priority should be given to the RF signal paths. Components and
component PADs should be located as close to the device as possible. The shorter the distance
between the tracks, the better.
When placing component leave room for the VCC and GND lines.

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 12 / 14 November 5, 2020
Routing
Tracks with right angles will cause impedance discontinuities which can accumulate charge
with resulting discharge effects. As this can affect the PCB stability, 45 degree angles or arcs
should be used.
The distance between adjacent tracks should not be less than 6 mils.
The distance between tracks and through holes should not be less than 6 mils.
The distance between two adjacent holes should not be less than 6 mils.
The VCC and GND main tracks width should not be less than 12 mils.
Power lines must first pass through a bypass capacitor before reaching the device power pins.
The ground plane must be as complete as possible under the device. It is important not to have
any tracks under the device and matching circuits otherwise the RF performance may be
affected. Refer to Figure 11.
Figure 11. Recommended Poured Ground Diagram
VSS should be directly connected to the back ground plane of the device during the layout
stage. If space permits, it is recommended to connect all the way to the external ground (GND),
as shown in Figure 12.
Figure 12. Ground Pin Recommendations
The connections between the crystal and the device should be kept as short as possible. In order
to avoid affecting the power supply, a ground area must be laid under the wiring with no
crossing power or signal paths. The crystal and the power lines should be separated by a certain
distance or a ground line. Refer to Figure 13.

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 13 / 14 November 5, 2020
Figure 13. Recommended Crystal Trace Diagram
Antenna
Do not layout any ground planes under the antenna element to avoid affecting RF Performance.
The matching circuit is used for the antenna, with the bottom layer requiring grounding,
otherwise the RF performance will be adversely affected.
In the antenna area, with the exception of the matching circuit components, avoid placing other
components nearby to avoid affecting the RF performance.
Conclusion
This application note has introduced the BA45F56xx architecture and application description, and
has provided a program example for users, allowing it to be used quickly by users in practical
applications to increase product stability.
Reference Material
Reference Document: BA45F56xx Datasheet.
For more details consult the Holtek website at www.holtek.com.
Versions and Modification Information
Date
Author
Issue Release
2020.08.05 陳柏霖
V1.00

BA45F56xx Wireless Transceiver Application
AN0571EN V1.00 14 / 14 November 5, 2020
Disclaimer
All information, trademarks, logos, graphics, videos, audio clips, links and other items appearing
on this website ('Information') are for reference only and is subject to change at any time without
prior notice and at the discretion of Holtek Semiconductor Inc. and its related companies
(hereinafter 'Holtek', 'the company', 'us', 'we' or 'our'). Whilst Holtek endeavors to ensure the
accuracy of the Information on this website, no express or implied warranty is given by Holtek to
the accuracy of the Information. Holtek shall bear no responsibility for any incorrectness or leakage.
Holtek shall not be liable for any damages (including but not limited to computer virus, system
problems or data loss) whatsoever arising in using or in connection with the use of this website by
any party. There may be links in this area, which allow you to visit the websites of other companies.
These websites are not controlled by Holtek. Holtek will bear no responsibility and no guarantee to
whatsoever Information displayed at such sites. Hyperlinks to other websites are at your own risk.
Limitation of Liability
In no event shall Holtek Limited be liable to any other party for any loss or damage whatsoever or
howsoever caused directly or indirectly in connection with your access to or use of this website, the
content thereon or any goods, materials or services.
Governing Law
This disclaimer is subjected to the laws of the Republic of China and under the jurisdiction of the
Court of the Republic of China.
Update of Disclaimer
Holtek reserves the right to update the Disclaimer at any time with or without prior notice, all
changes are effective immediately upon posting to the website.
This manual suits for next models
1
Table of contents
Other Holtek Smoke Alarm manuals