-
Notifications
You must be signed in to change notification settings - Fork 60
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
[Internal] GPS Shift support #2141
[Internal] GPS Shift support #2141
Conversation
dde0749
to
871af55
Compare
871af55
to
b5a97c3
Compare
@@ -0,0 +1,44 @@ | |||
--------------------------------------------------------------------------------------------------- | |||
-- Proposal: | |||
-- https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0192-button_subscription_response_from_hmi.md |
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.
Wrong proposal link
-- 2) SDL transfers this request to HMI | ||
-- 3) HMI sends "shifted" item (boolean) in "gps" parameter (Common.GPSData) of GetVehicleData response | ||
-- SDL does: | ||
-- 1) Sends GetVehicleData response to mobile with "shifted" item in "gps" parameter |
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.
Send
runner.testSettings.isSelfIncluded = false | ||
|
||
--[[ Local Functions ]] | ||
local function pTUpdateFunc(tbl) |
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.
Function will be used not in one script, so can be defined in common
-- In case: | ||
-- 1) Mobile sends GetVehicleData(gps(shifted=true/false)) request | ||
-- 2) SDL transfers this request to HMI | ||
-- 3) HMI sends "shifted" item (boolean) in "gps" parameter (Common.GPSData) of GetVehicleData response |
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.
t think that (Common.GPSData) is redundant info
-- | ||
-- Description: | ||
-- In case: | ||
-- 1) Mobile sends GetVehicleData(gps(shifted=true/false)) request |
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 is not clear for me the struct GetVehicleData(gps(shifted=true/false)). in GetVehicleData is defined only gps, so (gps(shifted=true/false)) can mislead the reader.
altitude = 7.7, | ||
heading = 173.99, | ||
speed = 2.78, | ||
shifted |
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.
There is no need to define empty shifted, please remove
@@ -0,0 +1,46 @@ | |||
--------------------------------------------------------------------------------------------------- | |||
-- Proposal: |
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.
Please update script according to comments in 001 script
runner.Step("Start SDL, HMI, connect Mobile, start Session", common.start) | ||
runner.Step("Register App", common.registerAppWOPTU) | ||
runner.Step("Activate App", common.activateApp) | ||
runner.Step("Subscribe on InteriorVehicleData, RADIO module", common.getInteriorVehicleData, { _,true }) |
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.
@TMyza _
can't be used as a parameter. Use nil
instead.
:Do(function(_, data) | ||
m.getHMIConnection():SendResponse(data.id, data.method, "SUCCESS", { gps = m.gpsParams }) | ||
end) | ||
m.getMobileSession():ExpectResponse(cid, { success = true, resultCode = "SUCCESS", gps = m.gpsParams }) |
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.
@TMyza In case of missing shifted
parameter we have to check explicitly that it's not transferred to mobile
moduleData = m.radioData | ||
}) | ||
:ValidIf(function(_, data) | ||
return m.checkShifted(data.payload.moduleData.shifted, pShiftValue) |
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.
@TMyza Please check if data.payload.moduleData.shifted
is a correct path for shifted
parameter
aa5cc50
to
5928404
Compare
ATF Test Scripts to check #2639
This PR is not ready for review.
Summary
Adding-GPS-Shift-support
CLA