Dorji DRF4463 - Si4463 - Wireless Transceiver Module

srnet

Senior Member
I have been looking at the Dorji DRF4463 as a replacement for the Hope RFM22B.

The new Dorji module uses the Si4463 versus the Si4432 used in the RFM22.

The newer Si4463 transceiver claims an extra 5dB of sensitivity at low data rates over the Si4432, so that should make line of sight operation at approx 70km using simple 1/4 wave antennas possible, assuming the extra sensitivity is realised in practice.

The interface from PICAXE to Si4463 is completely different to the register approach used for the Si4432, for which there are several working examples of PICAXE code published.

So the first thing to do after the Dorji modules arrived is to work out how, using the new API based interface to flash a a couple of LEDs attached to the GPIO pins.

This is the result, it works, and shows the basics of addressing the device.

Code:
'DorjiSat.BAS
'Copyright Stuart Robinson - October 2013

#rem
This program is designed to test the basic interfacing of a PICAXE to the Dorji DRF4463 which uses the Si4463 RF chip. 
The program initialises the Si4463, reads the internal part info then rapidly flashes two LEDs connected to GPIO0 and GPIO1.
If the Si4463 is initilaised and written to correctly the two LEDs should alternate flash very rapidly for 2 seconds
When the rapid flashing is finished, the GPIO0 LED will be off and GPIO1 LED should remain on for one second. 
The GPIO1 LED should then go off and the sequence repeats. 
Any deviation from the sequence indicates that the Si4463 is not being written to correctly.

Runs at 16Mhz and SPIFAST without needing to read the Si4463 CTS (busy) flag.
Details and pinouts of the Dorji DRF4463 are found here;
http://www.dorji.com/pro/Wireless-module/si4463_Module.html

The Si4463 API Command referance (AN625) is a critical document, but for some reason Si have chosen to hide it. 
You wont find it on the documentation listed for the Si4463, so do a Google search for 'AN625 Si446XAPI DESCRIPTIONS'
#endrem


#PICAXE 28X2

#no_data
#no_table


symbol NSEL = a.1  		'chip select line for DRF4463
symbol PXLED = a.3  		'pin to drive LED on PCB
symbol SDN = A.0  		'shutdown line for RFM22
symbol SCK = c.3

symbol var1 = b4			'General use variable
symbol var2 = b5			'General use variable
symbol var3 = b6			'General use variable
symbol var4 = b7			'General use variable
symbol var5 = b8			'General use variable

symbol Si4463Data = b20
symbol leddelay = b21
symbol loopv1 = b22

symbol wvar1 = w27

symbol si4463startupdelay = 1			'startup delay for Si4463 after SDN goes active


main:

high PXLED
pause 1000  					'wait for terminal to be ready		

sertxd("DorjiSAT - Stuart Robinson",CR,LF)

hspisetup spimode00,spimedium  		'setup the SPI interface

high SDN						'ensure Si4463 is reset
pause 10
low SDN

pause si4463startupdelay         		'there needs to be a delay here or the Si4463 fails to startup properly

low NSEL
HSPIout($02,$01,$00,$01,$C9,$C3,$80)	'power up sequence for Si4463 - needed
high NSEL

leddelay = 255

low PXLED

gosub displayversion 

setfreq M16						'run at 16Mhz
		
loop1:
		
	for loopv1 = 1 to 20
	
		'Note that the full syntax for the API command GPIO_PIN_CFG would be HSPIout($13,3,2,0,0,0,0)
		'partial commands appear to work, so only the first two bytes that configure GPIO0 and GPIO1 are sent.
		'The parameters that configure GPIO2,GPIO3 (not used on DRF4464) and the NIRQ and SDO setup are not sent.
	
		low NSEL 
		HSPIout($13,3,2)			'send API command to turn GPIO0 high,GIO1 low, drop rest of commands.
		high NSEL
		
		pause 50
		
		low NSEL
		HSPIout($13,2,3)			'send API command to turn GPIO0 low, GPIO1 high, drop rest of commands
		high NSEL
		
		pause 50
		
	next loopv1
			
	pause 2000  				'leave LED on GPIO1 on for a while
	
	low NSEL
	HSPIout($13,2,2)				'both LEDs off
	high NSEL	
	
	pause 2000
					
goto loop1	


waitcts:
	'checks the Si4463 CTS (busy) flag
	
	do 
		low NSEL 
		HSPIout($44)			'command to check CTS
		HSPIin(Si4463Data)
		high NSEL
	
	loop until Si4463Data = $ff   	'if $FF is ready previous command has completed

return



waitCTSforread:
	'this is used when retrieving data from the Si4463 and is different to a normal CTS 
	'check as NSEL is left low on exit

	do 

		low NSEL 
		HSPIout($44)			'write out command to check CTS
		HSPIin(Si4463Data)
		if Si4463Data = $FF then	'if Si4463 is not busy then leave NSEL low and exit 	 
			exit
		end if
		high NSEL
	loop until Si4463Data = $ff
return	



displayversion:
	'this demonstrates how to read from the Si4463, it performs the PART_INFO command
	'retrieving 8 bytes of info from the Si4463, and should display 4463 as the part	
	
	
	gosub waitcts			'check if Si4463 is busy 

	low NSEL
	HSPIout($01)			'start the PART_INFO command
	high NSEL
	
	
	gosub waitCTSforread		'check for busy, but leave NSEL low if not	

	ptr = 1				'ensure scrathpad pointr is at o
		
	for loopv1 = 1 to 8 		'there are 8 bytes to get
		HSPIIN(Si4463Data) 	'get the byte of PART_INFO
		put loopv1, Si4463Data
	next loopv1
		
	high NSEL
	
	sertxd("Si4463 Part_Info")
	
	for loopv1 = 1 to 8 		'there are 8 bytes to get
		get loopv1, var1		'get the byte of PART_INFO
		gosub hextoASCII
		sertxd(",0x",var1,var2)
	next loopv1
	
	sertxd(CR,LF)
	
	get 2, var1				'get first part of part number
	
	gosub hextoASCII
	
	sertxd("Reported Part Si",var1,var2)
	
	get 3, var1				'get first part of part number
	
	gosub hextoASCII
	
	sertxd(var1,var2,CR,LF)
		
	
return



hextoASCII:
	'converts var1 byte variable to 2 ASCII hex characters, ASCII characters returned in var1 and var2
		
	var2 = var1 AND $0F 			'isolate bottom nibble
	if var2 < 10 then 
		var2 = $30 + var2
	else
		var2 = var2 + 55 
	endif

	var3 = var1 AND  $F0 			'isolate top nibble
	var3 = var3 / 16				'moves top 4 bits into bottom 4 bits

	if var3 < 10 then 
		var3 = $30 + var3
	else 
		var3 = var3 + 55
	endif

	var1 = var3
return
 
Last edited:

srnet

Senior Member
This is a comment on the API for Si4463 in one of the documents;

"The major benefit of the API is that the radio can execute complex commands and procedures with minimal host MCU interaction. This approach helps to reduce the time-critical tasks from the host MCU and allows selection of a simpler, lower-cost MCU for the application"

The reverse may be the case, on the Si4432, this is the code, as per datasheet requirements, needed to read the firmware version of the IC into a variable;

Code:
low NSEL
HSPIout($01)			'read a register
HSPIin(Si4463Data)
high NSEL
9 bytes.

This is the equivalent for the newer API that 'reduces' the load on the MPU, as per datasheet requirements,;

Code:
low NSEL
HSPIout($01)			'start the PART_INFO command
high NSEL
	
do 
	low NSEL 
	HSPIout($44)			'write out command to check CTS
	HSPIin(Si4463Data)
	if Si4463Data = $FF then	'if Si4463 is not busy then leave NSEL low and exit 	 
		exit
	end if
	high NSEL
loop until Si4463Data = $ff
		
	HSPIIN(Si4463Data) 	'get the byte of PART_INFO
	
	high NSEL
35 Bytes.
 

srnet

Senior Member
I so far have got the DRF4463 to transmit a carrier (on the right frequency !) but I cant get it into direct modulation or packet transmit modes.

Anyone trying to use the device should note that the DRF4463 pinouts are labelled incorrectly, and that the Silicon Labs API reference manual is missing definitions of some properties that the sample code (in C) uses.
 

srnet

Senior Member
After some time trying, I would conclude that this Dorji module is most unsuited to PICAXE use. The configuration of the Si4463 is a great deal more complex than the Si4432 (as used on the Hope RFM22).

So in order to carry out tests on the device, to see if the newer device had any useful signal gain over the Si4432, I took some of the published C programs and converted them to run on an Atmega328.

I now have the ATMEGA & Si4463 receiving packets, the preamble and sync word at least, at 437Mhz, 1200bps and 20khz deviation. I tried in vain to convert that to the rates used by 'PICAXE in Space', 1000bps and 5khz deviation, but gave up as there is a fair amount of manual intervention required to take the header file from Silicon Labs config program (WDS) and get it working in an application.

So I converted my PICAXE Si4432 receiver instead across to 1200bps and 20khz, that change took around 5 minutes, easy.

I now have a transmitter of packets (PICAXE and Si4432) and two receivers; one PICAXE based using the Si4432 and another ATMEGA based using the Si4463.

Initial tests show no significant differences in sensitivity, although I am waiting for some decent weather in order to carry out a 4km test.
 

srnet

Senior Member
I carried out some comparative testing out of doors on the RFM22\Si4432 and DRF4463\Si4463.

The test setup for the RFM22 and DRF4463 was the same, 434.100Mhz, 1200bps and 20Khz deviation. Packet reception flagged on receipt of valid preamble and sync word. The transmitter is a PICAXE\RFM22 sending out packets starting at 20dbm, and reducing by 3dBm in steps, a total of 8 packets of descending power. Its thus easy to see when a receiver stops working.

My conclusion is that the RFM22 receives packets around 9-12dB below what the DRF4463 is capable of.

So in terms of better performance, the RFM22\Si4432 is a far better receiver at circa 1000bps rates.

Its possible the Silicn Labs WDS generated settings are rubbish, or that the DRF4463 output matching is very poor, but there is little that can be done to change either.
 
Top