#circuitpython-dev
1 messages · Page 209 of 1
ESC[0;1;32m type stuff
right
One of these days I want to write a curses based UI to run on one of these guys
@pastel panther ... one step at a time...
Following up on #1326 and #1327:
Made some CPX builds to test NeoPixels.
168e23e and after don't work: no REPL
9d91111b does not seem to build: I get this error:
In file included from ../../shared-module/usb_hid/Device.c:33:0:
../../lib/tinyusb/src/tusb.h:92:7: error: "CFG_TUD_CUSTOM_CLASS" is not defined, evaluates to 0 [-Werror=undef]
#if CFG_TUD_CUSTOM_CLASS
^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
../../py/mkrules.mk:81: recipe for target ...
I find the more time that has passed between a difficult technical accomplishment, and my reexamination of it, the more likely it feels 'stable' subjectively, to me -- the more I'm apt to successfully re-navigate its ins and outs. ;)
There's no cheat for that -- no I know KungFu neo declaration for that.
The time itself is what does it.
I think I know what you mean
For me, the ability to flip a switch ON or OFF (easily, without a screwdriver) has human remembrance consequences that stabilize the longer I do not touch the ON/OFF switch. ;)
If I flipped it twenty times in the past hour, I won't be able to tell you which state I left it in, without very special concentrated effort to commit the final state (ON / OFF) to human memory (to remember it).
After several hours driving in Pennsylvania on the Interstate at night, I cannot tell if I'm going uphill or downhill. ;)
Wow! Blinka on the Raspberry Pi is really nice! Just discovered that I can write text to my OLED display using bitmapfont.py just like I can on my feather M0/4 boards. just copied bitmapfont.py and font5x8.bin to the local directory and it works... Maybe I'm just easily impressed 😉
@solar whale no you're right, that's pretty cool
Quick WIP update on my black panther cosplay LED upgrade using circuitpython
46% of the way done. Not using soldered connections(yet) for digital pins on circuit express playground. Center animation will work after that. Ribs connection needs to be fixed too along with upper arm animation. Need to turn off green light as well
@sly wagon great work, we're adding this to the newsletter this week!
email pt@adafruit.com with any updates, photos, etc. too, we can do a blog post or whatever, circuitpython was made for this, thanks for showing the progress and more!
Will do for sure 😃 !!!
I was reading through the docs for troubleshooting when the CIRCUITPY drive isn't showing up and saw this: https://learn.adafruit.com/welcome-to-circuitpython/troubleshooting#circuitpy-drive-does-not-appear-18-12
I don't have Kaspersky though and didn't see it on Ubuntu either
was wondering if there's any other known issues
I was thinking it might be the flash memory on my custom board might not be soldered down properly. I'll try resoldering it tomorrow but wondering if there's anything else to look at
@digital slate There are more reasons why it wouldn't show up but most of them are software related when in the context of issues we typically run into. (Which is to say, most times it's not someone creating custom boards.) The software can become corrupted and cause issues, sometimes things will mess with the host USB controller and cause it to not show up...
Trying to think. There's an issue right now with one of the builds that causes CIRCUITPY to show up and then disappear and not show up again until you reload CircuitPython in a particular manner...
yeah, was wondering if it might be a driver thing
The Kaspersky thing is in the troubleshooting page because we've been seeing it so often lately, and shouldn't imply that it's the only thing that would cause it.
Which OS are you on?
Windows 10 normally but like I said I tested on Ubuntu as well
Neither of those should have driver issues. Hmm.
it should show up without driver installs, correct?
maybe i should try reloading the bootloader
Unless you installed drivers for something else that is interfering. Which can happen. As in installing drivers when you don't need them.
Yes correct. Should work without drivers.
Ok. Then that's probably not it then.
another data point
I have a Feather M4 and that worked fine
so it's capable of showing a drive
also when I hit reset, FEATHERBOOT shows up
and you didn't change anything in your custom build that might have done something with mounting the drive?
Building it yourself shouldn't change anything like that.
UF2 Bootloader v2.0.0-adafruit.7 SFHWRO
Model: Feather M4 Express
Board-ID: SAMD51J19A-FeatherM4-v0
no, this is right off of GitHub for UF2
Ah ok. And what's custom about your board?
not too much, I basically refactored the feather
different shape and the pins go different places
but kept everything else the same
AFAIK
Got it, so that's why you're thinking the feather build should work
Thing is CircuitPython does not need the SPI flash (there are boards without it), but that build assumes it's there. So maybe you're right that the flash chip soldering isn't solid?
You said you mounted CIRCUITPY from the Feather M4, so I would agree it's not a driver or computer software issue.
yeah, had some footprint issues with the part
so might not be soldered properly
question about this page: https://learn.adafruit.com/adafruit-feather-m0-express-designed-for-circuit-python-circuitpython/uf2-bootloader-details#making-your-own-uf2-45-42
If your bootloader is mounting, I don't think it's a bootloader issue, but redoing the bootloader isn't a terrible step to try. I really don't think that's it though.
did I miss a step and I need to convert the uf2 after compilation?
Hmmm.... no. That shouldn't have been necessary.
Because building CircuitPython produces firmware.uf2 on its own
I did the .bin from the build
OH!
yeah, it's the stuff I was asking about Friday
but if you have bootloader, you can use the firmware.uf2 produced from your build of CircuitPython, and drag it over, I think....
ah, I didn't build CP yet
Loading the .bin with the JLink produces a lot more feedback if you're trying to debug something in that section
I built the uf2 bootloader
okay.......
and then loaded the .bin to the board using a JLink
oh sorry
I mean i built the UF2 bootloader, which produced a .bin, not a .uf2
and then I loaded the .bin onto the board
which then gave me a FEATHERBOOT drive
Ok. I think that means you still have to load CircuitPython if you want the CIRCUITPY drive. The bootloader is separate from CP
which I dropped the .uf2 file onto
(of CP)
Alright. Back on the same page again
yep
haha
and I am decently certain the CP is working, since i can get to the REPL via a serial terminal
Right, that seems accurate.
at least part of it is working
Oooh question. Can you check the mount points more specifically and see if it mounted but didn't show up in the file explorer?
That has happened
As in see if the drive is there but doesn't show up on its own in the available drives in the main bit of the file explorer
Hmm not sure in Windows....
"computer management" is the screen I was thinking of
but it's not there
should the drive have a name when it shows up in hardware manager?
Ok. If it's not there, it's probably not connected. I'm pretty sure that's the most base level drive list on Windows.
um.... I'm not sure about that
ok, I think I need to mess with the hardware again tomorrow
I have another board I can try this on as well
(tomorrow when I'm back in the office)
appreciate the troubleshooting help!
For sure! Sorry it wasn't something simpler. At least you've got enough stuff to test with to determine it's probably not the computer. So many variables to deal with 😄
yeah, it really can add up, even for seemingly simple stuff
Nothing is ever simple ™
haha
It seriously never is though.... it's always one more thing you never expected
ah, one other datapoint i just noticed as I went to go close some files
the part I have on board is the ATSAMD51J19
I believe this is similar to the feather m4
since i loaded from that
didn't noitce that though and was following tutorials that said ATSAMD51J20
might be some register differences preventing?
from when I was putting the boatloader on there
so might just retry thta with the correct part number
I'm not sure. I feel like the big changer is the letter not the number... so the ATSAMD51G vs J. But I'm not sure. Datasheet might have that answer although that's a rabbit hole all its own right there.
Definitely worth retrying with the correct part though.
My Feather M4 has a J19 on it.
Arduino: 1.8.7 (Windows Store 1.8.15.0) (Windows 10), Board: "Adafruit Feather M0 Express"
C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.15.0_x86__mdqgnx93n4wtt\arduino-builder -dump-prefs -logger=machine -hardware C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.15.0_x86__mdqgnx93n4wtt\hardware -hardware C:\Users\Glenn\Documents\ArduinoData\packages -hardware C:\Users\Glenn\Documents\Arduino\hardware -tools C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.15.0_x86__md...
I think that you need to press reset twice to get the board into the bootloader mode.
It seems that when I try to feed DFLL into GCLK0 my program hangs
This should go in the community bundle since its not carried by Adafruit.
I'd copy what CPython does on a UNIX style system.
@digital slate Sounds like the build isn't configured correctly for the flash chip. Over serial do:
import os
os.listdir("/")```
if it raises an error there is a spi flash issue (not a host os issue)
<@&356864093652516868> Here are the notes for tomorrow's meeting: https://docs.google.com/document/d/1z3-F_GTPGvw5fETP39sFrMuKw3qlRyQftPCn9bAJaRU/edit?usp=sharing
I should be able to make it to circuitpython weekly this week 😀 It's a national holiday in Canada tomorrow so I don't have any school
Thank you - but could you kindly clarify: is that something that I'll have to take actions? Is this a wrong place to raise this issue?..
Hi, I have a question, can any port be set to double-precision floats? I tried setting MICROPY_FLOAT_IMPL to MICROPY_FLOAT_IMPL_DOUBLE in mpconfigport.h but I see issues "/py/formatfloat.c:94:5: error: floating constant exceeds range of 'float' " , do you know if there is something else I need to change?
clearing the FRAM breadboard, re-bagging the breakouts, and realize i have 2 of the I2C version. oddly enough, i have no recollection of ordering two, nor do i remember soldering headers on both... good thing i don't spend much time on ebay. 😆
yep, looks like there's something wonky @slender iron
Nothing there
is there a default bootloader .bin I can try pushing to the chip?
I'll definitely still want to build it
@raven canopy maybe you were thinking you'd test multiple devices on the I2C bus?
Why bootloader? Seems like that is working. This is a circuitpython issue
@tidal kiln we'll go with that. since it reduces any cases of brain == absent. 😄
The bootloader’s drive is fake, not the spi flash
oo
got it got it
yeah bootloader does seem to work
it pops back into featherboot whenever I doubleclick the reset
You’ll need to configure your board config for the spi flash device
Yup that’s all good then
just thought I was copying things exactly
hence my confusion
like same parts AFAIK on the Feather M4
Hrm. Then it could be an assembly issue. But I’d triple check the pin mapping and part number
Boot_out.txt at least
@ngmacha hiya, the issue can stay here. we don't have a plan to write this driver ourselves. if you plan to, or someone else can write it - we can include it in the bundle!
My talk on CP at PyCon Canada went well. Packed room, lots of interest, good questions, plenty of followup discussions after the talk.
@umbral dagger That's great! 🎉
I believe it was recorded.
@umbral dagger Drop a link to the video when you know what it is. I looked but couldn't find it.
This adds support for the OSError subclasses listed in the Python docs:
+-- OSError
| +-- BlockingIOError
| +-- ChildProcessError
| +-- ConnectionError
| | +-- BrokenPipeError
| | +-- ConnectionAbortedError
| | +-- ConnectionRefusedError
| | +-- ConnectionResetError
| +-- FileExistsError
| +-- FileNotFoundError
| +-- I...
@tulip sleet They don't seem to be posted yet. I'd expect later this week. I'll be sure to post the link.
Forgot to mention flash usage:
Base:
58368 bytes free in flash out of 499712 bytes ( 488.0 kb ).
OSError patch: Use 2468 bytes
55900 bytes free in flash out of 499712 bytes ( 488.0 kb ).
uerrno patch: Use 320 bytes
55580 bytes free in flash out of 499712 bytes ( 488.0 kb ).
@slender iron after solder touchup on the QSPI, looks like some drives show up now
does that part get touched in the bootloader install?
great!
like should I reload that
nope, its ignored
but the drives are empty, as is the os.listdir
no boot_out.txt?
but some progress is better than none
nope
tried reloading the latest CP build as well
@digital slate Great job!
@digital slate can you load a file from the comp and have it stay?
Version 2
- Fix viper_misc test
it's still not showing up as a CIRCUITPY drive, to be clear
let me try dropping something onto there in a bit
oh, I thought it was
ah, that sounds suspect. you can try to reformat them from the repl
storage.erase_filesystem()```
<@&356864093652516868> and any/all who wish to participate: weekly meeting in about 40 minutes. Notes are here: https://docs.google.com/document/d/1z3-F_GTPGvw5fETP39sFrMuKw3qlRyQftPCn9bAJaRU/edit?usp=sharing
Not gonna make it today folks, sorry
I'm new to all things. sorry. When you use REPL, you need to enter each line of code in? You cant, like, set a breakpoint and troubleshoot 1 part/section?
No, it's a repl, not a debugger. There is some work ongoing to provide a debugger as well, but I think it has stalled a bit.
@hazy gust unfortunately, no, we don't have breakpoint-style debugging. like @stuck elbow stated, it has been brought up and discussed: https://github.com/adafruit/circuitpython/issues/298
cool, no worries, thank you.
my discord is saying RTC Disconnected, not sure what that means
real-time chat, I guess
@exotic pumice mine did too when i first tried to connect. try re-connecting.
yeah, seems like discord is a little glitchy today.
With the M0 Express Feather is it possible to tell when it is connected to a USB power source?
brb.
goood day everybody
(back.)
Scott: Travelling so I'm just lurking today
anyone else have no audio ?
@strange pumice yes and no.
nm
@inland tusk we're hearing background noise ; could you mute?
@timber mango - The only way I can think of is to have a battery connected and watch the voltage change. Obviously this would be unreliable if the battery were fully charged. What ways do work?
@strange pumice let's go over to #general-tech and discuss it.
Tannewt: i'm just lurking, b/c only been working on my project
@hazy gust We're in a meeting right now, FYI - may be a bit for a response.
Oh I wasn't scrolled. Someone already responded.
I added a new PR this morning in libraries 😃
@strange pumice you can tell if there's a usb serial connection: supervisor.runtime.serial_connected
@exotic pumice We had already pulled the stats before you put that in. You'll be included in next week's.
yep
@strange pumice note to dan's suggestion: serial_connected is not totally dynamic. it will update when a USB connection is made, but not when a disconnect happens.
CircuitPython Library Tracking Issue: https://github.com/adafruit/circuitpython/issues/1246
Good to know, thank you both @tulip sleet and @raven canopy
can one hug report even if just lurking?
bug...fixed!
thanks!
@marble hornet Feel free to type it in now, you'll be next 😃
hugs to: @tulip sleet, @solar whale , @tidal kiln , @slender iron , and @raven canopy for always being so kind and willing to help 😊
also for helping debug
stuff in notes plz
To kattni, scott, cgrover, nis, sommersoft and everyone else who helped me troubleshoot the issues with the board who shall not be named and talked me off the ledge when things went more and more pear-shaped.
To cgrover for a reminder that styrene is a thing that exists; it made my bezel making waay easier
who said that ^^^?
meeee
@gusty kiln Drew Fustini might have some intelligence on gpiod packages and their eventual appearance in Raspbian.
Yeah Drew's in on the issue for it.
Yeah
I'll think about the packaging issue
We do have it on the Debian image for BeagleBone
But yeah raspbian is the more important platform
i kind of lean towards "use it if available, otherwise fall back"
that way we could tell people how to install but not make it a prereq for blinka on the pi.
studio builds...such fun.
It will be ahwile before /sys/class/gpio dissappears
so fun. much wiring
The Trinket M0 meter tester.
NEATO man
@errant grail do you use eagle or kicad?
how'd you make the trinket footprint?
Manually with the footprint editor.
OLED sneeze guard?
Works for fingerprints, too. I have a very curious grandkid...
Version 3
- Really fix the test including the expected result file
@ leaving the protective film on forever
@marble hornet I believe the technical term is cheese wrapper, or so I have been told. 😉
hmmm.... meta... now my brain has to work...
Stuff in notes again, please. pix incoming
From @pastel panther:
last week: Received and assembled the new boards, didn't work, couldn't figure out issues in time for a new board rev :(((((
Scrapped the first board and assembled a second one that is working great though the boost converter needs rework before assembly
Learned a lesson: never. ever trust someone else's footprints.
Resolved to have a single example of the blinky Cyborg Raccoon for display at Designer Con instead of having some for sale :|
Started assembly of a base, doing some woodwork to build in the TFT and made an initial bezel out of styrene.
This week:
Finish up the rest of the base, prep and paint.
Work on more animations for the TFT and finalize coding for TFT and LED animations.
Pack up the car and drive to Anaheim for Designer Con! http://www.designercon.com/
(we're in booth 1049 for anyone who wants to stop by)
@pastel panther what screen is that ?
Cool! BluefruitSPI allowing control of CPX neopixels from iPhone in CircuitPython
@marble hornet https://www.aliexpress.com/item/maithoga-0-9-inch-13PIN-262K-SPI-TFT-LCD-Color-Display-Screen-ST7735S-Drive-IC-80/32841634717.html (via hot tip from @stuck elbow )
does it work with the st7735r lib?
ooh
by the way, it would be nice to add those tweaks to the library at some point
Definitely will.
as another class?
possibly
No, just need some offsets
Still waiting for my particles too 😦
And some register munging to fix the rotation
oh, is that the same as on : https://www.adafruit.com/product/3321 ?
Add a dazzling color display to your Feather project with this Adafruit Mini Color TFT with Joystick FeatherWing.It has so much stuff going on, we could not fit any more parts on the ...
@raven canopy Nice! Thank you!
IN THE WEEDS
- still need flash eraser UF2s?
yeah...Google can be mean. 😦
it is the same
blobfish: does what says on tin.
after the weeds: talk about scheduling a get together for learning?
It does look like that in the water
the '51 errata is a graveyard of broken dreams
XD 32 pages of errata
wonder if you could patch uf2-samd to jump to some different offset with some reset tap pattern?
@pastel panther I've been brainstorming that too. It could just set special memory values
is there a try and except in c?
also that
@tulip sleet i posted it ... or that. 😄
what about the capacitive pins?
doubletapping with tweezers is also hard
There's no D13 on the Trellis M4.
(foot moat?)
@raven canopy, the samd51 version is on my fork here if you're curious https://github.com/sajattack/atsamd/tree/samd51
@exotic pumice will check it out! make no promises i can help...my smarts have limits. 😄
real popular in webdev land
"polite" suggestions (replaces interrupts after being nudged) 😉
nudges - not interrupts
I just noticed, I think I typed exclamation marks in my commit messages and it got replaced with my previous command
rust has interrupts 😛
so...MQTT-lite? no living history, just last events...
@slender iron why can you not implement queues like the bus module.
so the t-shirt is labelled "pre-emption DE-nied" with an image of the towering 7 foot basketballer between you and rim... and you have have to choose between walking away with nothing, or looking at message queues and saying... "I could work with this" 😃
gotta run everyone! 👋
so i wanted something like interrupts when i was doing a project with LoRa + some other stuff a while back.
message queues feel like interface scaffolding that people wind up kind of naively re-implementing when they're polling across a bunch of stuff.
i dig it, personally.
Have to hit the road, folks. Great meeting today!
better cues than none, as someone who learned it in school the cues sound great as a start
typedef struct {
uintxx_t message[n]; // message; what's the cutoff size?
timestamp; // systick
} msg_queue;
top-of-the-noggin, less than stellar psuedo...
@slender iron Is there any reason not to do a release on this lib? https://github.com/adafruit/Adafruit_CircuitPython_CPython
not annoyed at all -- but I also have to run -- Have a good day all!
same here. gotta figure out lunch. i may drop back in.
a "LEARN SESSION" being a a live session analog to a LEARN GUIDE
I would like for the first session or series of sessions to be about using GitHub to do code reviews.
If I was dreaming big, this might develop into a recording series like a "coding workshop", since I think one could learn to code from doing reviews at the start.
For reference, adding a link to the Learn Guide that this would augment:
https://learn.adafruit.com/contribute-to-circuitpython-with-git-and-github/overview
what speed does this achieve? 1.92 MHz? https://github.com/adafruit/samd-peripherals/blob/f20fcf642b5654ee68d7d551ea7db39716ef83bf/samd/samd51/clocks.c#L96
I'm not quite sure what the reference clock is at
I calculated based on 32KHz
<@&356864093652516868> Here is the recording from today's meeting: https://youtu.be/FPqeLzMAFvA
Notes with time codes are available here: https://github.com/adafruit/adafruit-circuitpython-weekly-meeting/blob/master/2018/2018-11-12.md Thanks to @kattni ...
@tulip sleet debug works for me
@tulip sleet make sure you have the latest tiny usb
halbert@salmonx:~/repos/adafruit/circuitpython/lib/tinyusb$ git status
HEAD detached at 299a2f12
nothing to commit, working tree clean
halbert@salmonx:~/repos/adafruit/circuitpython/lib/tinyusb$ git remote -v
origin https://github.com/tannewt/tinyusb.git (fetch)
origin https://github.com/tannewt/tinyusb.git (push)
i'll try it on a mac
that might be a mistake, but dpll0 might have been left over from the bootloader??
I'm gonna try doing the initialization first and see what happens
@tulip sleet hihi
hi
if we add a new UF2 bootloader def to our repo
what is the thing we do to make it generate the release files, do you do that manually
i tag it and then build by hand and upload them
oi
yeah, it should be travis-ized
ok - thanx - we have an incoming PR soon
should we have a shell script that at least iterates over everything to build?
i could probably write that
there's a makefile target: drop-pkg or something like that. It's at the end of the makefile
ooh ok thats not too bad then - ok thanx
yeah, it doesn't take long
Howdy all...I've poking today and wanted to make sure I'm not missing anything - has anyone ever gotten the CircuitPython adafruit_rgb_display library working on the Hallowing?
@slender iron HEAD of master works on Mac, does not work on Linux or Windows 10. On Windows 10, gets "USB device not recognized". I started with a completely fresh clone of adafruit/circuitpython, just to make sure there was no issue with tinyusb submodule
@slender iron does not always work on Mac. If I plug it in fresh, sometimes it doesn't enumerate and neopixel stays dark. If I then press reset, it does come up.
reset button on Linux doesn't help
I was testing with arch linux
try on your windows box - i assume you're out
But I give it boot time before connecting usb. Ya at the gym now
Will try later. Probably a race condition of some sort
we're going to the movies but I'll be back later in the evening like after 6:30-7 your time
w00t! Nevermind - I got it working...so stoked! Thanks to all of you wonderful folks behind CP 😄
I seem to be getting stuck waiting for dpll status to be ready
maybe a quick sanity check is in order
while (!(OSCCTRL->Dpll[0].DPLLSTATUS.bit.LOCK || OSCCTRL->Dpll[0].DPLLSTATUS.bit.CLKRDY)) {}
is the same as
while oscctrl.dpllstatus0.read().lock().bit_is_clear() ||
oscctrl.dpllstatus0.read().clkrdy().bit_is_clear() {}
}
oh wait no it's not
tricky boolean logic
still not happy
hm, is there a win7 usb serial driver exe that includes the trellis m4?
@tulip sleet I'm back working now if you get back
@idle owl is there a guide on how to get started with github for adafruit?
Also I would like to know if there is a template for creating libraries for drivers?
https://git-scm.com/book/en/v2 for advanced stuff in git
You can clone a git repository on your hard disk -- to another directory on your hard disk.
Then you can push changes from the clone, back to the original.
In that way, your edits are not exposed to the public (as they would be on github.com).
@slender iron heya for tinyusb do you get enumeration on samd51?
@meager fog I do when I power it, start it and then connect usb. Its flaky on samd21 if I connect immediately
I think it may be because don't wait for the enable sync. Adding it now to see
@inland tusk That is for creating libraries. This is for general Git/GitHub workflow: https://learn.adafruit.com/contribute-to-circuitpython-with-git-and-github/
@slender iron kk just checkin'!
that wasn't it. so there are startup gremlins I gotta find
hopefully not. I didn't change those 😃
its always clocks
it might be.....
I have no idea, I'm just venting my own frustration
its not a bad intuition 😃
@slender iron I'm back but have a phone call to make for a while.
k np, just poking at it. I can only replicate when plugging it in
@slender iron k i @'d ya on basecamp if you can reply before you zzz
@idle owl It occured to me that when you upgrade a brand new cp express, you need to replace certain libraries for the demo to work. Could you include a list so that updater could know what libraries to extract from the new bundle.
@slender iron thanks - back to routing for meeeee
hm, feather m4 shows up, trellis m4 does not.
same build?
does the adafruit windows drivers know the neotrellis m4 vid/pid?
I did not have to tell Linux about Trellis M4.
I set my d13 to be !(dpll0->clkrdy) and it's always on 😢
linux is better at resolving usb devices 😉 win7 is a bit old school
I seem to recall I had to do something unusual when I first got the Trellis. There's a new .UF2 bootloader update out, and is a required update.
yeah, looking at Adafruit_usbser.inf there is no USB\VID & PID entry for the trellis m4
right, that deals with the bootloader not being marked protected
this is getting the computer to see the trellis at all
@ruby lake windows 7 or 10?
7
sorry, yes, we need to update the driver package for it. I'll consult about it.
It probably needs lines like "%FEATHER_M0_RADIOFRUIT% CircuitPython (8025:00)"=DriverInstall, USB\VID_239A&PID_8025&MI_00
tuned for the trellis m4
right, you could make your own, but it won't take that long to update. I'll try to do it tonight or by sometime tomorrow.
no huge rush, I'm about to zonk for the evening..but thanks 😉
ok, I won't stay up late for it 😃
@tulip sleet can you see what beagle shows?
I can replicate it sometimes but its not obvious where the code is stuck
i'll get a trace
can we get a sad clock emoji?
@slender iron here are two traces from plugging in the M4 metro: once it worked, once it didn't
excellent!
the failed one looks like it started working
and beagle would be better for this too since it shows the packet level
the failed one just hung. I'll break out the beagle
it could have hung on the set configuration
bonus points for getting it to hang with jlink tracing
I gotta take a break for now though
frustrating to have something so picky
i'll post something here when I can get it to fail
thanks!
@slender iron
^C
Program received signal SIGTRAP, Trace/breakpoint trap.
0x0001057c in maybe_transfer_complete () at ../../lib/tinyusb/src/portable/microchip/samd21/dcd.c:283
283 if (maybe_handle_setup_packet()) {
(gdb) bt
#0 0x0001057c in maybe_transfer_complete () at ../../lib/tinyusb/src/portable/microchip/samd21/dcd.c:283
#1 USB_Handler () at ../../lib/tinyusb/src/portable/microchip/samd21/dcd.c:338
#2 <signal handler called>
#3 0x00002174 in __udivsi3 ()
#4 0x0002d806 in color_brightness (color=12288, brightness=<optimized out>)
at ../../supervisor/shared/rgb_led_status.c:189
#5 0x0000d8c4 in tick_rgb_status_animation (status=<synthetic pointer>)
at ../../supervisor/shared/rgb_led_status.c:267
#6 run_code_py (safe_mode=NO_SAFE_MODE) at ../../main.c:278
#7 main () at ../../main.c:432
Failed the first time I tried it. I should go to sleep but that backtrace looks promising. Getting datacenter to work on Ubuntu 18.04 required adding a bunch of old .so's to their private lib dir. They've had months to update their Linux version for 18.04 and haven't done it yet.
ya, that doesn't surprise me. Thanks!
many minutes later now, bt is just like #3 down. I assume the USB went dead.
ya, I think its a concurrency issue. maybe with the fifo
anyway, back to my break. thanks again!
sure, gn!
that backtrace was a lucky break. Repeating the whole thing now and I'm just backtracing in the pulsing loop
ooooh
nice! very excited
@meager fog is there a fuse on the trellis? I think I'm triggering it
will all pixels at full brightness trip it?
and what happens when its tripped?
the whole thing will shut off
no power
for about 30 sec
until the fuse resets
cuts the UBS 5V
hrm, i'm seeing them stay on but get dimmer and yellower
and the mcu becomes inaccessible
ya, thats what it seems like
somehow my usb change causes us to send all white 🤦
heck yeah chapter 9
kinda hard to debug until I can recover from the brownout
you could hot air the shifter off
its easy to replace
its the same chip as an itsy m4
nah, ideally I'll make it recoverable
first, when we reset the board, set them to off
its possible..
the SK's tend to come up off
unlike previous pixels
so if you depower, they should not light up
if that makes sense
like, its definiately something sending data to cause it to turn white
right, but ideally we can recover from the brownout
hmmm not sure how
if we manage to run the start of circuitpython before things get worse
the pixels are putting it into brownout, you have ot shut em off
its possible! i think?
eh, worth a try
not sure tho
the brownout isn't immediate so resetting with ctrl-c could save you too
as long as it shuts them off for you
welp, it does it when I try and reset them at the start
totally a clock thing 😕
its always clocks
The third single from Coldplay's second album A Rush Of Blood To The Head (2005). Stream / download it now from http://smarturl.it/AROBTTHcp Video directed b...
💤 for me
night!
Hey @slender iron can I get a pointer to the library and/or board def for the M0+BLE? I may have time to test it tomorrow
Thank you for the detailed report. I was able to reproduce this on my end. I believe @jerryneedell is right that the bad failure mode is a result of overdrawing the usb line with all white pixels.
The question is, why the white pixels? Well, I haven't figured it out. It appears that the neopixel clocking is slightly slower than in d08747d. The zero high time is 0.5 us instead of 0.38 us which is enough to be a one. I get these numbers on a Metro M4 without neopixels attached so it isn't a ...
@tough flax accordting to this Guide https://learn.adafruit.com/munny-lamp/code-with-circuitpython - use the feather_m0_adalogger build. I did this and it worked fine. I think the only difference from the feather_m0_basic is the definition of some of the pines used on the adalogger -- I did not look to closely to see if they are actually used but as I noted, it worked for me 😉 Looking at the code, it is not clear to me why the feather_m0_basic build would not work as well. I'll test it later.
there are exaple scripts here for testing the board https://github.com/adafruit/Adafruit_CircuitPython_BluefruitSPI/tree/master/examples
@slender iron I'm really sorry - the USB traces I posted last night were for Metro M0, not an M4 board, despite the filenames.
I wonder if the instruction/data cache is on at the right time? Maybe that got lost in some refactoring? It gets turned on in the beginning, and also gets turned off/on during some external flash operations.
I'm trying to write to the SD Card on the Adalogger with CircuitPython from a Feather M4 Express. The docs don't seem to directly address using Adalogger with this setup, so I'm trying different options: https://learn.adafruit.com/adafruit-adalogger-featherwing/circuitpython#initialize-and-mount-sd-card-filesystem-3-4
Trying this:
cs = digitalio.DigitalInOut(board.D0)
sdcard = adafruit_sdcard.SDCard(spi, cs) ```
produces:
```Traceback (most recent call last):
File "main.py", line 19, in <module>
File "adafruit_sdcard.py", line 113, in __init__
File "adafruit_sdcard.py", line 141, in _init_card
OSError: no SD card```
There's an 32GB micro SD card in the Adalogger. I looked at it on a Mac and it appears to be formatted.
Replacing board.D0 with board.SD_CS won't work because that attribute doesn't exist:
Traceback (most recent call last):
File "main.py", line 18, in <module>
AttributeError: 'module' object has no attribute 'SD_CS'```
These are the attributes of board:
['A0', 'A1', 'A2', 'A3', 'A4', 'A5', 'SCK', 'MOSI', 'MISO', 'D0', 'RX', 'D1', 'TX', 'SDA', 'SCL', 'D4', 'D5', 'D6', 'D9', 'D10', 'D11', 'D12', 'D13', 'NEOPIXEL', 'VOLTAGE_MONITOR', 'I2C', 'SPI', 'UART']```
What's the correct setup to write to the Adalogger SD Card from the Feather M4 Express?
@neon briar try D10
cs = digitalio.DigitalInOut(board.D10)
TinyLoraWAN moving into a circuitpython library 😃
@prime flower heya are you around? plz ping me on slack 😃
@ruby lake new adafruit win7 drivers package with Trellis M4: https://github.com/adafruit/Adafruit_Windows_Drivers/releases/tag/2.3.3
@tulip sleet Thanks, will check it out when I get home
@pastel panther yep, both 😃
Lookin good!
hey @slender iron I saw your post over on the CE forum about QSPI configuration
this page: https://github.com/adafruit/circuitpython/blob/master/supervisor/shared/external_flash/devices.h
yup yup
this is the part I have on board
FLASH - NOR Memory IC 16Mb (2M x 8) SPI 133MHz 8-SOIC
looks like its W25Q16JV_IQ in the list
kk!
thanks all for the help
np
Does anyone using VSCode encounter it "locking up"/unresponsive window errors when editing files on the /circuitpy/ volume?
same
@tulip sleet the disassembly of neopixel_write looks very different between the two builds
welp, the debug build was switched from -Os to -O0 which would do it
!!!! thats for all builds
Thanks @tidal kiln board.D10 works. 👍
(╯°□°)╯︵ ┻━┻
well that was a rathole
you have no idea
@tidal kiln was there a schematic you looked at to find that? Or source code?
@slender iron oi...
@neon briar, the learn guide here says "On Atmel M0, M4, 328p or 32u4 it's on GPIO 10"
https://learn.adafruit.com/adafruit-adalogger-featherwing/pinouts
It messes up neopixel timing otherwise.
Fixes #1326
@slender iron was @idle owl using the debug build?
🤦
Thanks @exotic pumice
could put a warning in the Makefile
Using the GNU Compiler Collection (GCC): Function Specific Option Pragmas
I like -O0 for debugging
@tulip sleet adding the pragmas now
i'll wait for the travis-rerun
Unfortunately, since this makes the SAMD21 builds throw different exceptions, this is a pretty user-visible incompatibility. We don't really have room for this in the M0 builds now.
@tannewt notes that each new class adds 60 bytes for the class object, and the most of rest could be qstrs. He has some ideas about shrinking the class objects.
a3a690d Add pragma to ensure neopixel_write is always -Os - tannewt
I think the m0 issue is separate. moving onto it now
@neon briar i double checked via the pinouts here:
https://learn.adafruit.com/adafruit-adalogger-featherwing/pinouts#sd-and-spi-pins-2-11
as sajattack mentioned. but i do think the part of the guide you linked is unfortunately confusing. it looks like it might be re-used from the Adalogger Feather main boards (i.e., not the Wing)
This makes it easier to change code in cases where the pixels may
cause a brownout.
uint8_t zeroes[96] = {0}; works to init to zero also, and the compiler will choose the best way. Don't have to change it if you don't want to.
got the project built without issue (a first for me, I'm normally chasing compile ghosts)
created a new project
or new board, sourced from the feather m4 project
built with the memory I am using
...and now serial is gone too 😃
devices pop up whenever i'm in the bootloader
but back in the normal CircuitPython mode, it goes dark and I don't see anything
I assume that means something else is wrong
currently on my Linux machine (where I built the project), going to swap back to my windows machine to see if it sees something different on the board.
just loaded the file here back onto my board: https://github.com/adafruit/circuitpython/releases/tag/3.1.1
and it at least comes up with serial
so maybe something wrong with my build?
yeah, homemade board with a different chip
that's why I was building
should I be building at a particular tag/release/commit?
what chip?
FLASH - NOR Memory IC 16Mb (2M x 8) SPI 133MHz 8-SOIC
was talking with @slender iron about it above
-IQ and -IM variants have differences. Do we have a def for that chip?
but even the default feather_m4 wasn't showing serial when I plugged it in
the one I built, that is
There have been some usb issues so it might be worth trying from before the big usb merge
should I just chekcout from the release? https://github.com/adafruit/circuitpython/commit/fa1edb2a01f7238ac6fc108142aae35faf7f9b15
that one?
that's the commit tied to the release
yes, try 4.0.0-alpha.2 if you want 4.0. I thought you were using 3.1.1 all the time, but if 4, yes
3.x branch should be fine
if you're on master, you're on 4
master is pretty unstable right now
ok, good to know
that'll be a good sanity check against the files I downloaded from the site
(which work a bit more)
and 3.x should build no problem?
or are there other things I need to do other than swap branches
after you checkout 3.x, do a git submodule update --init --recursive
and rebuild mpy-cross if you are freezing anytying
woooot
CIRCUITPY shows
as is the case of many woes in my current life, I didn't pay enough attention to the BOM
😃
but this was a useful journey of learning how to build the firmware as well
@digital slate 🎉
when the feather boards are shipped from the adafruit factory, they have main.py programmed onto that drive, is that part of the build process as well? Should I be seeing those files or would I need to include them in future build processes?
They aren’t on there by default. The test code that loads circuitpython loads them onto the flash
that makes sense
fancy system y'all got going around here 😃
thanks again for troubleshooting help
Version 4
- Drop subclasses
As expected, a lot less flash use:
Base:
58368 bytes free in flash out of 499712 bytes ( 488.0 kb ).
OSError patch: Use 384 bytes
57984 bytes free in flash out of 499712 bytes ( 488.0 kb ).
uerrno patch: Use 328 bytes
57656 bytes free in flash out of 499712 bytes ( 488.0 kb ).
@slender iron @tulip sleet congratulations on the trellisM4 fix -- just built and ran on mine -- working well now! Nice!
@solar whale any usb problems?
not that I have noticed - on the trellism4
k cool maybe its the m0 that has gremlins still
Ok so.... long story short the character LCD library never had support for the RGB shield, and was using incorporated driver shims for the other versions.... I redid the entire thing to use MCP230xx, sorted both I2C and SPI for the backpack, and I added code that makes the shield work. I've literally never done anything like this. I'm so crazy excited. (Had to share.)
I will try more boards tomorrow - or possibly later tonight.
Ive been writing to and running some test scripts on the trellism4 -- not using neopixels -- but no issues with USB
CPython passes the path straight through to (g)libc (posix_mkdir()):
static PyObject *
posix_mkdir(PyObject *self, PyObject *args, PyObject *kwargs)
{
...
result = mkdir(path.narrow, mode);
...
}
glibc passes it straight through to Linux (mkdir()):
int
__mkdir (const char *path, mode_...
@Makdaam Why do you strip off backslashes in #1066?
@tulip sleet I caught a concurrency issue similar to what you saw. ```
(gdb) p *_usbd_q
$20 = {buffer = 0x20000401 <_usbd_qdef_buf> "", depth = 16, item_size = 12, count = 0, wr_idx = 9,
rd_idx = 8, overwritable = false, mutex = 0x0}
count != wr_idx - rd_idx
and it should
@tulip sleet I can now see the usb serial port of the Trellis m4, but the CIRCUITPY: usb drive does not exist.
@ruby lake the visibility of CIRCUITPY shouldn't depend on the drivers, so that is some other problem. are you using the trellis m4 build linked in the trellis guide?
checking
I updated that using a pi
hm, I thin kthe reset button on this board is broken
it has no tactile feel and the dotstar led glitches a lot
@tulip sleet ok, things are better now. I have the drive appearing and serial console
hm, actually it does not see the REPL in Mu
Yeah, I had restarted the pca10056 build once before. I haven't sent anything this way in a while, so not sure if 3.x builds are perpetually broken for that specific board. 🤷♂️
@dhalbert, any insight?
Argh! Good catch! I shall return my previously received 🌮
No joy on the RFM69 transmit/receive
😦
One chip is the built-in M0, the other is a wing on an M0 Bluefruit (loaded the Adalogger bin)
Temperature: 22.0C
Frequency: 914.999mhz
Bit rate: 250.0kbit/s
Frequency deviation: 250000.0hz
Sent hello world message!
Waiting for packets...
Built-in output:
Temperature: 32.0C
Frequency: 914.999mhz
Bit rate: 250.0kbit/s
Frequency deviation: 250000.0hz
Sent hello world message!
Waiting for packets...
Temp is off
on the built-in
I'm too tired - will chat w/@tulip sleet about this in the morning
Nevermind! My bad - 😃 All is working
(except the temp is wrong)
The following code succeeds in running:
from adafruit_hid.keyboard import Keyboard
from adafruit_hid.keyboard import Keycode
import adafruit_rfm69
#code to do the work...
while the following fails:
import adafruit_rfm69
from adafruit_hid.keyboard import Keyboard
from adafruit_hid.keyboard import Keycode
#code to do the work...
I get the following error:
Traceback (most recent call last):
File "main.py", line 10, in <module>
File "adafruit_hid/keybo...
It can because the memory gets fragmented differently depending on allocation order and the size of objects. Loading mpy files uses less memory so its recommended to do that for files you aren't editing.
If I need to drive a stepper motor directly via DRV8833 breakout board, which circuitpython library to use? I only found examples and libraries for Arduino, not circuitpython...
you may need to write your own
@slender iron @tulip sleet FYI -- tried current master on pca10059 -- still not working. Will try on some atmel M0 and M4's next
@tough flax FYI -- The CP build to use for the Feather_Bluefruit_M0 is indeed the Feather_m0_adalogger build, The pin D8 is not available in the feather_M0_basic build and it is needed to se the Chip select for the Bluefruit SPI interface. D8 is avaliable in the adalogger build. Mystery solved...
@tulip sleet @slender iron No luck with current master on any M0 builds yet -- tried feather_m0_express,feathere_m0_adalogger,, trinket_m0,CPX --- none boot to REPL.
Metro M0 express "looks" like it boots -- green pulsing neopixel but no CIRCUITPY drive ....
Metro M4 express seems to be working fine -- so so far only M4s (MetroM4 and TrellisM4) are working for me.
FYI - tried commit f190bb2c269b06ab2ce8ee8aa220682ab4f2fc2f on several boards,
the MetroM4 express and TrellisM4 both appear to be working well.
None of the M0 boards tased will boot to present CIRCUITP
tried feather_m0_express,CPX,feather_m0_adalogger,metro_m0_express
Also tried pca10059 -- no luck there either.
one for @ruby lake for later (#comingsoon) ...
@hoary hill check this out: https://circuitpython.readthedocs.io/projects/motor/en/latest/api.html#adafruit-motor-stepper
@tulip sleet another flash erase related thread:
https://forums.adafruit.com/viewtopic.php?f=57&t=143622&p=709201#p709003
note they tried to use the UF2s from here:
https://github.com/adafruit/Adafruit_SPIFlash/tree/master/examples/flash_erase_express
which apparently did not work.
are they different than the ones offered here?
https://learn.adafruit.com/welcome-to-circuitpython/troubleshooting#old-way-for-the-circuit-playground-express-feather-m0-express-and-metro-m0-express-18-25
@kattni this does come up once a while, please add it to our FAQ :)
https://learn.adafruit.com/circuitpython-essentials/circuitpython-expectations#frequently-asked-questions-18-8
@solar whale thanks for the update. I know what I need to fix for the internal flash variants of nrf but have been focused on the M0s. One thing worth trying on the M0 is leaving it plugged in and hitting the reset button. I believe I'm seeing a clock startup issue from time to time
I did try that on some. No response. I can try again in a little while.
k, I'm going to try other m0s today after breakfast. some of them may be glaring issues
I'm seeing some crazy clock stuff on the metro sometimes. I have a code.py with 500hz pwm and it can be in the 600s after. The neopixel doesn't work then either
Anyone done much with character LCDs? I'm thinking there's a superfluous property in the RGB lib for it but I want to make sure I'm not missing something.
@river quest woo
@idle owl the rgb lib doesn't do character lcds?
@stuck elbow I mean the character_lcd_rgb.py file
For character LCDs with RGB backlights
ah, no idea about that one, sorry
Ok thanks!
The code doesn't really strip anything (the path is left intact) it only accepts "\\x00" and "/\x00" as valid endings of a path (before that it was only looking for chars lower than the printables - I don't know why not only \x00).
I added the rule for backslash as well as slash, because it was already used as a separator in other parts of the oofatfs code. No other rationale behind it.
If notro is here, sorry for replying so late.
@idle owl I use char lcds but haven't done anything with the rgb ones
@tulip sleet It's an RGB specific question. I think I'm right but if anyone else had worked with them I wanted an opinion.
@tulip sleet How are you at schematics? Maybe you could at least take a look and see if you agree. I don't have a schematic for the display itself, only it used on a shield, but it shows the pins on the display which is the thing I'm questioning
i am good at schematics, so ga
There is no "backlight" pin on that display. Because the backlights are the red green and blue pins.
Correct?
think of it as 3 separate backlights
right, there are three backlights instead of just one. The anode should be the common +V for all the backlights. You ground the R and/or G and/or B pins to turn them. I have one to verify
Ok.
well not that one, but I have the raw display
Because there is a thing setting the the specific backlight pin, and then it uses set_backlight to turn it on or off. I don't think it belongs in this file, because it's meant for the monochrome.
That's what I was thinking.
which pin?
It defaults to None
So it's not actually setting anything.
But that means the property is in there, doing nothing
and you could add it to your code, and nothing would happen
because I don't think it makes sense for this LCD
for a monochrome backlight, do you give it the pin to ground or the +V pin?
Ok, monochrome and RGB are two different files. But here is what I used for the monochrome pins and it works: https://cdn-learn.adafruit.com/assets/assets/000/035/681/original/lcds___displays_schem.png?1473701923
Has a backlight pin.
so set_backlight makes sense and also works
would you set_backlight to pin 16?
let me look
No it's set based on the expander chip and the shift register
I'm using external libraries for both.
@proven bluff notro is github only
which library file should I look at?
thanks @slender iron
It's not all pushed to GitHub, hold on
There aren't any issues with the monochrome backlight
My question was regarding the lack of a separate "backlight" pin on the RGB one, separate from red, green and blue.
but let me get as much of this as I can pushed to GitHub
it's still a mess.
@idle owl sounds you're asking about backlight here?
https://github.com/adafruit/Adafruit_CircuitPython_CharLCD/blob/master/adafruit_character_lcd/character_lcd_rgb.py#L132
yes. and then https://github.com/adafruit/Adafruit_CircuitPython_CharLCD/blob/3775cd7a033b3a9cf2c6806d77807570ffb67794/adafruit_character_lcd/character_lcd_rgb.py#L263 this
not sure, but looks like you just ignore that maybe...
you create the RGB instance with:
lcd = adafruit_character_lcd.Character_LCD_RGB(lcd_rs, lcd_en, lcd_d4, lcd_d5, lcd_d6, lcd_d7, lcd_columns, lcd_rows, red, green, blue)
so backlight will just be None
Yes I know
and then the idea is to use set_color
Right
but that means that the property set_backlight does nothing.
And you could put it in your code, your code will run, and it will do nothing.
I don't think it needs to be in that file.
from what i see, i agree
they're all generally the same in terms of backlight - one or more LEDs that you can PWM control. RGBs are basically just monochrome with 2 extra LEDs
in my mind, the only reason to have it is probably if you want to be able to drop either of an rgb or monochrome display into code that talks to the interface.
and that's already kind of... you're gonna have to know which class you're instantiating anyway.
@tulip sleet this is what I was referring to: https://github.com/adafruit/Adafruit_CircuitPython_CharLCD/blob/3775cd7a033b3a9cf2c6806d77807570ffb67794/adafruit_character_lcd/character_lcd_rgb.py#L263
But here's the current state of mine. https://github.com/kattni/Adafruit_CircuitPython_CharLCD/tree/mcp230xx-support/adafruit_character_lcd
@slender iron pressing reset a few times did get Metro_m0 to boot to CIRCUITPY!
or to allow simple code to treat the RGB as a monochrome version, for simplicity
but then the RGB version of set_backlight should operate on the rgb_led
But no REPL
yes neopixel pusling green
which I considered @tidal kiln
but then it's not set_backlight
and it shouldn't be called the same thing in both and do different things
@idle owl this is one of those things where i'd ask the original author if possible
i agree w/ cater and brennen. one thing to worry about is the polarity. The code talks about R and G and B anodes (+), but the shield schematic you posted above has a common anode pin, so the polarity is opposite.
yes ubuntu 18.04 -- I can see the CIRCUITPY foloer -- looks OK and screen /dev/ttyACM0 connects, but not response from REPL
@tidal kiln Not possible.
😦
Already looked into that when I started this.
then you are free to decide what the future holds 🌈
@tulip sleet the polarity thing is already an issue because set_backlight works backwards at the moment.
pressing RESET does drop the /dev/ttyACM0 to the metro_m0
ok. I'm taking it out. or maybe just have it throw an error in case someone uses the same code as from a monochrome
but it came back to CIRCUITPY
i'd just take it out. It will throw an error because there's no property. That' good enough.
i could argue to leave it in
The error I'd throw is "This isn't supported for RGB. Instead use set_color"
allow an RGB display to act like a monochrome
well, there's also an optional arg to __init__. Do you want to support that? I'd say if you want to make it act like a monochrome, use the monochrome class, not the RGB class.
you can then specify which pin you want. Unless the polarity issue complicates things also
no, I would take all of the backlight stuff out.
@solar whale if you have time can you try it with this version of tinyusb? https://github.com/tannewt/tinyusb/tree/careful_reset
I don't get what the use case is here.
This seems like an edge case. That could be done using the current code anyway
would that make the rgb class smaller?
you could run monochrome code with an RGB display, and it would just act like a monochrome display
R=G=B=backlight
and what color would the backlight be?
shades of white
That will fail on RPi I think.
or whatever was set with set_color
@slender iron OK will give it a try -- take me a few minutes to figure out how...
Can't use more than one LED at the same time
you'd have to make all three pins be the backlight pin, can't do that
i'm thinking overriding backlight in RGB class
@solar whale you can go into the submodule and add me as a remote
ah
@idle owl just a guess - but current character_lcd_rgb.py was probably started from character_lcd.py copy pasta style, that's why the set_backlight code is there and the same between the two
Yes I agree.
But since this is my first major driver work, I wanted to make sure I wasn't missing something before making the change.
i don't think so
@slender iron it now has ```origin https://github.com/tannewt/tinyusb.git (fetch)
origin https://github.com/tannewt/tinyusb.git (push)
that was git remote -v
are you planning on moving to @property style also?
can I just do git fetch origin careful_reset?
ah, ya. I think that will work
seemd to accept it -- building now
k I'm trying on adalogger too
@idle owl fwiw - it's easier when you start from scratch. dealing with "why is this here?" kind of stuff when inheriting code is an unfortunate side effect. you end up burning time reverse engineering and speculating about things.
on metro M0 -- I had to reset it twice htne it boots OK and I have REPL
was the neopixel ok when it didn't work?
commit did not change -- I htink I have ther right build ```uto-reload is on. Simply save files over USB to run them or enter REPL to disable.
Press any key to enter the REPL. Use CTRL-D to reload.
Adafruit CircuitPython 4.0.0-alpha.2-149-gf190bb2c2 on 2018-11-14; Adafruit Metro M0 Express with samd21g18
checking
(make sure you checkout the branch too)
HEAD detached at 299a2f12
nothing to commit, working tree clean
``` ahh - I did not checkout -- trying again
just asec
./bossac -e -w -v -R -p ttyACM0 adafruit-circuitpython-feather_m0_adalogger-0.8.0.bin
thanks!
hmmm -- no REPL on metro_m0 now -- didi get CIRCUITPY after two resets....
hrm
git status ```n branch master
Your branch is up to date with 'origin/master'.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git checkout -- <file>..." to discard changes in working directory)
modified: ../../lib/tinyusb (new commits)
Untracked files:
(use "git add <file>..." to include in what will be committed)
../nrf/drivers/
no changes added to commit (use "git add" and/or "git commit -a")
the adalogger worked for me when I loaded it
OK -- I can try it -- did metro_m0 work for you?
it was pretty reliable yesterday. when it failed the neopixel did too
ddi you do debug build -- I am not
no, let me post my bin
adalogger not working for me either 😦
Press any key to enter the REPL. Use CTRL-D to reload.
Adafruit CircuitPython 4.0.0-alpha.2-150-ga96580e92-dirty on 2018-11-14; Adafruit Feather M0 Adalogger with samd21g18
>>>
>>>
>>>
I think I'll PR these changes so we can see
code runs!
I will try on a metro m0 as well
👍
having a code.py with pwm out can help diagnose clock startup issues because a saleae can verify its speed
my metro_m0 still not happy -- do you want me to try your .uf2?
let me build one
not working for me on metro m0 with adafruit/circuitpython f190bb2c269 (head) and tannewt/tinyusb at tip of careful-reset 😦
rebuilding again to double-check
i did, and also plug/unplug
hrm, is the neopixel working?
so its not a clock issue
@tulip sleet and I are consistent
k let me get closer to a clean branch
on thirdt reset I got a CIRCUITPY mount, but still not REPL
no -- my dog is part beagle 😉
😃
do you want another beagle trace from me?
I get repl on mac
Press any key to enter the REPL. Use CTRL-D to reload.
Adafruit CircuitPython 4.0.0-alpha.2-149-gf190bb2c2-dirty on 2018-11-14; Adafruit Metro M0 Express with samd21g18
>>>
>>>
>>>
sure I guess
after a reset
making a new build for myself now
@slender iron are you on mac?
does it work on both? works on my mac but not linux
that was my build -- I can try yours
ya, I think so
worked on mac first time, but then I unplugged/plugged, and am now getting an irregular green flicker on the neoxpixel on metro m0
and no repl or circuitpy
that sounds like a clock issue
mine (my build ) was OK after plug.unplug on mac -- still needed a reset
here is my code.py: ```
import pulseio
import board
p = pulseio.PWMOut(board.D8, frequency=500)
p.duty_cycle = 2 ** 15
while True:
pass```
@chrome perch can you repro with a jlink attached?
oops wrong dan
i'll try, and you want me to monitor D8 with saleae?
ya, please
you want me to do this on mac or linux?
either as long as you plug it into what causes the issue
I can hook it up too -- seeing solig green on mac after reset
the flicker is new, never seen this before, only on mac
it should be very close to 500 hz
I see same thing -- solid green on Ubuntu, but no boot
what linux kernel is it?
Linux salmonx 4.15.0-38-generic #41-Ubuntu SMP Wed Oct 10 10:59:38 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
~ $ uname -a
Linux dalinar 4.18.16-arch1-1-ARCH #1 SMP PREEMPT Sat Oct 20 22:06:45 UTC 2018 x86_64 GNU/Linux
mine is ame as Dan
k, I may go try it with the rosie box which is running ubuntu
let's see if i can use jlink on linux with it plugged into Mac
thats what I do 😃
we are running ubuntu 18.04, updated to latest kernel
k will update my box. its a little behind
i mean latest 18.04 kernel
dmesg shows ```[245044.317406] usb 3-3.4: new full-speed USB device number 111 using xhci_hcd
[245044.440146] usb 3-3.4: New USB device found, idVendor=239a, idProduct=8014
[245044.440152] usb 3-3.4: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[245044.440156] usb 3-3.4: Product: Metro M0 Express
[245044.440158] usb 3-3.4: Manufacturer: Adafruit Industries LLC
[245044.440161] usb 3-3.4: SerialNumber: D5B6D46D8413D405C413E263011241FF
[245044.440937] usb 3-3.4: can't set config #1, error -32
that's the same error I was getting
I do not have wireshark
ok, thats good its the same error. I was digging in the code that responds to the set config request
I don't know where its getting lost though
ok, I got it too.
gonna move that box down here
plugged into mac, removed jlink (because it interferes with neopixel), runing the PWM test code. PWM is fine at 500 Hz. LED started regular green, then switched to very bright green after a few seconds. can't reproduce that yet
hrm
stil not working on win10 either
@tulip sleet I've reproed the beagle trace you sent me. lots of stalls
a usb state viewer says "Configuration Descriptor Request Failed", which is what I saw in the usb traces
ya, its weird. it looks like it works the second time
maybe windows and linux are too fast? You could compare the time stamps on the enumeration requests/responses in the good and bad traces and see whether one is significantly ahead of the other?
I can't get it to work at all on Ubuntu now -- still get 500hz on D8 but no response from USB
arg - unplugged/plugged and CIRCUITPY came right up!
I've got it reproing with gdb attached
but no REPL
I kinda suspect a buffer overrun
the setup request data isn't making it through correctly
but there is something on Mac and Arch Linux that's different: order of requests or timing related
that makes it less likely to fail
@umbral dagger heya i replied in github but dunno if you didnt see it (you mentioned before not getting github notes) - wanna split Debouncer out?