[Microbit-Python] Current state of play - a summary and straw man

David Whale david at thinkingbinaries.com
Tue Oct 13 13:53:59 CEST 2015


Most, if not all, schools teach LMC (Little Man Computer).Those who do use
real hardware for assembly tend to use Microchip PIC's because they have a
tiny instruction set you can teach completely in 1 or two lessons.

I have a clean room implementation of an extensible LMC simulator written
in Python here: https://github.com/whaleygeek/MyLittleComputer

I was considering using the extendable IO instruction to expose GPIO on
raspberry pi, but now I think of it, running LMC on the micro:bit would be
fun, and directly applicable to what schools already teach.

D


___________________________________________________________
David Whale, B.Sc (Hons), MIET
*Software Engineer and IET Schools Liaison Officer, Essex*

email:  dwhale at theiet.org
twitter: @whaleygeek
blog:  blog.whaleygeek.co.uk

Co-author of the new book "Adventures in Minecraft" <http://amzn.to/ZGfxZG>
- lets get kids coding!


On 13 October 2015 at 12:33, Michael <sparks.m at gmail.com> wrote:

> On 13 October 2015 at 11:46, Nicholas H.Tollervey <ntoll at ntoll.org> wrote:
> ...
>
>> > 2. The proper inline assembler that already exists, where you write
>> code like:
>> >
>> > @micropython.asm_thumb
>> > def f(r0, r1):
>> >     label(loop)
>> >     add(r0, r1)
>> >     bne(loop)
>> >
>> > This is easier to hack, but since it's verbose you'll run out of
>> > memory (in the compile stage) if you try to write long functions.  It
>> > also takes up flash space (not too much though) and maybe in the
>> > future we need this flash space for other things?
>> >
>>
>> I like this too. Take a look at this - http://peter-cockerell.net/aalp/
>> from 1987!!!! My first programming language was BBC BASIC.
>>
>> Can we do both. My reason for asking is that there appears to be a clear
>> progression from the inline assembler to the cut'n'paste bytes solution.
>>
>
> While the primary audience for the micro:bit is obviously the kids, it's
> worth noting that the GCSE computing curriculum (depending on which one you
> read), still has references to using assembler & machine code. Having an
> actual device that is something the kids can use (rather use a web page
> simulator) and put even limited amounts of assembler into - even to switch
> on/off leds or pins - would probably be a major thing for teachers. (at
> least the ones that grasp the potential)
>
> For kids, it also puts in reach getting access to the lowest layers of the
> device, which makes this really cool.
>
> (I have a copy of "machine code for beginners" at home -
> http://boingboing.net/2013/05/16/1983s-wonderful-introducti.html - so
> anyone who says it's not for kids is just silly :-) )
>
>
> Michael.
>
>
> _______________________________________________
> Microbit mailing list
> Microbit at python.org
> https://mail.python.org/mailman/listinfo/microbit
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.python.org/mailman/private/microbit/attachments/20151013/bb91799b/attachment.html>


More information about the Microbit mailing list