Q: BCM43142 WIFI became unrecognized suddenly after reboot Up until an hour ago I had access to the internet and then my battery drained and my PC closed and when I booted it up again suddenly I had no connection.
I tried a bunch of stuff I found online but nothing.


*

*There is no enable wireless option

*In System Settings > Network there is only network proxy no wireless

*The output of rfkill list all lists only Bluetooth

*sudo lshw -c network lists an ethernet controller and a network controller

*It's a dual boot system, and internet works fine on Windows

*sudo ifconfig lists only lo
Output of lspci -nnk | grep 0280 -A2 is:
 0d:00.0 Network controller [0280]: Broadcom Corporation BCM43142 802.11B/g/n [14e4:4365] (rev01)
 Subsystem: Hewlett - Packard Company Device [103c:804a]
 Kernel driver in use: bcma-pci-bridge


A: I think it is a problem of drivers...
I can see Kernel driver in use: bcma-pci-bridge.
Your Broadcom Corporation BCM43142 802.11B/g/n [14e4:4365] should work with the Broadcom proprietary driver. If you have an ethernet cable please connect and execute the following with the terminal:
sudo apt-get update
sudo apt-get install bcmwl-kernel-source

When this is done, unplug the cable and verify that your wireless is working .

A: What solved my problem (for now and hopefully for good!) is Yufenyuy Veyeh Dider's answer, but I am posting my own answer to explain in detail what I did.
Since I had no wireless or ethernet I found the right package on another machine and copied it to my PC via usb.
In my case the package was this one, amd64 architecture because it's a 64 bit machine. Double clicking the package opened the software center but it wouldn't let me install it citing  This requires installation of untrusted packages.
I searched online and found that you can install  deb files by the following command:
 sudo dpkg -i DEB_PACKAGE_NAME

which I did but another package dkms was requested and failed to fetch since I have no internet connection. The name of it was dkms_2.2.0.3-2ubuntu6.1_all.deb so I found it the same way as the bcmwl-kernel-source and installed it using sudo dpkg -i  dkms_2.2.0.3-2ubuntu6.1_all.deb. After it installed, I installed the original package bcmwl-kernel-source and my wireless started working again!
I hope this is the end of it. But I have no idea why this happened out of the blue, when wireless was working perfectly an hour ago.
rfkill list all now lists:
0:phy0: Wireless LAN
1:brcmwl-0: Wireless LAN
2:hci0: Bluetooth

ifconfig -a lists:
lo
wlp13so

sudo lshw -c network lists an ethernet controller and a wireless interface.
Does that mean that everything is as it should be?
I have no idea why this happened in the first place, I hope my answer helps anyone with the same problem.
Again thanks Yufenyuy Veyeh Dider!
