[Microbit-Python] Using micro-python to send simple radio commands?

David Whale david at thinkingbinaries.com
Fri Jul 8 05:52:27 EDT 2016


Is it possible to make the power level changeable dynamically without
having to set everything else? I have a homing beacon in pxt that works
nicely by using dynamic power setting, its easy in pxt but looks harder in
your python api to reconfigure every time just to change power level?
On 8 Jul 2016 9:00 am, "Nicholas H.Tollervey" <ntoll at ntoll.org> wrote:

> Folks,
>
> Yes, the draft API docs (here:
>
> https://github.com/bbcmicrobit/micropython/pull/305/files#diff-9670f8cd030b22f84c34b6dfd1dcdc5dR32
> )
> for the upcoming module describe a config method where you can override
> the defaults for: message length, queue size, channel number, power,
> address and data rate.
>
> It'll have two send/receive methods: send_bytes/receive_bytes (for
> arbitrary bytes) and a simple convenience send/receive (for strings).
> The former allows advanced users to send any arbitrary data, the latter
> (for kids) facilitates the simplest possible messages with zero overhead.
>
> FWIW, I was writing the C for this stuff on the train into work this
> morning. I should have it finished off this evening after my commute
> home. Will then be tested and I hope it'll be in master by the end of
> next week.
>
> Hope this helps.
>
> N.
>
> On 08/07/16 08:50, Ben Mustill-Rose wrote:
> > Hi,
> >
> > Are there plans to support changing the tx power using MicroPython?
> > I'm happy to send people prebuilt hex files if required - email me off
> list.
> >
> > Cheers,
> > Ben.
> >
> > On 7/7/16, Nicholas H.Tollervey <ntoll at ntoll.org> wrote:
> >> On 07/07/16 11:26, David Whale wrote:
> >>> Ben from BBC research recompiled MicroPython, and repackaged uflash and
> >>> mu and got it working himself recently for a coder dojo he was running.
> >>> He is bmustillrose on twitter, I'm sure he would share his build with
> >>> you if you wanted to get going quickly?
> >>>
> >>> David
> >>>
> >>>
> >>>
> >>> _______________________________________________
> >>> Microbit mailing list
> >>> Microbit at python.org
> >>> https://mail.python.org/mailman/listinfo/microbit
> >>>
> >>
> >> As it stands, it should be in the latest version of Mu / uFlash sometime
> >> at the end of next week.
> >>
> >> Updating the version of MicroPython on the BBC website is problematic.
> >>
> >> N.
> >>
> >>
> > _______________________________________________
> > Microbit mailing list
> > Microbit at python.org
> > https://mail.python.org/mailman/listinfo/microbit
> >
>
>
>
> _______________________________________________
> Microbit mailing list
> Microbit at python.org
> https://mail.python.org/mailman/listinfo/microbit
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/microbit/attachments/20160708/2154b078/attachment.html>


More information about the Microbit mailing list