-
Notifications
You must be signed in to change notification settings - Fork 10
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
Reorganize FMCDAQ3, ADRV9361_BOB, SYNCHRONA #20
base: reorganize_tests
Are you sure you want to change the base?
Reorganize FMCDAQ3, ADRV9361_BOB, SYNCHRONA #20
Conversation
Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
Scripts which are directly run (e.g. production.sh) should be executable. Scripts which are always `source`-d (e.g. lib/*) should not be. Signed-off-by: Ioan Dragomir <[email protected]>
setup_env.sh sometimes fails because apt can't get the dpkg lock because of other running apt processes, such as You need to be root to run this application. This change allows for a 60s grace period before failing Signed-off-by: Ioan Dragomir <[email protected]>
On a fresh kuiper prebuilt image, the current date&time are not synchronized to anything and are usually long in the past. This breaks apt install and potentially other utilities as well. This setup step tries to first use NTP (which I found is not available on said fresh kuiper image) and alternatively queries a well-known HTTP server (in this case, google.com) for the current date&time, as a low precision but still OK fallback. Signed-off-by: Ioan Dragomir <[email protected]>
Required in the build step of libiio Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
To make this work, the following commit was also squashed-in: Prepend to LD_LIBRARY_PATH instead of overwriting The current implementation traces back to fed5304 from 5 years ago, but combined with `setup_env.sh` adding `vars.sh` to be run in `.bashrc`, this overwrites any other directories in LD_LIBRARY_PATH, sometimes breaking expected `ld.so` behaviour.
@@ -3,6 +3,6 @@ ANSWER=1 | |||
SCRIPT_DIR="$(readlink -f $(dirname $0))" | |||
|
|||
echo | |||
python3 -m pytest --color yes -vs $SCRIPT_DIR/../work/pyadi-iio/test/test_fmcomms2-3_prod.py --uri="ip:analog.local" --adi-hw-map --hw=adrv9361 | |||
python3 -m pytest --color yes -vs $SCRIPT_DIR/../work/pyadi-iio/test/test_adrv9361_prod.py --uri="ip:analog.local" --adi-hw-map --hw=adrv9361 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this test_adrv9361_prod.py file actually exist?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was added in the fmcomms_scpi branch, commit 476bbcc.
main_tests/fmcdaq3/production.sh
Outdated
MODE="$1" | ||
case $MODE in | ||
"FMCDAQ3 Test") | ||
"$SCRIPT_DIR/rf_test.sh"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why the quotation marks?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added the quotes to allow for spaces in the file path. Not absolutely necessary for the prodtest images - this is likely a harmless leftover from one of my test runs. Should I remove it the quotes consistency's sake?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes
wait_for_board_online | ||
export BOARD_SERIAL=$(get_board_serial) | ||
echo_blue "Starting FMCDAQ3 Test" | ||
production "crr" "$opt" "FMCDAQ3" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's outside the scope of this pull request, but for future reference I think the "crr"/target parameter is redundant, i think only talise uses it for something minor. Perhaps it should be removed in future versions
sudo timedatectl set-ntp true && return | ||
|
||
# Alternatively, use a much less precise source, but still good enough for certificates to be valid | ||
sudo date +"%d %b %Y %T %Z" -s "$(curl -s --head http://google.com | grep '^Date:' | cut -d' ' -f 3-)" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a nitpick but since this step and prereqs install require internet, maybe it would be useful to add a short connection check in the beginning of the script, to avoid going further if the device is not connected to the internet (maybe just a ping?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does def3e61 look alright?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good to me
Signed-off-by: Ioan Dragomir <[email protected]>
Signed-off-by: Ioan Dragomir <[email protected]>
This is a squashed commit which introduces the following: 1. Move synchrona test files to the proper folder (synch -> synchrona) 2. Fix bash syntax errors in lib/utils.sh (whitespace around env var assignments) 3. Change DUT subnet to /16 instead of /24 4. Copy the test files to the DUT using rsync at the beginning of each test 5. Detect ADT7422 hwmon index instead of hardcoding hwmon1 (hwmon indices may change, they are not bound to a device)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
take it out of draft before merging, otherwise looks good to me
3a807f3
to
670d7eb
Compare
e4e5a91
to
9f88cbf
Compare
No description provided.