#circuitpython-dev

1 messages ยท Page 115 of 1

manic glacierBOT
formal plover
#

lololol

#

soooooo

#

Remember when I said I need to spin up a new pi

idle owl
#

It wouldn't even let me into the directory in terminal initially. Took a few resets to get it to show up in Finder correctly which while I had no intention of using the explorer to delete the file, it was freezing my terminal when it wasn't working in Finder anyway... reset a few times, took some fussing, but I finally got it to where I could delete it.

formal plover
#

Well def need to soon

umbral dagger
#

Auto-reload seems to be working

idle owl
#

@formal plover Oh man...

formal plover
#

took down my network

#

fun fact... when you have 4 usb ports and every since one has a CircuitPython board plugged in...

solar whale
#

@formal plover ouch

formal plover
#

bootloader mode will shut off the pi evey time

umbral dagger
#

C-d does not force a reload. But if I press C-d several times (nothign happens) but then I press C-c, for each one a C-d gets processed. Once they're all processed, a C-c gets me to the repl.

#

Something going on with USB input processing?

solar whale
#

@formal plover anotehr reason for the 9v supply - is it a powered hub?

#

bee back in 5 - I have to give the cats their treats!

idle owl
#

Reset, doesn't mount in the explorer, enter the REPL, it shows up in the explorer. Repeat, mounts the first time. So that's inconsistent. Ahhh... but it won't let me do anything with it in Finder like it did when it had a main.py. This time I enter the REPL and it disappears from Finder. lol. Third and fourth time, like the first.

formal plover
#

serial fails to connect with that 3.0 file

idle owl
#

Mine or jerryn's?

formal plover
#

yours is garbled @idle owl and @solar whale's times out

idle owl
#

Oi

formal plover
#

115200 is the correct baud rate?

idle owl
#

Yeah

formal plover
#

hmmm

solar whale
#

@formal plover does CIRCUITPY show up ?

formal plover
#

no

solar whale
#

but it does leave bootloader -

formal plover
#

yes

solar whale
#

tyep dmesg - anything of note

#

@tulip sleet sorry about the wrong advice re: -lto error - I keep forgetting that that is the toolset

tulip sleet
#

@solar whale your advice is necessary too. I'm sure that's the next thing they'll hit.

formal plover
#

[ 739.150458] usb 1-1.5: reset full-speed USB device number 7 using dwc_otg [ 739.281805] cdc_acm 1-1.5:1.0: ttyACM0: USB ACM device [ 770.530678] usb 1-1.5: reset full-speed USB device number 7 using dwc_otg [ 770.662062] cdc_acm 1-1.5:1.0: ttyACM0: USB ACM device [ 801.230894] usb 1-1.5: reset full-speed USB device number 7 using dwc_otg [ 801.362305] cdc_acm 1-1.5:1.0: ttyACM0: USB ACM device [ 832.671232] usb 1-1.5: reset full-speed USB device number 7 using dwc_otg [ 832.802436] cdc_acm 1-1.5:1.0: ttyACM0: USB ACM device

solar whale
#

hmm - is that mine or Kattnis's

formal plover
#

yours

#

Kattni's gave me garbage at least lol

solar whale
#

Choose your poison - did oyu happen to checl dmesg with hers?

formal plover
#

haha right? Nope

#

I did not

tulip sleet
#

you folks seem to be willing to take a lot of punishment! I hope (and I'm sure Scott does too) that we'll fix all this in the next few days

solar whale
#

probaly similar - 3.0 is not kind to USB

#

@tulip sleet we are gluttons for punishment - all for a good cause.

formal plover
#

I'm here for the punishment

#

lol

idle owl
#

^^

#

@tulip sleet It's part of any development. The only thing that changes is the flavor.

tulip sleet
#

in the meantime it's good jlink practice ๐Ÿ˜

formal plover
#

So cool to watch it develop

#

and yes good fun with the jlink

idle owl
#

Though practice implies some previous knowledge to practice, lol..... all of it feels like brand new fumbling still.

pastel panther
#

@tulip sleet is CP close enough in design still to micropython for information on its architecture to be relevant to CP?

solar whale
#

@pastel panther my metro-wing boards are in fab! Looking forward to trying one!

formal plover
#

@pastel panther closest match is the feather HUZZAH

umbral dagger
#

@solar whale metro-wing?

pastel panther
#

@solar whale sweet! I hope there are no bugs!

tulip sleet
#

@pastel panther very much so; the main CPy changes are the atmel-samd port (which didn't exist before) and the changes of how to do I/O.

pastel panther
#

@umbral dagger I made an adapter for putting featherwings on a metro/uno

#

@tulip sleet Ok cool. I'm trying to get familiar with the code and an idea of the rough shape would be helpful

formal plover
#

I say that because it's maintained more of the MicroPythonish stuff (not by a lot, but more than some other boards)

pastel panther
#

I've been able to grok some stuff by reading the code but more info is always better

#

@umbral dagger I can point you towards my oshpark page but I'm hesitant to encourage anyone else to order one until they've been tested

umbral dagger
#

@pastel panther Ah. Cool.

tulip sleet
#

the Python language implementation is completely the same. The shared-bindings and shared-module structure is new from Scott. It's a regularization and a cleaner split between port-independent and port-dependent parts. (port = chip choice)

pastel panther
#

right, makes sense

umbral dagger
#

I'm waiting for an order of prototype boards to arrive (Tinket M0 based)

formal plover
#

@tulip sleet always so good at explaining things out

pastel panther
#

were those base on the flash upgrade you did?

umbral dagger
#

@pastel panther no. This is a small embedded humidity monitor/alarm. TrinketM0 + Si7021 breakout + TPL5110 + piezo buzzer + lipo

#

A few dozen lines of CP

pastel panther
#

noice

umbral dagger
#

I have thoughts of making into a product next summer.

pastel panther
#

@umbral dagger is it made to scratch a particular itch?

solar whale
#

@formal plover It was nice to learn to use the JLink commander tonight.

umbral dagger
#

@pastel panther yes

solar whale
#

Time for me to get to bed - Goodnight all!

umbral dagger
#

'night

idle owl
#

@solar whale Night!

formal plover
#

night @solar whale!!! Thanks for the help!

umbral dagger
#

@slender iron @tulip sleet What's the best way to inject a delay into the C code for CP? Akin to time.sleep(...)

pastel panther
#

night @solar whale

umbral dagger
#

@pastel panther Though if I do commercialize it, I'll probably do a fully custom board (i.e. no breakouts)

lofty topaz
#

@umbral dagger
asm
{
nop
nop
nop
}

#

๐Ÿ˜ƒ

umbral dagger
#

@lofty topaz lolz

pastel panther
#

@umbral dagger I'm always looking for excuses to make new boards, hence the metrowing exists

umbral dagger
#

@lofty topaz I want a delay on the order of a second. That's a lot of nops.

lofty topaz
#

@umbral dagger Sorry, it just popped into my head for some reason. Memories can be a beeech. ๐Ÿ˜ƒ

umbral dagger
#

@pastel panther I'm the same. This board uses the breakouts (& the Trinket) and will be for a small batch of prototypes to actually deploy.

#

@pastel panther You use Oshpark? I have yet to try them. I've used FritzingFab and now Aisler (since they took over as Fritzings fab)

#

Does Oshpark do assembly as well or just raw boards?

pastel panther
#

@umbral dagger I've only used them but for the two projects I have, they've been great. They only do boards, though rumor is they're working on a flex-pcb service

lofty topaz
#

@umbral dagger Have you checked out double difftime(time_t time1, time_t time2)

idle owl
#

I'm headed out as well. Good work tonight!

pastel panther
#

night @idle owl

umbral dagger
#

@idle owl Yeah, we seem to have made some progress.

formal plover
#

Yay progress!

#

@solar whale You never quit my friend

#

Lucky to have you around

#

Side note as I was catching up lol

umbral dagger
#

I'm out as well. 'night

formal plover
#

night @umbral dagger

pastel panther
#

night @umbral dagger

#

@formal plover so, have you been working on anything fun?

slender iron
#

@umbral dagger look in the time module. You can call the c implementation of sleep if you like

formal plover
#

@pastel panther Mainly just CircuitPython stuff. I have most the boards now, so just learning as I go. It's been a lot of fun

pastel panther
#

@nice I got my led matrix working in just a few minutes just the other day. Ain't CP great?

formal plover
#

Nice! Yes, it's awesome

#

@slender iron are you going to be on show and tell talking about CircuitPython again?

tulip sleet
#

<@&356864093652516868> Oh frabjous day. I just managed to build a Windows version of mpy-cross. It's 32-bit, I think. Compiled and ran a simple program. Try it out. We could supply this with the release.

pastel panther
#

@tulip sleet I can boot into windows and test it but I wouldn't know what to look for. Unless you think it might work with wine

tulip sleet
#

@pastel panther that's ok, it works for me. I'll leave it here for someone who uses windows all the time.

formal plover
#

great job @tulip sleet

#

as always

tidal kiln
#

i need a BeOS version, can you work on that next?

tulip sleet
#

now we have a complete set of cross-platform mpy-cross's, which is what I was wanting

#

@tidal kiln no, the next version will run on the Commodore 64

#

ok, good night, debugging in the morning

tidal kiln
#

๐Ÿ‘‹

formal plover
#

Night @tulip sleet !

pastel panther
#

Don't forget OS/2

#

ta ta

tulip sleet
#

tops-10

formal plover
#

I'm out as well, night all

pastel panther
#

buenos nachos

hollow tartan
#

oh oh THINGS were great until this happened:

#
   text    data     bss     dec     hex filename
 132574     808     872  134254   20c6e mpy-cross
make: Leaving directory `/home/vagrant/micropython/mpy-cross'
vagrant@vagrant-ubuntu-trusty-64:~/micropython$ cd ~/micropython/esp8266
-bash: cd: /home/vagrant/micropython/esp8266: No such file or directory
vagrant@vagrant-ubuntu-trusty-64:~/micropython$ make axtls
make: *** No rule to make target `axtls'.  Stop.
vagrant@vagrant-ubuntu-trusty-64:~/micropython$ make
make: *** No targets specified and no makefile found.  Stop.
vagrant@vagrant-ubuntu-trusty-64:~/micropython$
slender iron
#

@hollow tartan I think you need to be in the esp8266 directory

hollow tartan
#

okay... brb

#

it was there early in the step but now it is gone. ?

#

ls -l

#

and no sign of it.

#

? is my $PATH correct

#
/home/vagrant/esp-open-sdk/xtensa-lx106-elf/bin:/home/vagrant/xtensa-esp32-elf/b
in:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/
local/games
#

there is a

#

vagrant@vagrant-ubuntu-trusty-64:~/micropython/ports/esp8266$

#

directory

#

pressing on ... I get:

#
-rw-rw-r-- 1 vagrant vagrant  576404 Oct 25 04:36 firmware-combined.bin
-rwxrwxr-x 1 vagrant vagrant  894936 Oct 25 04:36 firmware.elf
-rw-rw-r-- 1 vagrant vagrant   35456 Oct 25 04:36 firmware.elf-0x00000.bin
-rw-rw-r-- 1 vagrant vagrant  539524 Oct 25 04:36 firmware.elf-0x09000.bin
-rw-rw-r-- 1 vagrant vagrant 2048253 Oct 25 04:36 firmware.map
vagrant@vagrant-ubuntu-trusty-64:~/micropython/ports/esp8266/build$
slender iron
#

did you try building axtls in ports/esp8266?

hollow tartan
#

yes, I did a cd ./ports/esp8266

#

it worked out find and I have installed my new bin into an ESP8266

#
object <module 'esp'> is of type module
  __name__ -- esp
  osdebug -- <function>
  sleep_type -- <function>
  deepsleep -- <function>
  flash_id -- <function>
  flash_read -- <function>
  flash_write -- <function>
  flash_erase -- <function>
  flash_size -- <function>
  flash_user_start -- <function>
  neopixel_write -- <function>
  apa102_write -- <function>
  dht_readinto -- <function>
  freemem -- <function>
  meminfo -- <function>
  check_fw -- <function>
  info -- <function>
  malloc -- <function>
  free -- <function>
  esf_free_bufs -- <function>
  set_native_code_location -- <function>
  SLEEP_NONE -- 0
  SLEEP_LIGHT -- 1
  SLEEP_MODEM -- 2
>>>```
#

So the methodology you want me to use is what exactly? to find the incongruent parameters.

slender iron
#

it should be as easy as changing the arg_check_num arguments

hollow tartan
#

hmmm he says

slender iron
#

now that you have it building it should be easy to test and verify

hollow tartan
#

I did see something that said once repl prompt returns it has no memory of the previous state. Seems to me that is making debugging extra hard. Is the a learn guide on learn.adafruit for debugging and or working issues?

#

yes , possibly can tweet a module if I can scope out a path to it. so where is the road map?

slender iron
#

loading a code.py with ampy on the esp8266 is an easier way to do it

#

I don't know what you mean by roadmap

manic glacierBOT
hollow tartan
#

I looked at the issue DigitalInOut.c#L65 and it contains the C source code in question. So they will all be like this one. I was given to thinking that it is a broader general problem. But, maybe you are saying that there are clearly defined specifc cases that issues have been noted already by others. Yes, that will be much easier.

manic glacierBOT
slender iron
#

@hollow tartan DigitalInOut is one case and the issue has another one noted

#

start with those, it does need a broader look

hollow tartan
#

OK, well, it is time to dream for 6 hours or more. I listen to The Dark Tower audio books for 30 min as I am falling asleep. ๐Ÿ˜ƒ

#

Roland, The Gun Slinger.

slender iron
#

night @hollow tartan !

drowsy geyser
#

Interesting. I just did a pull and built the latest CP 3.0 for the M4, and it no longer mounts as a mass storage device. At the same time, I don't have a working REPL.

manic glacierBOT
manic glacierBOT
stuck elbow
#

@tulip sleet Colloh! Callay!

formal plover
#

Ditto @drowsy geyser

drowsy geyser
#

Ah, ok. Thanks for confirming, @formal plover . I thought I might have messed up my build.

#

Unfortunately, I need to get ready for work or I'd plug in the JLink and see if I could figure out where the REPL is hanging.

formal plover
#

But hey, the NeoPixel works. Lolololol

#

Yeah. I'm working for home today, so I'll mess with it on lunch or a break later

drowsy geyser
#

Oh hey. My only meeting today is at 10. Maybe I'll take the M4 and JLink to work and tinker on my lunch break....

formal plover
#

Awesome @drowsy geyser. I'll be around. Just tag/ping me if you want my attention haha. People get cooking on these channel mid day, sometimes it takes me 15mins just to figure out what's going on.

#

The jlink is a really cool tool btw. Thank you @slender iron for getting us into testing with the jlink.

manic glacierBOT
drowsy geyser
#

@formal plover Tell me about it (the channel gets going mid-day). I usually have my personal laptop at work, too, but I can't keep up with the conversations!

stuck elbow
#

@formal plover you mean the software or the programmer?

umbral dagger
#

@tulip sleet a breakpoint() function... it's Smalltalk in 1980 all over again! In that case it was a halt method.

formal plover
#

@stuck elbow both I guess.

tulip sleet
#

@umbral dagger limor was interested in this. I was looking at what's coming up in Python 3.7. I was actually writing Smalltalk code in 1980.

stuck elbow
#

because I'm not really impressed by JLinkExe

umbral dagger
#

@tulip sleet sweet, Smalltalk was my first exposure to OO. Worked in it my first couple jobs out of grad school (and my grad work implementations primarily were in Smalltalk).

tulip sleet
umbral dagger
#

@tulip sleet As we move to more capable chips, it makes sense to enhance the implementation. Adding a debugger would be a good move.

formal plover
#

@stuck elbow Haha I just think it's cool that I can take a dead board and program it with the jlink. So I guess the concept is what I like

umbral dagger
#

@tulip sleet Legit background

tulip sleet
#

@umbral dagger I'm old

umbral dagger
#

@tulip sleet Some of us are.

stuck elbow
#

@formal plover I see, well, I'm quite used to microcontrollers that you can't brick. STM32s even have a serial bootloader built-in, so you don't even need a special programmer

formal plover
#

@tulip sleet has a very awesome/impressive background

#

He's the real deal.

stuck elbow
#

agreed

drowsy geyser
#

Ok, enough playing around. ๐Ÿ˜ƒ Time to put away Atmel Studio and actually get ready for work. I'll be AFK for a bit but I should be back online within the hour. I'm looking forward to the day's developments!

umbral dagger
#

@tulip sleet Back to CP... based on what I was seeign last night, I am wondering if there's a race condition with USB initialization and running main.py (or one of the other 3 options).

#

@tulip sleet Things run fine if there's no code to execute. I.e. screen connects and I'm in the repl. Add a code file then and all remains good.

#

@tulip sleet If there's a code file to start, screen just gives nothing. Remove the code file and boom you're in the repl.

tulip sleet
#

@umbral dagger you mean in 3.0? I'll look at that: it could easily be true. But on Linux, it's messed up even without main.py.

umbral dagger
#

3.0, latest (as of ~11:00pm ET) master. on Linux.

#

@tulip sleet With the patch you posted to only start one device.

tulip sleet
#

@umbral dagger - hmm - I'll erase my flash to make sure there's no main.py. Maybe just try a delay as well. Do you see stuff in syslog restarting every 30 seconds without main.py? That's what I was seeing.

drowsy geyser
#

@umbral dagger Does the default build include main.py? My board is not working so I can't check atm. I have a fresh compile and it neither gives me a REPL nor mounts CPYTHON.

umbral dagger
#

@tulip sleet I do.. approximately every 30 sec.

#

@tulip sleet And CIRCUITPY doesn't show up

tulip sleet
#

@umbral dagger same here I am planning to look very carefully at the ASF4 library this morning and how we are calling it.

floral dagger
#

lol @formal plover I know what you mean. I usually keep up with what's going on in here pretty well. Then, sometime around midday, it gets really busy, and it's like you're all speaking a foreign language lol.

umbral dagger
#

@tulip sleet OK.. several resets & dis/re-connection usb CIRCUITPY shows up and I can get the repl.

drowsy geyser
#

@umbral dagger You and @tulip sleet are using Linux?

tulip sleet
#

@drowsy geyser yes

formal plover
#

@floral dagger Haha right?! Or morning nothing works, then I check after work and @tulip sleet and @slender iron are on version 5.0 and 3.0 is sooo this morning. Lol

#

An exaggeration of course lol. But you get the point

umbral dagger
#

@tulip sleet Really smells like something in USB setup. The semi-nondeterminism makes me think race condition of some sort. Especially where that's happened elsewhere. And the fact that it's running ~3x faster than previous hardware.

drowsy geyser
#

Interesting. No amount of resetting/reconnecting will get it to work on Windows 10. I'll have a Linux desktop tomorrow night to experiment with.

umbral dagger
#

Different systems -> different USB stacks -> different timings -> different behaviour.

#

@drowsy geyser Linux, yes.

drowsy geyser
#

Thanks!

umbral dagger
#

Also, once I get to the repl, it seems pretty solid.

tulip sleet
#

@umbral dagger I am having the same problem on M0's. I haven't bothered to try on M4 yet. The devices are recognized properly by Linux if you look in the system log. But the issues with connecting to the REPL could be a race condition on the CPy side. THe "every 30 seconds" thing is odd, but the device is not talking to the host regularly, as it does in CPy 2.x (based on USb traces). ... Try letting it sit for several minutes with not activity and see if the REPL disconnects.

umbral dagger
#

AH.. ok. maybe not that. Or maybe since using the ASF code is a 3.0 addition, yes?

#

@tulip sleet leaving it sit in the repl and tailing syslog

tulip sleet
#

We switched from ASF3 to ASF4, which is a completely different set of libraries. It's also new and poorly documented. Scott had to write a scraper from the http://start.atmel.com website to get the code bundle: it's not even available as an ordinary packaged download, and there's no version information (can't tell when they update it).

#

There is no ASF3 for SAMD51, or else we would have just continued with that.

umbral dagger
#

@tulip sleet ugh

drowsy geyser
#

Slight update: on Windows 10 pressing reset does nothing to make CIRCUITPY appear or the repl work. Disconnecting and reconnecting, however, does make CIRCUITPY mount. As soon as I try writing a file to the device, though, it locks up, the write never completes, and the REPL is not available. Again, the reset button does nothing and it takes a power cycle/disconnect-reconnect to bring it back.

#

And the write worked , in that my code.py now runs, but it never "completed" from the OS perspective.

umbral dagger
#

@tulip sleet 5 minutes and repl is still good and no USB related activity in syslog

formal plover
#

@tulip sleet is 3.0 going to use ASF4 for all the boards, or just SAMD51 boards?

tulip sleet
#

@umbral dagger so the 30 second thing is something where the mass storage is cycling state for some reason.

#

ASF4 for all - it's too much trouble to have separate impls. If we can get it working on SAMD51 it should work fine on SAMD21 and vice versa. The differences are slight.

formal plover
#

@tulip sleet Gotcha. I figured as much

#

Once you guys get it stable, it won't be as painful I'm sure

#

Says the guy not directly working on core code

#

Hahaha

umbral dagger
#

OK.. back to Haskell for me. I'm around and this will be open if anything needs testing on linux. Just yell.

formal plover
#

Sounds good @umbral dagger. I'm on break right now, but I'll check in at my 2pm break to see if the Linux status has changed.

drowsy geyser
#

@umbral dagger Haskell? Wow. The quintessential functional language, and Python. Almost polar opposites (though functions are first class objects in Python, too).

umbral dagger
#

@drowsy geyser There are overlaps. The typing in Haskell was annoying at first, but I'm growing to love it. I spend most of my "free" time working in Lisp (Scheme actually), and various things for work. At the moment I'm adding some property based http API testing and decided to use QuickCheck. Now I'm refreshing/expanding my understanding of Haskell.

drowsy geyser
#

Nice!!!

#

is impressed

umbral dagger
#

@drowsy geyser You'll see me react at times with "don't use strings for that!" It seems to be a knee-jerk reaction now. "But.. but.. there's no type information on a string!"

#

@drowsy geyser Actually some things at work are getting more functional: ObjC -> Swift, Java -> Kotlin. The .Net folks are resolute in their love of C#. I'll be gently nudging them toward F# in time, but there's many of them. Also, we have several ex-MS people, so it's deeply engrained.

drowsy geyser
#

@umbral dagger I hear you on the C# camp (I work at Microsoft). But there are things that are forcing their hands. For example, HDInsights (aka Spark ๐Ÿ˜ƒ ) is really most effective with Scala - which I'm teaching myself since I've been offered a 1,000 core cluster for experimenting.

umbral dagger
#

@drowsy geyser Nice. Scala is certainly popular. Especially with the data commuinty. It's popular and high paying on the FP job boards, as well.

drowsy geyser
#

I'm still wrapping my head around functional programming. Just like people will look at my code and suggest more pythonic approaches ("you really should use a list comprehension there"), people will look at my Scala code and say my imperative programming background is showing. ๐Ÿ˜ƒ

fringe trench
#

@drowsy geyser Just remember not to have side effects!

#

heh.

drowsy geyser
#

Much easier said than done! At least for me....

fringe trench
#

If you can think back to math classes in college, that's what helps me.

#

But, I'm mostly a Python coder.

umbral dagger
#

@drowsy geyser That's why I like Haskell... stricter. IMO a better place to learn FP.

fringe trench
#

Haskell is a pure-functional language.

#

Which is why there are some weird things to do normal stuff you might want to do, like print things, that change the state of the world.

drowsy geyser
#

I'm mostly a security architect, but I dabble in coding, mostly Python and R, but now Scala. Maybe I should study Haskell in the evenings to sort of force my hand at FP....

fringe trench
#

Haskell is also a lazy-evaluation language, which lets you get away with apparently infinite loops.

#

Like defining the infinite sequence of counting numbers. It won't calculate any of them until you try to do something that actually requires a value.

#

Then it will calculate as many as you use, as you use them.

drowsy geyser
#

That's kind of interesting. I can see where that would be very useful in set theory.

fringe trench
#

Some of the Haskell libraries are built by people with a lot of interest in category theory.

#

Enough so that one of my friends joined a reading group to get a handle on Homotopy Type Theory.

#

Which I don't understand, so don't ask. ๐Ÿ˜ƒ

drowsy geyser
#

That's serious. ๐Ÿ˜ƒ

umbral dagger
#

Clojure is similarly lazy

fringe trench
#

My sense is that Clojure is very Lisp-y

umbral dagger
#

And you can easily implement lazy sequences in Scheme/Lisp

#

Clojure is a Lisp syntactically

#

It's somewhat something else really though

fringe trench
#

@umbral dagger function arguments are lazy in Haskell also.

#

It's lazy in general.

#

But, strongly typed, with decent type inference.

umbral dagger
#

@fringe trench You mean function ARGUMENT (singular) ๐Ÿ˜ƒ

fringe trench
#

autocurrying is a thing also, yes.

umbral dagger
#

@fringe trench multi-argument functions are really just curried single argument functions

#

@fringe trench but not in a hurry... lazily ๐Ÿ˜ƒ

fringe trench
#

thunk thunk thunk.

#

Anyway, I'm not any good at Haskell.

#

I just think it looks cool.

#

I've done Hello World in a number of languages, just so I have references.

drowsy geyser
#

So, if the argument is lazy, does that mean the compiler (interpreter?) doesn't allocate memory for the data until they're referenced?

umbral dagger
#

@tulip sleet from my poking around last night it looks like maybe_run is the entry point into the python VM. Yes? so one could replace the python vm (and a corresponding stuff around calling maybe_run) and get all the other goodness? repl command line editing, USB storage file system, etc? There's need to be changes to repl details, naturally.

#

@tulip sleet I'm just wondering how decoupled that is.

#

@tulip sleet See, I have this Scheme runtime in C that I've been working on with the idea of running it in an embedded environment...

#

@drowsy geyser Nothing gets evaluated until its value is requested.

drowsy geyser
#

Cool!

umbral dagger
#

@drowsy geyser Hence, if you have an infinite sequence, and ask for the first 5, it computes the first 5 values in the sequence. You can later ask for more values from it, and it will compute them then.

tulip sleet
#

@astels well, maybe, but the python object types are used all over the place. So for instance the stuff in shared-bindings is the python-to-hal interface, but sometimes the objects are passed down into the hal level. You could probably use the top level stuff around main.c, but there's not a lot of it.

fringe trench
#

@drowsy geyser I don't know.

tulip sleet
#

there was no attempt to decouple python knowledge at the various levels

fringe trench
#

@umbral dagger you could maybe port it as an IPython kernel, and interact with it in Jupyter notebooks....

umbral dagger
#

@tulip sleet makes sense. The USB storage and change detection, and USB repl are the especially interesting bits.

tulip sleet
#

@umbral dagger yes, the lowest level stuff that talks to the HW libraries could be reused, and the FAT storage stuff, which was adapted from an existing library.

#

The change detection has its own issues, due to delayed write of metadata both in Windows and Linux.

umbral dagger
#

@tulip sleet OK, sounds like I could reuse enough to be worthwhile. If I ever get back to that project. It's close.. just have to finish the gc.

fading solstice
#

Did i miss something concerning M4 USB. I built metro M4 using latest this morning. My ubuntu machine now sees the CIRCUITPY drive (which wasn't working yesterday), but now my windows 10 machine does not mount the drive (which was was working day before yesterday)

solar whale
#

@fading solstice yes - USB is rather unstable depending on platform and karma... It is being actively worked. Tha last 6000 or so messages (excluding the Haskeil discussion) contain the sordid details of testing last evening and htis morning. ๐Ÿ˜‰

fading solstice
#

ok thanks

solar whale
#

the response on Linux/Windows/mac/Rasp Pi are all different .

frail geode
#

Hi folks! My M4 arrived. Are there any docs or a "getting started" link, or is that all in the package?

tidal kiln
#

ha! good question. i think the chat in this channel over the last few days is 90% about this.

#

but i'm wondering same. if anyone has consolidated notes? i'm not going to be able to really take mine for a spin for a day or so.

solar whale
#

@frail geode It's a moving target but I think this si sa basic outline use Jlink to load new bootlader that supports UF2 Flash the latest CP 3.0 Build for the M4 The latest bootloader has been posted to theis channel - last nigtht there were several.

bronze geyser
#

is it possible to use Atom with Feather Huzzah Circuit Python?

umbral dagger
#

@tidal kiln It's a moving target so I'm not sure what value that woudl have. Other than things like "how to flash the bootloader using jlink".

drowsy geyser
#

You can also build the image and use bossac if you don't want to go through setting up JLink...

manic glacierBOT
solar whale
#

@drowsy geyser yes - good point - Whne I first did that I had to update bossac - is that still necessary or is it icorpartaed into the CP repo now.

umbral dagger
#

That stuff would be useful to have on a guide somewhere, regardless, for people that want to do low level hacking or debug C firmware.

drowsy geyser
#

I had to update bossac, but that was last weekend.

#

I'm not sure of the current status.

#

I have a OneNote notebook of all my tasks, from "I have a box with JLink and a bare M4 board" up to, well, this morning's USB discussion.

#

I can start making a guide, though I'll need help with the MacOS parts.

tidal kiln
#

@bronze geyser yes. in general, you can use any text editor.

bronze geyser
#

Thanks @tidal kiln I guess I'm being stupid. I keep thinking I need a REPL interface to interact with Python on the Huzzah...at the least be able to "mount" a drive like I can on the raspberry pi.

frail geode
#

thanks @solar whale and folks

solar whale
#

It was nice to find taht we culd upload the bootloader with just JLinkEXE (aka Jlink Commander) - It can also be done with JLinkGDBServer or Ozone. Choose your weapon....

tidal kiln
#

@bronze geyser using the REPL isn't required, it's just another way to interact with Python running on the board. in that case (accessing REPL) you would use some form of terminal program

bronze geyser
#

@tidal kiln = yah, if I wanna REPL, I use CoolTerm and all is great.

tidal kiln
#

@bronze geyser the other way is to just edit a text file and put it on the board, it will then run it for you automatically

solar whale
#

@bronze geyser there is no USB like file system on the Feather Huzzah for CircuitPythion

bronze geyser
#

Thank you @solar whale. How do I save a file I'm editing in Atom (and then run it)?

#

ah. Right. there was some apy tool or something...thank you.

solar whale
#

@bronze geyser you have to upload it via the ampy tool - or WebREPL if you have that working.

#

ampy is the best way in my opinion.

bronze geyser
#

ah yes @solar whale . Thank you very much. Thank you @tidal kiln.

tidal kiln
#

thanks @solar whale , yeah, the huzzah is a little different

solar whale
#

a little ๐Ÿ˜‰

tidal kiln
#

didn't read past 'feather'

bronze geyser
#

Another challenge I have with the Huzzah is lack of external antenna (i.e. : no FCC/CE certification...so no offering.)

tidal kiln
#

that should be on the module itself

solar whale
#

@bronze geyser one warnigt - make sure you exit your terminall session to the Huzzah before trying to use ampy to load. Only one serial connection at a time....

bronze geyser
#

@solar whale Oh. Right. makes sense. Thank you.

solar whale
#

I forget at least once a day....

manic glacierBOT
formal plover
#

@bronze geyser HUZZAH, much fun there. Only CircuitPython board with Wi-Fi currently

manic glacierBOT
#

We could also reach out upstream to see if its development we could fund.

On Wed, Oct 25, 2017 at 9:09 AM Dan Halbert notifications@github.com
wrote:

yeah - it provides us a syntax that will be the standard

โ€”
You are receiving this because you commented.

Reply to this email directly, view it on GitHub
https://github.com/adafruit/circuitpython/issues/298#issuecomment-339383022,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AADNqZr3jJgMUEODnfGdV...

bronze geyser
#

@kurt h I thought Feather M0 WiFi - ATSAMD21 + ATWINC1500 would have CircuitPython. But ah yes. Different wifi

manic glacierBOT
solar whale
#

@bronze geyser there is wifi support for the M0 boards with the ATWINC1500 but it has not been implmented in CircuitPython -- yet

formal plover
#

To my knowledge, networking only works on the HUZZAH ESP8266

#

For CircuitPython that is

manic glacierBOT
bronze geyser
#

I am using a Arduino SPI library that talks to an ATM90e26 (energy monitor - reads power, voltage and stuff with input being a current transformer). I'm using it to monitor my house's energy use. I thought..geez...looks like it should be fairly "easy" to port this Arduino SPI to circuit python...but then...sigh...i (probably) need an external antenna...hmmm...there are esp-07's that have external antenna's...so now...hmm...i might try w/ this board.

solar whale
#

Circuit Python has SPI support so hopefully that should make it easier.

meager fog
#

installation details in readme, scroll down

#

arduino core is 'pretty much done' and we appreciate any bug reports on that too - USB host and I2S dont work but honestly, they didn't work great on SAMD21 either ๐Ÿ˜„

solar whale
#

@meager fog is there a linux build of the updated bossac that can be added to the released builds?

meager fog
#

not at this time because i dont have access to a linux box ๐Ÿ˜ƒ if you do, give me the bin and ill attach it

solar whale
#

I'll make one toninght when I get home and pass it along. - it is from the arduino branch, correct?

meager fog
#

yep

solar whale
#

OK - I was planning to set up the arduino support on my linux system this eveing so I'll be able to test it out.

manic glacierBOT
meager fog
#

@solar whale that would be great, please do! i know Arduino IDE on linux can be a little different

formal plover
#

@meager fog I can try Arduino on it as well. Until CircuitPython Linux issues are sorted out.

#

I'll follow up with @solar whale on it

tulip sleet
#

@slender iron here is someone else trying to use ASF4 and MSC. Very helpful. I also was wondering about MODE SENSE. https://hackaday.io/project/20772-orthrus/log/68209-firmware-success. I'll see if I can find his code.

I got Orthrus v3 hardware working all the way as a disk drive last night. There are a few bugs in Start's code that you have to work around:Start doesn't adjust the UTMI_CKTRIM register when configured with a 16 MHx crystal. You have to do that yourself.mscdf.c has no support for the MODE_SENSE_6 command, which is necessary (you just have to give back 4 zero bytes).mscdf.c has a bug where it returns non-zero when there's no error sending the zero-length "sync" at the end of a write.Start doesn't allow you to configure 512 byte endpoints, as the HS spec requires.There are still a couple of bugs to work out - mostly centered around the handling of situations where cards are removed or missing.Performance is not as good as hoped. Throughput is around 540 MB/sec. Halving the SD card clock doesn't appreciably change throughput, so this may be being limited by USB. But even at only ~5 times faster than before, it's now actually usable as opposed to unacceptable.Another couple of days to polish the firmware, and I think I'll be able to send some units off to the HP judges!

slender iron
#

awesome! we should reach out

formal plover
#

"Reaching out, touching me, touching you" ๐ŸŽต

#

You know where I'm going with this @slender iron.... Sweet Caroline!!!!

#

Sorry I had to

tulip sleet
tidal kiln
#

is macos finder complaining about data loss a known UF2 thing? like when dragging a UF2 file over.

#

seems like something i remember seeing mentioned before. maybe?

slender iron
#

it complains about the early eject

#

the uf2 bootloader is smart enough to know when it has everything it needs

tidal kiln
#

The Finder can't complete the operation because some data in the "FileName.UF2" can't be read or written. (error Code - 36)

#

that's it. expected / ignore?

solar whale
#

@tidal kiln I have never seen that.

#

but its been 12 hours since I built 3.0 so who knows ๐Ÿ˜‰

tidal kiln
#

this is with current shipped image

slender iron
#

shipped on what?

tidal kiln
#

cpx

slender iron
#

hrm, I haven't seen it

solar whale
#

Sorry _ ithought you were talking about M4

tidal kiln
#

no worries

#

i'm trying to catch up on my other duties so i can join everyone else in m4 land ๐Ÿ™ƒ

solar whale
#

I wonder if that user has the v1.23 bootloader installed as recommended in the guide.

#

but that error sounds like it is on the Mac side.

slender iron
#

@tidal kiln it may be worth asking them if it works despite the error

tidal kiln
#

yep. almost did. we'll see what happens if they go through the posted steps again.

formal plover
#

@solar whale if you're around later, might request your help with Arduino and the M4

tidal kiln
#

not sure they knew about those

solar whale
#

@formal plover sure - be happy to help. Will you be installig it on the RPi?

formal plover
#

I've got some errands after work and ask an engineer is on tonight, so I'm not 100% sure, but we shall see. Yup, on the Pi

solar whale
#

Hopefully if I get it workign on Linux RPi will be the same - I can try it on mine as well. I may not be availble late tonight but we'll get to it soon!

pastel panther
#

@tulip sleet @slender iron regarding Orthus, I actually know the guy who wrote it from my first job, though I doubt he remembers me

#

He was a rock star and I was a lowly QA peon

tulip sleet
#

@pastel panther he fixed about five bugs in the ASF4 MSC impl; he clearly knows that low-level stuff; I'm trying his patches right now. you can tell me more in DM if you'd rather it be private (e.g. company, etc.)

formal plover
#

@pastel panther after things get a little more stable with 3.0 and Linux, I'll try to whip up a quick guide for the flashing the M4.

pastel panther
#

@formal plover sweet!

slender iron
#

@tulip sleet I'm looking at improving travis

formal plover
#

It won't be anything fancy since after this is full blown production it'll never get used

slender iron
#

what do you all think about bring the xtensa toolchain in as a submodule?

solar whale
#

@slender iron doesn't the xtensa toochain require a "case-sesnsitve FS on a Mac" - will this cause problems for people who clone the repo?

slender iron
tulip sleet
#

you mean https://github.com/pfalcon/esp-open-sdk, and stick it under esp8266 ? There's still a lot of setup needed, but it would make it easier to keep up to date. But maybe just a README in there would be good. I'm wondering if there would be platform issues (one commit works on Linux, another is needed for Mac, etc.)

slender iron
#

yeah, thats what I'm thinking

#

more as a way to get travis building the esp8266 builds too

solar whale
#

@slender iron the reason I do my esp8266 build in a Vagrant VM is to avoid the case senitive FS for the xtensa.

slender iron
#

yeah, I have a sparsebundle FS on my mac for it

solar whale
#

do you just have to put xtensa in it ? or the whole CP repo?

tulip sleet
#

but you'd have to build the toolchain on each travis run, no? Or we need to pre-build it and stick that somewhere.

slender iron
#

@solar whale both

tulip sleet
#

oooooh! (pronounced with a long u sound)

slender iron
#

๐Ÿ˜ƒ

tulip sleet
#

@slender iron diff topic: I built a windows mpy-cross last night and passed it to her. I suggested and she liked adding some precompiled mpy-cross's to the release dir now. There'll be pointers in a Learn Guide. I have windows, mac, and 64-bit linux right now. Could build rpi and 32-bit linux later.

#

any qualms?

slender iron
#

@formal plover might be better for rpi since he does his dev on one

tulip sleet
#

yah, we can just ask someone. I was going to spin up one of my rpi's

slender iron
#

and precompiled mpy-crosses are fine with me

formal plover
#

@slender iron what am I doing? Lol

tulip sleet
#

we just had a discussion: I am under the impression that the MPy compiler reads the entire source file into RAM without stripping comments or anything in advance. Do you happen to know? I can look it up.

#

@formal plover do you have a built rpi mpy-cross you can drop here? Also @solar whale might have one. We are collecting a set to include with the release

slender iron
#

@tulip sleet I don't think it does because the lexer does the reading

tulip sleet
#

maybe that used to be true

slender iron
#

when I looked into it before I believe the memory peak was when converting the ASTish thing to byte code

solar whale
#

I dont have one now, but I can make one if needed.

tulip sleet
#

but maybe there are comments in the AST

slender iron
#

maybe

tulip sleet
#

anyway, I can check

#

@solar whale if it's handy or @formal plover has one, that woudl be great. Otherwise I will boot up one of my rpis.

slender iron
#

the heap profiling stuff I did woudl be agood way to look

solar whale
#

@tulip sleet I can't do it for a few hours yet but happy to do it then.

tulip sleet
#

@solar whale i'll get back to you if i need it.

#

tnx

formal plover
#

I have a Pi handy but not a mpy-cross

#

I don't even know what is Lolololol

#

Obviously it's a mpy file, but I dunno what the cross is

slender iron
#

@formal plover have you built circuitpython yourself yet?

formal plover
#

@slender iron nope

tulip sleet
#

mac folks - if i have an mpy-cross that is built on high sierra is it likely to be able to run on earlier versions? It's just an executable, but it may have some external dependencies, I guess (the equivalent of .so)

slender iron
#

@tulip sleet I can provide one

idle owl
#

@tulip sleet I was told it has dependency issues with previous versions.

#

I offered mine up to someone running something earlier and it failed. I'm on Sierra.

slender iron
#

I'm on high sierra

tulip sleet
#

@slender iron I have one I built for kattni a couple of weeks ago. Maybe it could be statically linked.

formal plover
#

@slender iron one of the only things I haven't done since working on CircuitPython.

#

That and core code work

#

I'm not as legit/cool as @idle owl

#

Hahaha

idle owl
#

Hah!

#

@formal plover I only built anything at all for the first time this weekend when I built CircuitPython. ๐Ÿ˜ƒ

solar whale
#

@idle owl and if I recall correctly, you did not build mpy-cross - is is not need for 3.0 yet. I meant to have you go back and do it.

idle owl
#

@solar whale I did not build mpy-cross, nope. The version of it I have is from Dan and I was using it to get mpys for 2.x use

solar whale
#

it is easy - just cd into mpy-cross subdirectory and type make.

umbral dagger
#

@slender iron @tulip sleet I just looked at the lexer. It skips over comments.

tulip sleet
#

@umbral dagger but is it reading from the file or from a string?

idle owl
#

@solar whale For 3.0 ?

umbral dagger
#

@tulip sleet I'll look... should be the same at that point unless it's weird

hollow tartan
#

I upgraded the ubuntu from 12 to 14. and I have some troubles.

#
William@Magnificat_V2 MINGW64 ~/esp8266-micropython-vagrant (master)
$ vagrant up --provider=virtualbox
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'ubuntu/trusty64' is up to date...
==> default: Clearing any previously set forwarded ports...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
Timed out while waiting for the machine to boot. This means that
Vagrant was unable to communicate with the guest machine within
the configured ("config.vm.boot_timeout" value) time period.

If you look above, you should be able to see the error(s) that
Vagrant had when attempting to connect to the machine. These errors
are usually good hints as to what may be wrong.

If you're using a custom box, make sure that networking is properly
working and you're able to connect to the machine. It is a common
problem that networking isn't setup properly in these boxes.
Verify that authentication configurations are also setup properly,
as well.

If the box appears to be booting properly, you may want to increase
the timeout ("config.vm.boot_timeout") value.
solar whale
#

@idle owl same mpy-cross for 2.x and 3.0

tulip sleet
#

i was collecting mpy-cross's for 2.1, not 3, but yes, it should be the same

idle owl
#

Just make?

hollow tartan
#

it also wanted me to provide the chef url and I left it blank.

solar whale
#

in circuitpython/mpy-cross - just make

idle owl
#

Fancy!

umbral dagger
#

@tulip sleet Looks to all go through the same thing from what I see. There are various ways to instantiate a lexer: file name, file handle, string.

#

@tulip sleet A different reader gets created in each case, and handed to the lexer.

#

py/lexer.c starting at line 669

manic glacierBOT
solar whale
#

@obsidian helm how did you do the ubuntu update?? the vagrant config should have loaded the ubuntu version it is configured for.

tulip sleet
#

@umbral dagger that sounds good. thanks for the code research! it was a q limor had

hollow tartan
#

@solar whale right, after the ssh booted it suggested that I upgrade to 14 and told me the command to use.

idle owl
#

@split ocean Nice job on the UFO!

sick creek
#

soon that UFO fly inside @split ocean workshop

split ocean
#

Thank you @idle owl and thanks so much for your help!

idle owl
#

@split ocean Anytime!

split ocean
#

@sick creek I think it'll make a nice addition to the decor

solar whale
#

@hollow tartan hmm - I'll have to check my congiuration after I get home.

formal plover
#

@split ocean it took all of me to not switch my avatar to your 90s photo and wait for someone to notice

sick creek
#

@split ocean the important part is circle motion

hollow tartan
#

@solar whale okay , I will wait to work with you in 3 or 4 hours.

sick creek
#

@split ocean if you can make 2 opposide rotate rings

split ocean
#

Ooh, I've got one of those big 60 pixel rings left over from my Lucio blaster project...

sick creek
#

that design need 2 rings what rotate oppposite directions enough speed so the UFO should hover

idle owl
#

@split ocean I love that you just have a 60 pixel ring left over from something.

umbral dagger
#

@tulip sleet @slender iron From a small bit of code spelunking it appears that python source is compiled to bytecode. That happens with all code I assume. The bytecode is stored in, and excuted from, RAM. I'm guessing that MPY files are precompiled bytecode. Does that get copied to RAM before execution or is it executed directly from FLASH?

sick creek
#

@split ocean try first with 2 fidget spinners perhaps if you can make them rotate different direction with circuitpython code and iterate from there

tulip sleet
#

@umbral dagger .mpy files are loaded into RAM. Only bytecode that is built into the firmware image ("internal frozen modules") can be executed from flash. So importing a .mpy saves a compilation step, but does not save any RAM during executiong.

umbral dagger
#

@tulip sleet Thanks. That gives me a couple intersting things to look in to (this stuff is where I live ๐Ÿ˜ƒ ) Related: With growing Flash space has thought been given to freezing more modules?

tulip sleet
#

@umbral dagger yup right now there are only internal frozen modules in CPX, but we can add more. In the small M0 builds there is still not enough room for anything, and we have more C stuff we want to add (framebuf, turn some features back on, etc.). On the Express boards, we can freeze more stuff. Advantage is saving RAM; disadvantage is keeping them up to date and explaing to people about sys.path and how to make sure the internal frozen ones are imported rather than those in lib/

umbral dagger
#

@tulip sleet That all makes sense. Flash grows faster than ram as you move to bigger chips. And you have the option of SPI flash as well (that must slow things down significantly, though... ya? Or is flash slow enough that SPI latency doesn't impact much? Not something I've spent time exploring.)

tulip sleet
#

@umbral dagger you can't execute from SPI flash unless you enable XIP (execute in place), and have a 4-bit (QSPI) SPI flash chip interface. Then the external flash can be mapped into the CPU's address space. That's on the SAMD51 but not the 21. The SPI flash chips we're using are single-bit.

slender iron
#

@tulip sleet where are you at on the MSC stuff? I'm about ready to pick something else up

tulip sleet
#

can we voice chat? it's a bit involved

slender iron
#

sure!

solar whale
#

@obsidian helm When I installed the esp8266 vagrant a few days ago, it installed Ubuntu 14.04 - Whn I ssh - it does let me know that 16.04 is avaialble, but I have not tried upgrading it.I'm not sure if that will cause any problems or not. Your report alos say it was using Ubuntu Trusty which is 14.04 so I am confused by your saying you were upgrading from 12 to 14....

slender iron
solar whale
#

@tulip sleet @slender iron have either of you ever tried upgrading the Ubuntu release within a Vagrant VM - since the Vagranfile is looking for a specific release, I think that will cause a problem, but I was curious if you have ever tried it?

slender iron
umbral dagger
#

Heh... claims to have developed it using TDD, then goes on to say "However, due to my limited time, not all the code base is tested yet, and it will be indeed an challenging to keep the test up to the code." Sigh.

slender iron
#

@umbral dagger he actually contracts for adafruit and will probably circle back to it

#

I'm thinking it'll be a good usb stack to share across ports in circuitpython

tulip sleet
#

@solar whale I have not tried that. I'd start with a newer vagrant base

solar whale
#

@tulip sleet agreed but just trying to help @obsidian helm using the micropython_esp8266 as provided - I suggest leaving it as distributed.

umbral dagger
#

@slender iron Cool. My comment relates to him saying two different things. The sigh was becasue that's so common... even after 17ish years.

tulip sleet
umbral dagger
#

@slender iron Having an 'internal' USB stack has definite advantages.

#

FYI: James' book on TDD for embedded C is good. Google did some amazing things TDD related for C++ using macros & templates. Mindboggling cool stuff. I think all that has been opensourced.

#

@tulip sleet That was back in my Java days shudder

tidal kiln
#

@slender iron question if you're free ๐Ÿ™‹

tulip sleet
#

@tidal kiln he said he was getting lunch

tidal kiln
#

k. thanks @tulip sleet

stuck elbow
#

what's maxiumum possible SPI clock on the samd21? I got as high as 24MHz, can I go higher?

#

I can't find it in the datasheet

#

and the code for _sercom_get_sync_baud_val is a bit convoluted

tulip sleet
stuck elbow
#

that is weird, I have it working with baudrate=24000000 on my display right now

slender iron
#

@stuck elbow I thought 12mhz as well

#

@umbral dagger I was at google for six years so my affinity for testing comes from there

#

@tidal kiln whats up?

tidal kiln
#

using tuple to specify channels for differential adc

umbral dagger
#

@slender iron Nice. I was with the Test Mercenaries, part of the Testing Grouplet, and edited Testing on the Toilet for a while.

tidal kiln
#

chan0 = adc[(0,1)] (oops edited)

slender iron
#

nice! I loved testing on the toilet

tulip sleet
tidal kiln
#

guess you would like similar syntax for single ended?

slender iron
#

haha, ok

tidal kiln
#

chan0 = adc[0]

slender iron
#

I'd only do a tuple for differential

#

nah, just the int

#

adc[0]

#

๐Ÿ‘

tidal kiln
#

ok. good.

#

it's also pretty failsafe

#

one element tuples are a little weird

#

(0,) not (0)

slender iron
#

exactly

tidal kiln
#

but (0) is just 0 so if someone tries it, it will work

slender iron
#

yup yup

tidal kiln
#

next question is what error to throw

#

i'm using a dict to map the tuple request to actual adc channel

slender iron
#

IndexError I believe

#

or KeyError

tidal kiln
#

so easiest would be to just let it do the work, which would be a KeyError

#

yep. KeyError

#

you don't want me to trap that and throw something else?

stuck elbow
#

@tulip sleet well, 48MHz works in circuitpython, though I have no idea what SPI clock it results in actually โ€” looking at the display's refresh speed, it seems to be less than 48MHz

solar whale
#

@meager fog I tried updating for the samd51 for arduino on linux but when I try to compile blink I get lots of errors - here are the first few - any suggestions?? ```Arduino: 1.8.5 (Linux), Board: "Adafruit Metro M4 (SAMD51)"

In file included from /home/jerryneedell/Arduino/hardware/Adafruit/samd/cores/arduino/Arduino.h:66:0,
from sketch/Blink.ino.cpp:1:
/home/jerryneedell/Arduino/hardware/Adafruit/samd/cores/arduino/WVariant.h:107:36: error: 'TCC_INST_NUM' was not declared in this scope
extern const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM] ;
^
/home/jerryneedell/Arduino/hardware/Adafruit/samd/cores/arduino/WVariant.h:107:49: error: 'TC_INST_NUM' was not declared in this scope
extern const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM] ;
^
In file included from /home/jerryneedell/Arduino/hardware/Adafruit/samd/variants/metro_m4/variant.h:42:0,
from /home/jerryneedell/Arduino/hardware/Adafruit/samd/cores/arduino/delay.h:27,
from /home/jerryneedell/Arduino/hardware/Adafruit/samd/cores/arduino/Arduino.h:81,
from sketch/Blink.ino.cpp:1:
/home/jerryneedell/Arduino/hardware/Adafruit/samd/cores/arduino/SERCOM.h:146:16: error: expected ')' before '' token
SERCOM(Sercom
s) ;
^

slender iron
#

@tidal kiln nah, KeyError is fine

tidal kiln
#

๐Ÿ‘

#

k. let me push what i got up.

slender iron
#

I'm gonna go heads down on USB reliability until the meeting. I can look later or tomorrow

idle owl
#

@slender iron Good luck. Here for testing if you need it.

tidal kiln
#

@slender iron cool. it's up now. same link as before. make sure to look at multi branch

#

for whenevs

idle owl
#

@tidal kiln Are (0,1) etc. addresses or something?

tidal kiln
#

keys

idle owl
#

ah

tidal kiln
#

basic dictionary semantics:

dictionary = { key : value }
#

and you can have as many key/value pairs as you want

idle owl
#

nice

tidal kiln
#

and...the best part.....they can be anything

idle owl
#

So it's arbitrary?

tidal kiln
#

pretty much

#

the most obvious is for the key to be something simple, like an int

#

but doesn't have to be

#

what i linked uses tuples for the key

#

oh, and to get an item, you use:

dictionary[key]
formal plover
#

@tidal kiln weren't you the one helping me with that back when I was working with my HUZZAH and open weather?

#

Dictionary stuff I mean

tidal kiln
#

maybe. rings a bell. something that looked like a json return?

formal plover
#

Yes!!!

tidal kiln
#

guess so then

idle owl
#

(brb also teaching someone else here ๐Ÿ˜ƒ )

formal plover
#

And the usual crowd was around too @solar whale an company lol

stuck elbow
#

hmm, the logic analyzer actually says it's 2.5MHz

#

at the best, it's very uneven, ranging from 500kHz ot 2.5MHz

#

correction, I had my analyzer in the wrong mode, it actually gives between 20MHz and 25MHz

solar whale
#

@meager fog Nevermind!! It was a problem with the "Device" file - all fixed - Blink works fine - Si7021 works fine!! all good

#

@meager fog oops - minor correction - I had an MCP9808 connected - it works great - si7021 code ran fine but gave funny results ๐Ÿ˜‰

tulip sleet
#

@solar whale I'm getting the arm-none toolchain set up on an RPi. Looks like I need to build it. Or did you just use the native Raspbian compiler?

umbral dagger
#

@tidal kiln @idle owl Re: dictionary keys. Yes, they can be anything, but the implementation has optimizations for numbers and strings. In your case the keys are 2-tuples of small numbers so it's still fast/simple: hash each element of the tuple and add them. Using more complex structures as keys gets more expensive.

tidal kiln
#

yep. nothing comes for free.

umbral dagger
#

@tidal kiln @idle owl Another thing about dictionaries, and probably more relevant in small memory environments is that can take up significantly more room that what they contain, and they grow non-linearly to maintain a certain overhead as you add to them. They do this to try to maintain a high lookup speed. You're trading space for time. If you're not familiar with the implementation it could be a surprize.

#

@tidal kiln @idle owl In this case you only have a few things in it, and it doesn't grow over time, so it' doesn't have much impact.

tidal kiln
#

if there's a more efficient approach, please let me know

#

efficient, but still has user friendly syntax

umbral dagger
#

@tidal kiln In this case you're fine: small and simple -> little overhead and cheap hashing.

#

py/map.c and py/objdict.c is the relevant implementation

tidal kiln
#

but even there. i'm always amazed at how there always seems to be a better way for everything.

#

at which point someone points out some python feature i've never seen before

cunning crypt
#

@tidal kiln That's... pretty much all of my projects, ever. After I'm done, "Have you tried X?" "Huh, that would have saved me a lot of time before!"

umbral dagger
#

@tidal kiln You'll often find that it's a trade off between readability/understandability/maintainability and efficiency. Always default to the former. Optimize to something more efficient (and again time/space is then often a tradeoff) only when you have a proven, observable need to.

tidal kiln
#

yep. that's inline with my approach.

#

although for embedded stuff, the later can sometimes be the driver.

umbral dagger
#

@tidal kiln And if you do optimize and have something less understandable, document/comment the *&^$#) out of it.

tidal kiln
#

of course. i always document. ๐Ÿ™„

umbral dagger
#

@tidal kiln Yes, embedded has a different set of constraints.

tidal kiln
#

yep. and cp is interesting as both are drivers.

#

readability (so it's beginner friendly) and efficiency (since we're running on mcu's)

cunning crypt
#

If you're running on a non-Express board, you can even get to a point where individual characters can be too much filespace.

umbral dagger
#

Definitely. Memory is probably a bigger constraint than time in most cases anyway. And you often also have power consumption to consider.

#

That said, The chip on the M4 is so much more everything that my first computers (ZX81 and then Apple ][+)....

tidal kiln
#

avoid big letters, like O and W and try use skinny ones like I

umbral dagger
#

The ATMEGA328 is more in line with those machines.

#

@tidal kiln Well, certainly forget using unicode ๐Ÿ˜ƒ

stuck elbow
#

I'm waiting for someone to write a python minifier

#

then I can safely give up on python and move onto rust or something

pastel panther
#

@stuck elbow wouldn't you need a python bytecode minifier?

umbral dagger
#

@stuck elbow Well MP/CP is compiled to bytecode on load and you can precompile to mpy files.

pastel panther
#

(for memory usage at least)

stuck elbow
#

@umbral dagger but all the names are retained

umbral dagger
#

@pastel panther I'm not sure (yet) how much the MP compiler optimizes.

stuck elbow
#

so shortening function and variable names still gives you gains

umbral dagger
#

@stuck elbow Yes, right you are. That should be a simple compiler optimization... that adds complexity and overhead, so many in the py->mpy version.

pastel panther
#

It would be interesting to see a color coded or otherwise human decipherable map of memory usage

umbral dagger
#

@pastel panther I believe there's a way to get one

#

@pastel panther in the repl

stuck elbow
#

@silent radish you can't do that, as some programs would stop working -- namely the ones that use getattr with computed values

#

python is too dynamic for such optimizations

pastel panther
#

@umbral dagger I think I mean something like a byte by byte layout of memory, not a usage figure

stuck elbow
#

@pastel panther that's available in micropython

#

@pastel panther not sure if cp has it

umbral dagger
#

@stuck elbow Hmmm...

pastel panther
#

@stuck elbow Like a realtime map or some generic "these things go to these addreses"?

stuck elbow
#

let me show you

umbral dagger
#

@stuck elbow Also, I'm new to python.

stuck elbow
#

here

#
>>> micropython.mem_info(1)
stack: 2144 out of 8192
GC: total: 36288, used: 7248, free: 29040
 No. of 1-blocks: 49, 2-blocks: 14, max blk sz: 264, max free sz: 1806
GC memory layout; from 3ffef2b0:
00000: h=ShhhMhSDhBhDhB=BBBh===h====hhBhh==h===========================
00400: ================================================================
00800: ================================================================
00c00: ================================================================
01000: ============================================hBh==AAh=======h====
01400: ================================================================
01800: =============h=hBhThShh==hh=hhBh=hBhhhBhTSh=hhh=h=h===h=h=h=Bh=B
01c00: ..h...h=....h=..................................................
       (27 lines all free)
08c00: ............................
pastel panther
#

ooh

umbral dagger
#

That's what I was thinking of

stuck elbow
#

a dot is free memory, each letter is a different structure (object, list, etc.) and equals means the same object as before contiunues

pastel panther
#

cool

stuck elbow
#

@umbral dagger what did you use before? do you have any experience with dynamic languages like perl, js, lua, lisp, etc.?

manic glacierBOT
pastel panther
#

It would be super cool if you could inspect the values as well but I imagine that would be significanly harder

stuck elbow
#

well, you can access arbitrary memory addresses

pastel panther
#

Hmm.....

#

hmm.....

#

Can you take a snapshot?

stuck elbow
#

where would you save it?

pastel panther
#

I don't know! To your segger?

#

Good point though

stuck elbow
#

ah, well, with a debugger you can just pause your program and get the memory contents

pastel panther
#

I'm excited to play around with my jlink when it arrives. I imagine not every debugger is made equal though and I'm only getting the mini for now

stuck elbow
#

I honestly can't see why the dongle you are using should even matter

pastel panther
#

Because licencing?

stuck elbow
#

all it does is forwarding the commands from your computer and giving back what it got in reply

#

licensing is unenforceable in open source world

#

you can't license the specification of the commands

pastel panther
#

Hearing people on the embedded podcast talk about debuggers, I got the impression that nicer ones (tracers?) can do a strace like dump of instructions as they're completed

stuck elbow
#

and once the commands are known, I can build my own debugger

pastel panther
#

Hey, if you want to build a sweet open hardware debugger, I'm all for it

stuck elbow
#

there is black magic probe already

#

I have one here

pastel panther
#

Do they do everything you would want?

stuck elbow
#

not sure it talks swd though

#

well, it's open source, so if it doesn't do something you want, you can add it

pastel panther
#

noice

stuck elbow
#

note that I don't really have that much experience with different debuggers

#

so far I have only used the stlink and played briefly with black magic probe

#

so maybe there are some limitations of the actual hardware -- like the sizes of buffers or something

pastel panther
#

I'm sure. Back to the salt mines for me, ttyl

idle owl
#

I helped my friend make a servo work on the CPX using MakeCode today! She's really getting into this. She's learning a lot!

idle owl
#

Next step will be CircuitPython, but I think we're not there yet. She's starting to think in code structure though, so I think it's going wonderfully.

slender iron
#

and tracing isn't expensive if the hardware supports tracing to memory

manic glacierBOT
pastel panther
#

@slender iron Awesome

slender iron
#

ok I need testers

pastel panther
#

Assuming it requires a jlink I'm no help yet

idle owl
#

@slender iron Ok

slender iron
#

let me know if you need a different format

idle owl
#

It's more jlink practice unless you can make a uf2 ๐Ÿ˜ƒ

drowsy geyser
#

@slender iron I asume those aren't commited yet?

slender iron
idle owl
#

Oh nice!

slender iron
#

nope

drowsy geyser
#

Ok, thanks!

formal plover
#

@slender iron Yay!!!

idle owl
#

Mounts on first flash! Going to repeat.

drowsy geyser
#

That was quick, @idle owl !

pastel panther
#

@idle owl Did you use your jlink to upload the uf2 or copy it to the virtual drive?

idle owl
#

@pastel panther I double-tapped reset to get into the bootloader and dragged the file to METROM4BOOT

umbral dagger
#

@stuck elbow I started with 8 bit assembly, Pascal, C, C++, ObjC, Java, various Lisps (mostly Scheme these days) (some of which I implemented) including Clojure, spent years with Ruby in various forms, Smalltalks of various flavours, and probbaly others Iโ€™ve forgotten about. Python is relatively new though. Tried to use it at Google but I was in a Ruby phase then. Guido extolled its virtues to me once, but to no avail.

idle owl
#

@slender iron It's consistently mounting immediately after flash, no issues. I was replicating yesterday where you had to make a serial connection to get it to mount in Finder. Great job!

umbral dagger
#

@stuck elbow Also dabbling in Swift & Kotlin for work. And am hardcore learning Haskell at the moment, also mainly for work.

drowsy geyser
#

CIRCUITPY mounts....

pastel panther
#

@idle owl Did you previously flash something with the segger to get the double tap->METROM4BOOT to work?

idle owl
#

@pastel panther Yes. I had to flash the bootloader with the jlink

stuck elbow
#

I suppose Ruby is the closest of those

pastel panther
#

ok, nvm for me then

idle owl
#

Can you load the uf2 bootloader with bossac?

slender iron
#

@idle owl yeah, the cdc reliability stuff I added also caused it to infinite loop if a terminal wasn't connected

drowsy geyser
#

@slender iron You're awesome! CIRCUITPy mounts and the REPL works!

slender iron
#

@idle owl I have code that will allow you to update the bootloader through bossac

pastel panther
#

and bossac doesn't require a jlink?

slender iron
#

it'll make it harder to update through jlink later

#

correct @pastel panther

pastel panther
#

Ah

idle owl
#

Ah ok. That's what I wasn't sure about.

pastel panther
#

Maybe I should just wait then

#

@slender iron how much harder are we talking?

slender iron
#

@pastel panther it doesn't make it impossible

formal plover
#

Oh boy, smoke on mine

slender iron
#

with gdb you just have to set a bit to tell it to ignore the bootloader protection

formal plover
#

lol jk. Same results as @idle owl using my Pi

idle owl
#

@formal plover Nice!

formal plover
#

๐Ÿ˜ƒ

pastel panther
#

That doesn't sound too bad

slender iron
#

@formal plover you had me scared

formal plover
#

Bwhahah gotta keep things interesting @slender iron

idle owl
#

Kurt's being sassy

formal plover
#

lol salty/sassy. @idle owl is correct

slender iron
formal plover
#

I don't like that my work from home day got moved

#

Sorry fam

drowsy geyser
#

@formal plover Sad panda, re: work from home day.

pastel panther
#

@slender iron And bossac instructions I can find will tell me what to do with that?

slender iron
#

@pastel panther what OS you on?

pastel panther
#

OSX

slender iron
#

k me too

#

download the macosx one

pastel panther
#

10.10.5 if that's of consequence

slender iron
#

try the download but its built with high sierra

drowsy geyser
#

@slender iron BTW, the problem with history getting garbled is fixed, too. I just tried it again....

slender iron
#

@drowsy geyser yeah, my fix for that is what broke mass storage without serial being connected

drowsy geyser
#

Ahhh, ok! Well, all seems to be working now. I'll write some programs to stress test it.

slender iron
#

w00t, I'll make a pull

idle owl
#

Excellent!

slender iron
#

@tulip sleet how closely do you want to review the nrf merge? I just did that usb fix on top of it

#

I could port it back or wait

umbral dagger
#

Mine M4 hosed now

#

Tryinbg to get it back

slender iron
#

@umbral dagger describe hosed and how you got there

umbral dagger
#

no USB drives, no screen connection. at the moment I can't get jLink to connect.

slender iron
#

bootloader ok?

umbral dagger
#

I dragged your new uf2 to the boot drive

#

double reset:: red LED pusling, Neopixel green. No BOOT drive

slender iron
#

I didn't test that build on linux yet

formal plover
#

`
Adafruit CircuitPython 3.0.0-alpha.0-1025-gb31d67320-dirty on 2017-10-25; Metro M4 Express with samd51j19

`

#

That's my Pi

#

serial

umbral dagger
#

Single reset -> green led. My file manager noticed but no drive mounts

#

@slender iron Ya, this is linux

slender iron
#

which uf2 did you grab? circuitpython or the bootloader?

umbral dagger
#

@slender iron the firmware.uf2 you posed at 6:40

slender iron
#

k, I'll need to test it on linux

#

did you try a different usb port?

tidal kiln
#

could be as simple as...

#

that

formal plover
#

Let me tell you about the wrong usb port...

#

lol

#

For those that were there trying to help me setup the jlink

pastel panther
#

That there is such a thing makes me wish they would remove the U from USB

tidal kiln
#

i think it might be a software thing too

umbral dagger
#

I tried a couple other ports... same

slender iron
#

hrm

#

which bootloader do you have?

tidal kiln
#

i had my linux box refuse to see my trinket at one point

slender iron
#

is it uf2 with neopixel working?

tidal kiln
#

while doing a bunch of testing and jumping between arduino and cp

#

tried it on a 2nd linux box and it showed up fine

umbral dagger
#

bootloader timestampsed 10:08 ET last night

slender iron
#

and neopixel works?

umbral dagger
#

Neopixel seems fine in the bootloader: red than switches to green

slender iron
#

kk

#

does it turn off when it should be in circuitpython?

#

(it should)

umbral dagger
#

Single reset: yes it turns off

slender iron
#

kk, thats when it should be in circuitpython

umbral dagger
#

Now, when I hook up the jlink, and double reset, neopixel is red and red LED pulses fast.

slender iron
#

thats when its not enumerated

pastel panther
#

bbaib

umbral dagger
#

With USB connected, double reset-> neopixel green, red LED pulsing slowly

slender iron
#

๐Ÿ‘‹

#

@umbral dagger thats when you should see the drive and be able to load it

umbral dagger
#

Ya... no drive

slender iron
#

sounds like the OS is unhappy

umbral dagger
#

That's what I'm wondering. BRB going to turn it off and turn it on again

slender iron
#

๐Ÿ˜„

#

now I want to rewatch IT crowd

umbral dagger
#

OK.. back

#

plug it in and CIRCUITPY shows up

#

double rest and nothing, and now it's unresponsive again

#

I saw a project really recently to make The Internet

tidal kiln
#

did they get approval from "the hawk"?

umbral dagger
#

OK.. bounced again. This time I went straight for jlink and reflashed the bootloader.

#

connect USB and have CIRCUITPY, screen in and have the repl

idle owl
#

Nice!

umbral dagger
#

No for the new firmware.uf2

idle owl
#

As in the uf2 didn't work for you?

#

Or you reflashed the bootloader and then it did

umbral dagger
#

double reset for the bootloader messes up everything

slender iron
#

hrm

umbral dagger
#

Nothing works after that.

#

building new bootloader and firmware

#

then bounce and try again

#

New bootloader flashed, but double reset hoses it

tulip sleet
#

@slender iron I'll take a look. I can probably do it in a hour or less.

slender iron
#

k, I'm distracted by streams now

umbral dagger
#

When I reset: ```Oct 25 19:34:01 rohan kernel: [ 196.493057] cdc_acm 3-1.4.3:1.0: ttyACM0: USB ACM device
Oct 25 19:34:01 rohan kernel: [ 196.493741] usb 3-1.4.3: USB disconnect, device number 12
Oct 25 19:34:02 rohan kernel: [ 196.796181] usb 3-1.4.3: new full-speed USB device number 13 using xhci_hcd
Oct 25 19:34:02 rohan kernel: [ 197.054010] usb 3-1.4.3: New USB device found, idVendor=239a, idProduct=8021
Oct 25 19:34:02 rohan kernel: [ 197.054011] usb 3-1.4.3: New USB device strings: Mfr=0, Product=0, SerialNumber=0
Oct 25 19:34:02 rohan kernel: [ 197.054985] cdc_acm 3-1.4.3:1.0: ttyACM0: USB ACM device
Oct 25 19:34:02 rohan kernel: [ 197.055254] usb-storage 3-1.4.3:1.2: USB Mass Storage device detected
Oct 25 19:34:02 rohan kernel: [ 197.055440] scsi host7: usb-storage 3-1.4.3:1.2
Oct 25 19:33:55 rohan gnome-terminal-[3377]: message repeated 23 times: [ Allocating size to GtkBox 0x556616f218a0 without calling gtk_widget_get_preferred_width/height(). How does the code know the size to allocate?]

#
Oct 25 19:34:03 rohan kernel: [  198.068653] scsi 7:0:0:0: Direct-Access                                    PQ: 0 ANSI: 3
Oct 25 19:34:03 rohan kernel: [  198.068930] scsi 7:0:0:1: Direct-Access                                    PQ: 0 ANSI: 3
Oct 25 19:34:03 rohan kernel: [  198.069317] sd 7:0:0:0: Attached scsi generic sg0 type 0
Oct 25 19:34:03 rohan kernel: [  198.069488] sd 7:0:0:1: Attached scsi generic sg1 type 0
Oct 25 19:34:03 rohan kernel: [  198.069580] sd 7:0:0:0: [sda] 513 512-byte logical blocks: (263 kB/257 KiB)
Oct 25 19:34:03 rohan kernel: [  198.070302] sd 7:0:0:0: [sda] Test WP failed, assume Write Enabled
Oct 25 19:34:03 rohan kernel: [  198.070579] sd 7:0:0:1: [sdb] Attached SCSI removable disk
Oct 25 19:34:03 rohan kernel: [  198.071006] sd 7:0:0:0: [sda] Asking for cache data failed
Oct 25 19:34:03 rohan kernel: [  198.071008] sd 7:0:0:0: [sda] Assuming drive cache: write through
Oct 25 19:34:03 rohan kernel: [  198.081432]  sda: sda1
Oct 25 19:34:03 rohan kernel: [  198.083084] sd 7:0:0:0: [sda] Attached SCSI removable disk
Oct 25 19:34:03 rohan systemd-udevd[3731]: message repeated 14 times: [ inotify_add_watch(9, /dev/sdb, 10) failed: No such file or directory]
#

gotta run for a bit

slender iron
#

I'll look soon

#

thanks @tulip sleet

pastel panther
#

@slender iron when you get a chance, does this look right? bossac -e -w -v -R -p tty.usbmodem1411 update-bootloader.bin

slender iron
#

yup

#

look for a slow red blink, that means it worked

pastel panther
#

slow red blink!

#

just changed to a pulse

slender iron
#

yup perfect

#

do you see a boot drive now?

pastel panther
#

yup!

slender iron
#

yay!

pastel panther
#

Should be able to drop the uf2 you posted earlier?

slender iron
#

yup, the circuitpython one

#

no promises it works

#

๐Ÿ˜ƒ

manic glacierBOT
pastel panther
#

that's the one you posted around 3:40 for kattni?

slender iron
#

yeah think so

pastel panther
#

hmm, I got a CIRCUITPY but no serial device now

slender iron
#

hrm

pastel panther
#

it shows up with a double tap

#

yea, bootloader mode makes it show up but I'm assuming thats bossac compatibily?

slender iron
#

it should support bossac and uf2 now

pastel panther
#

Ok, I was just commenting that the tty.usbmodem1411 showing up after double tap is bossac related

#

I just checked and copying blinky over works

slender iron
#

yup, cdc during bootloader is for bossac

pastel panther
#

I'm assuming cdc != cult of the dead cow or center for disease control

slender iron
#

its serial

#

not sure of the acronym

pastel panther
#

google says communications device class. I assume that's the proper name for the usb serial

slender iron
#

ya

pastel panther
#

any poking I can do to gather useful data?

slender iron
#

not yet

#

gonna get a couple fixes in now and then will look more tomorrow

pastel panther
#

ok

slender iron
#

thanks for testing!

pastel panther
#

glad to help. I'm gradually getting more familar with the code thanks to your and Dan's help

tulip sleet
#

@slender iron finished my review. Incredible churn without a lot that really needed to be looked at. Do you want to wait for ktown or should your or I squash and merge?

slender iron
#

@tulip sleet thanks! regular merge maybe?

#

no need to wait for ktown

tulip sleet
#

you want to keep the individual commits? ok by me to help bisecting or whatever

slender iron
#

yeah, especially since I did the micropython merge separate from the nrf52 one

manic glacierBOT
slender iron
#

+994 commits ๐Ÿ˜ƒ

tulip sleet
#

woot!

idle owl
#

Great job!

pastel panther
#

great googly moogly!

solar whale
#

I'm a bit late to the party - Is the repo now up to date for current build for 3.0 and is there a new bootloader tonight?

slender iron
#

still getting pulls info asf4 and circuitpython

solar whale
#

OK - just checking - looks like you made some great progress!

slender iron
#

haha, kinda

#

just fixing my own code mostly

solar whale
#

well done!

slender iron
#

@tulip sleet I'm finding myself liking regular merge commits more

manic glacierBOT
tulip sleet
#

@slender iron how about the asf4 pull request? Do you want a merge commit there or just squash the 1?

slender iron
#

just rebased it in

#

and prepping one more PR for circuitpython

idle owl
#

Nice! You guys are rocking it.

formal plover
#

crushing it!!!

tulip sleet
#

@solar whale on the RPi, did you build the arm-none toolchain yourself, or did you find a prebuilt version, or did you just use the supplied compiler and it still worked for CPY compiles?

slender iron
#

making sure it builds ๐Ÿ˜ƒ

solar whale
#

@tulip sleet been awhile since I built it on RPi - having trouble tonight buildiong bossac so I'm not confident in it - do you have "stretch" installed. I do and that may be part of the problem.

tulip sleet
#

@solar whale - no I have ordinary packages and just downloaded the .bz2 from ARM, and will build that, probably.

solar whale
#

waht raspian vesion are you using jessie or stretch?

tulip sleet
#

I am starting with jessie only so I can have an mpy-cross that will definitely run on jessie (and will probably run also on stretch). After I build the mpy-cross I may upgrade to stretch, and rebuild or just test that it works.

solar whale
#

Imave having problemd getting packages with stretch....

tulip sleet
#

you mean they're missing from the stretch repos?

solar whale
#

seem to be

#

doing some updates then will try again

umbral dagger
#

Catching up on the show...

#

Re the M4: CIRCUITPY has showed up, and I can manipulate the code on it, with autoreload working.

#

No repl, though ๐Ÿ˜ฆ

manic glacierBOT
#

There were a couple problems:

  1. The CDC code blocked when trying to transmit when no terminal software was connected on the other end reading.
  2. ASF4 replied with a fake inquiry result for the missing disk. Its changed to support returning null to ERR_ABORTED to indicate missing disks.
formal plover
#

I had to yank my M4 outta my Pi

slender iron
#

that PR is the last of the changes I have outstanding for today

formal plover
#

I have no idea why, but with no serial connection running at all... just plugged in, not even in bootloader mode. CPU would rise and rise and rise until it locked up

idle owl
#

You need to spin up another Pi something fierce.

umbral dagger
#

yay @idle owl !! #latetotheparty

idle owl
#

@umbral dagger Thanks!

solar whale
#

ok - able to build bossac after update - there is hope for arduino! still not sure about CP build - will try that too.

formal plover
#

Bwhahahah @idle owl

#

Yeah, gonna do it tomorrow. I'll download a fresh copy of NOOBS tonight though

tulip pebble
#

Go team ESP32!

solar whale
#

@slender iron thanks for all the updates! will give it a try.

idle owl
#

@tulip pebble Welcome team ESP32!

formal plover
#

Huh?

tulip pebble
formal plover
#

CircuitPython is on the ESP32 now?

pastel panther
#

@formal plover a bunch a ppl in the live chat were asking about helping with a ESP32 port

tulip pebble
#

LOL... Not yet...

idle owl
#

@formal plover Nah it's team-getting-it-on-the-ESP32

formal plover
#

Gotcha! thanks @pastel panther

slender iron
#

quick turn @tulip sleet !

formal plover
#

Hhaha @tulip pebble more power to ya!!!

tulip sleet
#

@slender iron this code I recognize!

slender iron
#

๐Ÿ˜ƒ

formal plover
#

I'm still adjusting

slender iron
formal plover
#

I was putting up a giant vinal decal and paper flowers on a wall...

tulip sleet
#

@slender iron squash and merge for this one?

slender iron
#

rebase and merge maybe?

#

up to you

manic glacierBOT
slender iron
#

I rebase if the commits make sense and squash if there are commits from feedback

idle owl
#

I did git pull on the CP repo and got something that looked like errors, but there were so many updates that the scrollback doesn't have the errors anymore, lol. So no idea what that was.

slender iron
#

what does git status say @idle owl ?

idle owl
#

On branch master, up to date, a list of untracked files.

slender iron
#

ah, the untracked files are probably build directories

#

all of the ports moved into ports

idle owl
#

And a bunch of .DS_Store files

#

slaps MacOS around a little

solar whale
#

@tulip sleet I am able to build mpy-cross on my RPi

#

what is with the ports subdirectory !!!

slender iron
#

upstream reorganized ๐Ÿ˜ƒ

#

I suggested it a year ago and offered to do the work but they baulked then. Its done now though!

solar whale
#

cool!

idle owl
#

Are we still making the build in circuitpython/atmel-samd or is it in cp/ports/atmel-samd?

slender iron
#

the second one

umbral dagger
#

No Adafruit order in the mail today, but a bag of transisters from China.

solar whale
#

@tulip sleet but cant build CP - need arm-none toolchain . What are you using?

slender iron
#

ok I'm off for a while. I expect those changes improved USB but still needs work

tulip sleet
#

@solar whale I haven't tried yet. But can you drop your mpy-cross here? Since it's stretch, I'll try it on jessie. Maybe checkout the 2.1.0 tag for consistency before building.

#

@solar whale I thought you were building circuitpython on the RPi (I thought you must be a very patient person if you were doing that.)

solar whale
#

@tulip sleet no - I have used it for arduino but not for CP building - yet

#

just a sec - need to get mpy-cross to this machine

tulip sleet
#

I'm building the arm-none toolchain, but it will be a while.

idle owl
#

I've only got Pi0Ws... I don't think they can handle this stuff at all. And I keep having to remember that's totally not what you guys are running, because I keep picturing you having all of this stuff running off a tiny PI, an OTG cable and a USB hub... Which is quite wrong.

pastel panther
#

I mean that should work, right?

#

If we can get it as easy on a RPi as a mac, that would be sweet

formal plover
#

@idle owl I might be able to supply you with a Pi 3

idle owl
#

@formal plover Oh man...

formal plover
#

@idle owl I've got one that I used for a retropie machine... Let's be honest, I won't be using that any time soon

idle owl
#

@formal plover lol. I haven't done any dev with a Pi0W in ages... Picked up the CPX and never looked back. I have a Pi0W running my tabletop lightbox photo studio, so I ssh in, run the last command and it does it's thing. That's all I've done in so long...

solar whale
formal plover
#

I'll reimage it with stretch. You can just VNC into it with your Mac @idle owl

tulip sleet
#

@solar whale thanks very much - I'll test and upload it to the release if it works on jessie too.

pastel panther
#

@idle owl Your Pi is running a lightbox? Do you have a project page somewhere?

solar whale
#

I have only verified that it turns a .py to a .mpy - not that the .mpy runs!

idle owl
#

@pastel panther I don't... I keep thinking I should make one but I didn't take any in-progress photos. I made the entire thing.

#

@formal plover I have an DVI to HDMI adapter, an HDMI cable and a wireless keyboard/trackpad combo thing that I was using when I needed display on the Pis. I haven't used it in ages, but it's still sitting there, lol

formal plover
#

I also have the one with the Z-wave card on it controlling... a lamp lololol

pastel panther
#

beep boop. light on, light off

idle owl
#

This is running nearly 2m of 60LED/m dotstars. Obviously the dotstars are powered separately.

formal plover
#

Can control like 40 devices.., and I am controlling a singular lamp lol

idle owl
#

A friend of mine wrote a quick script to control the brightness and a few different modes, and to control the 3 panels separately. They're soldered into 3 9x9led squares.

pastel panther
#

@idle owl if you have any details you can share offline/DM that would be swell. I'm going to be making something similar with UV leds for curing resin to make custom IEMs

idle owl
#

@pastel panther Yeah for sure! I'll try to get a few pics this week and I'll write up what I did. Won't be guide-worthy but enough to give you some ideas and at least give you some more questions to ask ๐Ÿ˜ƒ

pastel panther
#

@idle owl awesome, thanks!

#

Anyone know a good place to find a selection of rubber bands? I need to hold a mold together and don't want to wait for the internet

idle owl
#

I had it in the works for a while but I ended up finishing it much sooner so I could take the pics for the Key of Lime Learn Guide ๐Ÿ˜„

pastel panther
#

hah, cool

#

Awesome guide btw

idle owl
#

Thanks!

pastel panther
#

I'm going to try and do it with my neice once I get a CPX

#

the intersection of music and electronics is right up my alley

idle owl
#

That's so great!

solar whale
#

woohoo!! ```Adafruit CircuitPython 3.0.0-alpha.0-1030-gd613776 on 2017-10-25; Metro M4 Express with samd51j19

import led

pastel panther
#

REPLHOW

#

@solar whale You're on linux?

solar whale
#

jsut screen /dev/ttyACM0 115200 --- yes - Ubuntu 16.04

pastel panther
#

What build?

solar whale
#

current master - just downloaded and built

umbral dagger
#

@solar whale bootloader?

pastel panther
#

Did the Makefiles move or am I just...

idle owl
#

@solar whale I thought Scott said to run make in the circuitpython/ports/atmel-samd .... Did I misunderrstand?

solar whale
#

@idle owl taht is correct

#

@umbral dagger bootlaoder from last night - wioth working neopixel

idle owl
#

I just got a boatload of fatal errors.

solar whale
#

did you do git submodule update --init --recurstive

umbral dagger
#

OK, I have the latest, workign neopixel

idle owl
#

not again since I did git pull, I'll try it again

pastel panther
#

yea, I'm having to do a submodule fetch

#

much better, building now

umbral dagger
#

and it's been sitting here in bootloader mode (looking at the M4.. neopixel green) for 5 minutes or so.. and... the BOOT drive just showed up.

solar whale
#

very important - major cahnges - do that at circuitpython/

idle owl
#

oh bugger. I did it in ports

#

It seems to be building though

solar whale
#

just do it again

idle owl
#

After it builds?

#

and then rebuild?

solar whale
#

yse - make BOARD=xxx clean then real make

formal plover
#

@pastel panther I think you need to download screen