er9x development

er9x is the best known firmware. It has a superb range of features and is well supported by the community. Well worth trying out.
KayCee_V4
Posts: 7
Joined: Thu Jan 05, 2012 8:04 am
Country: -
Location: Sunny South Africa

Re: er9x development - Stick Reverse

Post by KayCee_V4 »

I recently installed Taranis Gimbals in my Turnigy 9x and can't get the Stick Reverse to work. (My Rud and Ele sticks are the wrong way round)
I followed the instructions in the Er9x Manual 2015 to reverse the sticks. i.e. highlight the stick diagram, press [MENU] and press [LEFT] or [RIGHT] but nothing changes on the display.
I downloaded and installed eePe Revision: 421 and er9x.hex - The Version on the Tx shows:
VERS: V1.747-Mike
DATE: 30.11.2016
TIME: 13:41:02
SUN: er9x-r820

Is there a more up-to-date firmware available ?

I have used INV on CH3 and CH4 on the LIMITS of each model to get it working, but would prefer to do it in the Radio Setup.

Thanks in advance.
KC
Professional Tinkerer

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

Re: er9x development

Post by MikeB »

This editing is protected with the hardware menu. Just power on holding the left horizontal trim to the left to enable the editing.
You should also be able to use eepe to change the setting, they are at the bottom of the General Setup tab.

Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
KayCee_V4
Posts: 7
Joined: Thu Jan 05, 2012 8:04 am
Country: -
Location: Sunny South Africa

Re: er9x development

Post by KayCee_V4 »

Thanks Mike, all sorted now.

Cheers,
KC
Professional Tinkerer
Marcos
Posts: 13
Joined: Thu May 21, 2015 11:03 am
Country: -
Location: Vastaranta

Re: er9x development

Post by Marcos »

Hi.
I have couple of questions about ER9X. I hope this is suitable place to ask.
First. I have understood that the latest firmware for m128 does have a bootloader that enables me to flash the firmware trough UART. Is this correct?
What serial pins it is using? PE0 and PE1 (HW_UART0) or PD2 and PD3(HW_UART1)?
Does ER9X use the RF Power check pin (PG1) for something? Can this be left floating, or used for something else?
Can I just connect a bluetooth-UART bridge to the serial lines and flash/setup over bluetooth with eepe?
For telemetry to work with my OpenLRSng-module, do I need to do other HW modifications than the telemetry mod?
Does ER9X support pass-trough feature of OpenLRSng or what telemetry protocol should I use? I am planing to use these with INav firmware FC.

I am building my own Franken TX based on the FS-THX9 mainboard. I am going to modify it heavily.
My plan is to run the whole TX from 5V (single cell li-po, USB port charging etc.) and I am in process of designing my own AUX/PWR board that has build in Arduvoice module and USB for firmware upgrading/setting up with eepe. I am planing to use my own TX module, based on OpenLRSng-firmware.

So answers and any pointers are very welcome and very much appreciated.
User avatar
MikeB
9x Developer
Posts: 17990
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: er9x development

Post by MikeB »

Marcos wrote: Wed Aug 09, 2017 6:03 am Hi.
I have couple of questions about ER9X. I hope this is suitable place to ask.
First. I have understood that the latest firmware for m128 does have a bootloader that enables me to flash the firmware trough UART. Is this correct?
Yes
What serial pins it is using? PE0 and PE1 (HW_UART0) or PD2 and PD3(HW_UART1)?
PE0/1, I use the same connector (10-pin) that may also be used to flash using a UsbAsp type device.
Does ER9X use the RF Power check pin (PG1) for something? Can this be left floating, or used for something else?
It is used to detect if the board is powered by the main power switch or the trainer jack to automatically switch between master and slave when used in a "buddy box" configuration.
Can I just connect a bluetooth-UART bridge to the serial lines and flash/setup over bluetooth with eepe?
It might work, I've never tried it.
For telemetry to work with my OpenLRSng-module, do I need to do other HW modifications than the telemetry mod?
Does ER9X support pass-trough feature of OpenLRSng or what telemetry protocol should I use? I am planing to use these with INav firmware FC.
I don't know enough about OpenLRS to answer.

I am building my own Franken TX based on the FS-THX9 mainboard. I am going to modify it heavily.
My plan is to run the whole TX from 5V (single cell li-po, USB port charging etc.) and I am in process of designing my own AUX/PWR board that has build in Arduvoice module and USB for firmware upgrading/setting up with eepe. I am planing to use my own TX module, based on OpenLRSng-firmware.
The standard mainboard needs at least 7V on the power supply for the voltage regulator to work properly.

So answers and any pointers are very welcome and very much appreciated.
You may like to consider this: https://www.rcgroups.com/forums/showthr ... rsal-board (currently out of stock, but I understand a new batch is being produced).
This is a MUCH more powerful board, and comes complete with voice and USB support.
The ersky9x firmware also supports things like native Mavling telemetry.

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

Marcos
Posts: 13
Joined: Thu May 21, 2015 11:03 am
Country: -
Location: Vastaranta

Re: er9x development

Post by Marcos »

Thank you for your quick reply!
MikeB wrote: Wed Aug 09, 2017 10:10 am
Marcos wrote: For telemetry to work with my OpenLRSng-module, do I need to do other HW modifications than the telemetry mod?
Does ER9X support pass-trough feature of OpenLRSng or what telemetry protocol should I use? I am planing to use these with INav firmware FC.
I don't know enough about OpenLRS to answer.
Actually this was quite stupid question anyway. If I have understood correctly when OpenLRSng is in pass-trough mode, it just outputs same serial data from TX that is input to RX, so this really is up to the flight controller, I have to study Inav some more...
MikeB wrote: Wed Aug 09, 2017 10:10 am The standard mainboard needs at least 7V on the power supply for the voltage regulator to work properly.
I am going to remove the 5V regulator and provide 5V straight from charger board with Li-Po battery. I am also going to remove the voltage divider from the battery voltage sense track and input the battery voltage. I think it should be safe with just some current protecting resistor as max voltage would be 4.2V, so the MCU should handle it just fine.
MikeB wrote: Wed Aug 09, 2017 10:10 am It is used to detect if the board is powered by the main power switch or the trainer jack to automatically switch between master and slave when used in a "buddy box" configuration.
This probably explains why I had no response from the sticks with the original FW when testing. I left the RF power check unconnected.
I just have to change the R135 for something suitable and it should also work with 5V as well. This got me thinking a Bluetooth trainer mod, but that is another matter for the future...
MikeB wrote: Wed Aug 09, 2017 10:10 am You may like to consider this: https://www.rcgroups.com/forums/showthr ... rsal-board (currently out of stock, but I understand a new batch is being produced).
This is a MUCH more powerful board, and comes complete with voice and USB support.
The ersky9x firmware also supports things like native Mavling telemetry.

Mike.
I am aware of the ARUni board and others, but I have all ready purchased the FS-THX9 mainboard with display and I have not flown my plane over a year, because I don't have suitable radios (long story), so I am rather anxious to have the TX finished sooner than later. ARUni was my first choice, but they where not available. Maybe I get one when they come available and cannibalise my other FS-T6 as well, or maybe I save it for DIY Horus...
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: er9x development

Post by jhsa »

Er9x doesn't support trainer over bluetooth. Only ErSky9x does, but it runs on more powerful boards like the Ar9x, ArUni, 9xtreme, etc.. It does not run on the stock mainboard.

Also, I wouldn't run the processor at much less than 5V, or you might have problems with the ADCs, and also, the 3.3V regulator needs about 2V above the regulated voltage. 5V is already tight, 4.2V might mess its output completely. Or you replace it with a low dropout regulator..
Just my 2c. :)

João

Sent from my thor using Tapatalk


My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
MikeB
9x Developer
Posts: 17990
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: er9x development

Post by MikeB »

The ATmega128 is running at 16MHz, but is only rated at this frequency down to 4.5V. If you go below this, then it is not guaranteed to work reliably.

Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
Marcos
Posts: 13
Joined: Thu May 21, 2015 11:03 am
Country: -
Location: Vastaranta

Re: er9x development

Post by Marcos »

@jhsa
I was pondering adding something like ATtiny85 for doing the PPM to UART conversion for the Bluetooth trainer interface, but it's more complicated than that and I don't really have time to investigate it further ATM.

According to the Schematics I have, the 3,3V regulator is powered off the 5V regulator output, so it should work fine with 5V. If not, I have pile of 3.3V LDO REG's to change over.

I am also very interested to use only one USB port (with UART-USB chip) for both MCU's (Arduvoice and the main one) to accessing the SD, configuring the TX with eepe and preferably flash firmware to both MCU's. Simplest way to achieve this would probably be a switch to connect the desired UART lines to the UART-USB chip, but I would much prefer something more elegant.
It would not seem to be hard to configure the bootloader to use UART1, but would it then conflict with the Arduvoice bootloader?
How does the Arduvoice bootloader mode work? Does it fire on every reset/power up or does it get some kind of command to enter bootloader mode from the main MCU trough serial when the main MCU is entered to bootloader mode? Would it be a major task to modify the code so that there would be a separate button configurations for entering the bootloader mode of the main MCU and the Arduvoice module?

@MikeB
My intension is to use a Li-Po charging board with boost converter that boosts the voltage to steady 5V and only connect the raw battery voltage to the voltage measuring pin(with a protecting resistor), to get the true battery voltage to show up in ER9X.
Will the code have a issue displaying voltages between ~3V-4.2V? What I understand is that in original configuration the battery voltage is divided by voltage divider down to below 5V and then multiplied back to "correct" reading by software, so what comes to the hardware, it should be no problem to measure single cell voltages.
Last edited by Marcos on Thu Aug 10, 2017 9:50 pm, edited 2 times in total.
User avatar
MikeB
9x Developer
Posts: 17990
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: er9x development

Post by MikeB »

I think the single cell voltage will measure OK, provided you use the same resistor divider ratio.

Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: er9x development

Post by jhsa »

I think Mike is the right person to answer all those questions because he wrote all the code for the ArduVoice module as far as I know.. :)

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
User avatar
MikeB
9x Developer
Posts: 17990
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: er9x development

Post by MikeB »

Marcos wrote: Thu Aug 10, 2017 9:28 pmI am also very interested to use only one USB port (with UART-USB chip) for both MCU's (Arduvoice and the main one) to accessing the SD, configuring the TX with eepe and preferably flash firmware to both MCU's. Simplest way to achieve this would probably be a switch to connect the desired UART lines to the UART-USB chip, but I would much prefer something more elegant.
It would not seem to be hard to configure the bootloader to use UART1, but would it then conflict with the Arduvoice bootloader?
How does the Arduvoice bootloader mode work? Does it fire on every reset/power up or does it get some kind of command to enter bootloader mode from the main MCU trough serial when the main MCU is entered to bootloader mode? Would it be a major task to modify the code so that there would be a separate button configurations for entering the bootloader mode of the main MCU and the Arduvoice module?
A switch is probably the 'best' answer.
While UART1 connects to the voice module, the '128 Tx connects to the voice module Rx, and module Tx to '128 Rx, so you still would need to have a different connection to flash one or the other.

The optiboot bootloader in the voice module check for being started either by power on or external reset. If neither of these, then the bootloader continues to run, otherwise it waits a short time, then checks PORT D, bit 0 (UART Rx signal). If it is low, it stays in the bootloader, if high, it tries to execute the application. If location 0000 of the flash is not 0xFF, then the application is run.
The application checks for a possible flashing operation on the serial port and if seen, drops out to the bootloader. Because the bootloader is started other than from power on or reset, it doesn't try to run the application.

Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
Marcos
Posts: 13
Joined: Thu May 21, 2015 11:03 am
Country: -
Location: Vastaranta

Re: er9x development

Post by Marcos »

Thanks for the answers. I have decided to go with USB for Arduvoice and Bluetooth for the TX. This keep it simple enough.
BTW. I can confirm that HC-06 connected to the TX and RX pins on the transmitter works great. I can read and write the firmware and eeprom with out any issues.
ReSt
Posts: 1581
Joined: Tue Dec 27, 2011 11:34 pm
Country: -

Re: er9x development

Post by ReSt »

Compiler problem

Some time ago I rebuilt an old FM-radio with the mainboard of the 9xr (?) radio, that has the built in analog multiplexer on the board.
As the old radio had separate trim pots for the sticks, that were now obsolete (as trims), with the help of Mike I modified the code to support these four trim pots as additional analog channels.

This works without any problems.

Last week I decided to implement the required modifications into the actual ER9x code (downloaded from github 2017-04-08)).
But every modified, compiled version newer than version r818 failed to run on my Tx.

Showing the splash screen, the radio startet to permanently chirp.

After half a week of try and error, I finally found that this is a problem with my AVR 4.8.0 compiler.
When I reactivated the older version 4.7.2, everything was fine and ran without any problem.

btw, all my other versions of ER9x, that also have just a handfull of modifications, do run with 4.8.0 and 4.7.2
But 4.7.2 makes bigger code.

The modified version r818 runs fine with both compiler versions
But as soon, as I add the code to support the additional channels to a newer version than r818, the problem is there.

I have no idea whats going wrong.

My personal solution now is simple, I use AVR 4.7.2 to compile my 'special' versions and AVR 4.8.0 for all others.


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

Re: er9x development

Post by MikeB »

Interesting, I'm using 4.8.0 myself. This currently gives the smallest code.
Perhaps you could PM me your changes (to r821) and I can take a look.

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: er9x development

Post by ReSt »

I have the source code with these changes available for r819, r820 and (I call it) 823, that is the latest I got from github.
But I could prepare r821 also.

Would one of the others be ok for you ?

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

Re: er9x development

Post by MikeB »

The latest from Github would be best. I've only got 3 files with any changes since the last commit.

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: er9x development

Post by ReSt »

Pm'ed you the code
But I never know if it really has been sent or not.

so as a precaution, I add it here also.

Reinhard
Attachments
r823_source.zip
(330.62 KiB) Downloaded 359 times
User avatar
MikeB
9x Developer
Posts: 17990
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: er9x development

Post by MikeB »

You appear to have:
uint16_t s_anaFilt[8] ;
but are filling it with 12 values!
The different compiler is probably putting the data in a different order, so different things get overwritten.
Try:
uint16_t s_anaFilt[12] ;

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: er9x development

Post by ReSt »

Mike, you got it !!! :)

Thanks a lot to solve this problem for me
All versions now run when compiled with 4.8.0

Reinhard
User avatar
jhsa
Posts: 19480
Joined: Tue Dec 27, 2011 5:13 pm
Country: Germany

Re: er9x development

Post by jhsa »

Mike, Er9x, in my case m2561. This was reported by some other user by PM.

Set timer countdown. Radio says " 1 Minutes" instead of "1 minute". Could you please check that when you have time?

Thanks

João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9

Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
kmargos
Posts: 86
Joined: Mon Jun 05, 2017 7:54 pm
Country: -

Re: er9x development

Post by kmargos »

Hi!!

I installed version r821 for the M2561, but on the transmitter it appears r820.
kmargos
Posts: 86
Joined: Mon Jun 05, 2017 7:54 pm
Country: -

Re: er9x development

Post by kmargos »

Hi,
splash screen custom, not works whit M64.
My image.
https://uploaddeimagens.com.br/imagens/ ... -1-bmp--17
User avatar
bob195558
Posts: 2377
Joined: Sun Dec 16, 2012 7:24 pm
Country: United States
Location: New England, Vermont
Contact:

Re: er9x development (about M2561 9x Radios)

Post by bob195558 »

kmargos wrote: Mon Oct 30, 2017 1:04 am Hi!!
I installed version r821 for the M2561, but on the transmitter it appears r820.
Several days ago I updated M2561 Radio using the official (http://www.er9x.com/)
er9x for Mega2561 processor (right click and select 'save as') firmware,
VERS: V1.749-Mike
DATE: 30.11.2016
SVN: er9x-r820
MOD: FRSKY 2561

It is not my radio so have not tested it, but seem to be working OK.

I am not seeing where you are finding version r821 ?
Last edited by bob195558 on Tue Oct 31, 2017 12:38 pm, edited 1 time in total.
Er9x on 9x radio, with Smartieparts Programmer and TelemetrEZ Board.
ErSky9x on Taranis, Sky9x, 9Xtreme radios.
3D-Printing: (https://openrcforums.com/forum/viewforum.php?f=129).
User avatar
bob195558
Posts: 2377
Joined: Sun Dec 16, 2012 7:24 pm
Country: United States
Location: New England, Vermont
Contact:

Re: er9x development (about M2561 9x Radios)

Post by bob195558 »

I think I see where you are seeing the r821, are you seeing it in the eePe / Preferences / Current Version er9x: r821 :?:
Click on photo to zoom in.
eePe-EEPROM Editor / er9x-2561 / Current Version r821 or r820
eePe-EEPROM Editor / er9x-2561 / Current Version r821 or r820
Last edited by bob195558 on Tue Oct 31, 2017 12:39 pm, edited 1 time in total.
Er9x on 9x radio, with Smartieparts Programmer and TelemetrEZ Board.
ErSky9x on Taranis, Sky9x, 9Xtreme radios.
3D-Printing: (https://openrcforums.com/forum/viewforum.php?f=129).
kmargos
Posts: 86
Joined: Mon Jun 05, 2017 7:54 pm
Country: -

Re: er9x development

Post by kmargos »

Hi,

Here to !!
Attachments
821.png
User avatar
bob195558
Posts: 2377
Joined: Sun Dec 16, 2012 7:24 pm
Country: United States
Location: New England, Vermont
Contact:

Re: er9x development (about M2561 9x Radios)

Post by bob195558 »

OK there is two places then.
Could try the Test Version too ?
Last edited by bob195558 on Tue Oct 31, 2017 12:39 pm, edited 1 time in total.
Er9x on 9x radio, with Smartieparts Programmer and TelemetrEZ Board.
ErSky9x on Taranis, Sky9x, 9Xtreme radios.
3D-Printing: (https://openrcforums.com/forum/viewforum.php?f=129).
User avatar
MikeB
9x Developer
Posts: 17990
Joined: Tue Dec 27, 2011 1:24 pm
Country: -
Location: Poole, Dorset, UK

Re: er9x development

Post by MikeB »

I clearly didn't change the setting to make the revision appear as r821.
As long as you have the date line as:
DATE: 30.11.2016
then you have r821.

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

Re: er9x development

Post by MikeB »

kmargos wrote: Mon Oct 30, 2017 1:15 am Hi,
splash screen custom, not works whit M64.
My image.
https://uploaddeimagens.com.br/imagens/ ... -1-bmp--17
Unfortunately, I disabled custom screens for the M64 version when I saved quite a bit of flash space by reducing the stored resolution of the splash screen from 128 by 64 (1K bytes of flash) to 64 by 32 (256 bytes of flash).
It seemed to me that the flash saving (to get more features in) was worth giving up the custom splash screen.

Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
kmargos
Posts: 86
Joined: Mon Jun 05, 2017 7:54 pm
Country: -

Re: er9x development

Post by kmargos »

MikeB wrote: Mon Oct 30, 2017 11:28 pm
kmargos wrote: Mon Oct 30, 2017 1:15 am Hi,
splash screen custom, not works whit M64.
My image.
https://uploaddeimagens.com.br/imagens/ ... -1-bmp--17
Unfortunately, I disabled custom screens for the M64 version when I saved quite a bit of flash space by reducing the stored resolution of the splash screen from 128 by 64 (1K bytes of flash) to 64 by 32 (256 bytes of flash).
It seemed to me that the flash saving (to get more features in) was worth giving up the custom splash screen.

Mike.
I thought that could be it, for having several resources.

Tks Mike !!!

Post Reply

Return to “er9x”