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

Some minor improvements and probably the last ones. #2602

Merged
merged 9 commits into from
Oct 15, 2020
Merged

Some minor improvements and probably the last ones. #2602

merged 9 commits into from
Oct 15, 2020

Conversation

hendrixgr
Copy link
Contributor

@hendrixgr hendrixgr commented Oct 15, 2020

I changed a bit the OSD busy flag checking in order to make it more strict and robust
I also changed the board_matek.xml autoload module a bit in order to suppress the warnings during compile time when the spi settings between the airframe and the imu module xml file don't agree.
(changed the <define to <configure)
Other than that nothing worth to be mentioned.
IMG_20201010_105919
IMG_20201015_161600

 changed <define name="MAX7456_SPI_DEV" value="spi2" /> AND  <define name="MAX7456_SLAVE_IDX" value="SPI_SLAVE1" />
to  <configure name="MAX7456_SPI_DEV" value="spi2" /> AND  <configure name="MAX7456_SLAVE_IDX" value="SPI_SLAVE1" />
otherwise i was getting to many warnings about "MAX7456_SLAVE_IDX" redefined
Removed one static function and the code now checks both the OSD busy flag and the OSD Reset flag.
Added two more definitions about the OSD busy flag and the OSD reset flag.
Removed one static function and the code now checks both the OSD busy flag and the OSD Reset flag.
Removed one static function and the code now checks both the OSD busy flag and the OSD Reset flag always after writing to the OSD
The code is also a bit cleaner.
I changed the OSD status register bit positions and names to better blend with the rest of the file.
They weren't used anywhere else except for the busy flag checks.
I changed the OSD status register bit positions and names to better blend with the rest of the file and to look better to the eye.
Those and the older ones are only used to check the busy flag.
The busy flag (actually the NVRAM Busy FLAG) and the Power On Reset flag now is checked every time the code writes something to NVRAM.
@hendrixgr
Copy link
Contributor Author

If you need to change file names or directory names or anything else please do.

@OpenUAS
Copy link
Contributor

OpenUAS commented Oct 15, 2020

Nice, PR honoured would be good. FYI I have a v2 of the board on my desk with MPU9250 could flash and get telemetry tested over transparent_usb after AC changes. Have a list of possible improvements, but the sooner your nice code is in master the more option I have to fix it myself...

change file names or directory names or anything else

Will do after a PR, else it will never land up in master ;)

Tested the OSD output on an CrazybeeProF4 FPV, layout not correct, but also before your PR not correct :), at least it works. Fixing that will then be in an issue and other PR

Tested also with magneto, possibly some work to do there, but if not in master no-one will likely test this anyhow

Good to see what Gautier has as input...

@hendrixgr
Copy link
Contributor Author

Version 2?
Any links?
Chris

Copy link
Member

@gautierhattenberger gautierhattenberger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one extra file included by mistake I guess

max7456.c Outdated
@@ -0,0 +1,733 @@
/*
* Copyright (C) 2013 Chris

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this file should not have been added I guess

Copy link
Contributor Author

@hendrixgr hendrixgr Oct 15, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If i understood you well...
The max7456.c file is needed as it has been changed, a new osd nvram busy method is implemented that checks the osd nvram busy flag every time the osd display is written.
Both version work equally well though, if you want you can keep the current version,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can see the changes in the file sw/airborne/modules/display/max7456.c, but their is also a max7456.c at the root directory. Are they the same or not ?

Copy link
Contributor Author

@hendrixgr hendrixgr Oct 15, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What?
I don't have the slightest idea how this file got there, DELETED.
Only the files in the display directory are needed.

@gautierhattenberger gautierhattenberger merged commit dbff73a into paparazzi:master Oct 15, 2020
@OpenUAS
Copy link
Contributor

OpenUAS commented Oct 18, 2020

🥇

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

Successfully merging this pull request may close these issues.

None yet

3 participants