#circuitpython-dev
1 messages · Page 156 of 1
it clearly returns one -- that is a change from earlier version:
So... I know it's a thing. But that's the extent of what I have.
>>> result=lis3dh.acceleration
>>> result
acceleration(x=-0.038314, y=0.0, z=0.766281)
Oh...... so it does it. It's not something you have to do.
used to just return the tuple - no name
Right.
but exisiting code works fine.
I didn't think we wanted to get rid of that option entirely. But eh. Scott said the code looks good. If it doesn't break anything, then it's probably good to go.
Thanks for testing it 😃
>>> x,y,z=lis3dh.acceleration
>>> x
-0.038314
>>> y
0.0
>>> z
0.766281
>>>
Oh hmm. Good question. It'll need to eventually.
not sure how it gets used - I did not follow look at the reason for the change. I should go back and look at it 😉
no issue and not much in the PR so I'm guessing it was a minor change.
ah found a refference to an issue (#12)
I thought I remembered there being one
it allows you to do this ```
result=lis3dh.acceleration
result
acceleration(x=-0.0957851, y=0.0287355, z=9.77966)
result.x
-0.0957851
result.y
0.0287355
result.z
9.77966
Hi guys,
I'm trying to read IR sensor data on a CircuitPlayground Express board. according to this doc: https://learn.adafruit.com/adafruit-circuit-playground-express/pinouts I should be able to use A10 and D39 to read the ir input. However i always get these errors:
NameError: name 'A10' is not defined or NameError: name 'D39' is not defined.
My code looks like this:
from analogio import AnalogIn
d39 = DigitalInOut(D39)
a10 = AnalogIn(A10)```
I can access other pins such as `A8` with no problem. Any thoughts?
do you have import board in there?
ok I found the solution, in REPL I typed
>>> import board
>>> help(board)```
and I saw
```board.IR_PROXIMITY``` and ```board.REMOTEIN``` which seems to be what I'm looking for. Not sure why it doesn't match whats in that document.
looks like they gave names to the pins beyond the arduino-style Ax, Dx
you can probably still use board.D39 etc
D39 is not defined in the pins assignment. REMOTEIN and IR_RX are assigned to PA12 (aka D39). I think IR_PROXIMITY will use both the IR_TX and IR_RX; it is mapped to its own port on the MCU.
@idle owl do we have an example or learn guide in the works for using the IR_PROXIMITY on the CPX? don't see anything on Learn or in the repos... (see above discussion)
Good job so far @notro! I think this will help you create a struct_time: https://github.com/adafruit/circuitpython/blob/master/shared-bindings/time/__init__.c#L82
Its actually just a named tuple. I believe the type you'll want to pass is &struct_time_type_obj.
We can updated Adabot to be ok with subfolders. I think a README.md would be fine but I don't think a .py makes sense.
I'll take a quick look now at APDS9960 and see if I can get a better mock function in there. I think another library may have done it already.
Here is a fix for APDS9960: https://github.com/adafruit/Adafruit_CircuitPython_APDS9960/pull/8
We can use the same technique to remove any MockObjects we see references in the auto-gened docs.
Great work everyone!
Thanks @kattni. Happy to share the process. It took me a long time to find out some of the RTD workflow stuff like this.
re the namedtuple stuff, you can continue to use numbered things too
>>> a[0]
>>> a.x```
I agree on both accounts. A README would be useful in the FeatherWing examples folder, but a .py might get confusing. Would RTD render a .md (lazy/at work; haven't looked it up myself)? If not, we could setup a toctree for the examples with an examples.rst, or sub-tree it in the index.rst.
I believe RTD would render the .md unless we explicitly ignore it.
On Mon, Mar 19, 2018 at 8:46 AM sommersoft notifications@github.com wrote:
I agree on both accounts. A README would be useful in the FeatherWing
examples folder, but a .py might get confusing. Would RTD render a .md
(lazy/at work; haven't looked it up myself)? If not, we could setup a
toctree for the examples with an examples.rst, or sub-tree it in the
index.rst.—
You are receiving this because you were me...
No pinned message?
@timber mango I forgot!
<@&356864093652516868> Weekly meeting will be here on Discord in an hour! See you soon!
I forgot if I remembered or not. ;) I thought I saw it last night, but could not find it just now. ;)
thanks for the reminder
You're welcome. I generally arrive home right about now, so unless I forget it's a Monday (and dawdle on the way home, perhaps to stop in for shopping or a visit with a friendly shop keeper) .. I just have to remember that this exists. The pinned note does help.
@idle owl I was playing more with lis3dh examples on CPX and I am not able to get the tap.py to work. It runs, but never detects taps. Is this a know problem or should I open an issue. I tried on 2.x and 3.0 - previous and current driver.
jerryn I have an oscilloscope now. 25 MHz digital w/LCD display and it's not bad at all.
Oh, cool. I'm actually here today.
@cunning crypt I say that to myself every day I wake up alive. ;)
nice! It will be a great addition to your bench. Mine has come in very handy!
And here I thought you'd just put on the BeeGees
(haha andon) jerry: now i see the value in multi-channel. Even for SPI I'd like to watch all three lines (or four, when MISO is used).
@shut karma Nice addition. I'm making due with a Bitscope Micro for now. Kates up a lot less room 😃 and does the job since my workbench & desk are next to each other.
I got the oscope for 100 bux at the Ham flea market in Southington, yesterday. I like buying there because there's a reputation economy among hams -- they can't afford to routinely sell junk. This one's in very good shape.
sounds like a great find. It's been a long time since I went to a hamfest. Quite an event!
PDS5022S I forget the mfgr's name owon or something:
https://www.amazon.com/PDS5022T-Portable-Oscilloscope-Multimeter-Channels/dp/B007T6XNCA/ref=sr_1_5?ie=UTF8&qid=1521399652&sr=8-5&keywords=PDS5022S
That one has more reviews and is one letter grade newer than mine (mine is the 'S' and the reviewed is a 'T' suffix to the model number -- same front panel fwict).
My point is that they can be had at far under retail, if you wait for the opportunity to arise. ;) Last year I acquried a 'LabVolt' unit that has several modules organized into 4 half-racks of equipment.
Function generators, two completely different meters (the top one is simplified; both measure current and voltage; the bottom one does full VOM functions). And a variable AC and DC supply.
It was designed for student use, so you have to move the bananna plug from one jack to another to measure Ohms (to avoid an 'oops' event).
Although 3.3v was rare when the LabVolt was made, they're very good at orienting the thing down to 2.0 VDC and up to 20 VDC (in two ranges).
The two LabVolt meters are my only analog d'arsonval movement meters. I have to have those to function. ;)
I also picked up a Dell Optiplex 790 with a Core i5 and 2 GB, 250 GB, like a 19" VGA widescreen display, keyboard, mouse and speakers -- $60. He asked $80, then lowered the price to 60 during the conversation.
I paid him 80 and explained it was worth more than 80. This guy just about licked it clean, days before the flea market. One of those people who take q-tips and clean the corners of their beloved equipment.
They were both excellent vendors, doing this as a hobby.
The monitor is worth that - I have a VGA monitor with a VGA to HDMI adaptor I use for getting Raspberry Pi's up and going.
The rest - well not sure what you have in mind, but not much will run in 2G these days -- sad...
It's a beautiful LCD and heavy as a boat anchor, and kinda thin. Probably the last of the heavier VGA LCD displays.
Well I will steal the 4GB out of a same-era system I never use. This one scores double my present laptop on cpubenchmarks.net
$ cat /proc/cpuinfo | egrep i3 | sed 1q
model name : Intel(R) Core(TM) i3-2350M CPU @ 2.30GHz
Been running this laptop (only) last three years. ;)
BTW upgrading Debian from i386 to amd64 is a nightmare. I gave up and will begin doing a proper install today on the 'new' unit.
At some point it wanted to change out systemd/init stuff and that was the end of that. HAVE to chroot jail to have a chance to succeed (I did it once; maybe twice, before).
And that's my daily not-quite-on-topic wall of text. And I'm back quiet. ;)
I believe @tannewt is correct. If you do not for some reason see it, double check that it is included in any toctree (local or master) and that recommonmark is installed.
gonna have my mic off for the helpers meething, got sick and my throat is wicked sore 😦
eesh, feel better @prime flower !
thanks, it's been 8 months since I've been sick so it was bound to happen eventually
@raven canopy We do not have an IR prox example afaik
@prime flower feel better - no chicken soup emoji 😦
@solar whale Open an issue, it's not something I was aware of.
<@&356864093652516868> Meeting in two minutes!
Yes. You do. To all of it....
you need a snowglobe kit
@slender iron I do that. Far too often.
I can't unmute
I do not hear anyone talking, but I see evidence that they are so I’m investigating
"NEat! I'll do this some day"
Reload @quick oyster
We all had the same issue earlier
Can't hear you if you're talking @quick oyster
"It's all electrons."
Electron. It's a platform.
@idle owl oops!
😃
fly on the wall mode for me this week. no mic. no updates. group hug.
That new microbit dragon thing is getting attractive.
any luck @quick oyster ?
Nope. Let me know when it’s my turn and I’ll report from here
My weekly report got long so I'll post it as a file instead of in-channel.
Tracebacks (vs gforth). vector graphics oscope netpbm. 74HC595 (shift register driving 7-segment LED array) in CircuitPython quickest route this week over Arduino (SPI ready in CircuitPython due to prior work by me). Status LED CircuitPython proving useful.
Is there an audio/video/hangout? Notice some comments about audio, but I'm only signed in to discord text chat.
@hollow ingot Yep!
Join the CircuitPython voice chat on the left
It's audio. To join, click on it.
@hollow ingot Scott is going through the State of CircuitPython at the moment.
Hug Report: Group Hug. Still busy with other things, so havent' paid much attention, but I'm sure you are all doing awesome stuff.
hug report for @slender iron for being on one of my favorite podcasts (the amp hour). I listened to it on my flight and it made time fly.
I've been train-ing for it, @slender iron
Carter said group hug earlier.
fly on the wall mode for me this week. no mic. no updates. group hug.
Group hug for all the work on 2.2.4! (Seamless conversion of existing projects.)
Congrats on Alpha 3
Hug report to Tony DiCola for the initial work on documenting the building of CircuitPython from source:
https://learn.adafruit.com/micropython-for-samd21/build-firmware
(Initially this was Micropython for Adafruit product line, more than a year ago)
The present Vagrantfile is verified correct by me. ;) There's enough info in the Vagrantfile to build everything, if you look. ;)
Was able to build the 3.0.0. Alpha-2 from those instructions, this week!
Hug from me, then. A Vagrantfile is just what I need!
Group hug this week. And @twin mica for ATizing last week's project.
Team up with @split ocean with the AT-AT ;)
The AT-enabled AT-AT
Apparently couldn't connect mic, sorry. Looking forward to trying out alpha3, thanks to tannewt for guiding me on conformance for https://github.com/adafruit/Adafruit_Micropython_Blinka and tannewt and ladyada for comments/feedback. Had a sprint on prepping @ShrimpingIt kits last week but now available again
Just don't lose it. Then you have to ask, "Where's the AT AT-AT at?"
Status update: Nothing CP-related. Main project is continuing to re-chip the DigiBadges for a convention at the end of the month, but I've also taken up writing a standard python program to generate random tectonic plates. It's absolutely not something I need to make, but... Well, I'm going to do it anyway.
Literal tectonic plates.
nothing cp related, spinning back up from vacation
Things that move on the planet and cause earthquakes.
🌍 generation
I think we broke Scott.
Next is SPI
We blink lights! We're all playing with kid's toys
@errant grail Don't worry. The convention I'm selling stuff at is a My Little Pony convention. There's nothing wrong with "Kid" stuff.
Although some people look at you funny when you're just horsing around.
I was going to say "I play with rockets" but definitely not kids toys, since they're taller than me, go up over a mile, and can break the sound barrier....
@drowsy geyser They're the toys kids wish they could play with.
LOL. As Elon says, "because who doesn't love rockets?"
I decided that I will always play with kid's toys.
nothing CP-related
... decided that long, long ago
@drowsy geyser So you're not as fishy as we thought?
LOL! I'm used to it. But, I don't have trouble with my user name being taken when registering on a new site!
Man, I do
@solar whale put the pHAT in the Community Bundle?
i think no dotstar, just IR led
@raven canopy good idea!
Big "yay" for @idle owl 's hard work!
Late hug report: @tulip sleet for pointing out the presence of 74HC595 Shift Register in the AF LCD backpack.
Status report (brief): Tracebacks (vs gforth). vector graphics oscope netpbm. 74HC595 (shift register driving 7-segment LED array) in CircuitPython quickest route this week over Arduino (SPI ready in CircuitPython due to prior work by me). Status LED CircuitPython proving useful.
See scrollback for a more detailed (haha) report.
I take it back, ladyada said in a github comment: "basically a trinket or gemma with only dotstar LED + IR Receiver"
re pirkey
Python was based on LISP, and Forth probably too
I’ve got to run, so I’m gonna paste my status here: I’m currently working on two things in the pursuit of asyncio: selectors and deque. Not much progress yet since I’ve had a busy week here at work, but I’m still on-track for delivery of asyncio before PyCon; no impassible road-blocks yet. I’ve got all the hardware I need and I’m gonna start running things on the CPX. My goal remains asyncio to allow rainbows and IR to coexist.
thanks @quick oyster perfect timing
😃
STATUS: Got debug working over the weekend on the "128char max paste in REPL". Still working my way to grabbing fully useful data with atmel studio & GDB, but the picture is a getting clearer. And to retract my statement from last week: docs are never done. :D
Joke...
PyCon is in May.
https://us.pycon.org/2018/about/
@quick oyster I'm excited for asyncio 😄
@twin mica nice. i know that's been asked about several times. thanks.
Yay to asyncio! Addicted following use of this on micropython
stringcar-transported maple syup site-inspection (automated)
that was really interesting (especially calc'ing distance)
Azure rocks!
rain shadow!
vive la rein ;)
@errant grail When I need to test my rover I'll bring it out your way...
@drowsy geyser We have sandy, arid space just waiting. You may have to compete with some ATVs and dirt bikes, though.
@pastel panther is the SPI mapping pinmeister -- helped me out with the SERCOM system.
We can test this pretty easily with a LiPo battery....
Use a LiPo battery with a USB fitting as with cell phone chargers.
I do that when I need electrical isolation from the laptop to avoid ground loops when testing with a powered oscilloscope &c so that there's only one thing (the oscope) connected to 120VAC power at a time.
bit rate vs large periods of 'silence'
You can.
Definitely.
Bitbanging reveals itself plainly in the code you ran. EDIT: except for fallback to bitbang! (special case)
Conversely, hardware SPI wil fail if your SERCOM cannot support hardware SPI.
In both cases, other nonessential code can side-track program flow enough to provide measurable delays.
The wheel code runs slow altogether. I'm still confused as to why.
(wheel is a function found in RGB LED demo code -- even in Arduino -- it basically maps 0-255 to a 'color' on an RGB LED)
the 'display' or 'show' code is usually a bottleneck in most of these libraries.
Yeah there's a fallback to bitbang for dotstar in CP -- forgot about that.
keyboard repeat was a BIOS setting in IBM PC world. That was a 5V two-wire protocol and a dedicated chip.
Later keyboard tech implementation probably emulates this.
yeah, key repeat is a operating system thing
the os rate-limits the keyboard i think
the keyboard only sends a keydown and keyup event
Momentary button, debounce, loop...
Alright, I'm out everyone. Lunch, have to call the State of California about the seller's permit, and then I have another 84 microcontrollers to pull off boards.
enjoy lunch, andon!
new boards/compatible products from adafruit too, maybe
community projects as well, in the links, right?
Oooh, time for a DSKY in CircuitPython (aka "the Apollo Guidance Computer")
I've been using jekyll, it's neat and im looking fwd to this
Have to see it first. ;)
@drowsy geyser i watched apollo 13 the other night, good timing 😃
@prime flower Great movie!
Thanks, everyone!
good work everyone, cheers!
Thanks everybody. Keep churning out your awesomeness!!!
fin 19:09 UTC
Thanks!
thanks!
thanks!
@twin mica if you did want to do a repeat, maybe you could add a 555 timer circuit to a button on the side of the switch? or do it in software?
👍
I had a thought after sat night. Would having HW_APA102 on the non-express boards make a difference with DotStar strips?
ItsyBitsy has a DotStar @raven canopy
Ahhhh. Scratch that then...
DotStar seems slightly less mysterious to me** but I haven't written code specific for it just yett. ;)
** vs NeoPixel
neopixels are whiny
they need their timings to be just right
By the way, this is not directly related to CircuitPython, and Adafruit only has a few kinds of displays, but I started a display module sruvey here: https://github.com/deshipu/displays/wiki
maybe you will find it useful for designing new projects
Maybe I'll look into hacking vim keybindings (basic set) into Mu editor if it doesn't have them already. Or at least dream about that. ;)
There's always "just use vim" 😃
I'm thinking IDE's like Arduino probably leverage the deep heritage of tracebacks to point to errors in the code. I'm assuming Mu might have that. Don't know how to point tracebacks to code loaded in Vim. ;)
Maybe python'ers have solved this already.
a la
https://vi.stackexchange.com/questions/5110/quickfix-support-for-python-tracebacks
https://github.com/mattboehm/vim-unstack
I think just using the programming ideas behind unstack will help me *cough* .. unpack .. the ideas behind tracebacks. ;) << this one's for you, @cunning crypt (3/5 of a limerick or haiku?)
DC Motor Driver: Still thinking about creating an issue for incorporating an acceleration/deceleration rate limiter into the driver. At this point, I'll just offer it as a project example instead.
@prime flower yeah at some point we'll need that, maybe like a USB game pad where the key presses on-release would be beneficial
wait... err, not on-release but "on press"
Hello everyone just got back from a 4-day field trip with my FBLA club. Tons of fun! Can this board be programmed using CP? Adafruit Feather HUZZAH with ESP-F V1.1 WiFi
Feather is the new development board from Adafruit, and like its namesake it is thin, light, and lets you fly! We designed Feather to be a new standard for portable microcontroller ...
@tulip sleet Ok, pylint doesn't care about those redundant parens. PEP8 does, but running pylint doesn't compain apparently.
@idle owl great!
https://learn.adafruit.com/adafruit-feather-huzzah-esp8266/downloads
cp2104 interface (Silabs USB to UART bridge). ESP8266 mcu/foo module. KTOWN March 2016 schematic.
@compact solstice - sorry - I deleted my post since upon further digging - I am confused about the board you referenced.
there are twi different parts but both link to the esp8266 guides! https://www.adafruit.com/product/2821 https://www.adafruit.com/product/3404
Feather is the new development board from Adafruit, and like its namesake it is thin, light, and lets you fly! We designed Feather to be a new standard for portable microcontroller ...
@humble mural I created a forum post to see if this can be clarified. https://forums.adafruit.com/viewtopic.php?f=57&t=132784
$ egrep USB0 esptool.py ; /bin/pwd
DEFAULT_PORT = "/dev/ttyUSB0"
/usr/local/lib/python2.7/dist-packages
That'd be the cp2104 -- it likes /dev/ttyUSB0.
.UF2 is a completely different idea. Doesn't apply here.
@timber mango yes ESP8266 comes up as /dev/ttyUSB0
@solar whale Thank you very much. It is in stock now and I truly don’t remember when I ordered (or set back in stock notifications). When I knew absolutely nothing I selected any project that I thought my students may like. As I learned more, I became more selective only focusing on items that can be used for CP projects (I’ll make an exception for a MicroPython project). I look for to follow that post. Thanks again.
With the ESP you're basically using a serial UART on the ESP end of things. With SAMD21 you got some fancy innards that supply a USB port to the host pc using the ACM stuff. Totally different ideas (almost).
I use the same CP2104 chip to do my 8051 development (it has a serial bootloader programmed into the 8051).
@timber mango sorry were you commenting on the post I deleted ? I was just trying to point out that eh ESP8266 did not support the USB drive (CIRCUITPY)
@timber mango and @solar whale in what machine (o/s) are you executing those commands. I tried flashing ESP32 and ESP8266 with Cp and MP this weekend using Linux in VBox and I would get /dev/pts/8 for example
@tulip sleet The updated rainbow code is lightning fast on NeoPixel as well. 😃 Strip of 120 in what seems to be about 30 seconds.
@compact solstice - they are for native Linux - I'm not sure how it will map with VBox.
@solar whale let get this right Ubuntu will behave differently in vBox than if installed as a stand alone?
peter vbox isn't hardware is it?
@humble mural Ihave not tried that - whwn I use VBOX - I copy the file out to the host system then do the uploads via the host system, not the Ubuntu vbox.
No sir
There's some remapping stuff inside the VM for virtualbox/vagrant used to build circuitpython from source code. That stuff should allow talking to the USB system (to some extent) if I understand things correctly.
Yeah it's easier to copy code built inside a virtual machine (VM) to a special directory that the outside (host) machine can see as well, and use that outside machine as the talker when it comes to writing to a (real) USB port.
@compact solstice - I never trusted mapping the USB port into the VM . So my VM could not directly access the USB port.
@timber mango I may have a hard time learning the configurations for a VBox Machine running Linux to flash/program dev boards. So would it be better to take one of my older laptop and make it a dedicated Linux box or use my MacMini?
@humble mural I converted an olld mac mini to ubuntu just for this purpose and it is working very well.
@solar whale now I don’t feel so bad, I tried all weekend long and couldn’t do it
@solar whale curious why you went that route. I would have kept a Mac a Mac
I ran Linux on PowerPC in 2003. ;) On an iMac G4.
The old MAc Mini was very slow and does not support the latest versions of MacOS well - I had retired it, but it runs Linux very well and has a new life. I also use my newer Mac Mini with MACOS but do most of my work on the Linux mac mini since I find the linux tools are much easier to work with,
I would put an Ubuntu 14 LTS or maybe (maybe) 16 LTS on a laptop and see what happens. But -- I have put Linux on just about everything I could find that'd accept it (at least a hundred times, maybe more).
I almost never have to burn bootable media, though I hardly count running 'dd' against a USB thumb drive, to do it. ;)
Linux is generally infinitely backwards compatible on i386 and amd64 hardware -- you do not have to find an older distributed version to work with older hardware (up to a point).
TinyCore is ideal for small machines with a modest amount of RAM.
If you're under 4 GB of RAM it may be less attractive to use it for programming. Even 2GB is pushing it.
Whereas TinyCore is fine in 500 MB RAM (though not as nice) and suitable for nettop duties (light web browsing without addon cruft -- wikipedia surfing and the like).
I have to step away for awhile - good luck @humble mural
@solar whale later and thanks
When 4 MB of RAM took up 4 slots on the motherboard, I was running Linux in text-mode only -- for two years. ;)
And was still compiling the Linux Kernel that way, just fine (about 25 minutes for a build).
@timber mango so TinyCore Linux is an acceptable distribution to do this type of work?
No it isn't. It is a .. a very social .. movement away from monolithic OMG this is too big .. Linux. ;)
TinyCore is oriented to machines that choke to death on full modern Linux installs.
Since TinyCore uses a modern kernel, I always have it on every hard drive I own, as a 'rescue' system to run fsck. and so forth. (fsck is file system check)
TinyCore is pretty much Knoppix which is Debian. Debian now has Debian Live for the same market. TinyCore used to be called ______ (censored word) small linux.
http://tinycorelinux.net/
The censored one is just before CRUX on this page:
https://en.wikipedia.org/wiki/Light-weight_Linux_distribution
@timber mango I’m just going to come out and ask what Linux distro can I put on this machine that won’t drown it and allow me to work dev boards.
Afaik that's Ubuntu -- Ubuntu was designed to be friendly.
You could put a flying carpet software on that system. You got 4GB and a Core i5 chip.
I wouldn't hesitate to put Ubuntu on that. If it runs too slow, there's simple ways to get around the problem.
Straight of the shelf 16.4 LTS or is there a ‘lighter” version, let me check site
Basically just add an .xsession file with one word in it 'fluxbox' after installing fluxbox. ;) that alone speeds up Ubuntu dramatically.
Might run fast enough for you as-is, using follow-your-nose installation methods.
Let's take this to project help as it's not really circuitpython related. ;)
I am not worried about it being a rocket, more interested in it working with these boards. I love seeing the YouTube videos but nothing seems to work and if I start in Win10, I see that the learning guide is in IOS, I learned this weekend that Ubuntu on Vbox doesn’t work. So let’s try turning a laptop in Linux and using that
I have to learn that .xsession trick. I have to search that and learn about that. That is fascinating
Let's go to #help-with-projects for this.
Go it
@humble mural to program the ESP8266 from the VM, you need to setup the passthrough for the USB in VirtualBox. Or, I think I successfully ran esptool from windows (using the shared drive, like jerryn spoke about earlier; but that was when building local firmware). I can show you how to setup the passthrough in VBox.
@compact solstice personally, I have found it much easier to set up a dual boot machine than mess with virtualbox, vagrant, etc. if you only have a laptop you have to split the single hdd. If you have a desktop just throw another drive in the box. The latter is much easier to deal with because Windows won't overwrite the grub bootloader.
@tulip sleet Agreed on dual-boot. VMs are nice...but the mix-n-match with Windows and <anything else> has serious limitations.
That and VirtualBox on my Windows 10 Creator's Build machine blue screens it. Every. Time.
I may end up in a dual boot. was going to re-use my latest upgrade leftovers for separate linux box. but, my new desk is significantly smaller and i'm running out of space as it is.
@drowsy geyser really? my vanilla Win10 has never had a blip...
Both my laptop and desktop (work) systems are very ... intollerant ... of VirtualBox.
It's ok. I just built an Ubuntu system and use that....
i had a terrible time getting vbox and vagrant to work on windows - much easier just to set up a vm manually or a dual-boot. had to do with uefi and networking - ugh
i find vmware player more straightforward (though doesn't work with vagrant). But i am too used to installing ubuntu to bother with vagrant
Meant to put this up last night before the meeting today, but ran out of time.
-
After looking at 2.x a little deeper, the only BIG difference I can see is that
usb_rx_notifyblocks out while it pulls the data from both endpoint buffers (128 bytes) and puts it in the local buffer. I may be wrong, but reconciling the difference between ASF3 and ASF4 conventions isn't easy for the untrained such as myself. -
3.x
read_completeis the equivalent [my perception] and only blocks out for e...
anyone have an image editor handy? I want an image with blink over the amp hour logo
Yah, how exactly?
for the newsletter
No I mean where do you want Blinka
maybe the left looking at the logo?
with a wider black background so its not super tall
so side by side? not over the top?
that reminds me. i need to re-dl GIMP...
nice! that'll work
Ok two shakes.
or like this?
either item can be scaled if you want smaller/larger
i like the little bit of overlay in kattni's though
I was thinking amp hour would be centered like @idle owl has
yah. it gets my vote too.
😃
i like how right facing blinka has tail in front. left facing has tail in back.
@tulip sleet @raven canopy funny I have moving away from dual booting the more I learned about VBox, but I see the challenges with using my main Machine is dual boot with Linux Mint. I am going to see if the laptop has enough hard drive space
@compact solstice your Linux Mint machine would be fine for development. Just
sudo add-apt-repository ppa:team-gcc-arm-embedded/ppa
sudo apt update
sudo apt install gcc-arm-embedded python build-essential
and install git too if not already installed. That might be all you need.
@tulip sleet I need to do this on a laptop because I need to use it both at home and at work
@compact solstice got it. If you have an external drive that could also work easily, esp if you have a USB3 port
@humble mural are you building local firmware, or just flashing the released firmware?
@raven canopy I’m just starting off. I am following Tony D’s guides search through YT flashing ESP32 and ESP8266 with CP or MP with the goal of programming them in CP or MP later
@humble mural ahh. ok. this is the guide you'll need: https://learn.adafruit.com/micropython-basics-how-to-load-micropython-on-a-board/esp8266
it has a link in there for building your own firmware, but you won't need to just to get programming CP/MP on the ESPx.
you won't need VBox on windows for that guide. just python2.
although, if you do want to use your VM.. I can still walk you through setting up the passthrough.
@raven canopy I’ll try them all again using Linux. As we speak I’m installing Ubuntu on an old laptop I had. I spent the weekend going through that guide using VBox, I expect a better outcome now
I tried it with Python 2 and 3
If using a windows machine do you do the work on command prompt or Powershell, I tried both
like i said earlier, i vaguely remember flashing on windows. used powershell to run esptool; not python shell.
in powershell: navigated to the python2 packages folder, then ran .\esptool blah blah. like i said. vague memories.
i didn't have a syspath setup to python2, which is why i nav'd to the packages folder.
@raven canopy thanks a million. I just to play with it until I know it like second nature. Can’t teach it until I master and I need a method that I can easily replicate. I saw a method using a RPi3. I pickup 15 from Adafruit this year, it that solution works, I may go that route.
understand totally. and rpi is definitely an option. lastly, no worries! if i can help someone help kids...i'm all in. 😄 📚
Thanks
@tulip sleet @timber mango thanks for the Linux tutorial everything worked as stated
newsletter draft is here: https://adafruit.github.io/circuitpython-weekly-newsletter/weekly/2018/03/20/scott-on-amp-hour.html
Looks great, @slender iron!
thanks @idle owl !
I concur, @slender iron! (that Blinka enhanced logo aint too shabby either, @idle owl!)
index is here: https://adafruit.github.io/circuitpython-weekly-newsletter/
Community newsletter for python on microcontrollers
@slender iron any tricks on getting optimized -O0 to fit on the chip? I was 406 bytes over when I tried, and -O1 isn't any better than -Os from a debug value-checking standpoint.
nah, I usually do -Os but make sure -flto is disabled
<@&356864093652516868> Here is the recording of today's meeting: https://youtu.be/G_br7smHsvU
Notes with timecodes are available here: https://gist.github.com/tannewt/5f0a7deca58bd451762ec340a62bdba4 Join here for the chat all week: http://adafru.it/d...
i didn't touch any of those flags....too much scaryness. 😄
The following error occurs when building with gcc 5.4.1 (debian stretch):
common-hal/busio/UART.c:104:83: error: 'sercom_index' may be used uninitialized in this function [-Werror=maybe-uninitialized]
sercom_insts[rx->sercom[j].index]->USART.CTRLA.bit.ENABLE == 0) ||
It may be related to the addition of rx-only UARTs; gcc is unable
to infer the intended relationship between have_tx and sercom_index
being set (I am still not entirely confident of it myself)
.. removing the need for -Wno-error=lto-type-mismatch, which is
not available in gcc 5.4.1 (debian stretch) while building the atmel-samd port.
@jepler We build with gcc 7.3.1 from https://developer.arm.com/open-source/gnu-toolchain/gnu-rm/downloads (7-2017-q4-major) or https://launchpad.net/~team-gcc-arm-embedded/+archive/ubuntu/ppa (if using Ubuntu). I'd recommend that you download that toolchain and put it in user space or use Ubuntu.
We need the -Wno-error=lto-type-mismatch to fix an issue when building frozen modules with gcc 7.3.1. This issue comes up when doing the BOARD=circuit_playground_express. You can see the iss...
This diagnostic does not appear in gcc 7.3.1 (see my comment in #686 re our build choices), probably due to better flow analysis in the later version of the compiler.
@raven canopy I'm setting this Ubuntu box for board work. I am installing esptool. will "pip install esptool" install it in Python 2, do I need to force it using "pip3 install esptool" or does it matter??
@humble mural my linux game is not what it used to be, so you may want to get someone else's answer. having said that, I think pip vs pip2/3 will depend on what you have setup. Also, fairly certain that esptool is python2 dependent, so pip2? let me check a couple things real quick...
the git hub page says "pip install esptool", only problem is that over the past 72 hours, I have read and seen so much, I'm a bit confused.
from the PyPI page: Since version 1.3, esptool supports both Python 2.7 and Python 3.4 or newer.
so looks like you can use either... Tony's guide has a few miles on it, which is what my knowledge base comes from mostly. 😄
You're not forcing it using pip3 install esptool, that's what your pip is called if you install Python3 unless you do aliases and such
Thanks @idle owl and @raven canopy
yah, np. sometimes I know a thing. Fighting with pip is one of those things.
It's a fresh install haven't had a time for any aliases yet.
yeah. for all of python's "ease of use"...it gets confusing quick in certain parts.
I would have to imagine the the Github page for the tool is the best source (no sarcasm).
one can hope. 😄
Thanks, I see that failure on travis-ci now. Oddly, I don't replicate the mp_qstr_const_pool problem here, with make -C ports/atmel-samd/ BOARD=circuitplayground_express.
Do you think there's any point in revising this pull request? If not, please feel free to close it up.
Do you think there's any point in opening a documentation pull request? I do not find these toolchain requirements listed in the docs, even after grepping for the URLs you cited above. (some of the other `ports...
had to install pip
pip install pip...wait. 😛
I'm moving over to #help-with-projects though
For instance, a revised patch might use the Linux kernel trick for checking whether a particular argument is accepted by the compiler or not, similar to
cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
> /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi ;)
...
CFLAGS += $(call cc-option,-mieee-fp)
This is fine in #circuitpython-dev, @humble mural. 😃 CircuitPython and Python related discussion, it works
ok
I agree we should list the toolchain requirements. That is an oversight: thanks for pointing that out. A PR to document that would be great, if you are willing, or we can just do it in a future PR of ours.
I submitted a gcc bug report for the bogus LTO mismatch warning. It is now fixed in gcc, but will not show up for a while: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81440.
You may also run into other issues with the older gcc, such as code size. Right now we have a few kbytes free ...
After a weekend in Orlando at a high school conference with over 5k kids, I'm beat. but I have to get at least a flash_id on a Feather Huzzah32
i'm out for a few... good luck @humble mural!
Thanks, in case I crash all you have a great evening. Peace
have a good one @raven canopy
pip required sudo to install the esptool.py thingy this afternoon. Runs fine without sudo until the very end, where it does not have write permissions into the /usr tree or somesuch.
Debian (amd64) did not seem to be able to compile CircuitPython 3.0.0 alpha-2 without the virtualbox/vagrant environment a few days ago, so I redid everything the way Tony describes. My suspicion is that it'd have worked in Ubuntu, or perhaps in Debian 9.x (I run Debian 8.x).
One of the scripts run maintains /etc/apt/sources.list and Debian did not know that command.
Also I had to solve a keyring problem whereby $ sudo apt-get update fails, after adding the extra repo.
This command failed in Debian:
$ sudo add-apt-repository ppa:team-gcc-arm-embedded/ppa
I did the add manually (used vim to edit /etc/apt/sources.list or the .d/sources.list file (I forget what's there).
That's when the keyring problem arises with apt-get update
Based on conversation in #686, improve the documentation surrounding build requirements and steps
Much simpler for me to abort and do the proper virtualbox/vagrant thing. That succeeds just fine. ;)
Thanks for the pointer to the upstream bug.
I've revised THIS pull request so that it only changes the declaration, and does NOT modify the compiler flags.
I botched this, will try again later when I can be bothered to try building first before PR'ing.
@idle owl @compact solstice @raven canopy I use pip3 install --user ... when I need to install something using pip. This does not require sudo and puts stuff in your home directory tree, so it doesn't mangle up your installation.
smart.
smart indeed.
@timber mango ppa's are for ubuntu, not plain debian. You could also install the toolchain in something like ~/bin from here: https://developer.arm.com/open-source/gnu-toolchain/gnu-rm/downloads
Download the GNU Embedded Toolchain for ARM, an open source suite of tools for C, C++ and Assembly programming for ARM Cortex-M and Cortex-R families.
trying to finalize the bday adafruit cart...why does the saleae have to cost so much? 😄 looking at their website though, there is the 'enthusiast' discount... 🤔
oh, and finally breaking down and getting a CPX....
https://blog.saleae.com/saleae-discounts/ I didn't know about that. They did raise the price - I got it from Adafruit at the old price last fall.
do you want the Logic 8 or Logic Pro 8?
yeah, i was browsing the old Logic 8 and 4, and couldn't understand the price difference. funny thing: all of the old models show as "out of stock" on the list page; product pages show "discontinued"
then there is the "extreme enthusiast discount": https://articles.saleae.com/how-to-create-content-for-saleae/
@raven canopy Just a couple of days ago I was looking at the Analog Discovery (idly - I don't need one), and found these two discussions: https://www.eevblog.com/forum/testgear/next-best-logic-analyzer-after-the-saleae-logic-pro/ https://www.bigmessowires.com/2015/01/07/saleae-pro-8-logic-analyzer-review/ From that, got the impression that the Saleae software is quite good compared with the other alternatives
the second link is a little old, but not sure if/how the situation has changed. The saleae has been very helpful for me, but every few weeks, not daily. I have a 100MHz scope too, and the Saleae was a lot more useful (easy timing measurements, triggering, etc.). But the Saleae can give some misleading waveforms because of the granularity of the sampling - at higher speeds I saw what looked like jitter and timing differences that weren't really present.
that second link may be a little old, but man that's a well written article! thanks @tulip sleet. I was also peeking at the BitScopes . A little more "value", but not as polished and the software probably isn't anywhere near Saleae quality. Then i have to factor in my use cases...which will be slim. maybe a post bday decision. 😄
You could celebrate it with Bdale Garbee!
New debug log: REPL Debug Gist 2
Here is an excerpt of the informational bits (better formatting here):
started this capture already at '>>>' (see first usb_rx_buf_tail == 70, with usb_rx_count == 64...difference of 6)
read_complete(_usb_d_cb_trans_done):: usb_rx_count: 0; pending_read: true **#<...
@tulip sleet
Adafruit CircuitPython 3.0.0-alpha.3-4-g4e3748d on 2018-03-20; Adafruit Trinket M0 with samd21e18
>>>
Built on a new Debian 8.10 installation without a VM environment.
Path is $HOME/dev/bin which is the top level 'bin' directory from the developer.arm.com download you pointed to.
Vagrantfile from the Guide followed otherwise, where possible, to get all prerequisites installed (using apt-get).
Never saw a single error -- so I don't know if all that was necessary.
I did have to add myself to the dialout group, and logout from a running X.org session (no restart of GDM was needed) to access /dev/ttyACM0 -- barebones Debian just installed today. ;)
$ mkdir unpack.d
$ cd unpack.d
$ bzcat ../gcc-arm-none-eabi-7-2017-q4-major-linux.tar.bz2 | tar -xvf -
# ~/dev does not pre-exist here:
$ mv gcc-arm-none-eabi-7-2017-q4-major ~/dev
$ rvim -n ~/.profile
# logout after editing ~/.profile to modify the $PATH to prepend ~/dev/bin to it.
$ echo $PATH
/home/nis/dev/bin:/home/nis/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
e.g.
$ cat -n ~/.profile | sed 22q | tail -4
19 # set PATH so it includes user's private bin if it exists
20 if [ -d "$HOME/bin" ] ; then
21 PATH="$HOME/dev/bin:$HOME/bin:$PATH"
22 fi
pre-existing test [ -d "$HOME/bin" ] retained from the distributed version of the file, somewhat against logic.
@timber mango the gcc-arm-none-eabi toolset can also just be installed to to /usr/bin by the package installer. It's a matter of choice. I find that simpler since it is already in my PATH.
Based on conversation in #686, improve the documentation surrounding build requirements and steps
While looking at LadyAda's new guide on a CP TV Be Gone I saw she used pwm to achieve a 38khz pulse train. So I tried to see what pwm (which I think is using a hardware timer inside the M0 chip) could do. I was able to generate upto 6mhz square waves from any pin I tried on a Trinket M0 and a Feather Express M0 using :
pwm = pulseio.PWMOut(board.A3, frequency=1000000, duty_cycle=2 ** 15, variable_frequency=True) (from above) The square waves look quite good upto about 2mhz and the jitter is very low! New projects are now possible!
@timber mango congrats - I also used the vagrant to see which prereqs I needed, but I was able to trim it back quite a bit because of what Ubuntu had preinstalled.
@long trail awesome! It does use a TC or TCC depending on the pin
@stuck elbow https://github.com/wez/atsamd21-rs
nice
@slender iron I'm liking the Adafruit MicroPython newsletter. Nicely done! 
@slender iron asf4 hid_generic driver does generic reports BUT IT CAN ONLY HAVE ONE INSTANCE 😠
i think I will spin my own with their low-level routines
mouse driver does its own reports, and the API is "make an X movement" or "make a Y movement", but not both at the same time. It splits them into separate reports. gah. who dealt this mess?
@tulip sleet bummer! thats why I like letting the python code construct the report
thanks @errant grail !
yeah, exactly. the lower-level api is fine - i'll just use that. ... also supposed to snow 8-12 inches tomorrow after noon . your friend who moved to Boston must wonder what's going on
@tulip sleet haha, I think hes back here this week but will be moving soon
I don't think we handle connect, disconnect and then reconnect well. (ASF4 USB code doesn't reset correctly as far as I know.) This is an artifact of it.
@sommersoft I think you are on the right trail! We're trying to rate limit incoming data by erroring on the callback with the new data but _usb_d_cb_trans_done ignores the result.
Perhaps changing this line to the below would fix it:
if (usb_rx_count < USB_RX_BUF_SIZE - 64) {
That way we'd only queue up a read when we have room for another packet.
@tannewt that might actually work. Initial thought is that it may force usb_read to clear the local buffer before triggering any further ep reads. Will likely have to change the if (!pending_read && usb_rx_count == (USB_RX_BUFF - 1)), unless we just wait on usb_cdc_background to call start_read. (On phone, by memory; otherwise I'd link to lines)
@solar whale The tarball offered for the eabi toolchain was a set of compiled binaries and libs -- was not in .deb format. I had to guess what to do with it - could not find any instructions.
Also: there are two other sets of this toolchain on my older system; one from Arduino and one from apt-get/dselect origin. The successful run occured on the new system I bought on Sunday and afaik it only has the downloaded tarball toolchain. /so_confused
@timber mango What you did should work fine. I alwasy have to search for the instructions to ad it to apt. I'll post a link when I find it - or @tulip sleet may have it at his fingertips. The nice thing about using apt is that is is easy to update.
The Arduino toolset is (or at least was) way behind and will not work.
@solar whale @timber mango is using Debian, not Ubuntu, so using the ppa with the latest toolchain with apt will no work. The ppa is Ubuntu-only.
If I can't use apt for some reason, I just unpack the tarball in my ~/bin directory and prepend gcc-arm-none-eabi-6-2017-q2-update/bin to my $PATH
I think I stopped using raw Debian around 2008 or earlier
Ah sorry @timber mango -- thanks for clarifying @tulip sleet I was a CentOS user but when I started working with MIcro and Circuit Python I went to Ubuntu just beacause it was the path (no pun intended) of least resitance.. Reistance is futile 😉
@solar whale I used CentOS for a while because it matched the servers we were using where I was working. But the desktop GUI always seemed like an afterthought. I got a netbook with Ubuntu and was really pleased and started using it at home (had been using unstable Debian for years at home before that).
I was dragged, kicking and screaming, to Ubuntu for a NASA project - but once I started using it, I actually liked it.
sometimes it's really annoying when they say "we've packaged it for Linux" and all you see is a ppa
@stuck elbow Agreed!
We used CentOS at work because some of the HW design tool (Xylinx) were only supported byt RedHat Enterprise or CentOS. That and some of the folks were just Ubuntu-phobic...
on the other hand, it used to be the same thing with RPMs a while back
sure was!
I gave up last time I tried to build CP on a Rasbperry Pi - I've got a 3 B+ arriving today - may be worth trying again..
Just for the experince 😉
fair enough
This won't take up much room in the message queue. ;)
If anyone is ever foolish enough to attempt the (one-way!) journey to the (2nd, heh) nearest star (Alpha Centauri, or whatever the current favorite is) .. they're going to need reliable computation, and often quite a bit of ad hockery.
After all, they're all going to die, and they're not going down without a fight.
This is where RPi + CircuitPython comes in. ;)
Alternative (and I'm offtopic in this) better choices (in no particular order): Antarctica, bottom of the sea, the Moon, and low-Earth (or near-Earth) orbits. Notice Mars is not on the list of hostile, but possibly sane places to send people to visit, in person. / And I'm back quiet.
don't forget about the hollow earth and the underside of flat earth
anyone want to answer https://forums.adafruit.com/viewtopic.php?f=60&t=132843 ?
I don't think we handle connect, disconnect and then reconnect well. (ASF4 USB code doesn't reset correctly as far as I know.) This is an artifact of it.
I haven't dug all the way back to the ASF level on this yet. But, in cdc_enabled, the first check is if variable mp_cdc_enabled == true and returns true. Only if mp_cdc_enabled == false does it actually call back to the ASF level to test the conne...
excellent answer on that forum post @cunning crypt!
Thanks!
CircuitPython is great and all, but they'd have to do a lot of compromising with what they want to do
i mostly agree, because of the wifi/nRF aspects. the PWM & RTC are totally doable, as long as they're not wanting Ludicrous Speed time updates from the MCU. (EDIT: there, they're, their...its simple)
Yeah. PWM and RTC are doable.
Thanks @cunning crypt !
@cunning crypt Yeah looks great! Thanks!
I try to be useful sometimes.
@stuck elbow rofl underside of flat Earth!
if you get to the underside then you will fall ... somewhere (or nowhere, I guess)
did you know that in flat-earth theory, the oceans don't fall off the edges because they're held back by ice ?!?
At least they posited a cause. That's encouraging!
"it's turtles all the way down"
RIP, SWH!
dropbear and rsync (from TinyCore sessions on two machines here, tonight) are doing a fine job transferring 54 GB across a CAT-5 crossover cable (no hub between the NICs). Don't need to enable ssh in the usual operating system; instead, dual-booted both into TinyCore (which is rather capable and very easy to install on any existing Linux box).
dropbear stands in as a replacement (and tiny) ssh server -- also provides a matching client.
didn't know about tinycore - i'll keep that in mind for something
Interview with Robert Shingledecker (project lead for TinyCore):
https://distrowatch.com/weekly.php?issue=20090323#feature
Skip the acrimony by scrolling down that page to:
Tiny Core's genesis was from a meeting at Linux World 2005, with myself, Kent Porter, and Chris Livesay.
In the interview, R Shingledecker states that he built on Rob Landley's work.
http://landley.net/
Firmware Linux: http://landley.net/aboriginal/old/
Aboriginal Linux: http://landley.net/aboriginal/
Firmware Linux would have been the one Shingledecker examined (and modified).
transcript of offtopic linux stuff.
Anyone else run into 2.2.4 not working on CPX?
I flashed it, the serial console stopped printing anything, and then it wouldn't mount at all, showed up as unreadable. So I went through the flash eraser, back to 2.2.3, everything worked. Update to 2.2.4, won't mount. I tried downloading a new copy of 2.2.4, I tried 3 different CPXs, tried rebooting my computer.
@idle owl I have a CPX next to me, want me to test?
it took a few tries to get it back, if you're ok with potentially borking it, go for it. It could also be me
OoF, that's a CP not a CPX. I left mine in a lab today, sorry 😦
oh - lol. this is the one that was toasted a bit too much
oops 😃
I'm not sure if it works, don't remember when I got it but I gave it a home
@idle owl just put 2.2.4 on a CPX. seems to be running fine. anything specific to try?
Not really.... I thought it worked fine for me a bunch of times before which is what really confused me.
I don't know. Must be something on my end.
still misbehaving though?
I haven't tried it again. But I managed to repro it on 3 CPXs before concluding it wasn't coincidence.
I had a weird bootloader with WebUSB enabled on one... who knew on the other, so I blamed weird stuff before I opened a brand new one, updated it to 2.2.4 and broke it outright.
Well "broke"
what machine / os you working on?
tried a different machine?
No, I didn't. I was in the middle of something else
getting it to repeat on 3 CPX's means something. next easiest variable to try is a different machine.
Ok I'll give it a try. I don't get why this would happen suddenly. I'm in the middle of fighting with Git at the moment.
NeoPixel/Dotstar are finished and mirrored. UART and CPU temp are waiting final approval.
That went badly. I had to reclone. I'm done for the night.
been there. git battles...rough.
will be there again, soon i'm sure. i've got like 3 or 4 clones on this system. 😄
@idle owl Just reloaded 2.2.4 on a CPX -- no issues.
Hi i'm searching for example code for my neopixel strip 30 led for a fading or crossfading effect ? I tried the Neopixel Uberguide demo, works great! thx!
Trying to get started building an automated LED controller (outputting PWM to independent LED drivers using a PCA9685), using the Raspberry Pi Zero W. I like the idea of having it connect via Wifi to a web based app. I want to be able to have each channel simulate multiple sunrises and sunsets each day. Can somebody point me in the right direction? I currently have one on Arduino Uno, but it is maxed on memory and outdated.
@somber rock Hello there!
Hello Andon, thanks for taking the time to respond!
Tannewt actually mentioned your post, I just happened to be the on that answered.
Have you used Linux in any capacity before?
I did about 15 years ago for a few months, so consider my answer no.
Things have changed a bit since then!
Well, I have time and money, so I'm ready to roll.
Both are good things to have when you have hobbies like this.
I am not particularly a Raspberry Pi expert - I believe the person that fits that bill would be @drowsy geyser
I am a pro level hobbyist then..
But I can run you through some of the basic bits and bobs.
How well do you know Python?
That sounds great. I started studying it about a month ago.
There's a handy guide for running the 16-channel PWM driver, which you may want to bookmark: https://learn.adafruit.com/adafruit-16-channel-servo-driver-with-raspberry-pi/overview
I'm trying to find a good "Starting Raspberry Pi" tutorial
It's been a while since I've used one
That's a really good reference.
Adafruit is really good with their guides
I agree, been a customer since 2006.
I can't believe how cheap the Pi zero's are. I can't buy the components on the board as cheap as they sell it for.
Pi Zero W I mean
Zero W and Zero are dirt cheap.
It's amazing.
Heck, the Zero Ws were $5 at MicroCenter for a while.
Dang. I guess if you make them a million at a time they get cheap.
Yep. Even 100-250 at a time gets significantly cheaper.
On a side note - off the record, If I eventually develop something that works well, could I sell this embedded in a product legally (with software open source of course), or is that not ok?
Maybe?
I'm not 100% sure what you mean.
You can re-sell the Raspberry Pi - companies do it in a lot of kits and the like
Just wondering down the road, if I can use this to make a marketable/profitable product.
Getting a hold of sufficient quantities of Pi Zeros is not the easiest thing, though.
I ran this by on the arduino forums a while back, and was frowned upon because I wanted to try and make money with a hobby project.
It might be better to sell everything else and have the user supply the Pi. They're not hard to get individually
You're talking to someone who, well, is in the complete opposite camp from what the others you've talked to have done.
One reason they are dirt cheap is the $5 is the wholesale cost: no markup was allowed initially.
I make custom arduino-compatible things, and sell them. There's no issue with making money with hobby projects. That's effectively why Tindie exists.
Yeah, I just saw that MicroCenter sells 1 for $3.14/ea and 6 for 19.99/ea
$3.14 is a Pi Day loss leader. Usually $5 for 1.
I guess it would be hard to get 100 of them, but Pi 3's could fit the bill I suppose.
I figured it was too good to be true (Zero W), has everything I want except availability.
@somber rock Having the end-user supply the pi can have multiple benefits. You don't have to worry about availability, or the cost of including them, and the user can supply a pi they already have. And if they don't have one, Zeros are cheap.
Side note: Don't try to say "Supply the Pi" too fast. Almost a tongue twister there
Arduino doesn't care if you use their products embedded. They even make industrial versions of Arduino. The grumbling in the forums is not official policy by any means.
👌
Arduino is open source and that liscence allows for commerical use, if I remember correctly.
The only downside is convincing potential customers that they have to buy something from someone else to be able to get my item to even function. People like the convenience of one stop shopping.
That is true.
True, this new design will be replacing a legacy controller that is run with Arduino.
Just another point - Pi Zero/W are sold without headers so the end user has to install them.
ah - did not know there was one. Thanks
It's really new
I suppose if I write software for the Zero W, and I can't find a source, I can just use Pi 3's? Of course this is months down the road, and not really even worth considering right now. I need to get a Pi to reference a web based app via wifi in the meantime....
and sort of flew under the radar because it's... honestly? Not that special.
You can take the SD card (With OS, etc on it) out of a Pi3 and put it in a Pi Zero and vice versa
The Pi 3 uses a different processor and has more power, but generally speaking, what runs on one will run on the other.
That's awesome, yet unheard of despite the elementary logic of it.
The Pi Foundation is very good.
I'll build a prototype with a Pi3 then since appears to be a little more friendly.
Their version of the Debian - Aptly called Raspbian - Will run on all of the Raspberry Pis
If I needed help with particular aspects of programming, is this the best place or is there somewhere better?
This CircuitPython channel is intended for discussion of CircuitPython hardware/software
The best place would be in #general-tech or in #help-with-projects
Ok, thanks for that info.
I'll get my hands on some hardware and pop back up over there.
I look forward to it
This file prevents Mac OSx from cluttering the filesystem with index files.
@somber rock I was looking at Adafruit stuff just now, and noticed this: https://www.adafruit.com/product/3416
It's the same 16-channel driver, just pined out for a Pi.
there is also an independent breakout board
and a feather shield
two, in fact, one for servos and one for motors
Yep, but TechnoSteve was looking to use it with the Pi.
I see, sorry, didn't see the whole conversation
Evidently Mu requires you to have some space on the device... it crashed with a no space left on device error in the terminal trying to use Trinket.
@idle owl it shouldn't crash - ntoll would probably appreciate an issue
ok
if it is mu beta 15 then it may be trying to save some files. There is a know issue that will be fixed in next release.
For m it was creating a sounds and images older and putting in a few files!
I reported it to ntoll and he confirmed and fixed it 😉
Oh ok
is there a new release?
I'm so bloody glad you told me that, oi, I really genuinely thought I didn't remember those getting copied there earlier.
no new release yet
ok
I was sure I had been hacked!
I thought, oh right, images and sounds, I must have done that... when.... did I do that....
especiially when I saw alien.png
Oh right!
I was thinking I had copied it from someone else's test code
to test something for someone
and forgotten
After deleting it - reformatting and it coming back, I reported it!
It didn't even occur to me. I rarely use Mu, usually only for screenshots of REPL with code, so I didn't put it together
i just thought it was a cute easter egg
that's the alien from Pygame Zero
@stuck elbow yes it is - for some reason mu decided everyone needed it.
it's probably related to the recent support for pygame zero that was added to it
yes and a subtle bug the ntoll found that caused mu to save it to the system - it did not show up until the second startup if I recall correctly. It was a good bug!
good as in hard to find.
@solar whale, the King of Weird Bugs.
I try 😉
👑
🐞
@timber mango don't open the .uf2, that's a firmware file.
these are some handy steps to follow once you have that downloaded
It's for a trinket M0
^ check this quickstart
@timber mango both of @prime flower's links will get you where you need to go. There is an ongoing effort to combine and unitize most of the learn guides, so here is another one that is considered the "jumping off point". And...Welcome to CircuitPython!! 
https://learn.adafruit.com/welcome-to-circuitpython
Thanks
we're here to help if you get stuck anywhere
okay i have the right verison
@timber mango next step... https://learn.adafruit.com/welcome-to-circuitpython/installing-circuitpython
yay!
yay!
got it working?
time to make to code 
@timber mango the double press on the reset to go into bootloader can be a little tricky. it's like that. sounds like you got it though.
NOTE TO SELF: revisit the nRF since the new version turns off the UARTtoUSB chip.
GOING FURTHER: will this drive a much wider update for all things USB?
i'm guessing that there won't be any real way for us to decipher between old feather52 and new feather52 (52832 versions)... hmmm.
and, now they're out of stock so i can't drop one in the cart.
@raven canopy subscribe, they may not have been put in stock
done! 😄
Unfortunately, changing that line didn't work. 😞 Also disabled all of the 'in function' calls to start_read to see if letting usb_bytes_available would just pick up the additional transfers...nope. I finally put in some variables to extract the function args (read_complete(return code), etc). Nothing is showing any issues just yet. So it may be deeper in the endpoint setup after all. Just gotta keep pushing...
Is the esp32 feather supported? I've seen some conflicting information
Willing to try building it myself, just curious
@drowsy dagger esp32 is not supported in CircuitPython. But, there is support in MicroPython I believe. grabbing a link
doesn't seem to be in the documentation yet, but there might be some threads on the forum with status/info. http://www.micropython.org/
cheers
found some docs here https://github.com/micropython/micropython/blob/master/ports/esp32/README.md
np! also, went and checked the forum. they have a sub-forum for the esp32: https://forum.micropython.org/viewforum.php?f=18
esp32 is planned for CircuitPython. Maybe in the next major revision after 3.x (current dev). No ETA though.
So pardon my ignorance, but the main advantage of CP is that you are trying to target ports for popular adafruit boards, and have cleaner parity with cpython modules?
Is that the main thrust of the effort? Or is there something more fundamental I'm missing
I'm new to this, so just trying to understand the differences better... not trying to cast stones 😃
"We don't use gitter anymore" -- the last message on
https://gitter.im/adafruit/circuitpython on February 18
@tannewt there's also a reference in CONTRIBUTING.md to your personal handle on gitter. Should I offer a PR to delete that too, or should I leave it?
no pardon necessary, and no perceived stones being casted. I could attempt an accurate comparison, but there are people who could explain it better. Scott (@ tannewt; project lead) recently did an interview that has some good discussion on the subject: https://theamphour.com/383-an-interview-with-scott-shawcroft/
so I'm looking at https://github.com/adafruit/circuitpython/issues/689 and .. where is the initial filesystem actually built? Some grepping in circuitpython.git didn't find it for me. (I mostly looked for files named main.py...)
This file prevents Mac OSx from cluttering the filesystem with index files.
https://apple.stackexchange.com/questions/92784/preventing-spotlight-from-indexing-files-folders?utm_medium=organic&u...
@raven canopy thanks I'll check it out!
yw. also, here is a "shorter" version: https://github.com/adafruit/circuitpython#differences-from-micropython
@onyx hinge it's all built from the Makefile in each port's top directory. There are also a few py scripts that gather/package things.
Mind rephrasing the Contributing doc for Discord? Thanks!
@raven canopy OK, I'm familiar with running 'make' in ports/atmel-samd, but where is it pulling the initial content (like "main.py") from?
There is no initial content. The board has an empty boot.txt with some info in it and that's it.
@idle owl ah so when my board arrived with content on it, that was due to some other step at adafruit other than uploading the .uf2 or whatever process they follow
Some of the boards ship with content, and updating doesn't erase this content. However, a fresh install on an empty board will have no content.
Yep!
I had noticed that upading the circuitpython with the uf2 method didn't cheese my main.py so that all makes more sense now!
The boards ship with demo content, which is usually available for download somewhere.
😃
Be aware, that sometimes it will erase the board, so always backup. But most of the time, you can update and it doesn't remove any of the files or code.
.. which makes me worry what my testing procedure for a issue 689 patch would be
Oh
Ok so we have a flash eraser, that works on the Express boards (so the ones with SPI flash). You can run that to completely erase the board. Then when you load a .uf2 on it, it will be a clean flash of CircuitPython
My board happens to be a Trinket M0
thanks for picking up my slack @idle owl. had to step away for a sec. 😄
@onyx hinge This will erase the entire board, so backup the demo content if you want to keep it easy to get to.
@tannewt I removed the mention in Contributing too
This is for when your board gets corrupted but for what you're doing would start you with a clean board.
Basically it writes the whole thing with 0s, I believe.
Hmm, it works a little differently than the one for the Express boards. Trinket M0 is not an express board.
So hopefully it does what I am saying it does, and will work for you 😄
Because the Express board flash eraser doesn't dump it back into the bootloader automatically, and I'm not sure if, since the non-express version does put it back into the bootloader, if MacOS will have time to dump those files on there before CircuitPython is loaded. I believe flashing CPy will nuke anything Mac adds, but I'm not certain.
@idle owl thanks that helps. And I found in ports/atmel-samd/supervisor/filesystem.c where it potentially calls f_mkfs
It's late in the local time so I think I'll call it a day instead of risking the precious program in my circuitpython board while tired. Thanks for your help and time @idle owl and @raven canopy !
You're welcome @onyx hinge! Have a good night!
you're welcome! night!
I wonder how this will interact with the process done at adafruit that loads the initial content onto the flash filesystem; is putting this circuitpython the right thing?
I have a compile-tested patch, but haven't run it on a device.
diff --git a/ports/atmel-samd/supervisor/filesystem.c b/ports/atmel-samd/supervisor/filesystem.c
index 45dc5667b..8819e45cb 100644
--- a/ports/atmel-samd/supervisor/filesystem.c
+++ b/ports/atmel-samd/supervisor/filesystem.c
@@ -66,6 +66,11 @@ void ...
@drowsy dagger FYI - Mircopython is supported for the ESP32: precompiled images are here: https://micropython.org/download/#esp32 Note, these do not yet support BLE.
Since putting the initial content on the board requires that the FS be present, this section of the code should not get run after the demo scripts are loaded. It will only get run if the FS is being recreated. If the demo code were there, it would get wiped anyway.
Just a few thoughts as to adding this to all builds. I am not convinced it is the right thing to do. MacCOS users are a subset of the users. On the smaller system, Trinket_m0, Gemma_m0 will this take a "node" out of service res...
If this is implemented, would it also be necessary to implement it in the /lib folder as well?
I think my patch above is probably missing a call to flash_flush(), and/o the old call should be moved below the file creation.
I don't actually have a MacOS machine to test, I just picked up this issue because it "looked easy" and was tagged accordingly :wink:
According to 'df' running on my Linux machine, creating a zero-byte file in the root of the filesystem doesn't consume any blocks of storage. However, it does take one away from the total number of files that can be created; the...
.. I noticed this in the README of the trinket m0's default contents from adafruit:
The Trinket has a very tiny disk drive so we have disabled Mac OS X indexing
which could take up that valuable space.
So *please* do not remove the empty .fseventsd/no_log, .metadata_never_index
or .Trashes files!
so at adafruit they do think this is a useful step to take, for whatever that's worth.
Yes, they did this for the Trinket M0 when the files are loaded. It is not "built into" CP for the trinket M0. My point was that if something is going to be built in, does all of the above need to be added in order to be effective. ( .fseventsd/no_log, .metadata_never_index
or .Trashes files )
How bad is the impact if these are not added? I don't often use MacOS for accessing these boards.
I do have a MacOS system and a Linux system so I can test the impacts on those, but I don't have a Windows system. Does any of this cause any issues for Windows users and are there any similar Windows file system quirks to me covered as well.
.. the price of this appears to be about 112 bytes of flash and 12
bytes of RAM, according to the stats printed during the build.
It also uses up 4 directory entries (out of 128), but does not reduce
the number of blocks usable for storing file contents.
These are the same items noted in the Adafruit README for Trinket M0
as preventing MacOS indexing.
Closes: #689
Do we want to implement this for all atmel-samd boards, or just the "non-express" boards. Is there any reason MacOS users would want file indexing enabled on express boards?
anyone want to answer https://forums.adafruit.com/viewtopic.php?f=60&t=132919 ?
I think this is worth it because non-Mac users can always delete the file to recover the entries. Its way more difficult for a Mac user to delete all the extra files made the very first time its plugged in.
@jepler I don't think you need to actually test with Mac. I use it, added that file and it prevented the indexing.
When I'm testing this code I usually force the if statement to be true. (Back up your files first!)
If a user wants the indexing they can always delete the file.
I would do it on Express versions as well because this also reduces file system churn. We currently don't do any wear leveling on the flash so stopping metadata writes will prolong its life.
@onyx hinge thanks for the PRs!
What did it do? Do you have a copy of the changes? I expected it to work. :-)
Someone is on a commit roll....
yeah, morning is time to go through emails
skimming the new hackspace now though...
Sooo, I'm trying to help @idle owl with her CircuitPython I2C guide and I can't load her program onto a Trinket M0. I get an "insufficient space" message. My Trinket is a bare system running 3.0 Alpha 3 from one build ago. There's just no space for the program. Is there a way to create a stripped firmware so there will be more space in the flash?
are you on mac?
Winderz 10
hrm, I think it might be a bug
Oh? I assumed it was just a lack of knowledge on my part!
are you trying to load a single file?
I ran into this yesterday with my samd51 oven board when trying to copy the bundle over
Yes, drag and copy one 60k python file. The OS is telling me there's only 47k available on the device.
that seems too big to me
Yes, just checked. Windows says the file is 60 kb.
Ok, I'll read the file and make sure it makes sense.
Thanks!
Oh dear....
The actual project I did with a Trinket M0 used the analog comparator modules to directly read 1.5V-referenced signals with no external components needed (a super neat trick, analog modules in modern chips are amazing!). I had to do it in C/Arduino instead of in CircuitPython, because there doesn't seem to be a nice interface to this facility. And also because it essentially the slave side of a unidirectional SPI, I'm not sure the speed would have been adequate.
Anyway, long story short, am I overlooking an analog comparator interface in CircuitPython? If not, does anybody have feelings about how one would look? It seems like you would want a few different classes, single-ended comparator to reference voltage, window comparator to two reference voltages, and analog comparator as differential decoder. All are possible with the T M0's analog comparator block.
@onyx hinge I've never used it so I'm not sure how to guide you. Adding a new built in module for it would be good though
@tulip sleet did you get your metro today?
What's the usual routine for obtaining the very latest code for Circuit Python, prior to a rebuild? Are there makefile targets? git commands?
git pull master
my adafruit remote is called adafruit so I usually do git pull adafruit/master
I don't know what a remote is in this context.
@timber mango It looks like adafruit has a guide about git, it may help you get started https://learn.adafruit.com/an-introduction-to-collaborating-with-version-control/overview
This:
git submodule update --init --recursive
is in the Vagrantfile. Seemed to be needed after a git clone of the circuitpython repository.
Does that get updated with the git pull master ?
I use git every day. ;)
@timber mango 😉 me too
short answer, no, "git pull" won't change any file content within submodules, at least by default. A "git submodule update" is advised if the "pull" has changes to the submodules.
(I still haven't personally achieved a level of comfort with git submodules that lets me confidently explain them... 🙁 )
@timber mango remote = a repository on a git server somewhere
All I need to know (I think I parsed your last, okay) is if it's typically required to worry about the submodule stuff -- it all looks like its from outside sources irrelevant to CircuitPython development.
@timber mango You DO need to have the submodules there, at least to build some of the things. But I suspect that most of the time they don't need care and feeding every day. You might put it in your list of steps to try when something isn't working, because doing a git submodule update --init --recursive shouldn't hurt anything,
@tidal kiln so he's not pulling from the canonical source tree that I am pulling from. But by virtue of changing his current directory to the code he wants to update, he doesn't get an out and has tp spell it out, because he frequently pulls from multiple places, and therefore must be more explicit?
yes (i think)
you can have more than one remote, so you would need to name them to disquish them (for when you push/pull commits)
@onyx hinge This sounds like enough to go on. I'll capture what all three of you has said, to disk in my noteook thingie. ;)
My goal is simple: If I test something for a developer, they'll be able to trust I'm building on the correct source tree, including all updates.
if you just have one remote, and you just use the default name, then generally don't need to specify it
@tidal kiln a qualfied yes is fine there -- I think I made small errors in concept and statement of them. ;) Haha. More simply: I generally only push or pull from my own one repository, or clone from a public one.
I think makefile targets would be easier. Maybe they're not so portable across multiple operating systems.
'make source-update' or similar would work for me. ;)
@timber mango when I just want to keep up to date with the master, I just do a git pull git submodule update --init --recursive works for me
Thanks @solar whale that sounds succinct. I'm going to see if I can construct a simple Makefile for common tasks. There's a vacuum there, or I'm not understanding something. ;)
@drowsy geyser Did you try making a .mpy of that large .py file?? Still may run into memory allocation issues once you get it on the trinket.
I actually have no idea how to convert .py to .mpy....
can you build CP 3.0 on your system?
Yup.
In fact, I have a fresh build to flash on all my boards... Thanks for the reminder!
/path/to/circuitpython_master/mpy-cross/mpy-cross script.py
this will convert script.py to script.mpy
if you do it in master it will be 3.0
NP
Very simple Makefile to implement @solar whale 's procedure. TESTED on another repo (not circuitpython). Behaves as expected. 'all' may not be the best choice in target names.
I gotta rename that -- saves as a binary!
I'm happy to just type it in 😉 make scares me....
make is sweet. I used it to concatenate files on my web server (serving hard documents stored as files).
Will edit this comment in a moment.
It is a great tool, but a slippery slope to very complex configurations ... If you start suggesting using autoconf and automake, I'm outtta here... 😉
I don't know how to do any of that. I have the (now very old) Make book from O'Reilly.
another project I use (RTEMS - real-time OS) relies heavily on a very complex build system that I cringe at every time I have to use it)
all:
@git pull
@git submodule update --init --recursive
That's the entire Makefile I just posted. ;)
I can handle that! 😉 thaks for the suggestion.
NP. I think of this kind of Makefile as an executable notebook of commonly typed commands. 'make all' does what it looks like it does. Or I can just look at the Makefile and type the commands it lists for the 'all' target, one by one.
Agreed - I use make a lot as well and I was just teasing. I have also seen it get so it is very hard to follow. Seems counterproductive if the mkaefile is more complex than the code it is building!
I think many programmers are found to be letting their inner Baroque run wild, at times. ;)
example: sendmail (hehe)
I need a quick microphone check. I'm in 'General' voice chat room.
just a sec - no mic on taht machine!
@tannewt, by changing the line to your suggested...it didn't do anything different. still 3 calls to read_complete but only printed out 128 characters.
When I was disabling 'in function' calls to start_read, I was trying to see if any of them were stepping on each other, in addition to seeing if usb_bytes_available would keep the wheel rolling. Oddly, it reduced the instances of read_complete from 3 to 2, but still produced the same 128 characters.
Baffling is the only word I ca...
@tulip sleet am I correct in remembering that you have a Beagle USB analyzer? At this point in my debugging, I think the only pieces I can't verify are what is actually happening with the control and endpoint transfers...
speaking of editor trouble, I need a way to teach vim not to write its "swap" files on the CIRCUITPY volume...
@humble mural @idle owl sounds like an argument could be made to improve Mu's default behavior. Opening main.py would almost always be what you want.. (I'm not a Mu user, mind you)
Well it would need to be updated to read the files in the same order as CircuitPython does, as CP will read multiple files, but only one at a time in a certain order.
But yes, it's worth suggesting.
@onyx hinge Frankly, not a big issue imo. If you just follow the policy of keeping only one as a naming convention you’re good
I’ve been meaning to ask about that. What does the CPX doe with a .txt file???
It's left in there in case someone new to everything doesn't have a code editor that understands .py files
@onyx hinge the -n switch to vim does .. what?
@timber mango that’s a tough one
@humble mural Did that answer your question or did you need something more specific?
About the .txt
@idle owl that makes sense, thanks. I’m just not sure how it would get processed. So you plug in the CPX via the USB, you don’t have Python or Mu installed, it wants to open the default .txt editor
And it might not want to open a .py file
What I meant was, it works for me and has for more than a decade. I used to find the swap files annoying, so I always (always) use the -n switch with vim.
Can't figure out how that's not doing what it should do, if it's behavior can be described as:
writes its "swap" files on the CIRCUITPY volume
so you could create code.txt, put CircuitPython code in it, and the board will run it.
😃
Amazon Kindle treats .txt as .html for many purposes. ;)
No, it's all good! That looks awesome!
That's Thomas' helmet right? I can never remember which one is Thomas and which one is Manuel's...
Yes, with the Bluetooth controls
and yes. looks great! ✨
Thanks. The kids want to add one of the CP boards to add sensors and a small display to show the data from the sensors. We’ll figure it out
I don't understand this daft punk business.
I don’t either. But 3D printed helmets with neopixles, Bluetooth and CP board to control sensors is very cool
@timber mango at least you knew it was Daft Punk, I call d it Daf punk
I don't think I could hide my disdain in a classroom setting. ;) There'd have to be an implementation that (by process n, which is not described in the litetrature) .. somehow gained my interest (or respect). ;)
Fibreglas helmet for pilot augmentation of a vehicle, that might do it. ;)
@timber mango I’m on my phone and I don’t know how to give you a double thumbs up. Consider it given!
;) Yeah SKR is in a class by himself. He's still doing stuff like this, plus or minus the QRM. ;)
I’m going for a nap, bbl.
I'm moving on to the usb_write/mp_hal_stdout side. I'm getting more and more convinced we're chasing a red herring on the read side.
Just spent the last 30 minutes stepping in/over read_completes while pasting and watching the callstack. This seems to be a little more accurate in Atmel Studio than printing out vars and automatically continuing execution.
So... I built for my M4, loaded the uf2, and no CIRCUITPY.
I did a pull right before it, submodule update etc.
@slender iron Is CP not ready for the most recent board? Or do I need to troubleshoot
the green one?
Yah
you can help me test 😃
Sounds good!
let me push my changes
do I need to figure out checking out a specific branch or are you pushing to master
it'll be to a branch of mine
Ok, I'll need help getting that figured out again. I've done it before but only once or twice.
k, np
I have an old clone of yours, should I start fresh
do you have my remote?
(git remote -v)
oh on my main circuitpython clone?
ok
kattni git@github.com:kattni/circuitpython.git (push)
upstream git@github.com:adafruit/circuitpython.git (fetch)
upstream git@github.com:adafruit/circuitpython.git (push)```
is my remote -v
kk, git remote add tannewt <my github url>
without the tree/latest_m4 on it I assume?
yah I did that
k then git fetch tannewt
kattni git@github.com:kattni/circuitpython.git (push)
tannewt git@github.com:tannewt/circuitpython.git (fetch)
tannewt git@github.com:tannewt/circuitpython.git (push)
upstream git@github.com:adafruit/circuitpython.git (fetch)
upstream git@github.com:adafruit/circuitpython.git (push)
ooh fancy
then you can checkout git checkout tannewt/latest_m4
oh neat
this flash chip hates me
yeah
if you don't want to be in "detached head state" you can create your own local branch git checkout -b my_latest_m4
(fyi its still not working for me)
I got overly excited and tried to do 3 things at once and now it's not happy...
whats it doing?
Purple LED, screen crash/disconnected, lib folder copy hung.
and no CIRCUITPY anymore on reset.
that sounds like a crash
Let me try that over again one step at a time.
👍
Ooohh..... goes to bootloader, copy firmware.uf2, goes to purple LED.
no CIRCUITPY.
Woops.
can you hook up the debugger?
Yep.
I need to install everything, haven't run it on this machine yet.
Download it from Segger's site?
ya
ok
@idle owl you want a link to the guide? i have it bookmarked...
now mac is ignoring my device....
ok downloaded.
Are you using command line or Ozone? I had Ozone last time. This is sort of coming back to me
command line
ok then follow the guide @raven canopy mentioned? Or do you have steps for me to do
the guide is good still I think
@raven canopy link would be great 😄
still brew install open-ocd?
Did that.
nah, you have jlink instead
you'll need to run gdb
my guess is that I'm clocking the spi flash too fast
so load with gdb, run and then see if you can get to purple neopixel
with this? arm-none-eabi-gdb-py build-metro_m4-express/firmware.elf ?
sorry, I don't remember loading with gdb.
yup!
in a different window or in the jlink window?
different one
ok thought so
ok I have a gdb prompt
k, tar ext :2331 to connect, then load, mon reset and continue
localhost: unknown host
:2331: No such file or directory.```
and jlink is running?
yes Connecting to J-Link... J-Link is connected. Firmware: J-Link V10 compiled Mar 2 2018 17:07:17 Hardware: V10.10 S/N: 50112632 Feature(s): GDB Checking target voltage... Target voltage: 3.30 V Listening on TCP/IP port 2331 Connecting to target...Connected to target Waiting for GDB connection...
weird!
😄
on mac?
yes
huh
GNU gdb (GNU Tools for Arm Embedded Processors 7-2017-q4-major) 8.0.50.20171128-git
is that right?
I don't know, guessing here.
thats what I'm using
I've never seen a cannot find localhost error
interesting.
do you use a proxy?
no, haven't ever even installed it on this machine
I have a network filter that I just stopped
did not resolve the issue.
Unless there's something installed in the network hardware I don't know about, checking
nope
I have no idea. it didn't look like a gdb problem
Troubleshooting.
its working for me now that I removed the saleae clips 🙄
It might be a little touchy.
Purple LED.
The SPI flash code now does a better job of handling random start states. The reset is needed to reset any status register protection bits that can wreak havok on the subsequent status writes.
weird!
mines working just fine but it could be a filesystem issue
any flashes happen before the purple led?
There's no audioio in the Gemma 2.2.4 build?
I think its express only
D13 flashes a bunch, then I get one red flash on the NeoPixel and then it goes purple
So you can't use rtttl on Gemma then. Correct?
not sure, I think brent added pwm tone support to it
I wouldn't expect D13 to flash
I wonder if the bootloader is broken
I was loading via gdb
maybe thats the test code still