-
Notifications
You must be signed in to change notification settings - Fork 2
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
host_wasmtime: support multiple sensor devices per backend #31
Conversation
@@ -211,7 +211,7 @@ exports_wasi_sensor_interface_main() | |||
|
|||
fprintf(stderr, "C guest started\n"); | |||
|
|||
const char *sensor = "dummy"; | |||
const char *sensor = "dummy:dummy"; |
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.
You mean we can specify
dummy:image
dummy:depth
dummy:imu
if we create dummy image device, dummy depth device, dummy imu 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.
Do you think it makes sense ?
nokhwa:/dev/video0
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.
You mean we can specify dummy:image dummy:depth dummy:imu
the dummy device ignores the latter part for now.
if we create dummy image device, dummy depth device, dummy imu device ?
it's possible.
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.
Do you think it makes sense ?
nokhwa:/dev/video0
sort of. except that /dev/video0 seems like a very linux specific identifier.
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.
understood. I agree as the spec.
_ => return Ok(Err(wasi::sensor::sensor::DeviceError::NotFound)), | ||
let v: Vec<&str> = device_name.split(":").collect(); | ||
if v.len() != 2 { | ||
return Ok(Err(wasi::sensor::sensor::DeviceError::NotFound)); |
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.
"aaa:bbb" would be mandatory ?
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.
in this particular implementation, yes.
in the wasi-sensor api, no.
No description provided.