From hwamok7712 at naver.com Thu Oct 13 05:00:07 2016 From: hwamok7712 at naver.com (=?UTF-8?B?6rmA7ZmU66qp?=) Date: Thu, 13 Oct 2016 18:00:07 +0900 (KST) Subject: [Microbit-Python] =?utf-8?q?hi=2C_i_have_some_question_in_MicroPy?= =?utf-8?q?thon?= Message-ID: <15ff72852aa8758f75ce068d518f11d@cweb17.nm.nhnsystem.com> i'm so interesting in Micro:bit and MicroPython so trying to looking at MicroPython In github there are two kind of mudule. one is [https://github.com/bbcmicrobit/micropython] other is [https://github.com/lancaster-university] what diffrent are they? (Dal & micropython) and finally my goal is make new MicroPython library in Micro:bit so last my question is that How to make library and testing? -------------- next part -------------- An HTML attachment was scrubbed... URL: From jim at groklearning.com Fri Oct 14 02:33:07 2016 From: jim at groklearning.com (Jim Mussared) Date: Fri, 14 Oct 2016 17:33:07 +1100 Subject: [Microbit-Python] hi, i have some question in MicroPython In-Reply-To: <15ff72852aa8758f75ce068d518f11d@cweb17.nm.nhnsystem.com> References: <15ff72852aa8758f75ce068d518f11d@cweb17.nm.nhnsystem.com> Message-ID: On 13 October 2016 at 20:00, ??? wrote: > i'm so interesting in Micro:bit and MicroPython > > so trying to looking at MicroPython > > In github there are two kind of mudule. > > one is [https://github.com/bbcmicrobit/micropython] > > other is [https://github.com/lancaster-university] > > > > what diffrent are they? (Dal & micropython) > hi, The first is the MicroPython implementation for the micro:bit, based on mbed. This is where you want to add new features or Python modules. The second is a library of hardware abstractions (DAL stands for "device abstraction layer") which is common code used to implement micro:bit firmwares. i.e. take a look at MicrobitDisplay.h/cpp to see how it implements the display multiplexing. The slightly confusing thing is that the MicroPython firmware uses quite little from the DAL now (e.g. it doesn't actually use that MicrobitDisplay class). I think the simplest way to look at it is to just focus on the main repo ( https://github.com/bbcmicrobit/micropython) and be aware that sometimes it'll call into code provided by the DAL. > > > and finally my goal is make new MicroPython library in Micro:bit > Look at something like modantigravity for a simple example ( https://github.com/bbcmicrobit/micropython/blob/master/source/microbit/modantigravity.cpp) or modneopixel for a more complicated one that uses the hardware ( https://github.com/bbcmicrobit/micropython/blob/master/source/microbit/modneopixel.cpp ) > > > so last my question is that How to make library and testing? > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From david at vividink.info Fri Oct 14 08:39:07 2016 From: david at vividink.info (david at vividink.info) Date: Fri, 14 Oct 2016 13:39:07 +0100 Subject: [Microbit-Python] Captured data - but how do I get it off the microbit onto my comp? Message-ID: <9f005bd08977a8adc95919377c32a675@vividink.info> Good afternoon, new microbit user here, but something of a dabbler in procedural python. I've written a simple script to capture accelerometer data to a file, using micropyton. After running the script on the mmicrobit, I can examine the filesystem issueing os.listdir() and os.size('data.csv') in the REPL and confirm the file is there. My question is, how do I get the csv file off the microbit and onto my computer? Searching google hasn't really come up with any answers yet - so useful search terms also gratefully received. Happy days! David From ntoll at ntoll.org Fri Oct 14 08:49:30 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Fri, 14 Oct 2016 13:49:30 +0100 Subject: [Microbit-Python] Captured data - but how do I get it off the microbit onto my comp? In-Reply-To: <9f005bd08977a8adc95919377c32a675@vividink.info> References: <9f005bd08977a8adc95919377c32a675@vividink.info> Message-ID: On 14/10/16 13:39, david at vividink.info wrote: > Good afternoon, > > new microbit user here, but something of a dabbler in procedural python. > > I've written a simple script to capture accelerometer data to a file, > using micropyton. > > After running the script on the mmicrobit, I can examine the filesystem > issueing os.listdir() and os.size('data.csv') in the REPL and confirm > the file is there. > > My question is, how do I get the csv file off the microbit and onto my > computer? > > Searching google hasn't really come up with any answers yet - so useful > search terms also gratefully received. > > Happy days! > David > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit If you use a recent version of Mu (http://codewith.mu/) you get a simple UI dragging files on / off the device (Use the "Files" button when your device is plugged in). Alternatively, use the microfs command documented here: https://microfs.readthedocs.io/en/latest/ Hope this helps, N. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From david at vividink.info Fri Oct 14 09:41:49 2016 From: david at vividink.info (=?UTF-8?Q?David_R=c3=bcder?=) Date: Fri, 14 Oct 2016 14:41:49 +0100 Subject: [Microbit-Python] Captured data - but how do I get it off the microbit onto my comp? In-Reply-To: References: <9f005bd08977a8adc95919377c32a675@vividink.info> Message-ID: Thanks Nicholas! Perfect. On 10/14/2016 01:49 PM, Nicholas H.Tollervey wrote: > If you use a recent version of Mu (http://codewith.mu/) you get a simple > UI dragging files on / off the device (Use the "Files" button when your > device is plugged in). > > Alternatively, use the microfs command documented here: > > https://microfs.readthedocs.io/en/latest/ > > Hope this helps, > > N. > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit -- David R?der News writer Vividink Ltd. Telephone: +44 (0)1433 445 001 Mobile: +44 (0)7885 572 769 Email: david at vividink.info Twitter: @DavidAtVividink company reg no: 05068421. vat reg no: gb 845 5689 78 vividink ltd is not liable for any loss, damages, claims, cost, demand and expense whatsoever and howsoever arising in connection with or out of the use of data and / or applications supplied in this email transmission. The receiver of this transmission shall ascertain the accuracy and suitability of this data for their purposes. The contents or opinions contained within this email are solely those of the sender and do not necessarily represent those of vividink ltd . If you receive this transmission in error, please notify vividink ltd immediately and then delete this email. Although content security software is used by vividink ltd, the receiver of this transmission shall be responsible for their own protection. -------------- next part -------------- An HTML attachment was scrubbed... URL: From nigel.kendrick at gmail.com Wed Oct 19 06:49:18 2016 From: nigel.kendrick at gmail.com (Nigel Kendrick) Date: Wed, 19 Oct 2016 11:49:18 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? Message-ID: http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ http://calliope.cc/ueber-mini (German) Let the clone wars..etc. -- Nigel -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Wed Oct 19 06:50:07 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Wed, 19 Oct 2016 11:50:07 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: On 19/10/16 11:49, Nigel Kendrick wrote: > http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ > http://calliope.cc/ueber-mini (German) > > Let the clone wars..etc. > > -- Nigel > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > This is a good thing. It runs MicroPython. N. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From barrachri at gmail.com Wed Oct 19 07:00:34 2016 From: barrachri at gmail.com (Christian Barra) Date: Wed, 19 Oct 2016 13:00:34 +0200 Subject: [Microbit-Python] Microbit is going global ! Message-ID: Good news: http://www.wired.co.uk/article/microbit-foundation-bbc-microsoft-samsung -- With Gravitational Cheers, Christian EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From nigel.kendrick at gmail.com Wed Oct 19 07:00:29 2016 From: nigel.kendrick at gmail.com (Nigel Kendrick) Date: Wed, 19 Oct 2016 12:00:29 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: <410A93FE-3ED9-4942-A9F5-73FF5CA5AB82@gmail.com> I....can't ....quite...force this expansion board to fiiiiit. Snap. Bugger. On 19 October 2016 11:50:07 BST, "Nicholas H.Tollervey" wrote: >On 19/10/16 11:49, Nigel Kendrick wrote: >> http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ >> http://calliope.cc/ueber-mini (German) >> >> Let the clone wars..etc. >> >> -- Nigel >> >> >> _______________________________________________ >> Microbit mailing list >> Microbit at python.org >> https://mail.python.org/mailman/listinfo/microbit >> > >This is a good thing. It runs MicroPython. > >N. > > > >------------------------------------------------------------------------ > >_______________________________________________ >Microbit mailing list >Microbit at python.org >https://mail.python.org/mailman/listinfo/microbit -------------- next part -------------- An HTML attachment was scrubbed... URL: From mal at egenix.com Wed Oct 19 07:01:16 2016 From: mal at egenix.com (M.-A. Lemburg) Date: Wed, 19 Oct 2016 13:01:16 +0200 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: <5807527C.5090907@egenix.com> On 19.10.2016 12:49, Nigel Kendrick wrote: > http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ > http://calliope.cc/ueber-mini (German) > > Let the clone wars..etc. I believe the main reason for such developments is that it's still not possible to (legally) order MBs outside the UK. I do wonder what is holding up EU- and world-wide sales of the device. -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>> Python Database Interfaces ... http://products.egenix.com/ >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ ________________________________________________________________________ ::::: Try our mxODBC.Connect Python Database Interface for free ! :::::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ From jim at groklearning.com Wed Oct 19 07:01:26 2016 From: jim at groklearning.com (Jim Mussared) Date: Wed, 19 Oct 2016 22:01:26 +1100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: On 19 October 2016 at 21:50, Nicholas H.Tollervey wrote: > On 19/10/16 11:49, Nigel Kendrick wrote: >> http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ >> http://calliope.cc/ueber-mini (German) >> >> Let the clone wars..etc. >> >> -- Nigel >> >> >> _______________________________________________ >> Microbit mailing list >> Microbit at python.org >> https://mail.python.org/mailman/listinfo/microbit >> > > This is a good thing. It runs MicroPython. Not just MicroPython but by the sounds of it, unmodified micro:bit firmware! Has anyone heard from them about (or possibly involved with) their plans? i.e. will they add their additional modules (RGB led, h-bridge, etc) to the main micro:bit micropython repo? > > N. > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > From carlosperate at gmail.com Wed Oct 19 07:02:15 2016 From: carlosperate at gmail.com (Carlos Pereira Atencio) Date: Wed, 19 Oct 2016 12:02:15 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: And it looks it'll be pin compatible as well, so the same micropython programs should run in both boards. Also Switch Science in Japan also created a slightly different version (can't remember exactly why, but they had to change the bluetooth/radio): https://www.switch-science.com/catalog/2778/ On 19 October 2016 at 11:50, Nicholas H.Tollervey wrote: > On 19/10/16 11:49, Nigel Kendrick wrote: > > http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ > > http://calliope.cc/ueber-mini (German) > > > > Let the clone wars..etc. > > > > -- Nigel > > > > > > _______________________________________________ > > Microbit mailing list > > Microbit at python.org > > https://mail.python.org/mailman/listinfo/microbit > > > > This is a good thing. It runs MicroPython. > > N. > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlosperate at gmail.com Wed Oct 19 07:05:47 2016 From: carlosperate at gmail.com (Carlos Pereira Atencio) Date: Wed, 19 Oct 2016 12:05:47 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: <5807527C.5090907@egenix.com> References: <5807527C.5090907@egenix.com> Message-ID: Are you sure that's right? I would have assumed Farnell could export them just like any other product. It's also gaining popularity in Finland, so they must be getting their boards somehow... On 19 October 2016 at 12:01, M.-A. Lemburg wrote: > On 19.10.2016 12:49, Nigel Kendrick wrote: > > http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ > > http://calliope.cc/ueber-mini (German) > > > > Let the clone wars..etc. > > I believe the main reason for such developments is that it's > still not possible to (legally) order MBs outside the UK. > > I do wonder what is holding up EU- and world-wide sales > of the device. > > -- > Marc-Andre Lemburg > eGenix.com > > Professional Python Services directly from the Experts > >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ > >>> Python Database Interfaces ... http://products.egenix.com/ > >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ > ________________________________________________________________________ > > ::::: Try our mxODBC.Connect Python Database Interface for free ! :::::: > > eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 > D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg > Registered at Amtsgericht Duesseldorf: HRB 46611 > http://www.egenix.com/company/contact/ > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Wed Oct 19 07:08:31 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Wed, 19 Oct 2016 12:08:31 +0100 Subject: [Microbit-Python] Microbit is going global ! In-Reply-To: References: Message-ID: On 19/10/16 12:00, Christian Barra wrote: > Good news: > > http://www.wired.co.uk/article/microbit-foundation-bbc-microsoft-samsung > > -- > With Gravitational Cheers, > > Christian > EuroPython Society board member > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > Yes, I've known about the micro:bit foundation for a while but have been under embargo about it. Regarding Marc-Andre's question - BBC is an acronym for big bureaucratic corporation and I think you can buy them online without legal problems. I believe the organisations who sell the boards must be UK based for odd legal reasons. Where they deliver them to is pretty open. I believe (and hope) the German team will be more open. I'm going to reach out to them in any case to see if / how they engage with the wider Python community. I'll let people on this list know how they respond. Ciao ciao, N. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From barrachri at gmail.com Wed Oct 19 07:13:07 2016 From: barrachri at gmail.com (Christian Barra) Date: Wed, 19 Oct 2016 13:13:07 +0200 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: <5807527C.5090907@egenix.com> References: <5807527C.5090907@egenix.com> Message-ID: 2016-10-19 13:01 GMT+02:00 M.-A. Lemburg : > > > I believe the main reason for such developments is that it's > still not possible to (legally) order MBs outside the UK. > > I do wonder what is holding up EU- and world-wide sales > of the device. > Hi Marc, are you sure ? I ordered some Microbits from UK and they sent it to Poland. -- With Gravitational Cheers, Christian EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From barrachri at gmail.com Wed Oct 19 07:14:30 2016 From: barrachri at gmail.com (Christian Barra) Date: Wed, 19 Oct 2016 13:14:30 +0200 Subject: [Microbit-Python] Microbit is going global ! In-Reply-To: References: Message-ID: 2016-10-19 13:08 GMT+02:00 Nicholas H.Tollervey : > On 19/10/16 12:00, Christian Barra wrote: > > Good news: > > > > http://www.wired.co.uk/article/microbit-foundation-bbc-microsoft-samsung > > > > -- > > With Gravitational Cheers, > > > > Christian > > EuroPython Society board member > > > > > > _______________________________________________ > > Microbit mailing list > > Microbit at python.org > > https://mail.python.org/mailman/listinfo/microbit > > > > Yes, I've known about the micro:bit foundation for a while but have been > > > N. > Cool ! Btw I just asked to the PSF for a grant to start the Microbit:Poland project ! I will keep the list updated :) -- With Gravitational Cheers, Christian EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From joakimbits at gmail.com Wed Oct 19 07:25:59 2016 From: joakimbits at gmail.com (Joakim Pettersson) Date: Wed, 19 Oct 2016 11:25:59 +0000 Subject: [Microbit-Python] Microbit is going global ! In-Reply-To: Message-ID: Cool! I pitched micro:bit to the Swedish prime minister at a student-industry gathering this Monday, and he received one! Hope it gets attention. (The kit was delivered inside this 3d print http://www.thingiverse.com/thing:1424624 - minimum 105% required, I printed at 110%). BR/joakim ------ Originalmeddelande ------ Fr?n: "Christian Barra" Till: "For Pythonic MicroBit related discussions" Skickat: 2016-10-19 13:14:30 ?mne: Re: [Microbit-Python] Microbit is going global ! > > >2016-10-19 13:08 GMT+02:00 Nicholas H.Tollervey : >>On 19/10/16 12:00, Christian Barra wrote: >> > Good news: >> > >> > >>http://www.wired.co.uk/article/microbit-foundation-bbc-microsoft-samsung >> > >> > -- >> > With Gravitational Cheers, >> > >> > Christian >> > EuroPython Society board member >> > >> > >> > _______________________________________________ >> > Microbit mailing list >> > Microbit at python.org >> > https://mail.python.org/mailman/listinfo/microbit >> > >> >>Yes, I've known about the micro:bit foundation for a while but have >>been >> >> >>N. > >Cool ! > >Btw I just asked to the PSF for a grant to start the Microbit:Poland >project ! > >I will keep the list updated :) > >-- >With Gravitational Cheers, > >Christian >EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From joakimbits at gmail.com Wed Oct 19 08:00:42 2016 From: joakimbits at gmail.com (Joakim Pettersson) Date: Wed, 19 Oct 2016 12:00:42 +0000 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences Message-ID: Hi, I stumped into problems with the online editor. Which documentation should I read to figure out the API? Why is that micropython implementation different from the one used by the mu editor? Here is code that works in the mu editor but fails when dowloading from https://www.microbit.co.uk/app/# (probably on the third line but how do I tell?). The code was running a swarm of 8 micro:bit at a student-industry event this Monday. I used it also to pitch micro:bit to the Swedish prime minister when he received one there:). Thanks/Joakim # A micro:bit virus-infectable Firefly. # mailto:Joakim.Pettersson at join.se from radio import send, receive, on import random from microbit import display, Image, button_a, button_b, sleep flock_size = 3 # Number of fireflies required for flock behaviour me = 2 # My lucky number a_name, b_name = { 0: ('HEART', 'ALL_ARROWS'), 1: ('HAPPY', 'ALL_CLOCKS'), 2: ('SURPRISED', 'CONFUSED'), 3: ('SNAKE', 'PACMAN'), 4: ('BUTTERFLY', 'COW'), 5: ('FABULOUS', 'SAD'), 6: ('SILLY', 'SMILE')}[me] a_image, b_image = (eval('Image.' + name) for name in (a_name, b_name)) # A show function that does not wait def show(x): display.show(x, delay=100, wait=False) show(a_image) # Create the "flash" animation frames. Can you work out how it's done? flash_animation = [Image().invert()*(i/9) for i in range(9, -1, -1)] # Timing is controlled with these global variables time = 0 # Current time flash_time = -1 # Time to flash LEDs reflash_time = -1 # Time to flash others # Define the "flash" function. def flash(): "Display the firefly flash animation after a random short pause" global time, flash_time, reflash_time flash_time = time + random.randint(50, 350) if random.randint(0, flock_size) == 0: reflash_time = flash_time + 500 # The step function decides what to do next def step(): global time, flash_time, reflash_time # Button A and B changes image. if button_a.was_pressed(): send('show(Image.%s)' % a_name) show(a_image) reflash_time = time # Reflash now! if button_b.was_pressed(): send('show(Image.%s)' % b_name) show(b_image) reflash_time = time # Reflash now! # Read any incoming messages. try: incoming_message = receive() except ValueError: pass if incoming_message: print(incoming_message) if incoming_message[:3] != 'On ': try: exec(incoming_message, globals(), globals()) except Exception as e: send("On %d: %s" % (me, e)) if time == flash_time: show(flash_animation) if time == reflash_time: send('flash()') # a-ha sleep(1) # Pause 1 ms time = time + 1 # Now it's time for next step # The radio won't work unless it's switched on. on() # Infinite loop while True: try: step() except Exception as e: print(e) # For the virus author: # Send <20 character strings containing new code ;-)! -------------- next part -------------- An HTML attachment was scrubbed... URL: From radomir at dopieralski.pl Wed Oct 19 08:11:13 2016 From: radomir at dopieralski.pl (Radomir Dopieralski) Date: Wed, 19 Oct 2016 14:11:13 +0200 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences In-Reply-To: References: Message-ID: <20161019141113.01854b0b@ghostwheel> Hi, the version of MicroPython at the microbit website is outdated, because it takes BBC a very long time to upgrade it. The Mu editor comes with the latest release, because it's in control of the developers. One note about your code. You *really* don't want to use eval(). I would use the getattr() function in its place, like this: a_image, b_image = getattr(Image, name) for name in (a_name, b_name) On Wed, 19 Oct 2016 12:00:42 +0000 "Joakim Pettersson" wrote: > Hi, > > I stumped into problems with the online editor. > Which documentation should I read to figure out the API? > Why is that micropython implementation different from the one used by > the mu editor? > > Here is code that works in the mu editor but fails when dowloading > from https://www.microbit.co.uk/app/# (probably on the third line but > how do I tell?). The code was running a swarm of 8 micro:bit at a > student-industry event this Monday. I used it also to pitch micro:bit > to the Swedish prime minister when he received one there:). > > Thanks/Joakim > > # A micro:bit virus-infectable Firefly. > # mailto:Joakim.Pettersson at join.se > > from radio import send, receive, on > import random > from microbit import display, Image, button_a, button_b, sleep > > flock_size = 3 # Number of fireflies required for flock behaviour > me = 2 # My lucky number > a_name, b_name = { > 0: ('HEART', 'ALL_ARROWS'), > 1: ('HAPPY', 'ALL_CLOCKS'), > 2: ('SURPRISED', 'CONFUSED'), > 3: ('SNAKE', 'PACMAN'), > 4: ('BUTTERFLY', 'COW'), > 5: ('FABULOUS', 'SAD'), > 6: ('SILLY', 'SMILE')}[me] > a_image, b_image = (eval('Image.' + name) for name in (a_name, > b_name)) > > > # A show function that does not wait > def show(x): display.show(x, delay=100, wait=False) > show(a_image) > > # Create the "flash" animation frames. Can you work out how it's done? > flash_animation = [Image().invert()*(i/9) for i in range(9, -1, -1)] > > # Timing is controlled with these global variables > time = 0 # Current time > flash_time = -1 # Time to flash LEDs > reflash_time = -1 # Time to flash others > > > # Define the "flash" function. > def flash(): > "Display the firefly flash animation after a random short pause" > global time, flash_time, reflash_time > flash_time = time + random.randint(50, 350) > if random.randint(0, flock_size) == 0: > reflash_time = flash_time + 500 > > > # The step function decides what to do next > def step(): > global time, flash_time, reflash_time > # Button A and B changes image. > if button_a.was_pressed(): > send('show(Image.%s)' % a_name) > show(a_image) > reflash_time = time # Reflash now! > if button_b.was_pressed(): > send('show(Image.%s)' % b_name) > show(b_image) > reflash_time = time # Reflash now! > # Read any incoming messages. > try: > incoming_message = receive() > except ValueError: > pass > if incoming_message: > print(incoming_message) > if incoming_message[:3] != 'On ': > try: > exec(incoming_message, globals(), globals()) > except Exception as e: > send("On %d: %s" % (me, e)) > if time == flash_time: > show(flash_animation) > if time == reflash_time: > send('flash()') # a-ha > sleep(1) # Pause 1 ms > time = time + 1 # Now it's time for next step > > # The radio won't work unless it's switched on. > on() > > # Infinite loop > while True: > try: > step() > except Exception as e: > print(e) > > # For the virus author: > # Send <20 character strings containing new code ;-)! > > > > > > -- Radomir Dopieralski From joakimbits at gmail.com Wed Oct 19 08:17:15 2016 From: joakimbits at gmail.com (Joakim Pettersson) Date: Wed, 19 Oct 2016 12:17:15 +0000 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences In-Reply-To: <20161019141113.01854b0b@ghostwheel> Message-ID: Aha, that's why - thanks for the explanation! Agree one should not eval, but this demo is about daring using the parser-interpreter so it's ok! Note the exec in globals() later on;). /joakim ------ Originalmeddelande ------ Fr?n: "Radomir Dopieralski" Till: microbit at python.org Kopia: "Joakim Pettersson" Skickat: 2016-10-19 14:11:13 ?mne: Re: [Microbit-Python] mu vs microbit.co.uk/create-code API differences >Hi, > >the version of MicroPython at the microbit website is outdated, because >it >takes BBC a very long time to upgrade it. The Mu editor comes with the >latest >release, because it's in control of the developers. > >One note about your code. You *really* don't want to use eval(). I >would use >the getattr() function in its place, like this: > >a_image, b_image = getattr(Image, name) for name in (a_name, b_name) > > >On Wed, 19 Oct 2016 12:00:42 +0000 >"Joakim Pettersson" wrote: > >> Hi, >> >> I stumped into problems with the online editor. >> Which documentation should I read to figure out the API? >> Why is that micropython implementation different from the one used by >> the mu editor? >> >> Here is code that works in the mu editor but fails when dowloading >> from https://www.microbit.co.uk/app/# (probably on the third line but >> how do I tell?). The code was running a swarm of 8 micro:bit at a >> student-industry event this Monday. I used it also to pitch micro:bit >> to the Swedish prime minister when he received one there:). >> >> Thanks/Joakim >> >> # A micro:bit virus-infectable Firefly. >> # mailto:Joakim.Pettersson at join.se >> >> from radio import send, receive, on >> import random >> from microbit import display, Image, button_a, button_b, sleep >> >> flock_size = 3 # Number of fireflies required for flock behaviour >> me = 2 # My lucky number >> a_name, b_name = { >> 0: ('HEART', 'ALL_ARROWS'), >> 1: ('HAPPY', 'ALL_CLOCKS'), >> 2: ('SURPRISED', 'CONFUSED'), >> 3: ('SNAKE', 'PACMAN'), >> 4: ('BUTTERFLY', 'COW'), >> 5: ('FABULOUS', 'SAD'), >> 6: ('SILLY', 'SMILE')}[me] >> a_image, b_image = (eval('Image.' + name) for name in (a_name, >> b_name)) >> >> >> # A show function that does not wait >> def show(x): display.show(x, delay=100, wait=False) >> show(a_image) >> >> # Create the "flash" animation frames. Can you work out how it's >>done? >> flash_animation = [Image().invert()*(i/9) for i in range(9, -1, -1)] >> >> # Timing is controlled with these global variables >> time = 0 # Current time >> flash_time = -1 # Time to flash LEDs >> reflash_time = -1 # Time to flash others >> >> >> # Define the "flash" function. >> def flash(): >> "Display the firefly flash animation after a random short pause" >> global time, flash_time, reflash_time >> flash_time = time + random.randint(50, 350) >> if random.randint(0, flock_size) == 0: >> reflash_time = flash_time + 500 >> >> >> # The step function decides what to do next >> def step(): >> global time, flash_time, reflash_time >> # Button A and B changes image. >> if button_a.was_pressed(): >> send('show(Image.%s)' % a_name) >> show(a_image) >> reflash_time = time # Reflash now! >> if button_b.was_pressed(): >> send('show(Image.%s)' % b_name) >> show(b_image) >> reflash_time = time # Reflash now! >> # Read any incoming messages. >> try: >> incoming_message = receive() >> except ValueError: >> pass >> if incoming_message: >> print(incoming_message) >> if incoming_message[:3] != 'On ': >> try: >> exec(incoming_message, globals(), globals()) >> except Exception as e: >> send("On %d: %s" % (me, e)) >> if time == flash_time: >> show(flash_animation) >> if time == reflash_time: >> send('flash()') # a-ha >> sleep(1) # Pause 1 ms >> time = time + 1 # Now it's time for next step >> >> # The radio won't work unless it's switched on. >> on() >> >> # Infinite loop >> while True: >> try: >> step() >> except Exception as e: >> print(e) >> >> # For the virus author: >> # Send <20 character strings containing new code ;-)! >> >> >> >> >> >> > > > >-- >Radomir Dopieralski From carlosperate at gmail.com Wed Oct 19 09:16:19 2016 From: carlosperate at gmail.com (Carlos Pereira Atencio) Date: Wed, 19 Oct 2016 14:16:19 +0100 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences In-Reply-To: References: <20161019141113.01854b0b@ghostwheel> Message-ID: Now that the foundation has been announced, the http://microbit.org website (note the change from .co.uk to .org) should contain the newest version of the online editor . So if you go to http://python.microbit.org/editor.html it should contain the latest micropython. On 19 October 2016 at 13:17, Joakim Pettersson wrote: > Aha, that's why - thanks for the explanation! > Agree one should not eval, but this demo is about daring using the > parser-interpreter so it's ok! > Note the exec in globals() later on;). > /joakim > > ------ Originalmeddelande ------ > Fr?n: "Radomir Dopieralski" > Till: microbit at python.org > Kopia: "Joakim Pettersson" > Skickat: 2016-10-19 14:11:13 > ?mne: Re: [Microbit-Python] mu vs microbit.co.uk/create-code API > differences > > > Hi, >> >> the version of MicroPython at the microbit website is outdated, because it >> takes BBC a very long time to upgrade it. The Mu editor comes with the >> latest >> release, because it's in control of the developers. >> >> One note about your code. You *really* don't want to use eval(). I would >> use >> the getattr() function in its place, like this: >> >> a_image, b_image = getattr(Image, name) for name in (a_name, b_name) >> >> >> On Wed, 19 Oct 2016 12:00:42 +0000 >> "Joakim Pettersson" wrote: >> >> Hi, >>> >>> I stumped into problems with the online editor. >>> Which documentation should I read to figure out the API? >>> Why is that micropython implementation different from the one used by >>> the mu editor? >>> >>> Here is code that works in the mu editor but fails when dowloading >>> from https://www.microbit.co.uk/app/# (probably on the third line but >>> how do I tell?). The code was running a swarm of 8 micro:bit at a >>> student-industry event this Monday. I used it also to pitch micro:bit >>> to the Swedish prime minister when he received one there:). >>> >>> Thanks/Joakim >>> >>> # A micro:bit virus-infectable Firefly. >>> # mailto:Joakim.Pettersson at join.se >>> >>> from radio import send, receive, on >>> import random >>> from microbit import display, Image, button_a, button_b, sleep >>> >>> flock_size = 3 # Number of fireflies required for flock behaviour >>> me = 2 # My lucky number >>> a_name, b_name = { >>> 0: ('HEART', 'ALL_ARROWS'), >>> 1: ('HAPPY', 'ALL_CLOCKS'), >>> 2: ('SURPRISED', 'CONFUSED'), >>> 3: ('SNAKE', 'PACMAN'), >>> 4: ('BUTTERFLY', 'COW'), >>> 5: ('FABULOUS', 'SAD'), >>> 6: ('SILLY', 'SMILE')}[me] >>> a_image, b_image = (eval('Image.' + name) for name in (a_name, >>> b_name)) >>> >>> >>> # A show function that does not wait >>> def show(x): display.show(x, delay=100, wait=False) >>> show(a_image) >>> >>> # Create the "flash" animation frames. Can you work out how it's done? >>> flash_animation = [Image().invert()*(i/9) for i in range(9, -1, -1)] >>> >>> # Timing is controlled with these global variables >>> time = 0 # Current time >>> flash_time = -1 # Time to flash LEDs >>> reflash_time = -1 # Time to flash others >>> >>> >>> # Define the "flash" function. >>> def flash(): >>> "Display the firefly flash animation after a random short pause" >>> global time, flash_time, reflash_time >>> flash_time = time + random.randint(50, 350) >>> if random.randint(0, flock_size) == 0: >>> reflash_time = flash_time + 500 >>> >>> >>> # The step function decides what to do next >>> def step(): >>> global time, flash_time, reflash_time >>> # Button A and B changes image. >>> if button_a.was_pressed(): >>> send('show(Image.%s)' % a_name) >>> show(a_image) >>> reflash_time = time # Reflash now! >>> if button_b.was_pressed(): >>> send('show(Image.%s)' % b_name) >>> show(b_image) >>> reflash_time = time # Reflash now! >>> # Read any incoming messages. >>> try: >>> incoming_message = receive() >>> except ValueError: >>> pass >>> if incoming_message: >>> print(incoming_message) >>> if incoming_message[:3] != 'On ': >>> try: >>> exec(incoming_message, globals(), globals()) >>> except Exception as e: >>> send("On %d: %s" % (me, e)) >>> if time == flash_time: >>> show(flash_animation) >>> if time == reflash_time: >>> send('flash()') # a-ha >>> sleep(1) # Pause 1 ms >>> time = time + 1 # Now it's time for next step >>> >>> # The radio won't work unless it's switched on. >>> on() >>> >>> # Infinite loop >>> while True: >>> try: >>> step() >>> except Exception as e: >>> print(e) >>> >>> # For the virus author: >>> # Send <20 character strings containing new code ;-)! >>> >>> >>> >>> >>> >>> >>> >> >> >> -- >> Radomir Dopieralski >> > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- An HTML attachment was scrubbed... URL: From david at thinkingbinaries.com Wed Oct 19 09:17:45 2016 From: david at thinkingbinaries.com (David Whale) Date: Wed, 19 Oct 2016 14:17:45 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: <5807527C.5090907@egenix.com> Message-ID: UK resellers will ship abroad, eg Kitronik to 35 countries. Farnell is in the process of rolling out resellers across Europe ___________________________________________________________ David Whale, B.Sc (Hons), MIET *Software Engineer and IET Schools Liaison Officer, Essex* On 19 October 2016 at 12:13, Christian Barra wrote: > > > 2016-10-19 13:01 GMT+02:00 M.-A. Lemburg : > >> >> >> I believe the main reason for such developments is that it's >> still not possible to (legally) order MBs outside the UK. >> >> I do wonder what is holding up EU- and world-wide sales >> of the device. >> > > Hi Marc, are you sure ? > > I ordered some Microbits from UK and they sent it to Poland. > > -- > With Gravitational Cheers, > > Christian > EuroPython Society board member > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Wed Oct 19 09:18:35 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Wed, 19 Oct 2016 14:18:35 +0100 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences In-Reply-To: References: <20161019141113.01854b0b@ghostwheel> Message-ID: <522c2183-e768-16df-832b-8c1fd049d710@ntoll.org> Carlos, You beat me to it! http://python.microbit.org/editor.html has the latest version. Also, the source code for the editor is open source and can be found here: https://github.com/bbcmicrobit/PythonEditor Hope this helps, N. On 19/10/16 14:16, Carlos Pereira Atencio wrote: > Now that the foundation has been announced, the http://microbit.org > website (note the change from .co.uk to .org) should > contain the newest version of the online editor . So if you go to > http://python.microbit.org/editor.html it should contain the latest > micropython. > > On 19 October 2016 at 13:17, Joakim Pettersson > wrote: > > Aha, that's why - thanks for the explanation! > Agree one should not eval, but this demo is about daring using the > parser-interpreter so it's ok! > Note the exec in globals() later on;). > /joakim > > ------ Originalmeddelande ------ > Fr?n: "Radomir Dopieralski" > > Till: microbit at python.org > Kopia: "Joakim Pettersson" > > Skickat: 2016-10-19 14:11:13 > ?mne: Re: [Microbit-Python] mu vs microbit.co.uk/create-code > API differences > > > Hi, > > the version of MicroPython at the microbit website is outdated, > because it > takes BBC a very long time to upgrade it. The Mu editor comes > with the latest > release, because it's in control of the developers. > > One note about your code. You *really* don't want to use eval(). > I would use > the getattr() function in its place, like this: > > a_image, b_image = getattr(Image, name) for name in (a_name, b_name) > > > On Wed, 19 Oct 2016 12:00:42 +0000 > "Joakim Pettersson" > wrote: > > Hi, > > I stumped into problems with the online editor. > Which documentation should I read to figure out the API? > Why is that micropython implementation different from the > one used by > the mu editor? > > Here is code that works in the mu editor but fails when > dowloading > from https://www.microbit.co.uk/app/# > (probably on the third > line but > how do I tell?). The code was running a swarm of 8 > micro:bit at a > student-industry event this Monday. I used it also to pitch > micro:bit > to the Swedish prime minister when he received one there:). > > Thanks/Joakim > > # A micro:bit virus-infectable Firefly. > # mailto:Joakim.Pettersson at join.se > > > from radio import send, receive, on > import random > from microbit import display, Image, button_a, button_b, sleep > > flock_size = 3 # Number of fireflies required for flock > behaviour > me = 2 # My lucky number > a_name, b_name = { > 0: ('HEART', 'ALL_ARROWS'), > 1: ('HAPPY', 'ALL_CLOCKS'), > 2: ('SURPRISED', 'CONFUSED'), > 3: ('SNAKE', 'PACMAN'), > 4: ('BUTTERFLY', 'COW'), > 5: ('FABULOUS', 'SAD'), > 6: ('SILLY', 'SMILE')}[me] > a_image, b_image = (eval('Image.' + name) for name in (a_name, > b_name)) > > > # A show function that does not wait > def show(x): display.show(x, delay=100, wait=False) > show(a_image) > > # Create the "flash" animation frames. Can you work out how > it's done? > flash_animation = [Image().invert()*(i/9) for i in range(9, > -1, -1)] > > # Timing is controlled with these global variables > time = 0 # Current time > flash_time = -1 # Time to flash LEDs > reflash_time = -1 # Time to flash others > > > # Define the "flash" function. > def flash(): > "Display the firefly flash animation after a random > short pause" > global time, flash_time, reflash_time > flash_time = time + random.randint(50, 350) > if random.randint(0, flock_size) == 0: > reflash_time = flash_time + 500 > > > # The step function decides what to do next > def step(): > global time, flash_time, reflash_time > # Button A and B changes image. > if button_a.was_pressed(): > send('show(Image.%s)' % a_name) > show(a_image) > reflash_time = time # Reflash now! > if button_b.was_pressed(): > send('show(Image.%s)' % b_name) > show(b_image) > reflash_time = time # Reflash now! > # Read any incoming messages. > try: > incoming_message = receive() > except ValueError: > pass > if incoming_message: > print(incoming_message) > if incoming_message[:3] != 'On ': > try: > exec(incoming_message, globals(), globals()) > except Exception as e: > send("On %d: %s" % (me, e)) > if time == flash_time: > show(flash_animation) > if time == reflash_time: > send('flash()') # a-ha > sleep(1) # Pause 1 ms > time = time + 1 # Now it's time for next step > > # The radio won't work unless it's switched on. > on() > > # Infinite loop > while True: > try: > step() > except Exception as e: > print(e) > > # For the virus author: > # Send <20 character strings containing new code ;-)! > > > > > > > > > > -- > Radomir Dopieralski > > > _______________________________________________ > 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 -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From ntoll at ntoll.org Wed Oct 19 09:23:09 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Wed, 19 Oct 2016 14:23:09 +0100 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences In-Reply-To: <522c2183-e768-16df-832b-8c1fd049d710@ntoll.org> References: <20161019141113.01854b0b@ghostwheel> <522c2183-e768-16df-832b-8c1fd049d710@ntoll.org> Message-ID: <6f02488d-c56c-f1c1-fd34-ebd85ffb8d56@ntoll.org> I forgot to mention - the BBC won't let me deploy the latest version of the editor for tedious bureaucratic reasons. You can't believe how frustrating this feels and I hope it certainly doesn't reflect on the efforts of the Python community to create, share and promote freely available resources. :-/ Joakim, please don't hesitate to ask questions or ask for help. The Python community is incredibly generous with their time and passionate about education. Basically, you have allies! N. On 19/10/16 14:18, Nicholas H.Tollervey wrote: > Carlos, > > You beat me to it! > > http://python.microbit.org/editor.html has the latest version. > > Also, the source code for the editor is open source and can be found here: > > https://github.com/bbcmicrobit/PythonEditor > > Hope this helps, > > N. > > On 19/10/16 14:16, Carlos Pereira Atencio wrote: >> Now that the foundation has been announced, the http://microbit.org >> website (note the change from .co.uk to .org) should >> contain the newest version of the online editor . So if you go to >> http://python.microbit.org/editor.html it should contain the latest >> micropython. >> >> On 19 October 2016 at 13:17, Joakim Pettersson > > wrote: >> >> Aha, that's why - thanks for the explanation! >> Agree one should not eval, but this demo is about daring using the >> parser-interpreter so it's ok! >> Note the exec in globals() later on;). >> /joakim >> >> ------ Originalmeddelande ------ >> Fr?n: "Radomir Dopieralski" > > >> Till: microbit at python.org >> Kopia: "Joakim Pettersson" > > >> Skickat: 2016-10-19 14:11:13 >> ?mne: Re: [Microbit-Python] mu vs microbit.co.uk/create-code >> API differences >> >> >> Hi, >> >> the version of MicroPython at the microbit website is outdated, >> because it >> takes BBC a very long time to upgrade it. The Mu editor comes >> with the latest >> release, because it's in control of the developers. >> >> One note about your code. You *really* don't want to use eval(). >> I would use >> the getattr() function in its place, like this: >> >> a_image, b_image = getattr(Image, name) for name in (a_name, b_name) >> >> >> On Wed, 19 Oct 2016 12:00:42 +0000 >> "Joakim Pettersson" > > wrote: >> >> Hi, >> >> I stumped into problems with the online editor. >> Which documentation should I read to figure out the API? >> Why is that micropython implementation different from the >> one used by >> the mu editor? >> >> Here is code that works in the mu editor but fails when >> dowloading >> from https://www.microbit.co.uk/app/# >> (probably on the third >> line but >> how do I tell?). The code was running a swarm of 8 >> micro:bit at a >> student-industry event this Monday. I used it also to pitch >> micro:bit >> to the Swedish prime minister when he received one there:). >> >> Thanks/Joakim >> >> # A micro:bit virus-infectable Firefly. >> # mailto:Joakim.Pettersson at join.se >> >> >> from radio import send, receive, on >> import random >> from microbit import display, Image, button_a, button_b, sleep >> >> flock_size = 3 # Number of fireflies required for flock >> behaviour >> me = 2 # My lucky number >> a_name, b_name = { >> 0: ('HEART', 'ALL_ARROWS'), >> 1: ('HAPPY', 'ALL_CLOCKS'), >> 2: ('SURPRISED', 'CONFUSED'), >> 3: ('SNAKE', 'PACMAN'), >> 4: ('BUTTERFLY', 'COW'), >> 5: ('FABULOUS', 'SAD'), >> 6: ('SILLY', 'SMILE')}[me] >> a_image, b_image = (eval('Image.' + name) for name in (a_name, >> b_name)) >> >> >> # A show function that does not wait >> def show(x): display.show(x, delay=100, wait=False) >> show(a_image) >> >> # Create the "flash" animation frames. Can you work out how >> it's done? >> flash_animation = [Image().invert()*(i/9) for i in range(9, >> -1, -1)] >> >> # Timing is controlled with these global variables >> time = 0 # Current time >> flash_time = -1 # Time to flash LEDs >> reflash_time = -1 # Time to flash others >> >> >> # Define the "flash" function. >> def flash(): >> "Display the firefly flash animation after a random >> short pause" >> global time, flash_time, reflash_time >> flash_time = time + random.randint(50, 350) >> if random.randint(0, flock_size) == 0: >> reflash_time = flash_time + 500 >> >> >> # The step function decides what to do next >> def step(): >> global time, flash_time, reflash_time >> # Button A and B changes image. >> if button_a.was_pressed(): >> send('show(Image.%s)' % a_name) >> show(a_image) >> reflash_time = time # Reflash now! >> if button_b.was_pressed(): >> send('show(Image.%s)' % b_name) >> show(b_image) >> reflash_time = time # Reflash now! >> # Read any incoming messages. >> try: >> incoming_message = receive() >> except ValueError: >> pass >> if incoming_message: >> print(incoming_message) >> if incoming_message[:3] != 'On ': >> try: >> exec(incoming_message, globals(), globals()) >> except Exception as e: >> send("On %d: %s" % (me, e)) >> if time == flash_time: >> show(flash_animation) >> if time == reflash_time: >> send('flash()') # a-ha >> sleep(1) # Pause 1 ms >> time = time + 1 # Now it's time for next step >> >> # The radio won't work unless it's switched on. >> on() >> >> # Infinite loop >> while True: >> try: >> step() >> except Exception as e: >> print(e) >> >> # For the virus author: >> # Send <20 character strings containing new code ;-)! >> >> >> >> >> >> >> >> >> >> -- >> Radomir Dopieralski >> >> >> _______________________________________________ >> 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 >> > > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From joakimbits at gmail.com Wed Oct 19 14:15:00 2016 From: joakimbits at gmail.com (Joakim Pettersson) Date: Wed, 19 Oct 2016 18:15:00 +0000 Subject: [Microbit-Python] mu vs microbit.co.uk/create-code API differences In-Reply-To: <6f02488d-c56c-f1c1-fd34-ebd85ffb8d56@ntoll.org> Message-ID: Hi Nick & Carlos, Great that the microbit.org is up and hopefully more compatible with Mu - thanks for the new pointer! /joakim ------ Originalmeddelande ------ Fr?n: "Nicholas H.Tollervey" Till: microbit at python.org Skickat: 2016-10-19 15:23:09 ?mne: Re: [Microbit-Python] mu vs microbit.co.uk/create-code API differences >I forgot to mention - the BBC won't let me deploy the latest version of >the editor for tedious bureaucratic reasons. You can't believe how >frustrating this feels and I hope it certainly doesn't reflect on the >efforts of the Python community to create, share and promote freely >available resources. > >:-/ > >Joakim, please don't hesitate to ask questions or ask for help. The >Python community is incredibly generous with their time and passionate >about education. > >Basically, you have allies! > >N. > >On 19/10/16 14:18, Nicholas H.Tollervey wrote: >> Carlos, >> >> You beat me to it! >> >> http://python.microbit.org/editor.html has the latest version. >> >> Also, the source code for the editor is open source and can be found >>here: >> >> https://github.com/bbcmicrobit/PythonEditor >> >> Hope this helps, >> >> N. >> >> On 19/10/16 14:16, Carlos Pereira Atencio wrote: >>> Now that the foundation has been announced, the http://microbit.org >>> website (note the change from .co.uk to .org) should >>> contain the newest version of the online editor . So if you go to >>> http://python.microbit.org/editor.html it should contain the latest >>> micropython. >>> >>> On 19 October 2016 at 13:17, Joakim Pettersson >> > wrote: >>> >>> Aha, that's why - thanks for the explanation! >>> Agree one should not eval, but this demo is about daring using >>>the >>> parser-interpreter so it's ok! >>> Note the exec in globals() later on;). >>> /joakim >>> >>> ------ Originalmeddelande ------ >>> Fr?n: "Radomir Dopieralski" >> > >>> Till: microbit at python.org >>> Kopia: "Joakim Pettersson" >> > >>> Skickat: 2016-10-19 14:11:13 >>> ?mne: Re: [Microbit-Python] mu vs microbit.co.uk/create-code >>> API differences >>> >>> >>> Hi, >>> >>> the version of MicroPython at the microbit website is >>>outdated, >>> because it >>> takes BBC a very long time to upgrade it. The Mu editor >>>comes >>> with the latest >>> release, because it's in control of the developers. >>> >>> One note about your code. You *really* don't want to use >>>eval(). >>> I would use >>> the getattr() function in its place, like this: >>> >>> a_image, b_image = getattr(Image, name) for name in (a_name, >>>b_name) >>> >>> >>> On Wed, 19 Oct 2016 12:00:42 +0000 >>> "Joakim Pettersson" >> > wrote: >>> >>> Hi, >>> >>> I stumped into problems with the online editor. >>> Which documentation should I read to figure out the >>>API? >>> Why is that micropython implementation different from >>>the >>> one used by >>> the mu editor? >>> >>> Here is code that works in the mu editor but fails when >>> dowloading >>> from https://www.microbit.co.uk/app/# >>> (probably on the >>>third >>> line but >>> how do I tell?). The code was running a swarm of 8 >>> micro:bit at a >>> student-industry event this Monday. I used it also to >>>pitch >>> micro:bit >>> to the Swedish prime minister when he received one >>>there:). >>> >>> Thanks/Joakim >>> >>> # A micro:bit virus-infectable Firefly. >>> # mailto:Joakim.Pettersson at join.se >>> >>> >>> from radio import send, receive, on >>> import random >>> from microbit import display, Image, button_a, >>>button_b, sleep >>> >>> flock_size = 3 # Number of fireflies required for >>>flock >>> behaviour >>> me = 2 # My lucky number >>> a_name, b_name = { >>> 0: ('HEART', 'ALL_ARROWS'), >>> 1: ('HAPPY', 'ALL_CLOCKS'), >>> 2: ('SURPRISED', 'CONFUSED'), >>> 3: ('SNAKE', 'PACMAN'), >>> 4: ('BUTTERFLY', 'COW'), >>> 5: ('FABULOUS', 'SAD'), >>> 6: ('SILLY', 'SMILE')}[me] >>> a_image, b_image = (eval('Image.' + name) for name in >>>(a_name, >>> b_name)) >>> >>> >>> # A show function that does not wait >>> def show(x): display.show(x, delay=100, wait=False) >>> show(a_image) >>> >>> # Create the "flash" animation frames. Can you work out >>>how >>> it's done? >>> flash_animation = [Image().invert()*(i/9) for i in >>>range(9, >>> -1, -1)] >>> >>> # Timing is controlled with these global variables >>> time = 0 # Current time >>> flash_time = -1 # Time to flash LEDs >>> reflash_time = -1 # Time to flash others >>> >>> >>> # Define the "flash" function. >>> def flash(): >>> "Display the firefly flash animation after a >>>random >>> short pause" >>> global time, flash_time, reflash_time >>> flash_time = time + random.randint(50, 350) >>> if random.randint(0, flock_size) == 0: >>> reflash_time = flash_time + 500 >>> >>> >>> # The step function decides what to do next >>> def step(): >>> global time, flash_time, reflash_time >>> # Button A and B changes image. >>> if button_a.was_pressed(): >>> send('show(Image.%s)' % a_name) >>> show(a_image) >>> reflash_time = time # Reflash now! >>> if button_b.was_pressed(): >>> send('show(Image.%s)' % b_name) >>> show(b_image) >>> reflash_time = time # Reflash now! >>> # Read any incoming messages. >>> try: >>> incoming_message = receive() >>> except ValueError: >>> pass >>> if incoming_message: >>> print(incoming_message) >>> if incoming_message[:3] != 'On ': >>> try: >>> exec(incoming_message, globals(), >>>globals()) >>> except Exception as e: >>> send("On %d: %s" % (me, e)) >>> if time == flash_time: >>> show(flash_animation) >>> if time == reflash_time: >>> send('flash()') # a-ha >>> sleep(1) # Pause 1 ms >>> time = time + 1 # Now it's time for next step >>> >>> # The radio won't work unless it's switched on. >>> on() >>> >>> # Infinite loop >>> while True: >>> try: >>> step() >>> except Exception as e: >>> print(e) >>> >>> # For the virus author: >>> # Send <20 character strings containing new code ;-)! >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> -- >>> Radomir Dopieralski >>> >>> >>> _______________________________________________ >>> 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 >>> >> >> >> >> >> _______________________________________________ >> Microbit mailing list >> Microbit at python.org >> https://mail.python.org/mailman/listinfo/microbit >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mal at egenix.com Wed Oct 19 15:48:50 2016 From: mal at egenix.com (M.-A. Lemburg) Date: Wed, 19 Oct 2016 21:48:50 +0200 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: <5807527C.5090907@egenix.com> Message-ID: <5807CE22.2040707@egenix.com> On 19.10.2016 13:05, Carlos Pereira Atencio wrote: > Are you sure that's right? I would have assumed Farnell could export them > just like any other product. It's also gaining popularity in Finland, so > they must be getting their boards somehow... The MBs are not available in the German version of their shop and ordering from the UK one results in a redirect to their export site mentioning that you have to contact the export team and cannot order online. Perhaps the restrictions are limited to only a few countries. I tried their Polish shop and this says: """ Thank you for your interest in BBC micro:bit however it is currently not available for sale. element14 are launching BBC micro:bit for sale in the UK, and are working with the partners for a further roll out around the world in due course """ I suppose that some shops in the UK resell the MBs and ship them elsewhere, but assume this is not done with official permission from whoever is blocking this for Farnell. > On 19 October 2016 at 12:01, M.-A. Lemburg wrote: > >> On 19.10.2016 12:49, Nigel Kendrick wrote: >>> http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ >>> http://calliope.cc/ueber-mini (German) >>> >>> Let the clone wars..etc. >> >> I believe the main reason for such developments is that it's >> still not possible to (legally) order MBs outside the UK. >> >> I do wonder what is holding up EU- and world-wide sales >> of the device. >> >> -- >> Marc-Andre Lemburg >> eGenix.com >> >> Professional Python Services directly from the Experts >>>>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>>>> Python Database Interfaces ... http://products.egenix.com/ >>>>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ >> ________________________________________________________________________ >> >> ::::: Try our mxODBC.Connect Python Database Interface for free ! :::::: >> >> eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 >> D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg >> Registered at Amtsgericht Duesseldorf: HRB 46611 >> http://www.egenix.com/company/contact/ >> _______________________________________________ >> 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 > -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>> Python Database Interfaces ... http://products.egenix.com/ >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ ________________________________________________________________________ ::::: Try our mxODBC.Connect Python Database Interface for free ! :::::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ From sparks.m at gmail.com Wed Oct 19 16:56:28 2016 From: sparks.m at gmail.com (Michael) Date: Wed, 19 Oct 2016 21:56:28 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: Clone wars? I prefer phrases like More The Merrier; Infinite diversity, infinite combination. And must admit I bounced around like a kid at Christmas when I saw it :-) Michael. On 19 October 2016 at 11:49, Nigel Kendrick wrote: > http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ > http://calliope.cc/ueber-mini (German) > > Let the clone wars..etc. > > -- Nigel > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sparks.m at gmail.com Wed Oct 19 16:58:40 2016 From: sparks.m at gmail.com (Michael) Date: Wed, 19 Oct 2016 21:58:40 +0100 Subject: [Microbit-Python] Micro:bit clone, anyone!? In-Reply-To: References: Message-ID: I spoke to the japanese Chibi:bit people via twitter and the reason for changing the bluetooth/radio was to do with Japan's equivalent for radio certification. Michael. On 19 October 2016 at 12:02, Carlos Pereira Atencio wrote: > And it looks it'll be pin compatible as well, so the same micropython > programs should run in both boards. > > Also Switch Science in Japan also created a slightly different version > (can't remember exactly why, but they had to change the bluetooth/radio): > https://www.switch-science.com/catalog/2778/ > > On 19 October 2016 at 11:50, Nicholas H.Tollervey wrote: > >> On 19/10/16 11:49, Nigel Kendrick wrote: >> > http://hackaday.com/2016/10/18/germans-react-to-uks-microbit/ >> > http://calliope.cc/ueber-mini (German) >> > >> > Let the clone wars..etc. >> > >> > -- Nigel >> > >> > >> > _______________________________________________ >> > Microbit mailing list >> > Microbit at python.org >> > https://mail.python.org/mailman/listinfo/microbit >> > >> >> This is a good thing. It runs MicroPython. >> >> 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: From brucepiggott at ntlworld.com Fri Oct 21 09:06:36 2016 From: brucepiggott at ntlworld.com (Piggott BRUCE) Date: Fri, 21 Oct 2016 14:06:36 +0100 (BST) Subject: [Microbit-Python] Hard copy of script files Message-ID: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Can anybody tell me how to print out a Microbit script file as hard copy. Regards, Bruce Piggott -------------- next part -------------- An HTML attachment was scrubbed... URL: From microbit at sheep.art.pl Fri Oct 21 10:04:17 2016 From: microbit at sheep.art.pl (Radomir Dopieralski) Date: Fri, 21 Oct 2016 16:04:17 +0200 Subject: [Microbit-Python] Hard copy of script files In-Reply-To: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> References: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Message-ID: <20161021160417.75c53d9b@ghostwheel> It's just a text file, so whatever you do to print those should work. On Fri, 21 Oct 2016 14:06:36 +0100 (BST) Piggott BRUCE wrote: > Can anybody tell me how to print out a Microbit script file as hard > copy. -- Radomir Dopieralski From ntoll at ntoll.org Fri Oct 21 10:06:14 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Fri, 21 Oct 2016 15:06:14 +0100 Subject: [Microbit-Python] Hard copy of script files In-Reply-To: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> References: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Message-ID: On 21/10/16 14:06, Piggott BRUCE wrote: > Can anybody tell me how to print out a Microbit script file as hard copy. > > Regards, Bruce Piggott > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > Hi Bruce, It could just be as simple as cutting and pasting your script into an application that has a print button. (Sorry if this is stating the blindingly obvious). However, and a word of caution, if you paste your script into a word processor like Microsoft Word, it'll try to re-format your code. Also, make sure you format the code in a fixed width font to make it readable. If you're on Windows you could just use Notepad. Hope this helps, N. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From brucepiggott at ntlworld.com Fri Oct 21 10:19:21 2016 From: brucepiggott at ntlworld.com (Piggott BRUCE) Date: Fri, 21 Oct 2016 15:19:21 +0100 (BST) Subject: [Microbit-Python] Hard copy of script files In-Reply-To: References: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Message-ID: <122294753.921764.1477059561765.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Thanks for that N, That works but all the nice formatting and colours are removed! Guess that'll have to do. Cheers, Bruce > > On 21 October 2016 at 15:06 "Nicholas H.Tollervey" > wrote: > > > On 21/10/16 14:06, Piggott BRUCE wrote: > > Can anybody tell me how to print out a Microbit script file as hard > > copy. > > > > Regards, Bruce Piggott > > > > > > > > _______________________________________________ > > Microbit mailing list > > Microbit at python.org > > https://mail.python.org/mailman/listinfo/microbit > > > > Hi Bruce, > > It could just be as simple as cutting and pasting your script into an > application that has a print button. (Sorry if this is stating the > blindingly obvious). > > However, and a word of caution, if you paste your script into a word > processor like Microsoft Word, it'll try to re-format your code. Also, > make sure you format the code in a fixed width font to make it readable. > > If you're on Windows you could just use Notepad. > > Hope this helps, > > N. > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sparks.m at gmail.com Fri Oct 21 10:52:02 2016 From: sparks.m at gmail.com (Michael) Date: Fri, 21 Oct 2016 15:52:02 +0100 Subject: [Microbit-Python] Hard copy of script files In-Reply-To: <122294753.921764.1477059561765.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> References: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> <122294753.921764.1477059561765.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Message-ID: Hi, More faff route that leaves everything still pretty formatted with colours (and doesn't use any particularly special tools :) ): 1. Select the program you want to print. 2. Open pastebin.com in a browser 3. Paste your program into the obvious box. 4. Below the pastebox, select "python" for syntaxt highlighting 5. Select "unlisted" (or private if you signin) 6. Hit submit 7. See your pretty printed program. You could hit print at this stage. 8. Select just your pretty printed program in the browser, and hit copy. 9. In open office or word, paste. 10. Print. (or export as PDF and print) (I'd personally just copy into kate and hit "print", but I'm guessing you're not using Linux) Michael On 21 October 2016 at 15:19, Piggott BRUCE wrote: > Thanks for that N, > > That works but all the nice formatting and colours are removed! > > Guess that'll have to do. > > Cheers, Bruce > > On 21 October 2016 at 15:06 "Nicholas H.Tollervey" > wrote: > > > On 21/10/16 14:06, Piggott BRUCE wrote: > > Can anybody tell me how to print out a Microbit script file as hard copy. > > > > Regards, Bruce Piggott > > > > > > > > _______________________________________________ > > Microbit mailing list > > Microbit at python.org > > https://mail.python.org/mailman/listinfo/microbit > > > > Hi Bruce, > > It could just be as simple as cutting and pasting your script into an > application that has a print button. (Sorry if this is stating the > blindingly obvious). > > However, and a word of caution, if you paste your script into a word > processor like Microsoft Word, it'll try to re-format your code. Also, > make sure you format the code in a fixed width font to make it readable. > > If you're on Windows you could just use Notepad. > > Hope this helps, > > 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: From david at thinkingbinaries.com Fri Oct 21 11:02:02 2016 From: david at thinkingbinaries.com (David Whale) Date: Fri, 21 Oct 2016 16:02:02 +0100 Subject: [Microbit-Python] Hard copy of script files In-Reply-To: References: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> <122294753.921764.1477059561765.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Message-ID: You could try using this tool to beautify it inside a web page, and then just hit the print button: http://www.cleancss.com/python-beautify/ On 21 October 2016 at 15:52, Michael wrote: > Hi, > > > More faff route that leaves everything still pretty formatted with colours > (and doesn't use any particularly special tools :) ): > > 1. Select the program you want to print. > 2. Open pastebin.com in a browser > 3. Paste your program into the obvious box. > 4. Below the pastebox, select "python" for syntaxt highlighting > 5. Select "unlisted" (or private if you signin) > 6. Hit submit > 7. See your pretty printed program. You could hit print at this stage. > 8. Select just your pretty printed program in the browser, and hit copy. > 9. In open office or word, paste. > 10. Print. (or export as PDF and print) > > (I'd personally just copy into kate and hit "print", but I'm guessing > you're not using Linux) > > > Michael > > On 21 October 2016 at 15:19, Piggott BRUCE > wrote: > >> Thanks for that N, >> >> That works but all the nice formatting and colours are removed! >> >> Guess that'll have to do. >> >> Cheers, Bruce >> >> On 21 October 2016 at 15:06 "Nicholas H.Tollervey" >> wrote: >> >> >> On 21/10/16 14:06, Piggott BRUCE wrote: >> > Can anybody tell me how to print out a Microbit script file as hard >> copy. >> > >> > Regards, Bruce Piggott >> > >> > >> > >> > _______________________________________________ >> > Microbit mailing list >> > Microbit at python.org >> > https://mail.python.org/mailman/listinfo/microbit >> > >> >> Hi Bruce, >> >> It could just be as simple as cutting and pasting your script into an >> application that has a print button. (Sorry if this is stating the >> blindingly obvious). >> >> However, and a word of caution, if you paste your script into a word >> processor like Microsoft Word, it'll try to re-format your code. Also, >> make sure you format the code in a fixed width font to make it readable. >> >> If you're on Windows you could just use Notepad. >> >> Hope this helps, >> >> 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 >> >> > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From brucepiggott at ntlworld.com Sat Oct 22 10:44:58 2016 From: brucepiggott at ntlworld.com (Piggott BRUCE) Date: Sat, 22 Oct 2016 15:44:58 +0100 (BST) Subject: [Microbit-Python] Hard copy of script files In-Reply-To: References: <585256804.918546.1477055196496.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> <122294753.921764.1477059561765.JavaMail.open-xchange@oxbe7.tb.ukmail.iss.as9143.net> Message-ID: <779341112.924290.1477147498378.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Thanks for that. I will try. Cheers, Bruce > On 21 October 2016 at 16:02 David Whale wrote: > > You could try using this tool to beautify it inside a web page, and then > just hit the print button: > > http://www.cleancss.com/python-beautify/ > > > > On 21 October 2016 at 15:52, Michael mailto:sparks.m at gmail.com > wrote: > > > > Hi, > > > > > > More faff route that leaves everything still pretty formatted with > > colours (and doesn't use any particularly special tools :) ): > > > > 1. Select the program you want to print. > > 2. Openhttp://pastebin.com in a browser > > 3. Paste your program into the obvious box. > > 4. Below the pastebox, select "python" for syntaxt highlighting > > 5. Select "unlisted" (or private if you signin) > > 6. Hit submit > > 7. See your pretty printed program. You could hit print at this > > stage. > > 8. Select just your pretty printed program in the browser, and hit > > copy. > > 9. In open office or word, paste. > > 10. Print. (or export as PDF and print) > > > > (I'd personally just copy into kate and hit "print", but I'm > > guessing you're not using Linux) > > > > > > Michael > > > > On 21 October 2016 at 15:19, Piggott BRUCE > > wrote: > > > > > > > > > > Thanks for that N, > > > > > > That works but all the nice formatting and colours are > > > removed! > > > > > > Guess that'll have to do. > > > > > > Cheers, Bruce > > > > > > > > > > > > > > On 21 October 2016 at 15:06 "Nicholas H.Tollervey" > > > > wrote: > > > > > > > > > > > > On 21/10/16 14:06, Piggott BRUCE wrote: > > > > > Can anybody tell me how to print out a Microbit script > > > > > file as hard copy. > > > > > > > > > > Regards, Bruce Piggott > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > Microbit mailing list > > > > > Microbit at python.org mailto:Microbit at python.org > > > > > https://mail.python.org/mailman/listinfo/microbit > > > > > https://mail.python.org/mailman/listinfo/microbit > > > > > > > > > > > > > Hi Bruce, > > > > > > > > It could just be as simple as cutting and pasting your > > > > script into an > > > > application that has a print button. (Sorry if this is > > > > stating the > > > > blindingly obvious). > > > > > > > > However, and a word of caution, if you paste your script > > > > into a word > > > > processor like Microsoft Word, it'll try to re-format > > > > your code. Also, > > > > make sure you format the code in a fixed width font to > > > > make it readable. > > > > > > > > If you're on Windows you could just use Notepad. > > > > > > > > Hope this helps, > > > > > > > > N. > > > > > > > > _______________________________________________ > > > > Microbit mailing list > > > > Microbit at python.org mailto:Microbit at python.org > > > > https://mail.python.org/mailman/listinfo/microbit > > > > https://mail.python.org/mailman/listinfo/microbit > > > > > > > > > > > > > > _______________________________________________ > > > Microbit mailing list > > > Microbit at python.org mailto:Microbit at python.org > > > https://mail.python.org/mailman/listinfo/microbit > > > https://mail.python.org/mailman/listinfo/microbit > > > > > > > > > > > > > > > _______________________________________________ > > Microbit mailing list > > Microbit at python.org mailto:Microbit at python.org > > https://mail.python.org/mailman/listinfo/microbit > > 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: From brucepiggott at ntlworld.com Sat Oct 22 10:54:50 2016 From: brucepiggott at ntlworld.com (Piggott BRUCE) Date: Sat, 22 Oct 2016 15:54:50 +0100 (BST) Subject: [Microbit-Python] Non volatile storage Message-ID: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Hi Guys. I'm having a problem finding the correct instruction for storing non volatile data in the microbit module. I need to store a variable collected during run time that is available on next power up. I know I need to create a file of some sort and have searched the web for how to do this but everything I have found does not work. Can anybody give me a simple example of how to create a file of data that is available after a subsequent power up? Cheers, Bruce -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Sat Oct 22 11:24:46 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Sat, 22 Oct 2016 16:24:46 +0100 Subject: [Microbit-Python] Non volatile storage In-Reply-To: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Message-ID: <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> It's all in the documentation here: https://microbit-micropython.readthedocs.io/en/latest/tutorials/storage.html Hope this helps, N. On 22/10/16 15:54, Piggott BRUCE wrote: > Hi Guys. > > I'm having a problem finding the correct instruction for storing non > volatile data in the microbit module. > > I need to store a variable collected during run time that is available > on next power up. > > I know I need to create a file of some sort and/ /have searched the web > for how to do this but everything I have found does not work. > > Can anybody give me a simple example of how to create a file of data > that is available after a subsequent power up? > > Cheers, Bruce > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From brucepiggott at ntlworld.com Sat Oct 22 11:52:53 2016 From: brucepiggott at ntlworld.com (Piggott BRUCE) Date: Sat, 22 Oct 2016 16:52:53 +0100 (BST) Subject: [Microbit-Python] Non volatile storage In-Reply-To: <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> Message-ID: <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Thanks for that but I have already tried that and it does not work. I copied the example and tried it: # test of non volatile storage from microbit import * with open('story.txt') as my_file: content = my_file.read() print(content) I get line 5 attribute error, etc Try it yourself. I have been trying to solve this for 3 days now! This for the BBC micro:bit using micropython Cheers, Bruce > > On 22 October 2016 at 16:24 "Nicholas H.Tollervey" > wrote: > > > It's all in the documentation here: > > > https://microbit-micropython.readthedocs.io/en/latest/tutorials/storage.html > > Hope this helps, > > N. > > On 22/10/16 15:54, Piggott BRUCE wrote: > > Hi Guys. > > > > I'm having a problem finding the correct instruction for storing non > > volatile data in the microbit module. > > > > I need to store a variable collected during run time that is available > > on next power up. > > > > I know I need to create a file of some sort and/ /have searched the web > > for how to do this but everything I have found does not work. > > > > Can anybody give me a simple example of how to create a file of data > > that is available after a subsequent power up? > > > > Cheers, Bruce > > > > > > > > _______________________________________________ > > 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: From ben at benmr.com Sat Oct 22 12:06:29 2016 From: ben at benmr.com (Ben Mustill-Rose) Date: Sat, 22 Oct 2016 17:06:29 +0100 Subject: [Microbit-Python] Non volatile storage In-Reply-To: <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Message-ID: Hi, Does story.txt exist on your micro:bit? Cheers, Ben. On 10/22/16, Piggott BRUCE wrote: > Thanks for that but I have already tried that and it does not work. > > I copied the example and tried it: > > > # test of non volatile storage > > from microbit import * > > with open('story.txt') as my_file: > content = my_file.read() > print(content) > > I get line 5 attribute error, etc > > > Try it yourself. > > I have been trying to solve this for 3 days now! > > This for the BBC micro:bit using micropython > > Cheers, Bruce > > >> >> On 22 October 2016 at 16:24 "Nicholas H.Tollervey" >> wrote: >> >> >> It's all in the documentation here: >> >> >> >> https://microbit-micropython.readthedocs.io/en/latest/tutorials/storage.html >> >> Hope this helps, >> >> N. >> >> On 22/10/16 15:54, Piggott BRUCE wrote: >> > Hi Guys. >> > >> > I'm having a problem finding the correct instruction for storing >> non >> > volatile data in the microbit module. >> > >> > I need to store a variable collected during run time that is >> available >> > on next power up. >> > >> > I know I need to create a file of some sort and/ /have searched the >> web >> > for how to do this but everything I have found does not work. >> > >> > Can anybody give me a simple example of how to create a file of >> data >> > that is available after a subsequent power up? >> > >> > Cheers, Bruce >> > >> > >> > >> > _______________________________________________ >> > 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 >> From david at thinkingbinaries.com Sat Oct 22 12:45:29 2016 From: david at thinkingbinaries.com (David Whale) Date: Sat, 22 Oct 2016 17:45:29 +0100 Subject: [Microbit-Python] Non volatile storage In-Reply-To: References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Message-ID: Are you using an up to date version of the Mu editor, or the BBC website? On 22 Oct 2016 5:06 pm, "Ben Mustill-Rose" wrote: > Hi, > > Does story.txt exist on your micro:bit? > > Cheers, > Ben. > > On 10/22/16, Piggott BRUCE wrote: > > Thanks for that but I have already tried that and it does not work. > > > > I copied the example and tried it: > > > > > > # test of non volatile storage > > > > from microbit import * > > > > with open('story.txt') as my_file: > > content = my_file.read() > > print(content) > > > > I get line 5 attribute error, etc > > > > > > Try it yourself. > > > > I have been trying to solve this for 3 days now! > > > > This for the BBC micro:bit using micropython > > > > Cheers, Bruce > > > > > >> > >> On 22 October 2016 at 16:24 "Nicholas H.Tollervey" > > >> wrote: > >> > >> > >> It's all in the documentation here: > >> > >> > >> > >> https://microbit-micropython.readthedocs.io/en/latest/ > tutorials/storage.html > >> > >> Hope this helps, > >> > >> N. > >> > >> On 22/10/16 15:54, Piggott BRUCE wrote: > >> > Hi Guys. > >> > > >> > I'm having a problem finding the correct instruction for storing > >> non > >> > volatile data in the microbit module. > >> > > >> > I need to store a variable collected during run time that is > >> available > >> > on next power up. > >> > > >> > I know I need to create a file of some sort and/ /have searched > the > >> web > >> > for how to do this but everything I have found does not work. > >> > > >> > Can anybody give me a simple example of how to create a file of > >> data > >> > that is available after a subsequent power up? > >> > > >> > Cheers, Bruce > >> > > >> > > >> > > >> > _______________________________________________ > >> > 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 > >> > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- An HTML attachment was scrubbed... URL: From brucepiggott at ntlworld.com Sat Oct 22 13:19:22 2016 From: brucepiggott at ntlworld.com (Piggott BRUCE) Date: Sat, 22 Oct 2016 18:19:22 +0100 (BST) Subject: [Microbit-Python] Non volatile storage In-Reply-To: References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Message-ID: <877508348.928195.1477156762101.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> I am using the BBC website. Is that the problem? I don't think I have story.txt on my microbit. Can anybody give me a simple program that creates and stores a constant that can be retrieved after a subsequent power up? Cheers, Bruce > On 22 October 2016 at 17:45 David Whale wrote: > > > Are you using an up to date version of the Mu editor, or the BBC website? > > > On 22 Oct 2016 5:06 pm, "Ben Mustill-Rose" mailto:ben at benmr.com > wrote: > > > > Hi, > > > > Does story.txt exist on your micro:bit? > > > > Cheers, > > Ben. > > > > On 10/22/16, Piggott BRUCE > mailto:brucepiggott at ntlworld.com > wrote: > > > Thanks for that but I have already tried that and it does not > > > work. > > > > > > I copied the example and tried it: > > > > > > > > > # test of non volatile storage > > > > > > from microbit import * > > > > > > with open('story.txt') as my_file: > > > content = my_file.read() > > > print(content) > > > > > > I get line 5 attribute error, etc > > > > > > > > > Try it yourself. > > > > > > I have been trying to solve this for 3 days now! > > > > > > This for the BBC micro:bit using micropython > > > > > > Cheers, Bruce > > > > > > > > >> > > >> On 22 October 2016 at 16:24 "Nicholas H.Tollervey" > > >> > > >> wrote: > > >> > > >> > > >> It's all in the documentation here: > > >> > > >> > > >> > > >> https://microbit-micropython.readthedocs.io/en/latest/tutorials/storage.html > > >> https://microbit-micropython.readthedocs.io/en/latest/tutorials/storage.html > > >> > > >> Hope this helps, > > >> > > >> N. > > >> > > >> On 22/10/16 15:54, Piggott BRUCE wrote: > > >> > Hi Guys. > > >> > > > >> > I'm having a problem finding the correct instruction for > > >> > storing > > >> non > > >> > volatile data in the microbit module. > > >> > > > >> > I need to store a variable collected during run time that > > >> > is > > >> available > > >> > on next power up. > > >> > > > >> > I know I need to create a file of some sort and/ /have > > >> > searched the > > >> web > > >> > for how to do this but everything I have found does not > > >> > work. > > >> > > > >> > Can anybody give me a simple example of how to create a > > >> > file of > > >> data > > >> > that is available after a subsequent power up? > > >> > > > >> > Cheers, Bruce > > >> > > > >> > > > >> > > > >> > _______________________________________________ > > >> > Microbit mailing list > > >> > Microbit at python.org mailto:Microbit at python.org > > >> > https://mail.python.org/mailman/listinfo/microbit > > >> > https://mail.python.org/mailman/listinfo/microbit > > >> > > > >> > > >> > > >> _______________________________________________ > > >> Microbit mailing list > > >> Microbit at python.org mailto:Microbit at python.org > > >> https://mail.python.org/mailman/listinfo/microbit > > >> https://mail.python.org/mailman/listinfo/microbit > > >> > > _______________________________________________ > > Microbit mailing list > > Microbit at python.org mailto:Microbit at python.org > > https://mail.python.org/mailman/listinfo/microbit > > 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: From david at thinkingbinaries.com Sat Oct 22 13:25:01 2016 From: david at thinkingbinaries.com (David Whale) Date: Sat, 22 Oct 2016 18:25:01 +0100 Subject: [Microbit-Python] Non volatile storage In-Reply-To: <877508348.928195.1477156762101.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <877508348.928195.1477156762101.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Message-ID: Hi Bruce, Yes, that will be the problem. The version of MicroPython on the BBC website is updated on a much slower schedule than the version inside the Mu editor, and as such, does not have a number of the new features. Your best bet is to go to codewith.mu and download one of the prebuilt packages for your platform and use that, as it will have the latest code (including radio, speech, music, singing and filing system) inside it. Also Mu has a FILES button that you can use to drag and drop files to and from the micro:bit file system, and a REPL button that allows you to interact live with your Python code. David On 22 October 2016 at 18:19, Piggott BRUCE wrote: > I am using the BBC website. > > Is that the problem? > > I don't think I have story.txt on my microbit. > > Can anybody give me a simple program that creates and stores a constant > that can be retrieved after a subsequent power up? > > Cheers, Bruce > > On 22 October 2016 at 17:45 David Whale > wrote: > > Are you using an up to date version of the Mu editor, or the BBC website? > > On 22 Oct 2016 5:06 pm, "Ben Mustill-Rose" wrote: > > Hi, > > Does story.txt exist on your micro:bit? > > Cheers, > Ben. > > On 10/22/16, Piggott BRUCE wrote: > > Thanks for that but I have already tried that and it does not work. > > > > I copied the example and tried it: > > > > > > # test of non volatile storage > > > > from microbit import * > > > > with open('story.txt') as my_file: > > content = my_file.read() > > print(content) > > > > I get line 5 attribute error, etc > > > > > > Try it yourself. > > > > I have been trying to solve this for 3 days now! > > > > This for the BBC micro:bit using micropython > > > > Cheers, Bruce > > > > > >> > >> On 22 October 2016 at 16:24 "Nicholas H.Tollervey" > > >> wrote: > >> > >> > >> It's all in the documentation here: > >> > >> > >> > >> https://microbit-micropython.readthedocs.io/en/latest/tutori > als/storage.html > >> > >> Hope this helps, > >> > >> N. > >> > >> On 22/10/16 15:54, Piggott BRUCE wrote: > >> > Hi Guys. > >> > > >> > I'm having a problem finding the correct instruction for storing > >> non > >> > volatile data in the microbit module. > >> > > >> > I need to store a variable collected during run time that is > >> available > >> > on next power up. > >> > > >> > I know I need to create a file of some sort and/ /have searched > the > >> web > >> > for how to do this but everything I have found does not work. > >> > > >> > Can anybody give me a simple example of how to create a file of > >> data > >> > that is available after a subsequent power up? > >> > > >> > Cheers, Bruce > >> > > >> > > >> > > >> > _______________________________________________ > >> > 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 > >> > _______________________________________________ > 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 > > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From david at thinkingbinaries.com Sat Oct 22 13:27:35 2016 From: david at thinkingbinaries.com (David Whale) Date: Sat, 22 Oct 2016 18:27:35 +0100 Subject: [Microbit-Python] Non volatile storage In-Reply-To: References: <478764929.924534.1477148090274.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <0f1f725f-1d4f-109c-9857-d41186abd237@ntoll.org> <455048747.925983.1477151573816.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> <877508348.928195.1477156762101.JavaMail.open-xchange@oxbe16.tb.ukmail.iss.as9143.net> Message-ID: P.S. the FILES button shows two browsers, one on the left is the micro:bit file system, one on the right is your PC/Mac/Pi filesystem (whatever platform you are using). So for example, on my mac, if I go into my home folder, inside that is a folder called python. I put a file called story.txt in that folder. Then I flash the .py program into the micro:bit using the FLASH button. Then I press the FILES button, and I see story.txt on the right pane. Drag and drop that to the left pane, and the file appears. Now press the reset button on your micro:bit and it will run your code, and successfully read and process the file. David On 22 October 2016 at 18:25, David Whale wrote: > Hi Bruce, > > Yes, that will be the problem. The version of MicroPython on the BBC > website is updated on a much slower schedule than the version inside the Mu > editor, and as such, does not have a number of the new features. > > Your best bet is to go to codewith.mu and download one of the prebuilt > packages for your platform and use that, as it will have the latest code > (including radio, speech, music, singing and filing system) inside it. > > Also Mu has a FILES button that you can use to drag and drop files to and > from the micro:bit file system, and a REPL button that allows you to > interact live with your Python code. > > David > > > > > On 22 October 2016 at 18:19, Piggott BRUCE > wrote: > >> I am using the BBC website. >> >> Is that the problem? >> >> I don't think I have story.txt on my microbit. >> >> Can anybody give me a simple program that creates and stores a constant >> that can be retrieved after a subsequent power up? >> >> Cheers, Bruce >> >> On 22 October 2016 at 17:45 David Whale >> wrote: >> >> Are you using an up to date version of the Mu editor, or the BBC website? >> >> On 22 Oct 2016 5:06 pm, "Ben Mustill-Rose" wrote: >> >> Hi, >> >> Does story.txt exist on your micro:bit? >> >> Cheers, >> Ben. >> >> On 10/22/16, Piggott BRUCE wrote: >> > Thanks for that but I have already tried that and it does not work. >> > >> > I copied the example and tried it: >> > >> > >> > # test of non volatile storage >> > >> > from microbit import * >> > >> > with open('story.txt') as my_file: >> > content = my_file.read() >> > print(content) >> > >> > I get line 5 attribute error, etc >> > >> > >> > Try it yourself. >> > >> > I have been trying to solve this for 3 days now! >> > >> > This for the BBC micro:bit using micropython >> > >> > Cheers, Bruce >> > >> > >> >> >> >> On 22 October 2016 at 16:24 "Nicholas H.Tollervey" < >> ntoll at ntoll.org> >> >> wrote: >> >> >> >> >> >> It's all in the documentation here: >> >> >> >> >> >> >> >> https://microbit-micropython.readthedocs.io/en/latest/tutori >> als/storage.html >> >> >> >> Hope this helps, >> >> >> >> N. >> >> >> >> On 22/10/16 15:54, Piggott BRUCE wrote: >> >> > Hi Guys. >> >> > >> >> > I'm having a problem finding the correct instruction for storing >> >> non >> >> > volatile data in the microbit module. >> >> > >> >> > I need to store a variable collected during run time that is >> >> available >> >> > on next power up. >> >> > >> >> > I know I need to create a file of some sort and/ /have searched >> the >> >> web >> >> > for how to do this but everything I have found does not work. >> >> > >> >> > Can anybody give me a simple example of how to create a file of >> >> data >> >> > that is available after a subsequent power up? >> >> > >> >> > Cheers, Bruce >> >> > >> >> > >> >> > >> >> > _______________________________________________ >> >> > 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 >> >> >> _______________________________________________ >> 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 >> >> >> >> >> _______________________________________________ >> Microbit mailing list >> Microbit at python.org >> https://mail.python.org/mailman/listinfo/microbit >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Sun Oct 23 12:52:38 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Sun, 23 Oct 2016 17:52:38 +0100 Subject: [Microbit-Python] Latest releases of Mu and uflash Message-ID: <8b8e5cde-0a99-9eb2-825f-3500ed0da918@ntoll.org> Hi Folks, Many of you will have contributed fixes, features or tidy-ups to both projects. I've spent my spare time this past week merging and generally working out how the resolve things. I've just released the latest version of both packages. Thank you for all your contributions. Please, please, please remember to include TESTS! I've added a bunch myself for people who didn't bother this time. But from now on, I'll just reject PR's with a "Please add tests!". If you're unsure about how to write tests, I'm more than happy to help - just ask! This is all explained in the CONTRIBUTING.rst files for both projects. Yay for tests! N. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 473 bytes Desc: OpenPGP digital signature URL: From Kostadin.Cvejoski at iais.fraunhofer.de Wed Oct 26 08:10:44 2016 From: Kostadin.Cvejoski at iais.fraunhofer.de (Cvejoski, Kostadin) Date: Wed, 26 Oct 2016 12:10:44 +0000 Subject: [Microbit-Python] New version of the microbit DAL Message-ID: <1477483844321.12877@iais.fraunhofer.de> Hi, ?I was looking into the microbit/micropython project and I would like to say you have done a great job. However the DAL that is used in the project is not up to date. My question is do you plan to update to the newest version of the DAL and if so when? Thank you Best Regards, Kostadin Cvejoski Abteilung Media Engineering Fraunhofer-Institut Intelligente Analyse- und Informationssysteme IAIS Schloss Birlinghoven D-53757 Sankt Augustin Telefon + 49-2241-14-2986 Fax + 49-2241-14-4-2986 kostadin.cvejoski at iais.fraunhofer.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From mark at hotpy.org Thu Oct 27 05:03:00 2016 From: mark at hotpy.org (Mark Shannon) Date: Thu, 27 Oct 2016 10:03:00 +0100 Subject: [Microbit-Python] New version of the microbit DAL In-Reply-To: <1477483844321.12877@iais.fraunhofer.de> References: <1477483844321.12877@iais.fraunhofer.de> Message-ID: <5811C2C4.7010704@hotpy.org> Hi, No, we don't plan to update to the newest version of the DAL, although we may well cherry pick bug-fixes if appropriate. We are moving away from the DAL, as the all the components of the DAL are tightly coupled together and its memory management and threading model do not work well with MicroPython. If there any features of the DAL that are missing from the MicroPython port and that you need, please file an issue. Cheers, Mark. On 26/10/16 13:10, Cvejoski, Kostadin wrote: > Hi, > > > ?I was looking into the microbit/micropython project and I would like to > say you have done a great job. > > > However the DAL that is used in the project is not up to date. > > > My question is do you plan to update to the newest version of the DAL > and if so when? > > > Thank you > > > Best Regards, > > > Kostadin Cvejoski > Abteilung Media Engineering > Fraunhofer-Institut Intelligente Analyse- und Informationssysteme IAIS > Schloss Birlinghoven > D-53757 Sankt Augustin > Telefon + 49-2241-14-2986 > Fax + 49-2241-14-4-2986 > kostadin.cvejoski at iais.fraunhofer.de > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > From barrachri at gmail.com Sat Oct 29 05:12:28 2016 From: barrachri at gmail.com (Christian Barra) Date: Sat, 29 Oct 2016 11:12:28 +0200 Subject: [Microbit-Python] Poland:Microbit In-Reply-To: References: <553bb6f6-1f1f-302e-6820-cd5eb0d93a3c@ntoll.org> <597d3998-5185-3e02-422f-ba8cbf81e0fa@ntoll.org> Message-ID: Well.... I am very happy to announce that I got a grant from PSF to start Microbit:Poland !!! Thanks to the PSF ! -- With Gravitational Cheers, Christian EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Sat Oct 29 12:34:29 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Sat, 29 Oct 2016 17:34:29 +0100 Subject: [Microbit-Python] Feedback please... Mu roadmap Message-ID: <0fea5507-e169-b093-025d-bfb58d6e616c@ntoll.org> Hi Folks, I've promised this for a while and have finally got round to writing it - the Mappa MUndi, or roadmap for Mu. https://github.com/mu-editor/mu/pull/180 This is a straw man so please feel free to review it, provide constructive critique and suggest ideas. I'm not precious about anything I write and love getting feedback, so, jump in! Here's to finding a consensus and set of aims for the short, medium and long-term future of Mu. Best wishes, N. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 455 bytes Desc: OpenPGP digital signature URL: From pt at adafruit.com Sat Oct 29 13:38:06 2016 From: pt at adafruit.com (phillip torrone) Date: Sat, 29 Oct 2016 13:38:06 -0400 Subject: [Microbit-Python] Feedback please... Mu roadmap In-Reply-To: <0fea5507-e169-b093-025d-bfb58d6e616c@ntoll.org> References: <0fea5507-e169-b093-025d-bfb58d6e616c@ntoll.org> Message-ID: wow! this is great, we were working on (and also need) many of the roadmap items for our short term and long term plans for getting micropython in the hands of young people in the easiest way possible. nice work N. ! limor (ladyada), some adafruit folks and myself will post up on the roadmap, mostly a lot of "YES!" and some ideas and suggestions too. i'll send another email here on this list about our work with micrppython, our current and future hardware and more. thank you everyone who has worked on mu! cheers, pt > On Oct 29, 2016, at 12:34 PM, Nicholas H.Tollervey wrote: > > Hi Folks, > > I've promised this for a while and have finally got round to writing it > - the Mappa MUndi, or roadmap for Mu. > > https://github.com/mu-editor/mu/pull/180 > > This is a straw man so please feel free to review it, provide > constructive critique and suggest ideas. I'm not precious about anything > I write and love getting feedback, so, jump in! > > Here's to finding a consensus and set of aims for the short, medium and > long-term future of Mu. > > Best wishes, > > N. > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit From pt at adafruit.com Sat Oct 29 14:02:38 2016 From: pt at adafruit.com (phillip torrone) Date: Sat, 29 Oct 2016 14:02:38 -0400 Subject: [Microbit-Python] some of the things we're working on @adafruit (mu / micropython) In-Reply-To: <0fea5507-e169-b093-025d-bfb58d6e616c@ntoll.org> References: <0fea5507-e169-b093-025d-bfb58d6e616c@ntoll.org> Message-ID: <0A0419A4-4C84-489E-9FBE-8BFF6865609A@adafruit.com> hey folks, we're working on some fun stuff at adafruit with micropython, a lot is in beta and we're seeing a lot of interest and we figured it was good time to join this list and also comment/kudos the work on mu which we're using for some testing now too. here's a bit about us: http://www.adafruit.com/about/ if anyone has any questions about our company let me know, happy to answer - we're an open source hardware company in NYC, USA, no loans or VC, limor "ladyada" is the founder and engineer, a 100% woman engineer company, we make our products at our factory - we're about 100+ people and are trying to make the world a better place with open source values, code, hardware and more for learning - here's a video tour of the latest: https://www.youtube.com/watch?v=PVx7xpYnWZI here is our current hardware in our "micropython" category: http://www.adafruit.com/micropython guides on our learning systems: https://learn.adafruit.com/category/micropython videos: https://www.youtube.com/playlist?list=PLjF7R1fz_OOXrI15wuXeESA0aA4VzcWSi tony dicola who works with us at adafruit is doing *fantastic* work on these, scott shawcroft is doing amazing work with the firmware. limor is making a lot of new hardware. we're currently working on "METRO Express" it's the adafruit METRO that is arduino-compatible, using the SAMD21, we have the FEATHER m0 and we're working on the SAMD21 version of CIRCUIT PLAYGROUND, our kid's version of arduino-compatible / micropython. we also have some future versions of hardware planned that we can share too (ESP32, etc). saturday am (now) just made a fun demo to show a problem solved we saw over and over, we get asked by people for a "badge" that anyone can just edit a text file and it changes the name, it also needs to be tiny, battery powered, no IDE to install, just double click a USB drive, open a text file, save, that's it. so this is a little demo to show what was possible with a FEATHER m0, OLED wing, battery and 13 lines of code: https://twitter.com/adafruit/status/792421589296025600 also pictured, we worked with damien and have some micropython stickers, $1 of each sticker goes to him and we also are supporting his work/efforts: https://www.adafruit.com/products/3270 that's it for now, we'll be chatty on the list with fun things we're doing, thank you everyone who works on mu! some short term goals are getting the adafruit USB VID/PID pull request in so more hardware works and some minor updates from eduvik that fixes some terminal stuff. we have a version of mu that i hacked up now that works with our stuff, but this is a good time to make the request with the roadmap! cheers, pt From mal at egenix.com Sat Oct 29 15:14:36 2016 From: mal at egenix.com (M.-A. Lemburg) Date: Sat, 29 Oct 2016 21:14:36 +0200 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits Message-ID: <5814F51C.1020401@egenix.com> Just in case there are some people from Germany around on this list: We'll be running our annual Python Meeting D?sseldorf Sprint later in November (weekend 19/20.11.) and one of the topics will be to work on a mesh network setup to get BBC microbits hooked up to a WLAN using an ESP8266. If you're interested, please let me know. This is our homepage: http://www.pyddf.de/ where we'll announce the sprint soonish. BTW: We all speak English, so speaking German is not a requirement for attending :-) Thanks, -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts (#1, Oct 29 2016) >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>> Python Database Interfaces ... http://products.egenix.com/ >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ ________________________________________________________________________ ::: We implement business ideas - efficiently in both time and costs ::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ http://www.malemburg.com/ From david at thinkingbinaries.com Sat Oct 29 16:30:26 2016 From: david at thinkingbinaries.com (David Whale) Date: Sat, 29 Oct 2016 21:30:26 +0100 Subject: [Microbit-Python] Traceability from REPL to github source Message-ID: Does anyone know how I can, given an arbitrary micro:bit that is running MicroPython, trace this back to the specific github version of source that was used to build it? e.g. when I start my micro:bit I see this at the REPL. How would I turn this into a githash that identifies the precise source code that was used to build the interpreter and libraries for that specific running instance that I have in front of me? MicroPython v1.7-9-gbe020eb on 2016-04-18; micro:bit with nRF51822 Type "help()" for more information. Thanks David -------------- next part -------------- An HTML attachment was scrubbed... URL: From dhylands at gmail.com Sat Oct 29 23:25:59 2016 From: dhylands at gmail.com (Dave Hylands) Date: Sat, 29 Oct 2016 20:25:59 -0700 Subject: [Microbit-Python] Traceability from REPL to github source In-Reply-To: References: Message-ID: The key is in the version number: v1.7-9-gbe020eb Take the last portion gbe020eb and drop the leading g. This is supposed to be the hash in github used to build this version of MicroPython. I checked: https://github.com/bbcmicrobit/micropython and couldn't find that hash (be020eb), but I did find: https://github.com/bbcmicrobit/micropython/blob/a20fbe82c919cea9519ce5a1140103f518b51caa/inc/genhdr/mpversion.h which refers to that hash. So it probably refers to a hash from some other repository. dpgeorge can probably identity which repository the hash corresponds to. On Sat, Oct 29, 2016 at 1:30 PM, David Whale wrote: > Does anyone know how I can, given an arbitrary micro:bit that is running > MicroPython, trace this back to the specific github version of source that > was used to build it? > > e.g. when I start my micro:bit I see this at the REPL. How would I turn > this into a githash that identifies the precise source code that was used > to build the interpreter and libraries for that specific running instance > that I have in front of me? > > MicroPython v1.7-9-gbe020eb on 2016-04-18; micro:bit with nRF51822 > > Type "help()" for more information. > > > Thanks > > > David > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -- Dave Hylands Shuswap, BC, Canada http://www.davehylands.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From damien.p.george at gmail.com Sun Oct 30 02:21:36 2016 From: damien.p.george at gmail.com (Damien George) Date: Sun, 30 Oct 2016 17:21:36 +1100 Subject: [Microbit-Python] Traceability from REPL to github source In-Reply-To: References: Message-ID: The upstream version of uPy used on the microbit is from the "parse-bytecode" branch of the main repo. The git hash that you found corresponds to this: https://github.com/micropython/micropython/commit/be020eb2c3c7e8421ee0989a7a09498a91b974fb If you run "os.uname()" on the microbit it might give you some more info, but probably not enough to find exactly the hash from the bbcmicrobit/micropython repository that corresponds to your firmware. If you feel that it's important to have this traceability, please open an issue (at bbcmicrobit/micropython). Thanks :) On 30 October 2016 at 14:25, Dave Hylands wrote: > The key is in the version number: v1.7-9-gbe020eb Take the last portion > gbe020eb and drop the leading g. This is supposed to be the hash in github > used to build this version of MicroPython. > > I checked: https://github.com/bbcmicrobit/micropython and couldn't find that > hash (be020eb), but I did find: > https://github.com/bbcmicrobit/micropython/blob/a20fbe82c919cea9519ce5a1140103f518b51caa/inc/genhdr/mpversion.h > which refers to that hash. > > So it probably refers to a hash from some other repository. dpgeorge can > probably identity which repository the hash corresponds to. > > > > On Sat, Oct 29, 2016 at 1:30 PM, David Whale > wrote: >> >> Does anyone know how I can, given an arbitrary micro:bit that is running >> MicroPython, trace this back to the specific github version of source that >> was used to build it? >> >> e.g. when I start my micro:bit I see this at the REPL. How would I turn >> this into a githash that identifies the precise source code that was used to >> build the interpreter and libraries for that specific running instance that >> I have in front of me? >> >> MicroPython v1.7-9-gbe020eb on 2016-04-18; micro:bit with nRF51822 >> >> Type "help()" for more information. >> >> >> Thanks >> >> >> David >> >> >> >> _______________________________________________ >> Microbit mailing list >> Microbit at python.org >> https://mail.python.org/mailman/listinfo/microbit >> > > > > -- > Dave Hylands > Shuswap, BC, Canada > http://www.davehylands.com > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > From david at thinkingbinaries.com Sun Oct 30 05:26:53 2016 From: david at thinkingbinaries.com (David Whale) Date: Sun, 30 Oct 2016 09:26:53 +0000 Subject: [Microbit-Python] Traceability from REPL to github source In-Reply-To: References: Message-ID: Thanks Damien, Issue logged: https://github.com/bbcmicrobit/micropython/issues/370 > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlosperate at gmail.com Sun Oct 30 15:25:38 2016 From: carlosperate at gmail.com (Carlos Pereira Atencio) Date: Sun, 30 Oct 2016 19:25:38 +0000 Subject: [Microbit-Python] Poland:Microbit In-Reply-To: References: <553bb6f6-1f1f-302e-6820-cd5eb0d93a3c@ntoll.org> <597d3998-5185-3e02-422f-ba8cbf81e0fa@ntoll.org> Message-ID: That's fantastic news Christian! Please keep us updated on how things go :) On 29 October 2016 at 10:12, Christian Barra wrote: > Well.... I am very happy to announce that I got a grant from PSF to start > Microbit:Poland !!! > > Thanks to the PSF ! > > > -- > With Gravitational Cheers, > > Christian > EuroPython Society board member > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From radomir at dopieralski.pl Sun Oct 30 17:42:01 2016 From: radomir at dopieralski.pl (Radomir Dopieralski) Date: Sun, 30 Oct 2016 22:42:01 +0100 Subject: [Microbit-Python] Poland:Microbit In-Reply-To: References: <553bb6f6-1f1f-302e-6820-cd5eb0d93a3c@ntoll.org> <597d3998-5185-3e02-422f-ba8cbf81e0fa@ntoll.org> Message-ID: <20161030224201.71024602@ghostwheel> This is great news! Is there any information anywhere about what exactly is involved? Any way to help? On Sat, 29 Oct 2016 11:12:28 +0200 Christian Barra wrote: > Well.... I am very happy to announce that I got a grant from PSF to > start Microbit:Poland !!! > > Thanks to the PSF ! > > -- Radomir Dopieralski From danka.miklos at gmail.com Mon Oct 31 06:26:54 2016 From: danka.miklos at gmail.com (=?UTF-8?B?TWlrbMOzcyBBbmRyw6FzIERhbmth?=) Date: Mon, 31 Oct 2016 10:26:54 +0000 Subject: [Microbit-Python] Microbit Python Doc translation Message-ID: Hello, I'm Miklos Danka, a software engineer and a teacher (here's an example ). I'm writing regarding the BBC Microbit Python edition - please let me know if this is not the right place or contact for it. First of all: *it's really awesome.* Incredible job, especially around the documentation, which even less experienced kids understood well. Very very cool. Since I teach kids in Hungary, I wanted to translate the documentation to Hungarian. My question is: *do you have a recommended/preferred way of publishing the translation?* I can always just fork the repository - but that would miss out on the benefits of having the documentations tracked together at the same website. Would you recommend it as a Sphinx "version" (next to "latest" and "stable")? Or does Sphinx provide and orthogonal translation feature? Any ideas/suggestions would be very welcome and appreciated. Thanks! Miklos -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Mon Oct 31 06:52:02 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Mon, 31 Oct 2016 10:52:02 +0000 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: References: Message-ID: Hi Mikl?s, This is something we need to work out - I'll have a look this evening and make a suggestion. Making our work easy to translate is *very* important and I'll read up on how Sphinx and Read-the-Docs suggests we do it. :-) N. On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: > Hello, > > I'm Miklos Danka, a software engineer and a teacher (here's an example > ). I'm > writing regarding the BBC Microbit Python edition - please let me know > if this is not the right place or contact for it. > > First of all: *it's really awesome.* Incredible job, especially around > the documentation, which even less experienced kids understood well. > Very very cool. > > Since I teach kids in Hungary, I wanted to translate the documentation > to Hungarian. > My question is: *do you have a recommended/preferred way of publishing > the translation?* I can always just fork the repository - but that would > miss out on the benefits of having the documentations tracked together > at the same website. > Would you recommend it as a Sphinx "version" (next to "latest" and > "stable")? Or does Sphinx provide and orthogonal translation feature? > > Any ideas/suggestions would be very welcome and appreciated. > > Thanks! > Miklos > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 455 bytes Desc: OpenPGP digital signature URL: From barrachri at gmail.com Mon Oct 31 06:56:07 2016 From: barrachri at gmail.com (Christian Barra) Date: Mon, 31 Oct 2016 11:56:07 +0100 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: References: Message-ID: I am facing the same problem for Poland.... 2016-10-31 11:52 GMT+01:00 Nicholas H.Tollervey : > Hi Mikl?s, > > This is something we need to work out - I'll have a look this evening > and make a suggestion. Making our work easy to translate is *very* > important and I'll read up on how Sphinx and Read-the-Docs suggests we > do it. :-) > > N. > > On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: > > Hello, > > > > I'm Miklos Danka, a software engineer and a teacher (here's an example > > ). I'm > > writing regarding the BBC Microbit Python edition - please let me know > > if this is not the right place or contact for it. > > > > First of all: *it's really awesome.* Incredible job, especially around > > the documentation, which even less experienced kids understood well. > > Very very cool. > > > > Since I teach kids in Hungary, I wanted to translate the documentation > > to Hungarian. > > My question is: *do you have a recommended/preferred way of publishing > > the translation?* I can always just fork the repository - but that would > > miss out on the benefits of having the documentations tracked together > > at the same website. > > Would you recommend it as a Sphinx "version" (next to "latest" and > > "stable")? Or does Sphinx provide and orthogonal translation feature? > > > > Any ideas/suggestions would be very welcome and appreciated. > > > > Thanks! > > Miklos > > > > > > _______________________________________________ > > 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 > > -- With Gravitational Cheers, Christian EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Mon Oct 31 07:02:18 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Mon, 31 Oct 2016 11:02:18 +0000 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: References: Message-ID: <78e81398-fc0b-e008-1300-a0046cf46d9f@ntoll.org> Yup... happy to have suggestions for the best way forward! I'm assuming there are existing conventions that we can follow (I just need to find time after "real work" to discover what they may be so I can document them in the right place / right way). N. On 31/10/16 10:56, Christian Barra wrote: > I am facing the same problem for Poland.... > > 2016-10-31 11:52 GMT+01:00 Nicholas H.Tollervey >: > > Hi Mikl?s, > > This is something we need to work out - I'll have a look this evening > and make a suggestion. Making our work easy to translate is *very* > important and I'll read up on how Sphinx and Read-the-Docs suggests we > do it. :-) > > N. > > On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: > > Hello, > > > > I'm Miklos Danka, a software engineer and a teacher (here's an example > > >). I'm > > writing regarding the BBC Microbit Python edition - please let me know > > if this is not the right place or contact for it. > > > > First of all: *it's really awesome.* Incredible job, especially around > > the documentation, which even less experienced kids understood well. > > Very very cool. > > > > Since I teach kids in Hungary, I wanted to translate the documentation > > > to Hungarian. > > My question is: *do you have a recommended/preferred way of publishing > > the translation?* I can always just fork the repository - but that > would > > miss out on the benefits of having the documentations tracked together > > at the same website. > > Would you recommend it as a Sphinx "version" (next to "latest" and > > "stable")? Or does Sphinx provide and orthogonal translation feature? > > > > Any ideas/suggestions would be very welcome and appreciated. > > > > Thanks! > > Miklos > > > > > > _______________________________________________ > > 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 > > > > > > -- > With Gravitational Cheers, > > Christian > EuroPython Society board member > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 455 bytes Desc: OpenPGP digital signature URL: From carlosperate at gmail.com Mon Oct 31 07:04:45 2016 From: carlosperate at gmail.com (Carlos Pereira Atencio) Date: Mon, 31 Oct 2016 11:04:45 +0000 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: References: Message-ID: Yeah, there was also somebody from France willing to contribute to the translations, and I'd be quite happy to get a Spanish version started as well. So it looks like we should definitely start moving in this direction. On 31 October 2016 at 10:56, Christian Barra wrote: > I am facing the same problem for Poland.... > > 2016-10-31 11:52 GMT+01:00 Nicholas H.Tollervey : > >> Hi Mikl?s, >> >> This is something we need to work out - I'll have a look this evening >> and make a suggestion. Making our work easy to translate is *very* >> important and I'll read up on how Sphinx and Read-the-Docs suggests we >> do it. :-) >> >> N. >> >> On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: >> > Hello, >> > >> > I'm Miklos Danka, a software engineer and a teacher (here's an example >> > ). I'm >> > writing regarding the BBC Microbit Python edition - please let me know >> > if this is not the right place or contact for it. >> > >> > First of all: *it's really awesome.* Incredible job, especially around >> > the documentation, which even less experienced kids understood well. >> > Very very cool. >> > >> > Since I teach kids in Hungary, I wanted to translate the documentation >> > to Hungarian. >> > My question is: *do you have a recommended/preferred way of publishing >> > the translation?* I can always just fork the repository - but that would >> > miss out on the benefits of having the documentations tracked together >> > at the same website. >> > Would you recommend it as a Sphinx "version" (next to "latest" and >> > "stable")? Or does Sphinx provide and orthogonal translation feature? >> > >> > Any ideas/suggestions would be very welcome and appreciated. >> > >> > Thanks! >> > Miklos >> > >> > >> > _______________________________________________ >> > 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 >> >> > > > -- > With Gravitational Cheers, > > Christian > EuroPython Society board member > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlosperate at gmail.com Mon Oct 31 07:06:28 2016 From: carlosperate at gmail.com (Carlos Pereira Atencio) Date: Mon, 31 Oct 2016 11:06:28 +0000 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: <78e81398-fc0b-e008-1300-a0046cf46d9f@ntoll.org> References: <78e81398-fc0b-e008-1300-a0046cf46d9f@ntoll.org> Message-ID: I'd say this seems like a good starting point: http://docs.readthedocs.io/en/latest/localization.html On 31 October 2016 at 11:02, Nicholas H.Tollervey wrote: > Yup... happy to have suggestions for the best way forward! I'm assuming > there are existing conventions that we can follow (I just need to find > time after "real work" to discover what they may be so I can document > them in the right place / right way). > > N. > > On 31/10/16 10:56, Christian Barra wrote: > > I am facing the same problem for Poland.... > > > > 2016-10-31 11:52 GMT+01:00 Nicholas H.Tollervey > >: > > > > Hi Mikl?s, > > > > This is something we need to work out - I'll have a look this evening > > and make a suggestion. Making our work easy to translate is *very* > > important and I'll read up on how Sphinx and Read-the-Docs suggests > we > > do it. :-) > > > > N. > > > > On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: > > > Hello, > > > > > > I'm Miklos Danka, a software engineer and a teacher (here's an > example > > > > >). > I'm > > > writing regarding the BBC Microbit Python edition - please let me > know > > > if this is not the right place or contact for it. > > > > > > First of all: *it's really awesome.* Incredible job, especially > around > > > the documentation, which even less experienced kids understood > well. > > > Very very cool. > > > > > > Since I teach kids in Hungary, I wanted to translate the > documentation > > > > > to > Hungarian. > > > My question is: *do you have a recommended/preferred way of > publishing > > > the translation?* I can always just fork the repository - but that > > would > > > miss out on the benefits of having the documentations tracked > together > > > at the same website. > > > Would you recommend it as a Sphinx "version" (next to "latest" and > > > "stable")? Or does Sphinx provide and orthogonal translation > feature? > > > > > > Any ideas/suggestions would be very welcome and appreciated. > > > > > > Thanks! > > > Miklos > > > > > > > > > _______________________________________________ > > > 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 > > > > > > > > > > > > -- > > With Gravitational Cheers, > > > > Christian > > EuroPython Society board member > > > > > > _______________________________________________ > > 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: From barrachri at gmail.com Mon Oct 31 07:54:37 2016 From: barrachri at gmail.com (Christian Barra) Date: Mon, 31 Oct 2016 12:54:37 +0100 Subject: [Microbit-Python] Poland:Microbit In-Reply-To: <20161030224201.71024602@ghostwheel> References: <553bb6f6-1f1f-302e-6820-cd5eb0d93a3c@ntoll.org> <597d3998-5185-3e02-422f-ba8cbf81e0fa@ntoll.org> <20161030224201.71024602@ghostwheel> Message-ID: Hi Radomir ! The idea is to have a day workshop, 4 hours of python and microbit + 2 hours of open lab where teachers&students can work on team projects supported by python programmers and then present them. I think during PyCon UK they did something similiar. The idea is to have around 30 kids, 5 teachers and 5 programmers. Probably we will start in Gliwice or Wroclaw and then find new sponsors to move to other cities. https://github.com/MicrobitPoland I just started with this ans yes...still a mess :) They idea is to have a website EN/PL and separate website for the lecture always in EN/PL. To idea is to use the materials that you can find in the micropython microbit wiki and build something from there. You will see something related to software carpentry in the repo because I would like to use their template for the lecture. I am naturally open to new idea, advices, feedback and help. And if you want to help, well welcome aboard ! Il domenica 30 ottobre 2016, Radomir Dopieralski ha scritto: > This is great news! > > Is there any information anywhere about what exactly is involved? > Any way to help? > > > On Sat, 29 Oct 2016 11:12:28 +0200 > Christian Barra > wrote: > > > Well.... I am very happy to announce that I got a grant from PSF to > > start Microbit:Poland !!! > > > > Thanks to the PSF ! > > > > > > > > -- > Radomir Dopieralski > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -- With Gravitational Cheers, Christian EuroPython Society board member -------------- next part -------------- An HTML attachment was scrubbed... URL: From nevil.hunt at hotmail.co.uk Mon Oct 31 10:26:16 2016 From: nevil.hunt at hotmail.co.uk (Nevil Hunt) Date: Mon, 31 Oct 2016 14:26:16 +0000 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: <5814F51C.1020401@egenix.com> References: <5814F51C.1020401@egenix.com> Message-ID: Hi Marc-Andre, I've not played with the ESP8266 yet so I'd be interested to hear how you get on. Which particular ESP8266 module will you be using? Nevil ________________________________ From: Microbit on behalf of M.-A. Lemburg Sent: 29 October 2016 20:14 To: For Pythonic MicroBit related discussions Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits Just in case there are some people from Germany around on this list: We'll be running our annual Python Meeting D?sseldorf Sprint later in November (weekend 19/20.11.) and one of the topics will be to work on a mesh network setup to get BBC microbits hooked up to a WLAN using an ESP8266. If you're interested, please let me know. This is our homepage: http://www.pyddf.de/ where we'll announce [http://www.pyddf.de/index_html_files/27.jpg] Python Meeting D?sseldorf (PyDDF) www.pyddf.de Python Meeting D?sseldorf - Ein Treffen von Python Enthusiasten und Interessierten in ungezwungener Atmosp?re. the sprint soonish. BTW: We all speak English, so speaking German is not a requirement for attending :-) Thanks, -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts (#1, Oct 29 2016) >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ eGenix.com - Professional Python Software, Skills and Services www.egenix.com eGenix(tm) is your leading partner for Python and database focused custom projects, services, coaching, consulting and products. We implement business ideas ... >>> Python Database Interfaces ... http://products.egenix.com/ eGenix.com Products products.egenix.com eGenix.com offers a large portfolio of products for Python and Python-based applications, many of them focusing on database connectivity. >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ eGenix.com: eGenix.com Plone & Zope Products zope.egenix.com Plone/Zope Database Connectivity. eGenix.com has been actively working in the field of Python database connectivity for more than 15 years. Using our Zope and Plone ... ________________________________________________________________________ ::: We implement business ideas - efficiently in both time and costs ::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ eGenix.com: Company: Contact www.egenix.com We provide various ways of contacting eGenix.com depending on what area of interest you have. EMail. General Questions: info at egenix.com Support: support at egenix.com http://www.malemburg.com/ Marc-Andre Lemburg: All Things Python www.malemburg.com Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core Developer, Trainer, Coach and Consultant _______________________________________________ Microbit mailing list Microbit at python.org https://mail.python.org/mailman/listinfo/microbit Microbit Info Page - Python mail.python.org The MicroBit is a small programmable device for children created by the BBC (in partnership with various other organisations, such as the PSF). -------------- next part -------------- An HTML attachment was scrubbed... URL: From mal at egenix.com Mon Oct 31 10:40:56 2016 From: mal at egenix.com (M.-A. Lemburg) Date: Mon, 31 Oct 2016 15:40:56 +0100 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: References: <5814F51C.1020401@egenix.com> Message-ID: <581757F8.6000701@egenix.com> Hi Nevil, On 31.10.2016 15:26, Nevil Hunt wrote: > Hi Marc-Andre, > > > I've not played with the ESP8266 yet so I'd be interested to hear how you get on. > > Which particular ESP8266 module will you be using? We'll probably be using one of the NodeMCU modules, since they make it much easier to get started than the ESP stand-alone devices. As for connecting the ESP to the Microbits, we still have to figure that one out. Perhaps we can use i2c for this. -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts (#1, Oct 31 2016) >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>> Python Database Interfaces ... http://products.egenix.com/ >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ ________________________________________________________________________ ::: We implement business ideas - efficiently in both time and costs ::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ http://www.malemburg.com/ From nevil.hunt at hotmail.co.uk Mon Oct 31 11:35:17 2016 From: nevil.hunt at hotmail.co.uk (Nevil Hunt) Date: Mon, 31 Oct 2016 15:35:17 +0000 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: <581757F8.6000701@egenix.com> References: <5814F51C.1020401@egenix.com> , <581757F8.6000701@egenix.com> Message-ID: Hi Marc-Andre, I've managed to get the micro:bit's I2C to drive various other devices such as some of the Adafruit backpack displays using micro python. It took me a while to get the I2C syntax and commands right so it loaded the right byte in the right register. I can send you some of my I2C display driver code to use as an I2C example if you like. I also bought a Spark Fun Bus Pirate to help debugging the I2C. Nevil ________________________________ From: Microbit on behalf of M.-A. Lemburg Sent: 31 October 2016 14:40 To: For Pythonic MicroBit related discussions Subject: Re: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits Hi Nevil, On 31.10.2016 15:26, Nevil Hunt wrote: > Hi Marc-Andre, > > > I've not played with the ESP8266 yet so I'd be interested to hear how you get on. > > Which particular ESP8266 module will you be using? We'll probably be using one of the NodeMCU modules, since they make it much easier to get started than the ESP stand-alone devices. As for connecting the ESP to the Microbits, we still have to figure that one out. Perhaps we can use i2c for this. -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts (#1, Oct 31 2016) >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ eGenix.com - Professional Python Software, Skills and Services www.egenix.com eGenix(tm) is your leading partner for Python and database focused custom projects, services, coaching, consulting and products. We implement business ideas ... >>> Python Database Interfaces ... http://products.egenix.com/ eGenix.com Products products.egenix.com eGenix.com offers a large portfolio of products for Python and Python-based applications, many of them focusing on database connectivity. >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ eGenix.com: eGenix.com Plone & Zope Products zope.egenix.com Plone/Zope Database Connectivity. eGenix.com has been actively working in the field of Python database connectivity for more than 15 years. Using our Zope and Plone ... ________________________________________________________________________ ::: We implement business ideas - efficiently in both time and costs ::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ eGenix.com: Company: Contact www.egenix.com We provide various ways of contacting eGenix.com depending on what area of interest you have. EMail. General Questions: info at egenix.com Support: support at egenix.com http://www.malemburg.com/ Marc-Andre Lemburg: All Things Python www.malemburg.com Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core Developer, Trainer, Coach and Consultant _______________________________________________ Microbit mailing list Microbit at python.org https://mail.python.org/mailman/listinfo/microbit Microbit Info Page - Python mail.python.org The MicroBit is a small programmable device for children created by the BBC (in partnership with various other organisations, such as the PSF). -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Mon Oct 31 12:12:25 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Mon, 31 Oct 2016 16:12:25 +0000 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: References: <5814F51C.1020401@egenix.com> <581757F8.6000701@egenix.com> Message-ID: <54515882-4d65-28cd-b2a2-f8cbacf1970b@ntoll.org> MicroPython already runs directly on the ESP8266... I was using a couple of weeks ago in a class Radomir ran at PyCon Poland. It's awesome! N. On 31/10/16 15:35, Nevil Hunt wrote: > Hi Marc-Andre, > > > I've managed to get the micro:bit's I2C to drive various other devices > such as some of the Adafruit backpack displays using micro python. > > It took me a while to get the I2C syntax and commands right so it loaded > the right byte in the right register. > > I can send you some of my I2C display driver code to use as an > I2C example if you like. > > I also bought a Spark Fun Bus Pirate to help debugging the I2C. > > > Nevil > > > > ------------------------------------------------------------------------ > *From:* Microbit > on behalf of M.-A. Lemburg > *Sent:* 31 October 2016 14:40 > *To:* For Pythonic MicroBit related discussions > *Subject:* Re: [Microbit-Python] Sprint with MicroPython on ESP8266 and > BBC microbits > > Hi Nevil, > > On 31.10.2016 15:26, Nevil Hunt wrote: >> Hi Marc-Andre, >> >> >> I've not played with the ESP8266 yet so I'd be interested to hear how you get on. >> >> Which particular ESP8266 module will you be using? > > We'll probably be using one of the NodeMCU modules, since > they make it much easier to get started than the ESP > stand-alone devices. > > As for connecting the ESP to the Microbits, we still have to > figure that one out. Perhaps we can use i2c for this. > > -- > Marc-Andre Lemburg > eGenix.com > > Professional Python Services directly from the Experts (#1, Oct 31 2016) >>>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ > > eGenix.com - Professional Python Software, Skills and Services > > www.egenix.com > eGenix? is your leading partner for Python and database focused custom > projects, services, coaching, consulting and products. We implement > business ideas ... > > > >>>> Python Database Interfaces ... http://products.egenix.com/ > > eGenix.com Products > products.egenix.com > eGenix.com offers a large portfolio of products for Python and > Python-based applications, many of them focusing on database connectivity. > > > >>>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ > > eGenix.com: eGenix.com Plone & Zope Products > zope.egenix.com > Plone/Zope Database Connectivity. eGenix.com has been actively working > in the field of Python database connectivity for more than 15 years. > Using our Zope and Plone ... > > > > ________________________________________________________________________ > > ::: We implement business ideas - efficiently in both time and costs ::: > > eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 > D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg > Registered at Amtsgericht Duesseldorf: HRB 46611 > http://www.egenix.com/company/contact/ > > eGenix.com: Company: Contact > www.egenix.com > We provide various ways of contacting eGenix.com depending on what area > of interest you have. EMail. General Questions: info at egenix.com Support: > support at egenix.com > > > > http://www.malemburg.com/ > > Marc-Andre Lemburg: All Things Python > www.malemburg.com > Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core > Developer, Trainer, Coach and Consultant > > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > Microbit Info Page - Python > > mail.python.org > The MicroBit is a small programmable device for children created by the > BBC (in partnership with various other organisations, such as the PSF). > > > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 455 bytes Desc: OpenPGP digital signature URL: From nevil.hunt at hotmail.co.uk Mon Oct 31 12:33:35 2016 From: nevil.hunt at hotmail.co.uk (Nevil Hunt) Date: Mon, 31 Oct 2016 16:33:35 +0000 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: <54515882-4d65-28cd-b2a2-f8cbacf1970b@ntoll.org> References: <5814F51C.1020401@egenix.com> <581757F8.6000701@egenix.com> , <54515882-4d65-28cd-b2a2-f8cbacf1970b@ntoll.org> Message-ID: Hi Nicholas, Were you running the ESP8266 stand alone using micro python or did you have it hooked up to a micro:bit? I think Marc-Andre was looking to drive it from a micro:bit but having not looked into the ESP8266 in detail I don't know if the best way for the micro:bit to control it would be via I2C, UART or some other way. Nevil ________________________________ From: Microbit on behalf of Nicholas H.Tollervey Sent: 31 October 2016 16:12 To: microbit at python.org Subject: Re: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits MicroPython already runs directly on the ESP8266... I was using a couple of weeks ago in a class Radomir ran at PyCon Poland. It's awesome! N. On 31/10/16 15:35, Nevil Hunt wrote: > Hi Marc-Andre, > > > I've managed to get the micro:bit's I2C to drive various other devices > such as some of the Adafruit backpack displays using micro python. > > It took me a while to get the I2C syntax and commands right so it loaded > the right byte in the right register. > > I can send you some of my I2C display driver code to use as an > I2C example if you like. > > I also bought a Spark Fun Bus Pirate to help debugging the I2C. > > > Nevil > > > > ------------------------------------------------------------------------ > *From:* Microbit > on behalf of M.-A. Lemburg > *Sent:* 31 October 2016 14:40 > *To:* For Pythonic MicroBit related discussions > *Subject:* Re: [Microbit-Python] Sprint with MicroPython on ESP8266 and > BBC microbits > > Hi Nevil, > > On 31.10.2016 15:26, Nevil Hunt wrote: >> Hi Marc-Andre, >> >> >> I've not played with the ESP8266 yet so I'd be interested to hear how you get on. >> >> Which particular ESP8266 module will you be using? > > We'll probably be using one of the NodeMCU modules, since > they make it much easier to get started than the ESP > stand-alone devices. > > As for connecting the ESP to the Microbits, we still have to > figure that one out. Perhaps we can use i2c for this. > > -- > Marc-Andre Lemburg > eGenix.com > > Professional Python Services directly from the Experts (#1, Oct 31 2016) >>>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ eGenix.com - Professional Python Software, Skills and Services www.egenix.com eGenix? is your leading partner for Python and database focused custom projects, services, coaching, consulting and products. We implement business ideas ... > > eGenix.com - Professional Python Software, Skills and Services > eGenix.com - Professional Python Software, Skills and Services www.egenix.com eGenix? is your leading partner for Python and database focused custom projects, services, coaching, consulting and products. We implement business ideas ... > www.egenix.com eGenix.com - Professional Python Software, Skills and Services www.egenix.com eGenix? is your leading partner for Python and database focused custom projects, services, coaching, consulting and products. We implement business ideas ... > eGenix? is your leading partner for Python and database focused custom > projects, services, coaching, consulting and products. We implement > business ideas ... > > > >>>> Python Database Interfaces ... http://products.egenix.com/ eGenix.com Products products.egenix.com eGenix.com offers a large portfolio of products for Python and Python-based applications, many of them focusing on database connectivity. > > eGenix.com Products eGenix.com Products products.egenix.com eGenix.com offers a large portfolio of products for Python and Python-based applications, many of them focusing on database connectivity. > products.egenix.com > eGenix.com offers a large portfolio of products for Python and > Python-based applications, many of them focusing on database connectivity. > > > >>>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ eGenix.com: eGenix.com Plone & Zope Products zope.egenix.com Plone/Zope Database Connectivity. eGenix.com has been actively working in the field of Python database connectivity for more than 15 years. Using our Zope and Plone ... > > eGenix.com: eGenix.com Plone & Zope Products eGenix.com: eGenix.com Plone & Zope Products zope.egenix.com Plone/Zope Database Connectivity. eGenix.com has been actively working in the field of Python database connectivity for more than 15 years. Using our Zope and Plone ... > zope.egenix.com > Plone/Zope Database Connectivity. eGenix.com has been actively working > in the field of Python database connectivity for more than 15 years. > Using our Zope and Plone ... > > > > ________________________________________________________________________ > > ::: We implement business ideas - efficiently in both time and costs ::: > > eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 > D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg > Registered at Amtsgericht Duesseldorf: HRB 46611 > http://www.egenix.com/company/contact/ eGenix.com: Company: Contact www.egenix.com We provide various ways of contacting eGenix.com depending on what area of interest you have. EMail. General Questions: info at egenix.com Support: support at egenix.com > > eGenix.com: Company: Contact eGenix.com: Company: Contact www.egenix.com We provide various ways of contacting eGenix.com depending on what area of interest you have. EMail. General Questions: info at egenix.com Support: support at egenix.com > www.egenix.com eGenix.com - Professional Python Software, Skills and Services www.egenix.com eGenix? is your leading partner for Python and database focused custom projects, services, coaching, consulting and products. We implement business ideas ... > We provide various ways of contacting eGenix.com depending on what area > of interest you have. EMail. General Questions: info at egenix.com Support: > support at egenix.com > > > > http://www.malemburg.com/ Marc-Andre Lemburg: All Things Python www.malemburg.com Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core Developer, Trainer, Coach and Consultant > > Marc-Andre Lemburg: All Things Python Marc-Andre Lemburg: All Things Python www.malemburg.com Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core Developer, Trainer, Coach and Consultant > www.malemburg.com Marc-Andre Lemburg: All Things Python www.malemburg.com Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core Developer, Trainer, Coach and Consultant > Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core > Developer, Trainer, Coach and Consultant > > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit Microbit Info Page - Python mail.python.org The MicroBit is a small programmable device for children created by the BBC (in partnership with various other organisations, such as the PSF). > > Microbit Info Page - Python > > mail.python.org > The MicroBit is a small programmable device for children created by the > BBC (in partnership with various other organisations, such as the PSF). > > > > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mal at egenix.com Mon Oct 31 12:46:30 2016 From: mal at egenix.com (M.-A. Lemburg) Date: Mon, 31 Oct 2016 17:46:30 +0100 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: <54515882-4d65-28cd-b2a2-f8cbacf1970b@ntoll.org> References: <5814F51C.1020401@egenix.com> <581757F8.6000701@egenix.com> <54515882-4d65-28cd-b2a2-f8cbacf1970b@ntoll.org> Message-ID: <58177566.5090409@egenix.com> On 31.10.2016 17:12, Nicholas H.Tollervey wrote: > MicroPython already runs directly on the ESP8266... I was using a couple > of weeks ago in a class Radomir ran at PyCon Poland. It's awesome! Yes, I know, that's why I think it'd be great to use the ESP as WLAN AP for a Microbit mesh network, e.g. to use the MBs for signal/data entry and have them send the data to the outside world via WLAN or to control them from the WLAN to e.g. use their display to signal notifications... after all, their original theme was to be a wearable device ;-) Anyway, it's all about having fun, so some of this probably doesn't make a lot of sense (e.g. programming the ESP in straight C isn't all that hard either). > N. > > On 31/10/16 15:35, Nevil Hunt wrote: >> Hi Marc-Andre, >> >> >> I've managed to get the micro:bit's I2C to drive various other devices >> such as some of the Adafruit backpack displays using micro python. >> >> It took me a while to get the I2C syntax and commands right so it loaded >> the right byte in the right register. >> >> I can send you some of my I2C display driver code to use as an >> I2C example if you like. >> >> I also bought a Spark Fun Bus Pirate to help debugging the I2C. >> >> >> Nevil >> >> >> >> ------------------------------------------------------------------------ >> *From:* Microbit >> on behalf of M.-A. Lemburg >> *Sent:* 31 October 2016 14:40 >> *To:* For Pythonic MicroBit related discussions >> *Subject:* Re: [Microbit-Python] Sprint with MicroPython on ESP8266 and >> BBC microbits >> >> Hi Nevil, >> >> On 31.10.2016 15:26, Nevil Hunt wrote: >>> Hi Marc-Andre, >>> >>> >>> I've not played with the ESP8266 yet so I'd be interested to hear how you get on. >>> >>> Which particular ESP8266 module will you be using? >> >> We'll probably be using one of the NodeMCU modules, since >> they make it much easier to get started than the ESP >> stand-alone devices. >> >> As for connecting the ESP to the Microbits, we still have to >> figure that one out. Perhaps we can use i2c for this. >> >> -- >> Marc-Andre Lemburg >> eGenix.com >> >> Professional Python Services directly from the Experts (#1, Oct 31 2016) >>>>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >> >> eGenix.com - Professional Python Software, Skills and Services >> >> www.egenix.com >> eGenix? is your leading partner for Python and database focused custom >> projects, services, coaching, consulting and products. We implement >> business ideas ... >> >> >> >>>>> Python Database Interfaces ... http://products.egenix.com/ >> >> eGenix.com Products >> products.egenix.com >> eGenix.com offers a large portfolio of products for Python and >> Python-based applications, many of them focusing on database connectivity. >> >> >> >>>>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ >> >> eGenix.com: eGenix.com Plone & Zope Products >> zope.egenix.com >> Plone/Zope Database Connectivity. eGenix.com has been actively working >> in the field of Python database connectivity for more than 15 years. >> Using our Zope and Plone ... >> >> >> >> ________________________________________________________________________ >> >> ::: We implement business ideas - efficiently in both time and costs ::: >> >> eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 >> D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg >> Registered at Amtsgericht Duesseldorf: HRB 46611 >> http://www.egenix.com/company/contact/ >> >> eGenix.com: Company: Contact >> www.egenix.com >> We provide various ways of contacting eGenix.com depending on what area >> of interest you have. EMail. General Questions: info at egenix.com Support: >> support at egenix.com >> >> >> >> http://www.malemburg.com/ >> >> Marc-Andre Lemburg: All Things Python >> www.malemburg.com >> Blog by Marc-Andr? Lemburg, Senior Software Architect, Python Core >> Developer, Trainer, Coach and Consultant >> >> >> >> >> _______________________________________________ >> Microbit mailing list >> Microbit at python.org >> https://mail.python.org/mailman/listinfo/microbit >> >> Microbit Info Page - Python >> >> mail.python.org >> The MicroBit is a small programmable device for children created by the >> BBC (in partnership with various other organisations, such as the PSF). >> >> >> >> >> >> _______________________________________________ >> 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 > -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts (#1, Oct 31 2016) >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>> Python Database Interfaces ... http://products.egenix.com/ >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ ________________________________________________________________________ ::: We implement business ideas - efficiently in both time and costs ::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ http://www.malemburg.com/ From mal at egenix.com Mon Oct 31 12:57:21 2016 From: mal at egenix.com (M.-A. Lemburg) Date: Mon, 31 Oct 2016 17:57:21 +0100 Subject: [Microbit-Python] Sprint with MicroPython on ESP8266 and BBC microbits In-Reply-To: References: <5814F51C.1020401@egenix.com> <581757F8.6000701@egenix.com> Message-ID: <581777F1.2020607@egenix.com> Hi Nevil, On 31.10.2016 16:35, Nevil Hunt wrote: > Hi Marc-Andre, > > > I've managed to get the micro:bit's I2C to drive various other devices such as some of the Adafruit backpack displays using micro python. > > It took me a while to get the I2C syntax and commands right so it loaded the right byte in the right register. > > I can send you some of my I2C display driver code to use as an I2C example if you like. If you have this up on github somewhere, that would be great :-) > I also bought a Spark Fun Bus Pirate to help debugging the I2C. Thanks, -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Experts (#1, Oct 31 2016) >>> Python Projects, Coaching and Consulting ... http://www.egenix.com/ >>> Python Database Interfaces ... http://products.egenix.com/ >>> Plone/Zope Database Interfaces ... http://zope.egenix.com/ ________________________________________________________________________ ::: We implement business ideas - efficiently in both time and costs ::: eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ http://www.malemburg.com/ From naomi.ceder at gmail.com Mon Oct 31 13:00:00 2016 From: naomi.ceder at gmail.com (Naomi Ceder) Date: Mon, 31 Oct 2016 12:00:00 -0500 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: References: <78e81398-fc0b-e008-1300-a0046cf46d9f@ntoll.org> Message-ID: On the subject of translations, last week I started the process of forming a translation working group to coordinate translations of PSF and Python documentation. I'm sure you all will be way ahead of us, but I'd be interested in hearing how you manage the process. Cheers, Naomi On 31 October 2016 at 06:06, Carlos Pereira Atencio wrote: > I'd say this seems like a good starting point: > http://docs.readthedocs.io/en/latest/localization.html > > On 31 October 2016 at 11:02, Nicholas H.Tollervey wrote: > >> Yup... happy to have suggestions for the best way forward! I'm assuming >> there are existing conventions that we can follow (I just need to find >> time after "real work" to discover what they may be so I can document >> them in the right place / right way). >> >> N. >> >> On 31/10/16 10:56, Christian Barra wrote: >> > I am facing the same problem for Poland.... >> > >> > 2016-10-31 11:52 GMT+01:00 Nicholas H.Tollervey > > >: >> > >> > Hi Mikl?s, >> > >> > This is something we need to work out - I'll have a look this >> evening >> > and make a suggestion. Making our work easy to translate is *very* >> > important and I'll read up on how Sphinx and Read-the-Docs suggests >> we >> > do it. :-) >> > >> > N. >> > >> > On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: >> > > Hello, >> > > >> > > I'm Miklos Danka, a software engineer and a teacher (here's an >> example >> > > > > >). >> I'm >> > > writing regarding the BBC Microbit Python edition - please let me >> know >> > > if this is not the right place or contact for it. >> > > >> > > First of all: *it's really awesome.* Incredible job, especially >> around >> > > the documentation, which even less experienced kids understood >> well. >> > > Very very cool. >> > > >> > > Since I teach kids in Hungary, I wanted to translate the >> documentation >> > > > > > to >> Hungarian. >> > > My question is: *do you have a recommended/preferred way of >> publishing >> > > the translation?* I can always just fork the repository - but that >> > would >> > > miss out on the benefits of having the documentations tracked >> together >> > > at the same website. >> > > Would you recommend it as a Sphinx "version" (next to "latest" and >> > > "stable")? Or does Sphinx provide and orthogonal translation >> feature? >> > > >> > > Any ideas/suggestions would be very welcome and appreciated. >> > > >> > > Thanks! >> > > Miklos >> > > >> > > >> > > _______________________________________________ >> > > 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 >> > >> > >> > >> > >> > >> > -- >> > With Gravitational Cheers, >> > >> > Christian >> > EuroPython Society board member >> > >> > >> > _______________________________________________ >> > 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 >> >> > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > > -- Naomi Ceder https://plus.google.com/u/0/111396744045017339164/about -------------- next part -------------- An HTML attachment was scrubbed... URL: From ntoll at ntoll.org Mon Oct 31 15:33:58 2016 From: ntoll at ntoll.org (Nicholas H.Tollervey) Date: Mon, 31 Oct 2016 19:33:58 +0000 Subject: [Microbit-Python] Microbit Python Doc translation In-Reply-To: References: Message-ID: <3281d1cd-6ca5-31a4-a0b3-c36216123db7@ntoll.org> OK Folks, I've had time (on my train ride home) to look into this and here's what I've come up with: * We host our documentation on ReadTheDocs. * The relevant aspect of their documentation is here: https://docs.readthedocs.io/en/latest/localization.html#project-with-multiple-translations * Put simply, we create a new project for each translation (presumably a Sphinx doc repos on GitHub) to actually hold the translated resources and I can add them as "translations of" the main repos whose main language is English. * Each of the translations will need to be configured correctly to reflect the target locale (see the docs linked above). * Read the Docs figures our the relationships and displays the appropriate links between all the related translation projects. So, next steps are: 1) Make a new Sphinx project that mirrors the structure of our "docs" directory. Call it something obvious like, for example, microbit-micropython-es (for Spanish). 2) Register the project on ReadTheDocs (see docs referenced above for how to do this). 3) Create a new issue in the microbit-micropython repos pointing to the ReadTheDocs project that forms the translation. We'll do it as an issue so others can see how it's done and different translations get visibility. Does this make sense? Happy to get feedback, constructive critique and ideas. I'll also write this up as part of the "main" docs associated with the project so there's further visibility of the process. The PR is here: https://github.com/bbcmicrobit/micropython/pull/371 for people to comment should they wish to before I'll merge it in a day or so. Yay! Many thanks in advance for all your help with translating these resources. Best wishes, N. On 31/10/16 10:26, Mikl?s Andr?s Danka wrote: > Hello, > > I'm Miklos Danka, a software engineer and a teacher (here's an example > ). I'm > writing regarding the BBC Microbit Python edition - please let me know > if this is not the right place or contact for it. > > First of all: *it's really awesome.* Incredible job, especially around > the documentation, which even less experienced kids understood well. > Very very cool. > > Since I teach kids in Hungary, I wanted to translate the documentation > to Hungarian. > My question is: *do you have a recommended/preferred way of publishing > the translation?* I can always just fork the repository - but that would > miss out on the benefits of having the documentations tracked together > at the same website. > Would you recommend it as a Sphinx "version" (next to "latest" and > "stable")? Or does Sphinx provide and orthogonal translation feature? > > Any ideas/suggestions would be very welcome and appreciated. > > Thanks! > Miklos > > > _______________________________________________ > Microbit mailing list > Microbit at python.org > https://mail.python.org/mailman/listinfo/microbit > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 455 bytes Desc: OpenPGP digital signature URL: