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

Z-Axis Pitch allows invalid input #720

Open
morganrallen opened this issue Apr 30, 2018 · 2 comments
Open

Z-Axis Pitch allows invalid input #720

morganrallen opened this issue Apr 30, 2018 · 2 comments
Labels

Comments

@morganrallen
Copy link

morganrallen commented Apr 30, 2018

First, this is a postmortem, I don't know how I actually got in this state but probably explains my disastrous Z-Axis calibration on Friday.

Today, upon opening Ground Control 1.11 and opening the Settings tabs the app crashes.

[5748] Failed to execute script main
 Traceback (most recent call last):
   File "C:\Users\Bar\Git\GroundControl\main.py", line 445, in <module>
     GroundControlApp().run()
   File "C:\Python27\lib\site-packages\kivy\app.py", line 828, in run
   File "C:\Python27\lib\site-packages\kivy\base.py", line 504, in runTouchApp
   File "C:\Python27\lib\site-packages\kivy\core\window\window_sdl2.py", line 663, in mainloop
   File "C:\Python27\lib\site-packages\kivy\core\window\window_sdl2.py", line 405, in _mainloop
   File "C:\Python27\lib\site-packages\kivy\base.py", line 339, in idle
   File "C:\Python27\lib\site-packages\kivy\clock.py", line 581, in tick
   File "kivy\_clock.pyx", line 367, in kivy._clock.CyClockBase._process_events (kivy\_clock.c:7700)
   File "kivy\_clock.pyx", line 397, in kivy._clock.CyClockBase._process_events (kivy\_clock.c:7577)
   File "kivy\_clock.pyx", line 395, in kivy._clock.CyClockBase._process_events (kivy\_clock.c:7498)
   File "kivy\_clock.pyx", line 167, in kivy._clock.ClockEvent.tick (kivy\_clock.c:3490)
   File "C:\Users\Bar\Git\GroundControl\main.py", line 305, in runPeriodically
     self.receivedSetting(message)
   File "C:\Users\Bar\Git\GroundControl\main.py", line 265, in receivedSetting
     maslowSettings.syncFirmwareKey(int(parameter), value, self.data)
   File "C:\Users\Bar\Git\GroundControl\Settings\maslowSettings.py", line 556, in syncFirmwareKey
 ValueError: invalid literal for float(): 0.062501.588 1.588 1.588

As you can see, the value is correctly an invalid float.
Checking my groundcontrol.ini and I can see the value go stored incorrectly.

zdistperrot = 0.062501.588
             1.588
             1.588

At a guess, it is because I was trying to use my keyboard or number pad instead of the onscreen number pad. I'm going to run through the process again tomorrow with 1.12 to see if it's still present.

This also might be related to #617

@morganrallen morganrallen changed the title x-axis allows invalid input z-axis allows invalid input May 1, 2018
@morganrallen morganrallen changed the title z-axis allows invalid input Z-Axis Pitch allows invalid input May 1, 2018
@morganrallen
Copy link
Author

I think I've figured it out. Because the input doesn't appear to be getting validated, it's possible to paste a carriage return into the field. I was probably doing in>mm conversions on the command line and accidentally picked up an invisible character.

@morganrallen
Copy link
Author

This is also still present in 1.12

@blurfl blurfl added the bug label May 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants