Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade not available #779

Closed
Giuserver opened this issue Dec 17, 2023 · 21 comments
Closed

Upgrade not available #779

Giuserver opened this issue Dec 17, 2023 · 21 comments

Comments

@Giuserver
Copy link

On all my cameras, the update button doesn't seem to work.
Screenshot 2023-12-17 alle 11 56 31

@mscosta01
Copy link

+1

@SnOOpeRa
Copy link

+1 , current ver 0.2.9 , same thing

@Giuserver
Copy link
Author

maybe @roleoroleo can explain 😊

@roleoroleo roleoroleo pinned this issue Dec 23, 2023
@roleoroleo
Copy link
Owner

I think it's the same probem described here:
roleoroleo/yi-hack-MStar#526 (comment)

A bug in the busybox wget.
I need to check it.
If you need to upgrade the fw, use the manual procedure described in the wiki.

@Giuserver
Copy link
Author

I think it's the same probem described here: roleoroleo/yi-hack-MStar#526 (comment)
A bug in the busybox wget. I need to check it. If you need to upgrade the fw, use the manual procedure described in the wiki.

for me it shows /root is only-read system following what the wiki says

root@Yi36:/tmp# mv y21ga_0.3.0.tgz /root/ mv: can't create '/root/y21ga_0.3.0.tgz': Read-only file system

I allowed myself to do an update like this only once and i broke everything 😅 we're waiting for the restore.. which I believe will happen on the server side. Also because i don't have the possibility to take the camera manually

@niziak
Copy link

niziak commented Jan 4, 2024

Manual update procedure mentioned here https://github.com/roleoroleo/yi-hack-MStar/wiki/Manual-firmware-upgrade says:

Copy the file in the root folder of the sd card.

ROOT FOLDER OF SD CARD is not /root

Working "remote" procedure:

  1. Download latest firmware. On my PC I'm using simple wget command: wget https://github.com/roleoroleo/yi-hack-Allwinner-v2/releases/download/0.3.0/y21ga_0.3.0.tgz
  2. Upload downloaded firmware to camera's SD card root /tmp/sd but with changed version number to x letters: scp y21ga_0.3.0.tgz scp://[email protected]//tmp/sd/y21ga_x.x.x.tgz
  3. Press Upgrade Firmware button

@roleoroleo Like you said before - there is no https support in wget nor any other utility available on camera. How upgrade works before ?

EDIT:
I've just added openssl package and enabled CONFIG_FEATURE_WGET_OPENSSL=y busybox wget option. Now busybox's wget spawn openssl binary to perform download:

31721 root       972 T    ./busybox1 wget --no-check-certificate https://github.com/roleoroleo/yi-hack-Allwinner-v2/releases/download/0.3.0/y21ga_0.3.0.tgz
31725 root         0 Z    [openssl]
31767 root      3772 T    openssl s_client -quiet -connect objects.githubusercontent.com:443 -servername objects.githubusercontent.com

Now only cosmetic fixes with ca-certificates bundle needed. @roleoroleo should I continue my efforts and create PR ?

@roleoroleo
Copy link
Owner

ROOT FOLDER OF SD CARD is not /root

Correct. I added a new note to the wiki page.

@roleoroleo Like you said before - there is no https support in wget nor any other utility available on camera. How upgrade works before ?

Simply wget ignores certificates.
I think the problem is harder than it appears. It's not true that wget doesn't work anymore with https.
It you try another site, maybe it works:

root@yi-hack-h52ga:~/bin# wget https://www.google.com
Connecting to www.google.com (142.250.180.132:443)
wget: note: TLS certificate validation not implemented
saving to 'index.html'
index.html           100% |***************************************************************************************************************************************************************| 18141  0:00:00 ETA
'index.html' saved

I think it's related to https + forward.

Now only cosmetic fixes with ca-certificates bundle needed. @roleoroleo should I continue my efforts and create PR ?

It depends on how big the openssl binary is.
Because I would like to find the same solution for all platforms (MStar, Allwinner and Allwinner-v2) and there is a big space constraint in MStar and Allwinner.

@niziak
Copy link

niziak commented Jan 6, 2024

Unstripped openssl + shared libs:

576K openssl
2,3M libcrypto.so.1.1
492K libssl.so.1.1

Plus default ca certs bundle ~200K. Bundle can be reduced to Github related certs. I can try to remove some features and link it statically. Many years ago static OpenSSL size was around 900kB. If it will be possible to get binary around 1-1.2 MB will it be big or OK for other platforms?
Another approach is to remove online checking and provide simple "upload firmware" button on web page ?

@roleoroleo
Copy link
Owner

1.2 MB it's big.
I have to do some calculations...

@roleoroleo
Copy link
Owner

roleoroleo commented Jan 8, 2024

It seems that bb 1.36.1 should fix the problem.
I will try asap.

EDIT

Confirmed.
After update to 1.36.1 it works.

@roleoroleo
Copy link
Owner

Fixed here:
f282010

@TungstenE2
Copy link

TungstenE2 commented Jan 13, 2024

1. Download latest firmware. On my PC I'm using simple wget command: `wget https://github.com/roleoroleo/yi-hack-Allwinner-v2/releases/download/0.3.0/y21ga_0.3.0.tgz`

2. Upload downloaded firmware to camera's SD card root `/tmp/sd` but with changed version number to `x` letters: `scp y21ga_0.3.0.tgz scp://[email protected]//tmp/sd/y21ga_x.x.x.tgz`

3. Press `Upgrade Firmware` button

done the steps, but copied to SD with card reader on PC.

after reboot still no update possible.

grafik

@pannal
Copy link

pannal commented Jan 17, 2024

after reboot still no update possible.

Yes it is, rename the file's version numbers to x, e.g.: r30gb_0.3.0.tgz -> r30gb_x.x.x.tgz

@TungstenE2
Copy link

after reboot still no update possible.

Yes it is, rename the file's version numbers to x, e.g.: r30gb_0.3.0.tgz -> r30gb_x.x.x.tgz

did this as stated before, but not working

@Giuserver
Copy link
Author

Solved with last version
Screenshot 2024-01-19 alle 18 50 47

@TungstenE2
Copy link

Solved with last version Screenshot 2024-01-19 alle 18 50 47

great, but how to update, if OTA and manual does not work?

@roleoroleo
Copy link
Owner

Manual upgrade must work.
Please try again.

In any case, you can format the sd card and create it again with the new version.
Backup the configuration.

@playersct
Copy link

Manual upgrade must work. Please try again.

Work without problems :)

@Giuserver
Copy link
Author

Manual upgrade must work. Please try again.

In any case, you can format the sd card and create it again with the new version. Backup the configuration.

How can I do the update manually?
Do you mean, format the sd card and paste it new version?

@roleoroleo
Copy link
Owner

Check the wiki.

@JoseAlcerreca
Copy link

This method worked but note that you can also use the FTP to upload the file if extracting the sd card is cumbersome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants