-
-
Notifications
You must be signed in to change notification settings - Fork 78
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
New OS for RPI4/5 causing Problems #457
Comments
Yeah Yeah; "Python is a WORA (Write Once, Run Anywhere) language."; everybody may judge how true the statement is. Please suggest what changes help you forward, apart from the missing whl. |
Hmmm... Did a quick check but don't find; please what page? |
Sorry, the address of marcDobler.com appeared in the message from the instalation script "4_InstallWxPython.sh". |
The missing scales look a little strange, and i would like to know, wether the generated whl in issue #440 has the same lost. It has the same wx revision number. |
I do not have an RPI4/5 so cannot test, but perhaps others can... |
Will you add the missing Parameter "--break-system-packages"? Or will this brake the installation for the others? |
I'm ok to do so, but in what line please |
every pip3 command needs it. |
I see two ways:
|
There is a strange behavior when I close the program. the terminal windows stays open and does not close.
Does this effect only appear with "bookworm"? |
It happens on Windows as well. Perhaps a coding error waiting for threads to complete. I don't know |
For me the waiting the thread problem seems be solved. I could not find the reason. I fixed the problem by "brutal force". I look for the process id from main. At the end I kill it.
In FortiusAntGui.py (1502) I kill it:
What do you think, will it have bad side effects? |
I found the reason for the disappeared Scales ( it was a white eagle on white ground problem). I found the reason in the speedmeter library. When I added the typecast to the color changing variables the blue background came back and the white scaling appeared again.
I have no experience how to handle this kind of problem. |
Hi @decodeais good work. You have greatly re-engineered to the location where the problem is created, let's see how to help. Some questions (I assume you can answer):
If you tell me this, it avoids work for myself. |
I will look into it; in fact it suggests there is some flow-error and it circumvents the problem creatively; but still no beauty. |
I tried to make a pull request for the speedometer software( I have no expearence with this things) . I found that there are other people withe the same problems with the intern typecast errors on the other instrumentts, but nothing seems to happen. |
I assume it can be considered a calling error, do if you help me forward, we can solve in our code |
It is an internal problem in the speedmeter software. The only workaround you can do, is to change the color of the scale from white to black. it looks much better than the white on white. |
Ok, please suggest code change |
|
I cannot change this code (other than locally) so I assume I cannot help. |
I made my first pull request (I never done before). The problem was accepted and verified. I hope they will change it as soon as possible. |
I my opinion a fundamental design of Python error not to implement strict data typing... |
You don't have to declare the Type, but you have to find out to what it has mutated. |
I'am afraid that this problem caused some displacements in the GUI. I had to move some Buttons. |
Well, not helping the subject but sure fun to read https://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html I did not get to the end of this stunning text 😉 |
This is what it looks like when a mathematician tries to code |
It was a hard work, so I hope it realy works. This is my default for <3.10: This was my first test for Raspbian Bookworm with Python3.11, it has still the Speedmeter bug: This is unofficial pre release with bug fix: Here are the wheels for normal Linux with Python >3.09 I hope somebody can use it and tell me if there is something wrong. Here is the script i used to generate these wheels. It has to be tested on some fresh systems. Nevertheless its a good starting point for own generated wheels: #!/bin/bash
# export PATH="$HOME/.local/bin:$PATH"
export DOXYGEN=/usr/bin/doxygen # for Raspian we must use the internal dxygen
# Update package lists
sudo apt-get update
sudo apt install doxygen
# Install required packagesexport PATH="$HOME/.local/bin:$PATH"
sudo apt install -y dpkg-dev build-essential python3-dev freeglut3-dev libgl1-mesa-dev \
libglu1-mesa-dev libgstreamer-plugins-base1.0-dev libgtk-3-dev libjpeg-dev libnotify-dev \
libpng-dev libsdl2-dev libsm-dev libtiff-dev libwebkit2gtk-4.0-dev libxtst-dev \
libgstreamer1.0-dev libjpeg-dev libtiff-dev libsm-dev
# Create directory for building
mkdir -p ~/WheelBuild311
# Change directory to the build directory
cd ~/WheelBuild311
# Create and activate virtual environment
python3.11 -m venv WheelBuilder311_py
source ~/WheelBuild311/WheelBuilder311_py/bin/activate
# Upgrade pip and install required Python packages
pip install -U pip six wheel setuptools sip requests
# Clone Phoenix repository
git clone https://github.com/wxWidgets/Phoenix.git --branch master
cd Phoenix
git submodule init
git submodule update
git submodule update --init --recursive
# Build Phoenix
python build.py dox etg --nodoc sip build bdist_wheel
#python build.py build bdist_wheel May be it would be necessary to use a virtual machine for linux. A fresh Raspbian should not be a problem. |
From the beginning - I was 100% new to python, github and visual studio code - I created the folder structure, including the .exe and .pdf files. Later I learned, github is intended for source-files only and large deliverables should be stored elsewhere; not that github blocks in any way. The .exe / .pdf files litter the repository (all previous versions are still available) but I see no straight-forward solution. If anyone reads this and has suggestions - feel free to suggest For the files you have created, the following approach is good for me:
If you write a pull request with the wheels at the suggested location, we can proceed like that and keep the files available for others. Please give the files a clear name... And again: |
First you can copy the link, I let them there. Everybody who has this link can use the file. |
I think the reason for the problem is that the chief from this project was unable to work for this problem for two years. They restarted the project, made the changes for python 3.11, the tool to generate the wheels does not work for linux and windows at this moment. This will change, I hope. |
Fair enough, easy stuff: https://github.com/WouterJD/FortiusANT/wiki#special-files, Accessible for everybody who needs. |
Please be strong i have some more question:
The good news:
|
I fixed the size problem for Wayland desktop, with the addition of a constant value to the size. I know its not the right way, but it is dificult to find out your strategy of your window size calculation.
For the gearbox, I had to change the size too.
Now it looks quite normal again. |
Next Problem but fixed. The old autostart can not work. These are working:
Autostart_Off.sh
|
I have put my changes to github: https://github.com/decodeais/FortiusANT/tree/Wayland |
I understand that. I think it's been experimental what looks goed. |
I took this image 1.1GB Raspbian Bookworm and installed it with my installation script. |
Hi, I can check it out. I just got a RP4 and am going to try to set it up. `Installing collected packages: six, numpy, wxPython Successfully installed numpy-1.26.4 six-1.16.0 wxPython-4.2.2a1 |
It looks for me that it can not find the stop.sh script. I get this error messages too. #!/bin/bash
cd /home/pi/FortiusANT/raspberry
source FortAntEnv/bin/activate #start the virtual envirement
pip list
./stop.sh Please check the execute permission for stop.sh, it was lost on my Raspi. #!/bin/bash
cd /home/pi/FortiusANT/raspberry
source FortAntEnv/bin/activate #start the virtual enviroment
|
I found the reason for the error messages there where 2 installations in the script. One from the download and one stock install with apt-get. The "stop.sh" has now its permission to run. |
I will do a complete new install from a clean sd card. Do you have have your install script on the Wayland branch? I noted you mix /home/pi with $HOME the latter is preferable I think as not to force people having the pi user. |
I know, but I have changed so much in this Wayland Branch. My aim is to get a good installation as soon as possible. |
I saw you made a Zapiens commit. I branched off at that commit to make the changes I thought of but I could not push. I forked the repo instead to try a complete hands free installation. |
If you succeed I would like to test yours. I think it would be a good idea to give the apt-get commands a yes parameter. Then it would run to the end in connection with install script n parameter. If it stopped with an error I allways tried to edit the script and restaerted it, fresh installs only to test. |
Many iterations when the aim is totally hands free, always a little thing left to do. I am almost there ..... ha ha If you have any questions about git feel free to ask me. Finally no hands and it is up and running on an RP4 |
This sounds good! I will get the new Raspi next days.we I orderd a Zero 2W too, so i can check this one too. The old autostart, setup onnly works only on X11 on Wayland we can use my autostart_ON/OFF script. The little help scripts will make problems when somebody forgets to start the virtual environment first, we should think about how to handle. Now the most important for me, how to get the last version from you to merge ( I am a github analphabet). |
Good work in getting wxPython to build. If you do this:
You will have mine fork together with yours. Nothing of what you have done is affected.
Shows my commits, now only one as I squashed them together Note the hash of my commit: 6ceca98 You can insert that commit where you see fit by:
I think pull requests are an overkill at this stage with work in progress. |
I have got your changes. I lost orientatio for a while between all the repositories, branches.. |
I hope you one day will see the beauty of Merkle trees and the git confusion will be gone ;) I still have the connection problem. I have tried to pair with my Android phone, windows 11, Ubuntu 22.04 all with the same outcome. I don't know how to debug this or what is expected at this point. In windows the 'FortiusAntTrainer' is shown as an Audio device and fails to pair. In Ubuntu the pairing comes up with the numbers that should match. Clicking confirm on both computers the Raspberry has the dialogue box 'Waiting for response from Bluetooth device' In ubuntu I get the error:
in dmesg |
I am totally lost on the bluetooth. I can connect now connect the raspberry to ubuntu 22.04/windows 11 and send files to/from ubuntu and only from windows 11. In windows 11 the fortius appears as an audio device. In neither ubuntu or windows the FortiusAntTrainer appears in training software. So far I have only tested with Zwift and GoldenCheetah. In ubuntu the device looks like:
|
I made a lot of updates in the installation. Now the installation script works with Linux too. !!!!!!!!!!!!!!!! I have a idea. The reason will be that you started the program direct. you have to switch the bluetooth driver: #-------------------------------------------------------------------------------
# If bluetooth required, stop service and enable for FortiusAnt
#-------------------------------------------------------------------------------
if [ $bluetooth == 1 ]; then
echo Stop standard Bluetooth Service
sudo service bluetooth stop
echo Enable Bluetooth for FortiusAnt
sudo hciconfig hci0 up
if [ $? != 0 ] ; then
Red='\033[0;31m'
NC='\033[0m'
printf "${Red} hciconfig failed, press enter to continue: ${NC}"; read x
fi
fi
it part of |
Hi @zapiens good to hear. I would like to remove all old versions and then Your recommendations are appreciated; if it's worthwhile we can start a new issue for that. |
I understand your problem. I think this Issue is really much to long now. Only the script to build the wxPython wheel and the links to the wheels should stay. |
Hi @WouterJD again thanks for all your work on this. A principle I have used when working with git is to never check in generates. Generates should go to a storage instead. Yes a repo gets bloated with time as binaries get checked in. To remove generates in the repo the history needs to be rewritten and thus all hashes after the changed point will be rewritten. In a small project with few developers I would communicate that and tell everyone to create pull requests for serious work done. After that freeze the repo and rewrite history and this will be a "new" repository that everyone needs to clone from (or fetch --force). If a larger project I would create a new rewritten repo and tell everyone to use that one instead, the old could be around for a while for archaeological reasons ;) |
Thanks @decodeais for the suggestions. I brought up the bluetooth connection on both machines with bluetoothctl to have total control over what was going on. The connection was very unstable. It connected and then disconnected. Sometimes it stayed connected for longer time and I could send files back and forth. When you say you use a bluetooth stick do you mean you omit using the built in bluetooth in RP and computer? |
It was for an old Raspi without BT and a Tablet without built in Ant plus. Ant sticks are a better than BT but more expensive. My wife is happy rp2 and two ant+ sticks. |
I wanted to set up RasperiPy4 again, as I use it as a true multifunctional device (Print spooler, web server, etc.).
However, with the latest version of the OS (Bookworm), some issues arose.
Activating the VNC server is no longer as straightforward. "raspi-config" must be called , and then "WayVNC" needs to be switched to the X backend. After that, RealVNC can be activated as usual by enabling the "VNC" option in the "Interface Options". Additionally, the "wayvnc" backend had to be uninstalled, as it caused annoying delays during boot.
The old instruction in the manual is no longer entirely accurate and could be confusing.
Whenever "pip3" commands were executed in the installation script, the option "--break-system-packages" had to be added.
Now that the new Python Version 3.11 is installed, the WHL for wxPython no longer fits. The reference in the manual to MarcDobler's page was useless as the link was dead (it should be removed from the manual).
Nevertheless, I managed to generate a suitable one:
The generated file "wxPython-4.2.1-cp311-cp311-linux_aarch64.whl" works,
The but the scales on the performance and speed indicators have disappeared.
These were the main issues. Initially, I would appreciate a suggestion on where to search for the missing scales. However, this is only a "Design" problem.
The text was updated successfully, but these errors were encountered: