-
Notifications
You must be signed in to change notification settings - Fork 18.2k
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
AP_Scripting: added HobbyWing DataLink driver #25428
Conversation
@IamPete1 Kyle has been hitting a problem where a scripting restart sometimes doesn't start the script. I added some debug code and it does get to reschedule_script() in lua_scripts::load_all_scripts_in_dir() so it isn't a microSD issue, but the script never runs (startup messages don't come out for example) |
2c1ea3d
to
d09b404
Compare
telem_data:current(curr) | ||
telem_data:temperature_cdeg(math.floor(mos_temp*100)) | ||
esc_telem:update_rpm(ofs+i, math.floor(eRPM*10.0/ESC_HW_POLES:get()), 0) | ||
-- 0x0D is temperature + voltage + current |
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.
With custom bindings we could make setting of the mask automatic. A valid value would add the bit to the mask and setting to nil would clear it.
Probably not worth the effort tho.
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.
Could do the same with if we used a multiple argument function rather than the userdata too. The binding would assemble the struct.
d09b404
to
64917d9
Compare
allows more complete ESC protocol implementation in scripting
64917d9
to
4d2b3f9
Compare
this supports the DataLink v2:

https://www.hobbywingdirect.com/products/data-link-v2
tested by Kyle from AerialVisionAustralia on a hexacopter