Skip to content

Check in files for the FPGA CI Test Shield #10540

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

Merged
merged 5 commits into from
May 24, 2019

Conversation

c1728p9
Copy link
Contributor

@c1728p9 c1728p9 commented May 7, 2019

Description

Bring all the FPGA CI Test Shield C and C++ driver files into mbed-os as the component FPGA_CI_TEST_SHIELD. When this component is enabled all the files that are needed to communicate with, update firmware on and run testing with the FPGA are built.

Pull request type

[ ] Fix
[ ] Refactor
[ ] Target update
[x] Functionality change
[ ] Docs update
[ ] Test update
[ ] Breaking change

Reviewers

@mrcoulter45 @maciejbocianski @mprse @fkjagodzinski @0xc0170 @jamesbeyond @donatieng @OPpuolitaival

Release Notes

Added files to control the FPGA CI Test Shield. This allows for enhanced testing.

Bring all the FPGA CI Test Shield C and C++ driver files into mbed-os
as the component FPGA_CI_TEST_SHIELD. When this component is enabled
all the files that are needed to communicate with, update firmware on
and run testing with the FPGA are built.
@ciarmcom
Copy link
Member

ciarmcom commented May 7, 2019

@c1728p9, thank you for your changes.
@mprse @mrcoulter45 @maciejbocianski @donatieng @jamesbeyond @fkjagodzinski @0xc0170 @OPpuolitaival @ARMmbed/mbed-os-maintainers please review.

And fix any build errors this caused.
Copy link
Contributor

@0xc0170 0xc0170 left a comment

Choose a reason for hiding this comment

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

initial review comments

#include "platform/Callback.h"
#include "drivers/DigitalInOut.h"

class MbedTester {
Copy link
Contributor

Choose a reason for hiding this comment

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

would it be worth documenting this class (for instance as SPI class has some example and description). Isn't this the most important object for this shield?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added some documentation and example code.

std::list<PortType> matched_ports, not_matched_ports;
find_ports<PortType, FormFactorType>(matched_ports, not_matched_ports);

utest_printf("***Testing one %s pin configuration***\n", PortType::PinMap::name);
Copy link
Contributor

Choose a reason for hiding this comment

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

why do we use utest_printf and not stdout?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Since this is a test utility shouldn't it use the utest_printf? @maciejbocianski can you comment on this?

Copy link
Contributor

Choose a reason for hiding this comment

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

Exactly, this utility code is intended to be used in tests only, this is why utest_printf was used

}
};

#if DEVICE_SPI
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we describe here with a comment what these peripherals utils mean (if I add here, what should I add? ) - small description would help

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added documentation to this.

return true;
}

class DefaultFormFactor {
Copy link
Contributor

Choose a reason for hiding this comment

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

I've noticed these utils are not much documented in this header file - what this defaultformfactor does ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added documentation to this.

Run astyle to correct formatting.
@c1728p9 c1728p9 force-pushed the fpga_ci_test_shield branch from 1fd7b1a to 45301ea Compare May 8, 2019 16:01
Add documentation to the MbedTester class and the test_utils.h file.
@c1728p9
Copy link
Contributor Author

c1728p9 commented May 9, 2019

Mbed OS CI won't be able to test this until the component FPGA_CI_TEST_SHIELD is added. To get some testing in I created a test branch where this is no longer a component and therefore built as part of CI and manually triggered a CI job on this branch.

@0xc0170
Copy link
Contributor

0xc0170 commented May 12, 2019

I've started first test job for this.

@0xc0170
Copy link
Contributor

0xc0170 commented May 13, 2019

internal CI fault, restarting IC

@mbed-ci
Copy link

mbed-ci commented May 13, 2019

Test run: FAILED

Summary: 1 of 11 test jobs failed
Build number : 2
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_greentea-test

@adbridge
Copy link
Contributor

CI started

@mbed-ci
Copy link

mbed-ci commented May 17, 2019

Test run: SUCCESS

Summary: 11 of 11 test jobs passed
Build number : 3
Build artifacts

@0xc0170 0xc0170 requested a review from bulislaw May 21, 2019 09:27
@0xc0170
Copy link
Contributor

0xc0170 commented May 21, 2019

It is almost ready, any more reviews done ?

Mbed OS CI won't be able to test this until the component FPGA_CI_TEST_SHIELD is added. To get some testing in I created a test branch where this is no longer a component and therefore built as part of CI and manually triggered a CI job on this branch.

@OPpuolitaival Can this be added?

Copy link
Member

@bulislaw bulislaw left a comment

Choose a reason for hiding this comment

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

Looks good. One thing I'd like to see is docs how to use it. I know that HW is not yet publicly available, but we'll need the docs soon anyway.

Copy link
Contributor

@mprse mprse left a comment

Choose a reason for hiding this comment

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

👍

Bring in updates the the FPGA CI Test Shield repo.
@c1728p9
Copy link
Contributor Author

c1728p9 commented May 24, 2019

Added some changes that came in since this PR was created. This should be ready for re-test and merge.

@0xc0170
Copy link
Contributor

0xc0170 commented May 24, 2019

Ci restarted

@0xc0170
Copy link
Contributor

0xc0170 commented May 24, 2019

@maciejbocianski @c1728p9 Please make sure there is documentation added for this one. This is ready for merging once CI is done

@mbed-ci
Copy link

mbed-ci commented May 24, 2019

Test run: SUCCESS

Summary: 11 of 11 test jobs passed
Build number : 4
Build artifacts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants