This is an old revision of the document!
By default, the Wi-Fi module's Country Code is set to 00
(global).
Wi-Fi channels and power levels are regulated differently in each country.
To ensure proper functionality and legal compliance when using the device in different country, you may need to set the Country Code to match your current location.
This can prevent issues where certain Wi-Fi networks are not visible or the connection is unstable.
On Ubuntu-based systems, the firmware and configuration files for Broadcom Wi-Fi modules are located in the following directory. This is the standard path used across the system.
/lib/firmware/brcm/
The configuration file for a specific Wi-Fi module follows the naming convention:
config_xxxxx.txt
where xxxxx corresponds to the module's firmware filename.
config_bcm43752a2_ag.txt
config_bcm43752a2_pcie_ag.txt
config_bcm4359c0_ag.txt
This is the quickest way to change the country code. It's perfect for testing if a specific setting resolves your issue, but the change will be lost after you reboot the device.
Open a terminal and run the iw reg set command with the two-letter ISO country code. For example, to set the country to Italy (IT):
sudo iw reg set IT
Verify the Change You can immediately check if the setting was applied using the iw reg get command:
sudo iw list | grep MHz
The output should show the frequency those are allowed in the set country.
If this temporary setting fixes your Wi-Fi problem, you should proceed to the permanent method below.
You can change the Country Code by editing the appropriate configuration file.
Check ccode and regrev correspondence
For VIM4 and Edge2, the regrev value for all countries is 0, such as the United states: US/0.
1. Open the configuration file with a text editor.
For the AP6398S(VIM3/3L) module, use:
sudo nano /lib/firmware/brcm/config_bcm4359c0_ag.txt
2. Modify the file content to specify the desired ccode and regrev values.
For Italy, the configuration should be:
ccode=IT regrev=20
The correct values for ccode and regrev are specific to your Wi-Fi module and country. You must consult the appropriate regulatory documentation or tables for your hardware. Using incorrect values may result in improper device operation.
After saving the configuration file, reboot the device for the changes to take effect.
sudo reboot
After rebooting, confirm that the new Country Code has been applied by checking the kernel messages:
dmesg | grep Country
If the configuration was successful (for Italy), you should see output similar to:
[ 18.743736] Country code: IT (IT/20)
This confirms that the Country Code has been successfully set to IT with a regulatory revision of 20.
config_*.txt
file under /lib/firmware/brcm/