Get your own customer support community
 

settxpower() on WA1000 fails. Why?

Hi there,

My code is :

'enable power to the Wi-Fi module
io.num=PL_IO_NUM_51
io.state=LOW
io.enabled=YES

'configure the CS line
wln.csmap=PL_IO_NUM_49
io.num=PL_IO_NUM_49
io.state=HIGH 'VERY IMPORTANT! -- you must have this line, and it must be placed before...
io.enabled=YES '...this line!

'set the mac address
wln.mac="2.131.206.31.44.5" 'set correct MAC here

'set the domain
wln.domain=PL_WLN_DOMAIN_OTHER

'boot it up
romfile.open("wln_fwar.bin")
If wln.boot(romfile.offset)=NG Then
'something is wrong, react to this
End If

wln.ip="192.168.1.39" 'And don't forget to set a correct IP-address
wln.netmask="255.255.255.0"

'set output power to maximum
If wln.settxpower(255)<>0 Then
'the task was rejected for some reason
pat.play("RRRRR-",PL_PAT_CANINT)
End If

The settxpower routine fails everytime. Any ideas? Please help! Is my WA1000 broken?
 
sad I’m frustrated
Inappropriate?
2 people have this problem

User_default_medium