bigtreetech / CB1

OS System image for CB1
366 stars 61 forks source link

CB1 WiFi #16

Open rmilyard opened 2 years ago

rmilyard commented 2 years ago

So I wrote the CB1 image.

In the system.cfg file I put in my Wifi info. I did the 2.4ghz since not sure if 5 supported. I am looking for IP and not finding it on network. On the Manta board there is a soild RED LED near the CPU and green LED blinking near the CB1.

shawnchr commented 2 years ago

After it booted on my network I had to remove power and plug it back in again for it to actually connect.

Does you wifi name have space in it?

rmilyard commented 2 years ago

Nope no spaces.

shawnchr commented 2 years ago

Did you try removing the power and power it back on after a fresh install I always had to do this to pull an IP.

rmilyard commented 2 years ago

I did remove power.

rmilyard commented 2 years ago

Noticed the ethernet LEDs are on with nothing plugged in. The Orange and Green LEDs on solid.

shawnchr commented 2 years ago

The ethernet LEDS do stay on currently when even connected to wifi on mine as well hopefully that get corrected in the future. BUt I am still connected to wifi.

rainerschulte commented 2 years ago

I can connect to LAN, but WiFi doesn't connect. I have a simple SSID whithout space.

thantik commented 2 years ago

There are 2 distributions for this board - I'm just passing along my experiences with this garbage. V1.1.0 Debian 11 just kernel panics for me, I can never get it working. Never connects to wifi. I even connected a monitor, keyboard, mouse, and did

sudo nmcli dev wifi list -- will list my spaces-laden SSID... sudo nmcli dev wifi connect "3D Print Orlando" password mypassword says that the SSID cannot be found though clearly listed otherwise.

I had to go back to the V1.0.1 Hurrican image, flash it, and then boot it on hardware with a screen, keyboard and mouse attached. Let it stay booted for a while - it might reboot once in order to expand the filesystem image. Upon its reboot it still gave me issues and never dropped me to a login prompt - it would continue to error about not being able to ping google, and not being able to connect to some random AP; but a CTRL+ALT+F2 managed to get me to the login prompt. Log in with biqu/biqu.

From there I did sudo nano /etc/rc.local and removed the line which runs the script in /home/biqu/scripts/init.sh (leave the exit 0 line; ctrl+x and then y {enter} to save.) -- This will get rid of the constant errors popping up in the terminal window.

I'd probably also run a sudo systemctl disable hostapd unless you want an access point instead of connecting to your local wifi

You can then issue

sudo nmcli dev wifi connect "yourssid even with spaces" password thewifipassword sudo nmcli dev set wlan0 autoconnect yes

This is the point at which you should be able to just power off the board, disconnect keyboard, mouse, monitor and then reboot and have an active working install on your local wifi network -- but since I was already connected I continued and did the rest of this. You should be able to do this over SSH without issue.

You'll want to do a...sudo nano /etc/apt/sources.list and change your sources from the chinese servers to normal debian servers

Your entire sources.list file can contain only these 4 lines. Adjust as is necessary for your individual usage.

deb http://deb.debian.org/debian bullseye main contrib non-free deb http://deb.debian.org/debian-security/ bullseye-security main contrib non-free deb http://deb.debian.org/debian bullseye-updates main contrib non-free deb http://deb.debian.org/debian bullseye-backports main contrib non-free

and make sure to do a sudo apt update after saving your sources.list to refresh your apt repo.

Afterwards, do

git config --global --unset https.proxy git config --global --unset http.proxy

In order to clear git of its proxy settings for a local machine they were using - this will allow git to connect to the internet and properly update things. Then run:

git clone https://github.com/th33xitus/kiauh.git ./kiauh/kiauh.sh

And I would suggest using that helper script from there.

Personally, I uninstalled everything with the helper script, exited the script, nuked all the rest of the klipper directories under /home/biqu/ and then restarted the helper script and started installing things once again. Remember, Fluidd/Mainsail are both the same thing, essentially. There's no reason to install both of them. I prefer Mainsail, but maybe you prefer Fluidd. No sense in installing both. If you do, you will be asked to choose a different port to place the "second" web interface on (8080, 8888, are usually good choices)

RPK3D commented 2 years ago

I can't connect the WLAN, installed the latest version for the CB1 and entered everything properly into the cfg file. But nothing happens, my SSID contains spaces

shawnchr commented 2 years ago

@RPK3D if you can reimage with a fresh load and connect it via ethernet You have to wait for all lights to stop and unplug and power back up before you modify the system.cfg. you can edit the /etc/wifi_config.sh like the following you need to add the IFS='' to get spaces to work. I submitted this fix to BTT. function read_wifi_config() { IFS='' while read LINE do

Then modify the system.cfg by editing /mnt/udisk/system.cfg with your creds and it will work.

AnAwesomePossum commented 2 years ago

I'm in the same boat, edited the config file with my ssid and pw, none of which have spaces. I can connect with ethernet and When I do sudo nmcli dev wifi list my wifi is listed, and when I do sudo nmcli dev status it says my wlan0 is connecting configuring but never makes it to wifi. Also seems to drop connection from ethernet every couple minutes or so. This is on the newest CB1 lite image but I've used every one from v1 to now with no results.

shawnchr commented 2 years ago

AnAwesomePos yep Thats where I am and I am fighting to get it replaced with tech support I have a big post on the facebook group might want to luke know you are seeing the same issue maybe BTT will get of there ass and realize they have an issue. Shawn "That Guy" Chronister in teh Big Tree Tech Offcial Group

AnAwesomePossum commented 2 years ago

AnAwesomePos yep Thats where I am and I am fighting to get it replaced with tech support I have a big post on the facebook group might want to luke know you are seeing the same issue maybe BTT will get of there ass and realize they have an issue. Shawn "That Guy" Chronister in teh Big Tree Tech Offcial Group

Will do! It sucks that this thing just refuses to work.

BeigeAnimal commented 2 years ago

I could be wrong, but it seems like the antenna just has pitiful range and doesn't reconnect once disconnected. I got it to connect to my router almost perfectly fine when I was setting it up at my desk, my router is on my desk. but when I actually tried using it in my printer it won't connect or would connect for two seconds before disconnecting. I wrapped a wire around the antenna, and pointed my router's antenna directly to my printer and it seems to work. it could be coincidence tho. but if other people could try testing the CB1 while in the same room as the router to confirm that be nice. keep mind there is a jumper for usb power on the Manta M4/8P.

Note: I did do what thantik did a few posts up.

shawnchr commented 2 years ago

It not the antenna I was right next to my router and it will not connect

BeigeAnimal commented 2 years ago

It not the antenna I was right next to my router and it will not connect

Did you do what Thantik did? it could be a combination of things.

also my router is right around the corner and it didn't connect and stay connected until I added the wire Only way it connected it before was when it was on the same desk as the router.

rainerschulte commented 2 years ago

I tried Thantik's suggestion and found, that the old image doesn't boot my CB1. Then I came back to a newer version and got a connect via LAN. Anyway... I tried all "garbage" to delete and again I came out without any wireless connection. All requests returned "Creds not provided". I will now flash a fluidd on it and use the Board wired network. I hope it provides the possibility to use a USB-Cam on my Switchwire. That's weird...

RPK3D commented 2 years ago

So @shawnchr's hotfix helped a bit to make it work. I still had to change my wireless connection via "sudo nmtui". The CB1 tried to dial in using WPA3 encryption, after I selected WPA and WPA2 it worked.

shawnchr commented 2 years ago

Thantik went back to an unsupported image. No I did not because I have successfully configured the current image and it works if you follow my steps unless there is hardware issue. I am fighting with support they keep trying to say it a software issue and I disagree.

I do agree the current image has issues but you can work around them unless the hardware is like mine I started with a working wifi connection it dies and now so has the ethernet so I have a bad board.

I have this running with an M4p + CB1 and this was my M8p+CB1 I tested because I saw all the issues so I have one thats fine and one that not both built the exact same way.

rainerschulte commented 2 years ago

@RPK3D That's the solution! WPA3 is not supported! I switched to WPA2 and I'm online!!!! HOORAY!!!

AnAwesomePossum commented 2 years ago

guys, I powered my board via usb and suddenly my wifi is working! BTT mentioned something about it in their facebook group when trying to troubleshoot another problem so I gave it a whirl. Of course, now I need to know how to power it from the a PSU and keep the wifi working but I suppose it's a step.

kshensley71 commented 2 years ago

@RPK3D if you can reimage with a fresh load and connect it via ethernet You have to wait for all lights to stop and unplug and power back up before you modify the system.cfg. you can edit the /etc/wifi_config.sh like the following you need to add the IFS='' to get spaces to work. I submitted this fix to BTT. function read_wifi_config() { IFS='' while read LINE do

Then modify the system.cfg by editing /mnt/udisk/system.cfg with your creds and it will work.

I bought 2 of these and neither of them worked (Wifi) the new release OS just kernel panics both boards, but the older release loads and works from LAN but not WLAN, I have no spaces in my wifi, but THIS worked for me! EDIT: This worked initially but after a reboot it stopped working. The solution that DID finally work for me was THANTIK's solution, which is long and uses the pre-release version, but it is the only thing that actually worked for me. the new release just kernel panics on both boards due to numerous errors. It looks to me like Biqu (BTT) has left a lot of location-specific settings in these releases that I'm sure work very well for them in their own wifi network with their equipment. The problem is literally EVERYONE else who tries to connect to their own wifi is going to have issues. This really needs to be fixed ASAP. I have spent 5 hours now to get these boards to be stable and connect to wifi, not to mention all the time that THANTIK and the others spent to get this to work. At this point I finally have it connecting to wifi and Klipper/Fluidd working, I'm really hoping I don't start having more issues when I actually try to use this on a printer.

basha318i commented 2 years ago

So @shawnchr's hotfix helped a bit to make it work. I still had to change my wireless connection via "sudo nmtui". The CB1 tried to dial in using WPA3 encryption, after I selected WPA and WPA2 it worked.

this is what actually worked for me, thanks a lot!

shawnchr commented 2 years ago

So @shawnchr's hotfix helped a bit to make it work. I still had to change my wireless connection via "sudo nmtui". The CB1 tried to dial in using WPA3 encryption, after I selected WPA and WPA2 it worked.

this is what actually worked for me, thanks a lot!

Your welcome I was trying to find a fix for everyone now if BTT would get the new image out so I can load and prove I have a bad board it would be great. This board should never have been released into the wild and no support is even worse. This iwill turn off alot of customers epecially when Raspi cm4's come back I am dumping this crap.

basha318i commented 2 years ago

So @shawnchr's hotfix helped a bit to make it work. I still had to change my wireless connection via "sudo nmtui". The CB1 tried to dial in using WPA3 encryption, after I selected WPA and WPA2 it worked.

this is what actually worked for me, thanks a lot!

Your welcome I was trying to find a fix for everyone now if BTT would get the new image out so I can load and prove I have a bad board it would be great. This board should never have been released into the wild and no support is even worse. This iwill turn off alot of customers epecially when Raspi cm4's come back I am dumping this crap.

I too believe I have a bad board; the WiFi is extremely slow like when I was downloading Klipper it was at 235KB/s I understand the WiFi module on the CB1 is not so great & maxes at 100Mb/s but at least achieve 80% of that! Also, my PWR LED (the one next to ACT) doesn’t come on at all, I tried the Hurakan & I didn’t have the ACT working; then the latest which I got ACT, but no PWR LES at all; although it’s up & I’m able to access it.

AnAwesomePossum commented 2 years ago

They sent out a new image to a few people. Wifi works over PSU power now. The screen isn't blurry. Ethernet does not work. They did say it was a pre release though.

kildiyarov commented 2 years ago

They sent out a new image to a few people. Wifi works over PSU power now. The screen isn't blurry. Ethernet does not work. They did say it was a pre release though.

Can you please share this image?

ma1069 commented 2 years ago

Did it solve the issue for you? I still see the same problem as before: wifi working over USB but not over PSU

AnAwesomePossum commented 2 years ago

Yes and no. Wifi is working over PSU ethernet doesn't. It also appears that wifi will drop or become unresponsive. Nmcli will give me an ip but can't ssh into it after so long. I'll post a link to the image in a few.

billru05 commented 2 years ago

The new image is on the images page for the CB1, but there still are tons of issues/ wifi dose not always work, when it dose work it drops connection, Lan not working, for me the image is not usable

kshensley71 commented 2 years ago

Unfortunately my second Pi4 adapter board appears to be defective. I tried the new image using the adapter and a CB1 and nothing happens. Lights come on but no video and no wifi or network. I tried another CB1 and the same thing, so I tried one of the older images and nothing. It looks like my PI4 adapter board is no good. My first one is mounted in a printer that I am using so I can't remove it to test the new image on it right now, and I'm traveling for the next week. When I get home I'll pull it and test the image on it. Sent from my Galaxy -------- Original message --------From: ma1069 @.> Date: 9/2/22 2:32 PM (GMT-05:00) To: bigtreetech/CB1 @.> Cc: kshensley71 @.>, Comment @.> Subject: Re: [bigtreetech/CB1] CB1 WiFi (Issue #16) Did it solve the issue for you? I still see the same problem as before: wifi working over USB but not over PSU

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

TxBillbr commented 2 years ago

I have a usb wireless dongle (supported by buster drivers) on one and a wired usb dongle on another cb1. Not using the BTT networking allows me to move forward a bit. At least I am operational.

Gavrik13 commented 1 year ago

Hello.

Can you tell me how to beat this on the latest releases?

Dersonje commented 6 months ago

I had to disable WPA 3 on my router to get 2.3.4 on the cb1 to connect to wifi. Tried everything else I reasonably could and that is the only thing that worked

dayrecker commented 6 months ago

Highly recommend NOT following BTT instructions to edit system.cfg prior to booting the E3EZ. Instead, leave system.cfg alone connect via ethernet and then connect to your wifi via nmcli. Also, I switched my router to WPA/WP2 from WPA2/WPA3 for the initial connection (not sure if that was necessary), but no problems connecting again after turning network back to WPA2/WPA3.

Puding07 commented 1 month ago

In my case the problem was that my password included a $ sign which cut off the rest of the password... Just to give you a basic udnerstanding what's happening is after boot an init script /boot/scripts/btt_init.sh runs /boot/scripts/connect_wifi.sh which will get the Wifi credentials from system.cfg file. The script generates a .nmconnection keyfile in /etc/NetworkManager/system-connections/. The generated file will be used to connect you to your wifi network.

Useful commands:

How I resolved the issue?

  1. Before first boot I edited the recommended system.cfg file with my Wifi credentials.
  2. After first boot I edited the init script with sudo nano /boot/scripts/btt_init.sh and commented out this line ./connect_wifi.sh &
  3. Edited the credentials in my keyfile: sudo vim /etc/NetworkManager/system-connections/SSID_NAME.nmconnection
  4. Reloaded keyfiles for Network Manager: sudo systemctl restart NetworkManager
  5. Connected to Wifi: sudo nmcli con up SSID_NAME

After reboot it should automatically connect so you don't have to repeat these steps.

Additionaly if you want you can add hostname to your device if you like to have verything organised. Add this line to you keyfile under ipv4 settings: dhcp-hostname=BTT-CB1.

Hope this helps you guys. 🙏 Cheers!