Custom Build Taranis X7 help

openTx has introduced a range of new features, ideas and bling. It is fast becoming the firmware of choice for many users. openTx will run on ALL current hardware platforms, including the gruvin9x and sky9x boards. Work has already started to support the new FrSky X9D radio!
Post Reply
tiaanv
Posts: 1
Joined: Wed Jan 10, 2018 3:30 pm
Country: -

Custom Build Taranis X7 help

Post by tiaanv »

Hi there

I have set up a build environment on Windows using QT creator Route to build open TX for my Taranis Q X7.

I can successfully build everything, and can update the frimware successfully. However soon after power up and the spash screen showing, the radio goes into a boot loop. Clearly I am doing something wrong, but am having a hard time on how to trace the route of the problem,

For reference here is what I have done:
  • I have used a stable branch of 2.2.1, and not made any changes to the source.
  • I have set the build options to build for "X7"
  • I have set the options I think are correct like "GVARS, NOHELI, LUA etc"
Is there perhaps a key option that I should be setting for this to work?

Any assistance would greatly be appreciated.

PS the main reason for this is to change the behaviour of the power button. I have already identified the required changes I need to make.

User avatar
Kilrah
Posts: 11107
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Custom Build Taranis X7 help

Post by Kilrah »

Did you use the specified versions of each tool, most importantly arm-gcc?
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

For various reasons, I thought I'd try to get a build environment configured for openTx using QTCreator, since I have that installed.
The problem I have is with Python. Python 2.7 is already on my PC, but NOT in my path.
Cmake is not finding Python. Is there a way of telling Cmake where it is installed when it can't find it?

Mike
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
User avatar
Kilrah
Posts: 11107
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Custom Build Taranis X7 help

Post by Kilrah »

I believe if you have it installed in the default location cmake should find it even if it isn't in the PATH...
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

It was installed as part of an original QT installation, so I've always just used it from there. So it is NOT in a default location. I often don't install things in "Program Files" either, since Windows started making that a write protected directory.

Mike
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!

User avatar
Kilrah
Posts: 11107
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Custom Build Taranis X7 help

Post by Kilrah »

Umm I never knew of python coming with Qt.

Python2.7 normally installs in c:\Python27 and that works as it should. No decent/ recent program should attempt to write into its program directory.
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

It's in QtSDK, I must have got this along with Qt.

Mike
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
ReSt
Posts: 1581
Joined: Tue Dec 27, 2011 11:34 pm
Country: -

Re: Custom Build Taranis X7 help

Post by ReSt »

On my pc (Win XP) python is installed in c:\python27 and is included in the path variable as very first entries.

PATH=C:\Python27;C:\Python27\Lib\site-packages\PyQt4;

Reinhard
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

I installed python2.7, and added PyQt4 from my existing installation. The build starts, but stops at:
" File "C:/xxx/opentx-2.2/radio/util/img2lbm.py", line 9, in <module>
from PyQt4 import Qt, QtGui
ImportError: DLL load failed: %1 is not a valid Win32 application."

Maybe I'll need to actually install PyQt4, but it seems wrong that I should need to install things just so Cmake can find them. Surely it should be possible to tell Cmake where thay are already installed, or is it the Cmakelists that is not able to accept a manual configuration?

Checking back, python2.7 and PyQt4 were installed when I installed QtCreator 4.7.3 originally, which is also in the QtSDK directory.

Mike
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

If I run "python img2lbm.py" in my original python directory it does the import from PyQt4 OK, but not from the new installation with PyQt4 copied to the correct place, so it is an installation problem.
I'm trying to avoid having multiple installations of python and PyQt4.

Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
User avatar
Kilrah
Posts: 11107
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Custom Build Taranis X7 help

Post by Kilrah »

According to this it should be possible to give the path in cmake's command line:
https://stackoverflow.com/questions/152 ... ion-how-do

Note that OpenTX 2.2 requires QT 5 (5.7.1 used for release).
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

In the end, I've added the path to my original python27 to my PATH variable. Now, the build is running (after cleaning Cmake files etc.).

It is openTx I'm wishing to build rather than companion, although, I see, in spite of having selected "firmware" before I needed to go out, it has reverted to building companion.

Mike
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
User avatar
Kilrah
Posts: 11107
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Custom Build Taranis X7 help

Post by Kilrah »

"make firmware" should make the firmware.

I unfortunately don't know QT Creator to help if you're using that to launch the build.
User avatar
MikeB
9x Developer
Posts: 17979
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: Custom Build Taranis X7 help

Post by MikeB »

Well, both companion and the firmware built correctly. Companion runs OK, I haven't treid the firmware (yet).
Just one niggle, Qt complains "sh.exe" is in my path and won't build unitl I remove it, but i NEED "sh.exe" in my path to build er9x and ersky9x!

Mike
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
User avatar
Kilrah
Posts: 11107
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Custom Build Taranis X7 help

Post by Kilrah »

That's cmake complaining when you start from a clean build dir. I noticed that just launching the same cmake command line a 2nd time after it has made a first cache it finishes the config normally. Never casued an issue.
bengmo
Posts: 2
Joined: Tue Apr 17, 2018 12:16 am
Country: -

Re: Custom Build Taranis X7 help

Post by bengmo »

I have the same problem as OP. The firmware I'm bulding works fine until I enable LUA in the project options, then after I build and flash that firmware my radio goes into a bootloop.

Post Reply

Return to “openTx”