Closed oskarpearson closed 7 years ago
What would be an example of the usage for this, so we can test it?
@scottleibrand https://github.com/openaps/oref0/pull/276 uses it. Please let me know if you're happy with this structure.
This particular change will modify pump.ini to contain this:
[device "pump"]
serial = 123123
radio_locale = WW
mmeowlink will look for that parameter when doing mmtune etc as per https://github.com/oskarpearson/mmeowlink/commit/3a8d8677497ad2217201b4f110083b6dbf89cd30 (currently only in the dev branch - but having the value in the ini file won't break anything if it's not used)
Cool. Might be easiest to go ahead and merge this for testing. Does anyone see any reason not to do that?
I think that this can be merged. We could need to make additional changes, but from what I can tell it'll work as expected.
Per https://gitter.im/nightscout/intend-to-bolus?at=5858a0f6c5a4e0233ba7961c it doesn't appear that openaps device add pump mmeowlink subg_rfspy /dev/spidev5.1 <serial> WW
ever adds the radio_locale = WW
line to the pump.ini. Any ideas why not?
@scottleibrand and @oskarpearson : i think pull request needs still to be applied to an openaps release to be able to remove the workaround in the current oref0-setup.sh
(currently on my devww branch, but statement is also available in oref0 master and dev)
# Hack to check if radio_locale has been set in pump.ini. This is a temporary workaround for https://github.com/oskarpearson/mmeowlink/issues/55
# It will remove empty line at the end of pump.ini and then append radio_locale if it's not there yet
# TODO: remove once https://github.com/openaps/openaps/pull/112 has been released in a openaps version
grep -q radio_locale pump.ini || echo "$(< pump.ini)" > pump.ini ; echo "radio_locale=$radio_locale" >> pump.ini
Add support for the 'radio_locale' medtronic parameter.
This helps make using https://github.com/oskarpearson/mmeowlink/commit/3a8d8677497ad2217201b4f110083b6dbf89cd30 easier.