#circuitpython-dev

1 messages ยท Page 214 of 1

tidal kiln
#

oof. that receive does a lot.

solar whale
#

teh first LSM CS is "normal" for the default SPI setting - but not for the LSM -- the second is flagged as bad by the salea , but it actually works for the LSM

main meteor
#

That's some good sleuthing.

solar whale
#

here I switched the SALEA to match the LSM , but I note that the CS is going low before the clock polarity switches for the first LSM transaction.

#

@main meteor this has been a puzzling adventure -- I think it is starting to make some sense.

#

@idle owl @raven canopy and all involved. It really is nice having the examples now part of the "Bundle" One stop shopping! It makes it so much easier to go grab the example. Thank you for implementing that!

tidal kiln
#

@solar whale i wonder if it's something with spidev? it doesn't actually change SCK until output is run?

solar whale
#

sounds suspicious ...

tidal kiln
#

everything higher level seems in order

#

on the Feather, maybe that takes effect right away - so SCK is changed before the next line that sets CS

#

but on the Pi, spidev isn't doing that....maybe?

#

it just buffers the config changes until a write

solar whale
#

@tidal kiln interesting -- that would explain why it works on the M4 and not on RPi. Not sure if the root cause it the handling of SCK or CS but they are not independent!

#

I have to go AFK for awhile back later -- Thanks for digging into this. I learned a lot today ๐Ÿ˜ƒ

tidal kiln
#

didn't happen to scope the feather test?

solar whale
#

no - I will try it later or tomorrow. It' will be good to compare.

tidal kiln
#

awesome. ok. thanks for all the help also. later.

main meteor
#

Fixed a SCSI bug like that. The controller would put the data out, assert strobe, take the data away, and wait for ack.

#

Worked with some targets but not with others. Switching the last two steps fixed it.

idle owl
#

@slender iron I have to remove the shared.py with shared.I2C_BUS from the Adafruit_CircuitPython_FeatherWing library to get Sphinx to build to put it on PyPI. Otherwise it fails hard. For some reason it's unable to figure out board.SCL and board.SDA. I'm letting you know because I know that was something you wrote into it. I initialised it separately in each file instead and Sphinx builds without errors (which means something changed because last time api.rst wouldn't populate, so this is good).

manic glacierBOT
slender iron
#

@idle owl did you try adding a board automock?

idle owl
#

no, but I thought we were trying to avoid any automocks. I'll try it.

#

that seemed to get it past that part. But now it' failing on No module named 'machine' .. there isn't anything referencing machine...

slender iron
#

blinka may

idle owl
#
autodoc: failed to import module 'adafruit_featherwing.motor_featherwing'; the following exception was raised:
No module named 'machine'```
slender iron
#

we should switch from a shared I2C to using board.I2C

idle owl
#

does that exist on Pi?

#

or is that something Blinka could make happen

slender iron
#

blinka uses machine if it thinks its on micropython

manic glacierBOT
idle owl
#

I mean does board.I2C work on Pi etc. Because the plan is for this code to work on Pi as well.

manic glacierBOT
slender iron
#

I don't know if it does yet. it'd be good to add though

idle owl
#

oi, I automocked machine and now it's failing hard. autodoc: failed to import module 'adafruit_featherwing.motor_featherwing'; the following exception was raised: Traceback (most recent call last): File "/Users/kattni/repos/venvpypi/lib/python3.6/site-packages/sphinx/ext/autodoc/importer.py", line 152, in import_module __import__(modname) File "/Users/kattni/repos/Adafruit_CircuitPython_FeatherWing/adafruit_featherwing/motor_featherwing.py", line 36, in <module> from adafruit_featherwing import shared File "/Users/kattni/repos/Adafruit_CircuitPython_FeatherWing/adafruit_featherwing/shared.py", line 35, in <module> I2C_BUS = busio.I2C(board.SCL, board.SDA) File "/Users/kattni/repos/venvpypi/lib/python3.6/site-packages/busio.py", line 15, in __init__ self.init(scl, sda, frequency) File "/Users/kattni/repos/venvpypi/lib/python3.6/site-packages/busio.py", line 23, in init from microcontroller.pin import i2cPorts File "/Users/kattni/repos/venvpypi/lib/python3.6/site-packages/microcontroller/__init__.py", line 36, in <module> raise NotImplementedError("Platform not supported:", platform) NotImplementedError: ('Platform not supported:', 'darwin')

#

not sure why none of this failed when there was no shared.py

slender iron
#

with shared.py ReadTheDocs is actually trying to create an I2C bus. try automocking busio

idle owl
#

Well done, you. But I thought we were avoiding automocks?

slender iron
#

in general yes

solar whale
slender iron
#

but the shared.py is causing ReadTheDocs to do more than it usually does

#

(It usually just imports a module)

idle owl
#

ok

tidal kiln
#

@solar whale as somewhat expected - SCK is high already when CS is set, right?

solar whale
#

yes

tidal kiln
#

starting to add up...maybe

#

seems like if we could find some way to kick it so the settings happen before CS, then we'd be good

#

@solar whale thanks for adding those to the issue thread

manic glacierBOT
tidal kiln
#

@solar whale i think i'm done for now. will see what ladyada comes up with. one other thing to mention, not the case here, but some sensors support both polarities of SCK, and they auto detect which one by the state of SCK when CS is asserted. so for those style sensors, this would be an even bigger issue.

solar whale
#

yeah and some like the stmpe610 just seem t o pick one !

tidal kiln
#

but it's well documented in the datasheet, right? ๐Ÿ˜œ

slender iron
manic glacierBOT
manic glacierBOT
raven canopy
#

@slender iron I'm back to testing adabot-on-travis and the bundle update. for now, i'm setting git config user.name/user.email in the yaml. would you rather these be env vars, and set them in python?

Travis log:

$ pip install -r requirements.txt
$ git config --global user.name "sommersoft"
$ git config --global user.email "sommersoft@gmail.com"
$ mkdir -p bin/adabot
The command "mkdir -p bin/adabot" exited with 0.

Updating Bundle...
$ python -m adabot.circuitpython_bundle

sommersoft
sommersoft@gmail.com

# in python: 
#    if "TRAVIS" in os.environ:
#         git_url = "https://" +
#                   os.environ["ADABOT_GITHUB_"] +
#                   "@github.com/adafruit/"
#    print(git.remote("-v"))
adafruit    https://[secure]@github.com/adafruit/Adafruit_CircuitPython_Bundle.git (fetch)
adafruit    https://[secure]@github.com/adafruit/Adafruit_CircuitPython_Bundle.git (push)

About to run a full one...trying to mitigate any actual updates (push --dry-run, no release)

raven canopy
idle owl
#

@raven canopy yay! (I think...)

solar whale
#

@slender iron what happened to tools/build_adafruit_bins.sh -- now I see a .py -- how iis it used?

raven canopy
#

@solar whale i suspect its the same as before, just with python. i briefly peeked at the PR earlier, but would check the new .travis.yml for any clues.

solar whale
#

๐Ÿ˜ฆ

#

I'm not travis savvy enough -- I quess I'll just build what I need

solar whale
#

That was too easy ๐Ÿ˜‰

raven canopy
#

hehe. just an alias away, i'm sure. if aliases are a thing one is inclined to used. oxymoronically, my laziness forces me to type everything out or just endlessly scroll my bash history. ๐Ÿ˜„

solar whale
#

but doesn't work

#
Traceback (most recent call last):
  File "build_adafruit_bins.py", line 2, in <module>
    from sh import rm
ModuleNotFoundError: No module named 'sh'
raven canopy
#

pip install sh

solar whale
#
Traceback (most recent call last):
  File "build_adafruit_bins.py", line 2, in <module>
    from sh import rm
ModuleNotFoundError: No module named 'sh'
idle owl
#

@raven canopy I have magical bash history that I can start typing something and up arrow and it goes to the last thing that starts with what I started typing....

solar whale
#

sigh -- it was so easy before today ...

raven canopy
#

lol

#

i've had sh for a while, thanks to adabot work. ๐Ÿ˜„

solar whale
#

sudo pip3 install sh FYI

#

and it is off and building -- thanks!

raven canopy
#

yw! (i didn't do much, you did all the keystrokes!) ๐Ÿ˜„

solar whale
#

the keybaord may not recover ๐Ÿ˜‰

raven canopy
#

and...i'm out. Fantastic Beasts await! ๐Ÿ‰
have a great evening ya'll!

idle owl
#

@raven canopy Have a good one!

solar whale
#

hmm -- I still get lots of build failures for many boards -- it seems to keep running and is OK for most of the boards I want but something is not right.. @slender iron or @tulip sleet when yo uhave a chance can you explain how to run tools/build_adafruit_bins.py now -- there must be some new steps

solar whale
#

may be OK now -- the boards taht don't build appear to be special cases -- I just had not seen then in the past.

#

and the nrf pca10056 and pca10059 do not geneate .uf2 files

#

ah - but if I do make BOARD=pca10059 -- i do get a .uf2

slender iron
#

@solar whale I'm back now

#

they should make uf2s and copy them over

solar whale
#

nrfs do not

#

atmel boards do

slender iron
#

@raven canopy good work! It may be easier to use the github api instead of git locally

#

@solar whale are you running it from the tools directory?

solar whale
#

yes

slender iron
#

hrm

solar whale
#

also it tries to build seveal boards taht fails

slender iron
#

I'm trying it now here

#

which ones fail?

solar whale
#

cp32-m4, feather_m0_supersized

#

tinket_m0_haxpress

slender iron
#

ah ok. I don't think those are built on travis

#

I must have messed up the flash definition

solar whale
#

just not used to seeig the erros -- it keeps going and build the rest

#

has tehre been a chang ein the bluetooth driver downloads -- looks like only 2.0.1 iss downloaded - ther others are in the repo now, correct?

slender iron
#

it now builds based on listing the board directories versus and hand coded list

#

correct

solar whale
#

OK -- I think I'm back on track -- still puzled aboyt nrf .uf2 -- I get tehm if I do a manual make BOARD=pca10059

slender iron
#

is it stating an error for them?

solar whale
#

not taht I noticed -- will scrool back and look

pastel panther
#

What bootloader do the nrf boards need for CP? It's there a uf2 Port?

slender iron
#

ya, there is a uf2 bootloader

solar whale
#

can-t go back that far -- too many errors from failed builds ๐Ÿ˜ฆ

slender iron
#

I'm building locally now

solar whale
#

ok -- pca10059 is fairly early

slender iron
#

TRAVIS_BOARDS="feather_nrf52832" python3 build_adafruit_bins.py

#

you can do that to only build one board

solar whale
#

ok -- will try it for pca10059

#
-rw-r--r-- 1 jerryneedell jerryneedell 243064 Nov 30 20:14 ../bin/pca10059/adafruit-circuitpython-pca10059-pt_BR-20181130-57b61a9.bin
-rw-r--r-- 1 jerryneedell jerryneedell 243672 Nov 30 20:14 ../bin/pca10059/adafruit-circuitpython-pca10059-it_IT-20181130-57b61a9.bin
-rw-r--r-- 1 jerryneedell jerryneedell 244120 Nov 30 20:14 ../bin/pca10059/adafruit-circuitpython-pca10059-fr-20181130-57b61a9.bin
-rw-r--r-- 1 jerryneedell jerryneedell 243544 Nov 30 20:14 ../bin/pca10059/adafruit-circuitpython-pca10059-fil-20181130-57b61a9.bin
-rw-r--r-- 1 jerryneedell jerryneedell 243048 Nov 30 20:14 ../bin/pca10059/adafruit-circuitpython-pca10059-es-20181130-57b61a9.bin
-rw-r--r-- 1 jerryneedell jerryneedell 242888 Nov 30 20:14 ../bin/pca10059/adafruit-circuitpython-pca10059-de_DE-20181130-57b61a9.bin
#

but it said it made them -- just did not copy them

#
Build pca10059 for en_US took 0.77s and succeeded
make: Entering directory '/home/jerryneedell/projects/adafruit_github/circuitpython_master/ports/nrf'
Use make V=1, make V=2 or set BUILD_VERBOSE similarly in your environment to increase build verbosity.
Create firmware.uf2
../../tools/uf2/utils/uf2conv.py -f 0xADA52840 -c -o "build-pca10059/firmware.uf2" build-pca10059/firmware.hex
Converting to uf2, output size: 477696, start address: 0x26000
Wrote 477696 bytes to build-pca10059/firmware.uf2.
make: Leaving directory '/home/jerryneedell/projects/adafruit_github/circuitpython_master/ports/nrf'



Build pca10059 for pt_BR took 1.48s and succeeded
make: Entering directory '/home/jerryneedell/projects/adafruit_github/circuitpython_master/ports/nrf'
Use make V=1, make V=2 or set BUILD_VERBOSE similarly in your environment to increase build verbosity.
LINK build-pca10059/firmware.elf
   text       data        bss        dec        hex    filename
 237848       1368      15364     254580      3e274    build-pca10059/firmware.elf
arm-none-eabi-objcopy -O binary build-pca10059/firmware.elf build-pca10059/firmware.bin
arm-none-eabi-objcopy -O ihex build-pca10059/firmware.elf build-pca10059/firmware.hex
Create firmware.uf2
../../tools/uf2/utils/uf2conv.py -f 0xADA52840 -c -o "build-pca10059/firmware.uf2" build-pca10059/firmware.hex
Converting to uf2, output size: 478720, start address: 0x26000
Wrote 478720 bytes to build-pca10059/firmware.uf2.
make: Leaving directory '/home/jerryneedell/projects/adafruit_github/circuitpython_master/ports/nrf'



manic glacierBOT
slender iron
#

@solar whale looks like it worked

solar whale
#

not for me -- it made .uf2 but did not cpy to /bin

slender iron
#

ah

#

its because you are special and have the uf2 bootloader on it

#

there is a mapping in build_board_info.py at the top

#

that tells it what extensions to copy over

solar whale
#

I do feel special .... ๐Ÿ˜‰

#

where is build_board_info.py?

slender iron
#

in tools as well

solar whale
#

ah -- thanks

slender iron
#

np

#

please pr any changes you'd like

solar whale
#

ok -- now taht I know how to do it , I'm good. I thought most users used .uf2 f fo pca10059 and pca10056 -- will it be the default for the feather_nrf52840

slender iron
#

looks like I missed it in that list ๐Ÿ˜ƒ

solar whale
#

and for feather_nrf52832 -- I always do a local make BOARD=... dfu-gen-dfu-flash so I don't pay attention to what is in /bin

#

some day it will all be52840s and no one will care ๐Ÿ˜‰

slender iron
#

๐Ÿ˜ƒ

solar whale
#

It looks like Sparkfun has become a CircuitPython fan ๐Ÿ˜ƒ nice to see

slender iron
#

yup! very excited to see their new board

#

just got my particles as well

solar whale
#

yes -- just ordered one -- so many boards -- so litlle time --

#

the particle.io pards are fun -- so far I've just played with their tools -- can't get my xenon to join the mesh network, but it appears to be a known issue on Xfinity routers(1) waitiing for fix.

slender iron
#

ah interesting

#

trying to add a xenon to go with my argon now

#

kinda surprised they don't to anything over usb

#

though it did enumerate in CDC mode briefly

river quest
#

these arrived now..

#

getting libgpiod running on these' sysfs is dead! long live libgpiod! https://blog.adafruit.com/2018/11/26/sysfs-is-dead-long-live-libgpiod-libgpiod-for-linux-circuitpython/

Adafruit Industries - Makers, hackers, artists, designers and engineers!

Earlier this year we wrote about the announcement of mainline kernel integration of libgpiod on the Adafruit blog (2/10/2018). libgpiod is intended to be a fast kernel-level-supported method for wrโ€ฆ

#

libre.computer boards, we'll see how this goes

slender iron
river quest
#

yah, it's a linux party here

exotic pumice
#

ain't no party like a linux party

pastel panther
#

@torn grail Have you double checked your wiring? What does busio.I2C.scan() show?

torn grail
#

yeah, I did. I had the 3v3 and GND swapped.

pastel panther
#

@slender iron fennec spotted!

torn grail
#

Working MUCH better now. LOL

slender iron
#

๐Ÿ˜ƒ

torn grail
#

Sometimes you check, double check, and triple check your wiring, and it is STILL wrong. I think its time for beer,

pastel panther
#

my watch says beer thirty, better hurry up

exotic pumice
#

I'm here to drink rum and eggnog and I'm all out of eggnog

#

true story

neon dragon
slender iron
#

@neon dragon awesome. I'm adding board defines for all three now

neon dragon
#

They are identical, not? Until we flash micropython to the ESP32 on the Argon.

slender iron
#

mostly, adding board defines for the coprocessors too

#

really good diagrams

neon dragon
#

Beware: I think the green flash chip on that diagram is incorrect. My board description has the correct one (I hope). Not sure if there are other errors in that schematic, better work from the Eagle docs.

slender iron
#

its not the MX25L1606?

#

have you thought about trying to leave the bootloader in tact?

#

ah, I see you have MX25L3233F in your repo

#

gonna go grab dinner. will be on later

#

I need to look closer at your repo. the added classes are interesting!

neon dragon
#

I'm not 100% sure about the flash chip. A while back they made an announcement that they switched from 2MB to 4MB flash chips. For the ESP32 they show the 4MB part, but the 2MB for the nRF. Moreover their memory map adds up to 4MB. So I expect 4MB is correct. It works but I have not tried to copy 4MB. No, I have not tried to keep the particle bootloader (supposedly its dfu, but flashing just "bricked" the device). Your bootloader is very slick, I don't need another.

manic glacierBOT
red dock
#

Ok, so I think at this point I'm beating my head against a wall and I need some help.

slender iron
#

@neon dragon glad you like our bootloader!

red dock
#

I'm not sure if this is the place to post this, but here goes.

I'm trying to hijack some of the fonts from the Adafruit-GFX-Library, like this one: https://github.com/adafruit/Adafruit-GFX-Library/blob/master/Fonts/FreeMono12pt7b.h

I'm just not understanding the encoding at all. For the 5x7 font it was easy, each line was a separate character, but with these other fonts I can't figure out how to interpret a character.

#

For the 5x7 font, it's pretty clear it's the following where each column is a 0xAA hexadecimal number from the table, and then each line of hex numbers is a character.

a b c d e
a b c d e
a b c d e
a b c d e
a b c d e
a b c d e
a b c d e

slender iron
slender iron
#

@main meteor did you start swd on circuitpython yet?

exotic pumice
#

@slender iron I was thinking of possibly doing something like that as well, furthest I've gotten is forking daplink

#

with no changes

slender iron
#

nice! I have a featherwing I could use it for

#

its a seesaw featherwing

exotic pumice
#

do you think it could be done through circuitpython rather than C?

slender iron
#

ya, I don't think its time sensitive. it'll just be slow

exotic pumice
#

that's interesting

#

I guess digitalio that plus whatever openocd needs?

#

idk how openocd targets work really

red dock
#

Anybody want to help me port this code from the Adafruit-GFX-Library to CircuitPy? If I can get this part, then I can basically port all the fonts with a little more work. From: https://github.com/adafruit/Adafruit-GFX-Library/blob/master/Adafruit_GFX.cpp

// Character is assumed previously filtered by write() to eliminate
// newlines, returns, non-printable characters, etc. Calling
// drawChar() directly with 'bad' characters of font may cause mayhem!

    c -= (uint8_t)pgm_read_byte(&gfxFont->first);
    GFXglyph *glyph  = &(((GFXglyph *)pgm_read_pointer(&gfxFont->glyph))[c]);
    uint8_t  *bitmap = (uint8_t *)pgm_read_pointer(&gfxFont->bitmap);

    uint16_t bo = pgm_read_word(&glyph->bitmapOffset);
    uint8_t  w  = pgm_read_byte(&glyph->width),
             h  = pgm_read_byte(&glyph->height);
    int8_t   xo = pgm_read_byte(&glyph->xOffset),
             yo = pgm_read_byte(&glyph->yOffset);
    uint8_t  xx, yy, bits = 0, bit = 0;
    int16_t  xo16 = 0, yo16 = 0;

    if(size > 1) {
        xo16 = xo;
        yo16 = yo;
    }

    // Todo: Add character clipping here....

   startWrite();
    for(yy=0; yy<h; yy++) {
        for(xx=0; xx<w; xx++) {
            if(!(bit++ & 7)) {
                bits = pgm_read_byte(&bitmap[bo++]);
            }
            if(bits & 0x80) {
                if(size == 1) {
                    writePixel(x+xo+xx, y+yo+yy, color);
                } else {
                    writeFillRect(x+(xo16+xx)*size, y+(yo16+yy)*size,
                      size, size, color);
                }
            }
            bits <<= 1;
        }
    }

endWrite();

exotic pumice
#

surround your code with
```
code here
```
so it looks cleaner

#

how do you do a 3 cycle delay in circuitpython?

raven canopy
#

@slender iron use the api for which part?

slender iron
#

@raven canopy use it for editing the file and committing

raven canopy
#

hmm...that is a big refactor, no?

#

to clarify (which i may have not done well enough to start), i'm battling this fail from the cron jobs:

exotic pumice
#

delay_cycles isn't exposed and I imagine even if it was it would have additional overhead

raven canopy
#

@exotic pumice you could probably use time.monotonic() and microcontroller.cpu.frequency to math your way there. monotonic is based on SysTick.

exotic pumice
#

ok

#

I'm also not sure what the frequency I'm dealing with is in daplink's case

raven canopy
#

won't be super precise...but close enough i imagine.

exotic pumice
#

I hate #defines

#

ok it looks like maybe 2-5Mhz

slender iron
#

@raven canopy ya, big refactor. I wasn't thinking about the submodule stuff it does

raven canopy
#

hehe. zactly. i was just about to pull up the api docs to see if that is even possible. ๐Ÿ˜„

velvet badger
#

Does the SR04 need 5v to work right with circuit python?

#

I get errors raised with test code every time. I've tried on a couple of feather boards.

raven canopy
#

@velvet badger looking at the guide, it shows it working with >1K ohm on the Echo pin. guide also notes that it is more accurate with 5V.

exotic pumice
#

@raven canopy, I'm printing time.monotonic, and it looks like millisecond precision

raven canopy
#

yep. i think a monotonic_us was recently added, actually.

exotic pumice
#

perhaps I need to pull

#
>>> dir(time)
['__name__', 'monotonic', 'sleep', 'struct_time', 'localtime', 'mktime', 'time']
>>> dir(time.monotonic)
[]
>>> dir(time.time)
[]
>>>
#

this is 3.1.1

velvet badger
#

Thanks @raven canopy

raven canopy
#

@velvet badger yw!

#

@exotic pumice ahh. it was actually monotonic_ns, and yeah i think its only in master (4.x)

exotic pumice
#

is that reasonably stable at this time?

#

not really but it's all I got, eh?

raven canopy
#

so, "delay 3 cycles" would be time.sleep(0.003) or microcontroller.delay_us(3000). yes?

exotic pumice
#

no, a cycle would be 1/5MHz or 200ns

#

would a hardware timer be a better idea and do I have access to those through circuitpython?

raven canopy
#

timers aren't available. i think there is an issue to bring them to the python side...

#

nope. that was for making it easier on the C side. ๐Ÿ˜ฆ

#

@exotic pumice if you need absolutely nothing happening during your wait, i think microcontroller.delay_us(1) is the shortest you'll get. time.sleep() will allow the VM to run if you need interrupts/periphs.

exotic pumice
#

hmm

#

I'll see what I can do but it sounds like I might have to go back into C or Rust

raven canopy
#

the crux of the python side. fine scale timing just doesn't pan out as easily..

exotic pumice
#

maybe the 2MHz mode, 1 cycle = 500ns, 3 cycles = 1.5us

#

can I do fractional us?

raven canopy
#

with delay_us(), looks int only. time.sleep() will take the float, but checks the procession of us...so i would say no.

exotic pumice
#

I'll have to see what the lower bound of speed is for SWD. DAPLink uses 2 or 5MHz, but possibly it is lower than that

#

according to the samd21 datasheet the clock for swd can be as low as 1KHz

#

so that's promising

slender iron
#

@raven canopy ya, I think you are on the right track

raven canopy
#

hmm. this will require much reading, in a circular fashion. always wanted to really, really dive into git's underworkings. ๐Ÿ˜

#

oh wow. its 1:30? i sat down like 5 minutes ago...at 11:30. ๐Ÿ˜†

exotic pumice
#

where do I get all the firmware.bins to do a build?

#

or is that generated?

slender iron
#

what do you mean to do a build? that is the output of a build

exotic pumice
#

ok, well it was complaining they're not there but I guess that's not the real problem

#

do I have to build_board_info before I build_adafruit_bins? I'm just following the travis output on what to do

#

it looked like it was just
clone, submodule update, then build_adafruit_bins

#

oh and mpy-cross

#

is it my gcc version?

#
[paul@P50-Arch atmel-samd]$ make BOARD=feather_m0_express -j4
Use make V=1, make V=2 or set BUILD_VERBOSE similarly in your environment to increase build verbosity.
QSTR not updated
../../lib/tinyusb/src/class/msc/msc_device.c: In function 'proc_builtin_scsi':
../../lib/tinyusb/src/class/msc/msc_device.c:268:7: error: 'strncpy' output truncated before terminating nul copying 8 bytes from a string of the same length [-Werror=stringop-truncation]
       strncpy((char*) inquiry_rsp.vendor_id  , CFG_TUD_MSC_VENDOR     , sizeof(inquiry_rsp.vendor_id));
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../lib/tinyusb/src/class/msc/msc_device.c:269:7: error: 'strncpy' output truncated before terminating nul copying 16 bytes from a string of the same length [-Werror=stringop-truncation]
       strncpy((char*) inquiry_rsp.product_id , CFG_TUD_MSC_PRODUCT    , sizeof(inquiry_rsp.product_id));
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [../../py/mkrules.mk:55: build-feather_m0_express/lib/tinyusb/src/class/msc/msc_device.o] Error 1
make: *** Waiting for unfinished jobs....
#
[paul@P50-Arch atmel-samd]$ gcc --version
gcc (GCC) 8.2.1 20180831
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
#

yeah that was it

#

should I PR to add -Wno-stringop-truncation or do you want to fix the warning?

#

I have no idea what language this is in now but it's not english

slender iron
#

I like to fix the warnings. we're not on gcc 8 yet though

exotic pumice
#

don't you use arch as well?

slender iron
#

not for regular development

#

and travis runs ubuntu

exotic pumice
#

ok

slender iron
#

I develop on mac day-to-day

exotic pumice
#

how do I set the langauge?

slender iron
#

TRANSLATION=

exotic pumice
#

thanks

#

would I use pwmout to do swclk?

slender iron
#

no but you might be able to use a SPI to

#

I'm not sure of the protocol details but if its just clocked bytes thats where I would start

exotic pumice
#

good idea

slender iron
#

thanks ๐Ÿ˜ƒ hopefully it works

exotic pumice
#

oh, I think it might be parallel though

slender iron
#

parallel? swd is two lines

#

do you mean bidirectional?

exotic pumice
#

bidirectional I mean

#

yeah

slender iron
#

ah ya

#

is the data line open drain?

#

thats more like i2c

#

ยฏ_(ใƒ„)_/ยฏ

#

start with bitbanging and you can always swap other transmission code later

exotic pumice
#

how do I bitbang synchronized to a clock and output that clock at the same time?

#

I guess just bang up and down the clock before I do anything that would take a clock cycle?

#

that doesn't really make sense either

slender iron
#

right, you set the clock pin intermixed with setting the data pin

exotic pumice
#

bang up, do 1 clock, bang down?

#

yeah I see it in the source now

exotic pumice
#

time.monotonic_ns seems like it's just time_monotonic * 1 000 000

#

or maybe that's print speed?

#

no, because I'm doing the timing independently of the prints actually

#
import time
import microcontroller

start_time = time.monotonic_ns()
microcontroller.delay_us(1)
end_time = time.monotonic_ns()
print(end_time-start_time)
slender iron
#

ya, it is

#

but its not a float so it won't lose precision

exotic pumice
#

ok, so I need a logic analyzer to figure out if I'm doing anything faster than 1kHz

#

that sparkfun one looked decent

#

for the price

#

and there's some on aliexpress too

slender iron
#

aren't you a student @exotic pumice ?

exotic pumice
#

yeah, why?

#

saleae student pricing?

#

still a little rich for my blood

slender iron
#

ya, I just looked and its more than I expected

#

I'm used to student software pricing ๐Ÿ˜ƒ

#

goodnight!

exotic pumice
#

night

slender iron
#

๐Ÿ’ค

exotic pumice
exotic pumice
#

can't get a valid id out of the debug register yet, oh well

#

if someone can sanity check that tomorrow, that'd be great

timber mango
#

@slender iron thank you for your reply. The MCU is running in an isolated area in a low voltage mode. (1.9V I think). When we designed the board we were not aware of circuitpython and therefore we were happy with plain UART communication as it was easy to isolate. However since we know about circuitpython now I would love to try it out.

#

So any pointers at what do do to get it working with just UART (if it is possible at all) are highly appreciated

main meteor
#

@slender iron I didn't know I was working on SWD on CircuitPython!

raven canopy
#

Welcome to the team, madbodger! ๐Ÿ˜†

exotic pumice
#

@main meteor it's never too late to start ๐Ÿ˜‰

manic glacierBOT
lone sandalBOT
exotic pumice
#

I guess swd needs a common ground, eh?

exotic pumice
#

I really need my swd breakout to get here lol. I'm trying to hold the wires on the cpx and it was doable with 2 but harder with 3

#

do you think the feather probing itself would be able to get an ID out?

#

I have no idea what I'm doing lol

#

@slender iron suggestions?

slender iron
#

do you have a soldering iron available? you could solder the wires down

exotic pumice
#

I'm getting one for christmas

#

I've been using my college's up to now

#

it would be nice if I hadn't killed my blue pill, it has 0.1" swd headers

pastel panther
#

hey @slender iron did you get a chance to see my response to your suggestions on the adxl34x PR?

slender iron
#

no I've been ignoring my github emails. will look now

pastel panther
#

thx

exotic pumice
#

I have a feeling it should be able to ask itself for an ID, because swd can work while other things are running, so there is probably something wrong with my code

jovial pine
#

Hi All, coming back to CPY after a break - I used V2 on my ATSAMD21E18 Keypad, and I'm looking to make a Bluetooth/USB version using an nRF52840 module. I've picked up couple of PCA10059 Dongles to experiment with, and was wondering if there is a guide on the steps needing to be taken to use Alpha4 on the Dongle.

exotic pumice
#

yo dawg, I heard you like swd, so we put a debug port on your debug port so you can swd your swd code

pastel panther
#

lol

tidal kiln
#

huh. i didn't realize CP supported namedtuples. i thought i checked sometime ago and it wasn't in there.

#

neat

manic glacierBOT
lone sandalBOT
slender iron
#

@jovial pine I don't know of one. I used a JLink to load a new bootloader on one.

jovial pine
#

@tannewt Thanks. I'll dig out my J-Link in the morning. Did you just solder wires to the board or mount a header?

scenic timber
#

I didn't see that instruction in the Installing Circuitpython on a pi either. Just took a guess and stuff started to work ๐Ÿ˜ƒ

#

Then I am guessing just follow the feather wing code?

slender iron
#

@jovial pine I can't recall. I do have extra headers for this purpose

manic glacierBOT
signal root
#

I think I bricked my Metro Express M4. Downloaded an UF2 from maker.makecode.com. It had circuit python on it originally and i didn't upgrade the bootloader. Anyone had experience reviving an M4?

manic glacierBOT
#

@ladyada is right! I'm sorry. pulseio is present in version 3.x. I assume you're running 2.x or earlier. Update to 3.1.1 and you'll be fine! Note that you also need to update the libraries in the lib directory to 3.x versions. For directions, see:
https://learn.adafruit.com/welcome-to-circuitpython/installing-circuitpython
https://learn.adafruit.com/welcome-to-circuitpython/circuitpython-libraries

Temporarily rename main.py or code.py to something else, like mainx.py while you a...

native palm
#

Can I use the CircuitPython libraries without installing anything else??? Like, I don't want to install the bootloader or build it or anything, I just want to use the libraries on this board I have that runs Ubuntu 16.04

radiant cypress
#

Hello there! First time here, I hope the first of many! Can I use the adafruit-circuitpython-feather_huzzah-3.1.1.bin on the HUZZAH ESP8266, I mean, the non Feather Huzzah ESP8266? Thank you!

tidal kiln
native palm
#

@tidal kiln I see. How hard is it to write support for a board that hasn't been made already?

tidal kiln
slender iron
#

@radiant cypress It should work but the pins in board might be wrong

radiant cypress
#

I'll try it @slender iron, thank you!

solar whale
#

@radiant cypress I have used it on the Huzzah breakouts with no issues. Good luck.

manic glacierBOT
neon dragon
#

What's the best way to "bridge" the USB on an nRF52840 to the UART? Application: esptool to flash micropython to the esp32 on particle Argon boards.

crude fossil
#

@neon dragon I'm not sure, but I suspect it'll be to create another serial port in the USB profile, and then just echo bytes back and forth. I've been messing with something similar in https://nick.zoic.org/art/micropython-webusb/

#

By making the serial appear as a separate serial port on the same device, you can still use all the usual serial UART based tools.

neon dragon
#

I see this is a bit of work. Perhaps I just try to port limited esptool functionality to CircuitPython and run this on the nRF52840.

crude fossil
#

What are you trying to do? Run MicroPython on the '32 or CircuitPython on the nRF or both?

#

or either ๐Ÿ˜ƒ

neon dragon
#

Nick: particle released a board that has an nRF52840 as the main processor and an ESP32 attached over UART for wifi. I want to reflash the ESP32 with micropython. The nRF runs CircuitPython. The ESP32 is not directly accessible, only via the nRF. Hence I cannot run esptool in the usual way.

#

BTW: getting the ESP32 into bootloader mode works fine. But it's in SPI_FAST_FLASH_BOOT. Anybody knows what that means?

night vale
#

I am using CircuitPython on a Raspberry Pi (3B+, I believe) and the adafruit_74hc595.ShiftRegister74HC595 library trying to control a bunch of power outlets (for Christmas lights and in place of light switches). It appears the library can only handle a single 74HC595 chip. I currently have 2 chips and planned to add more. Do I just need to use the SPI directly or does anyone know if the library can support more than a single chip?

manic glacierBOT
#

@C47D he intentado obtener los รบltimos cambios a mรญ repositorio a ver si eso lo soluciona, he visto que hay algunos conmuta que se han hecho arreglando cosas referentes a Bluetooth.
Por casualidad has probado los cambios? Hay alguna manera de compilar el cรณdigo con el lenguaje y verlo directamente en la placa?
Esperemos que eso lo solucione.

@tannewt I did try getting latest changes done on the main repository (adafruit one) since I saw some fixes regarding BLE. Hope it helps ๐Ÿ™ .

R...

idle owl
#

@night vale That library was very recently created, we did not test it with multiple chips. I don't know what would need to happen with it to support multiple chips. So if accessing the SPI directly works, I would suggest going that route.

manic glacierBOT
night vale
#

@idle owl Thank you for the quick response. When I hooked up the second chip, it appears it is simply ignoring the output past the 7 pins, so whatever the last value loaded into the first 74HC595 gets passed on to the second 74HC595. I will use the SPI directly. Thanks!

idle owl
crude fossil
#

I think you're right in that you could get away with having CircuitPython on the nRF CPU act as a relay to the ESP32 UART ... it'd have to be a "load through" kind of mode to use the usual tools though

manic glacierBOT
slender iron
#

@crude fossil make sure and get the latest commit. nordic changed their site and I fixed the script

granite crow
#

Hi, we were having problems with Travis, the log showed this error

slender iron
#

@granite crow I was just looking at that!

granite crow
#

Then PR #1 were merged and Travis is happy now, i would like to know if it's a known problem (the one on the screen capture)

crude fossil
#

@slender iron oh cool you've done that already? Ah, so you have, I was a couple of revisions back from master still

slender iron
#

yup, saw it a few days ago

crude fossil
#

I really wish vendors would just put sensibly named files in a bucket and leave them alone ๐Ÿ˜ƒ

slender iron
#

@granite crow is that PR ready to merge?

#

@crude fossil totally. at least the new ones are licensed so you can redistribute them

granite crow
#

@slender iron Travis is green but i would like you to take a look because there are some strings from the py directory and i don't know if those were meant to be translated.

slender iron
#

yup they can be

#

the only things we shouldn't translate are words that are also used in the code

granite crow
#

@slender iron oh ok, so merging the PR 1 seems to solve the problems we had, is that the right thing to do? i don't want to break CP :D.

crude fossil
#

@slender iron hey by the way the nrfjprog download has similarly moved.

slender iron
#

@granite crow I'm not sure why its called #1 but it looks right. travis passing means you haven't broken CP. Even if you do, we can always fix it

#

@crude fossil ah, I don't use it. Please update it if you can

#

@granite crow do you want to approve and merge?

granite crow
#

@slender iron i will take a quick look at the Spanish strings, if it's all right i will approve, sabas already check it and was waiting for Travis to become green.

slender iron
#

ok thanks! it looks good to me

granite crow
#

ok, i will check it later today, got to go, thanks for all the help!

lime trellis
#

hi is there a way to check which SERCOM I've used on a circuitpython board?
I feel like my USB and UART are talking over each other

manic glacierBOT
exotic pumice
slender iron
#

@lime trellis not from CircuitPython

#

@exotic pumice looks fine to me

exotic pumice
#

Ok thanks

main meteor
#

I was out for the day. Looks pretty much like the C version to me. Not sure if the timing is critical, but if so, might need to tweak some things.

manic glacierBOT
exotic pumice
#

I don't think timing is critical. It looks like it can range from like 5MHz to 1 or 10KHz

#

that's based on daplink using 2-5MHz and atmel datasheet saying the timing for a low and high swd pulse can be as long as 5000000ns (not sure the exact number of zeros but I checked earlier)

exotic pumice
#

I think we're at like 500KHz?

#

don't have a logic analyzer to check though

#

any compelling reason to not just use that?

scenic timber
#

is there an mqtt module for circuitpython?

exotic pumice
#

@scenic timber not as far as I can see

scenic timber
#

me either thats why I am asking ๐Ÿ˜ƒ

lime trellis
#

arrrggg does anyone know if circuitpython can handle a UART baudrate of 115200?

scenic timber
#

I'd like to port some holiday LED projects from arduino to circuitpython/seasaw

#

they use mqtt to get the commands as to which animations to run.

manic glacierBOT
lime trellis
#

@scenic timber (in case you didn't know) there's mqtt support on the master micropython repo. might give you a starting point

manic glacierBOT
lime trellis
#

thank you @slender iron I found another workaround. Is there a good explanation somewhere on why some pins can only be RX or TX? I can't seem to find any mention in the SAMD datasheet

exotic pumice
#

I think it's to do with SERCOM pad layout

slender iron
#

yup, look at the pinmux table and cross reference it with the pad settings for the UART sercom mode

exotic pumice
#

@slender iron were you aware of Adafruit_DAP?

slender iron
#

no

exotic pumice
#

yeah it looks like what we want

#

just arduino instead of circuitpython

scenic timber
#

@lime trellis thanks Iโ€™ll check it out!

exotic pumice
#

I don't see much reason to port it, do you?

lime trellis
marble hornet
#

does boot.py only run on hard reset or soft reset too?

exotic pumice
#

@lime trellis SERCOM5/PAD[1]

lime trellis
#

@exotic pumice yeah but where does it say that SERCOM5/PAD[1] can only be TX or RX?

exotic pumice
#

the UART section of the datasheet probably

lime trellis
#

I've combed through it, and their app-note. but I must be blind

#

I was hoping it was something I could set when configuring SERCOM5 somewhere

exotic pumice
#

if not, I can try to pull up some docs from a library I've used

lime trellis
#

@marble hornet I believe it's only on hard resets

slender iron
#

@lime trellis look in the CTRL register of the UART sectin

exotic pumice
lime trellis
#

๐Ÿ‘ I'll look right now

marble hornet
#

thank you !

lime trellis
#

so if I read this right.... TX can NEVER be on a PAD[1]??

exotic pumice
#

I think it's only pad 0 and pad 2

lime trellis
#

lol how has this never bit me before??? aarrrgggg

#

thank you both for your help!

marble hornet
#

@tulip sleet when I was asking about uart was a way to represent strings packed into bytes mentioned?

tulip sleet
#

looking it up...

exotic pumice
#

are you talking about like str.encode('utf-8')?

#

takes a string and returns a bytearray

tulip sleet
#

yeah, but that's not present in the smaller non-express builds

exotic pumice
#

ah bummer

tulip sleet
#

BUT, the workaround is:
bytes(some_string, 'ascii')

#

and in fact the second arg to bytes() is ignored (just like the arg to encode() is ignored. It's a MicroPython thing (or "deficiency"), or something.

#

@marble hornet ^^

marble hornet
#

thank you

exotic pumice
#

I guess you don't want too many encodings taking up space on a micrcontroller

tulip sleet
#

i keep forgetting this workaround; took me a while to find it again.

slender iron
manic glacierBOT
slender iron
manic glacierBOT
exotic pumice
#

it's just this right?

import random
sounds = ["jingle.wav", "good.wav", "bad.wav"]
cpx.play_file(random.choice(sounds))
#

a list is a sequence right?

#

@slender iron

slender iron
#

ya, thats what I was thinking

exotic pumice
#

ok cool

slender iron
#

that doesn't check for touch though

exotic pumice
#

oh, right

slender iron
#

but that can be left "for the reader" ๐Ÿ˜ƒ

exotic pumice
#

done

slender iron
#

thanks @exotic pumice !

exotic pumice
#

np

manic glacierBOT
#

It's an interesting idea! Do you have a specific example in mind? I've only done a little Arduino so don't exactly know what the API would be.

One of the biggest challenges we have with using other C libraries (including vendor libs) is that they all assume static allocation of resources. CircuitPython is the opposite because we don't know what will actually be used by user code. I imagine existing Arduino code will have this issue too.

manic glacierBOT
#

Hi,

Is there any further documentation on using the bleio as a peripheral? I can start the advertising but there is no further documentation on how to handle a connection, such as setting the connection handler and various event types, etc..

I am trying to build a very simple example following the one in ubluepy_temp, simply reporting the CPU temperature.

SoC I am using is the nRF52840.

BR/
Ed

cedar beacon
solar whale
#

I cannot access the link. Returns 404

inland tusk
stuck elbow
#

I would use fewer font faces and sizes...

manic glacierBOT
timber mango
#

@slender iron would you know where I need to change code / config to use UART instead of USB on the samd21?

manic glacierBOT
manic glacierBOT
marble hornet
#

hey, can one talk over spi in boot.py? i'm trying to send somehting to the screen but it isnt working

stuck elbow
#

I think the peripherals are not initialized yet

#

At that point

marble hornet
#

is there a way to?

#

or just flat out nope?

stuck elbow
marble hornet
#

thanks, is there a way to check if the device just turned on? not reloaded , reset?

stuck elbow
#

I don't know

marble hornet
#

okay๐Ÿ˜€ thank you

#

@tulip sleet could you please, if you're free, give me some help "parsing ๐Ÿ˜‰ " the nvm files? i can't find where the name of the module actually defined.

tulip sleet
#

it's kind of hacky. there are substitutions made for certain strings that turn into certain characters

granite crow
#

Hi, are there plans to suport the Bluefruit nRF52 board in Circuitpython?

tulip sleet
#

yes, that's the 52832 board, but we are also coming out with 52840 boards

marble hornet
#

to me, on 3.x, it isn't in string form ? so the name MP_QSTR_nvm is turned into the name?

tulip sleet
#

Yes, there's a preprocessing pass that looks for MP_QSTR_<something>, and builds a table of qstrs (compile-time shared string definitions).

#

see py/makeqstrdefs.py and py/makeqstrdata.py

marble hornet
#

so if i wanted to change it would i would just replace nvm right?

granite crow
#

@tulip sleet Sounds great, i'm seeing the Bluefruit with the Mynewt bootloader, can i go back and forth between Mynewt and Circuitpython (using just a SWD programmer i guess)?

tulip sleet
#

@marble hornet right

#

@granite crow in theory yes -- the newer boards will have a uf2 bootloader like other CircuitPython boards and that will be a lot easier to load. I'm not sure what you might smash if you overwrite stuff on the Mynewt board. I don't remember whether we have firmware images to reload (probably we do).

marble hornet
#

trying...

#

if i implement it in 3.x it can be pulled up to 4.blah right?

granite crow
#

@tulip sleet Thanks, i guess i will wait for the 52840 boards.

marble hornet
#

hmmm not working, gonna try again

#

do i need to tell cp to include it if i renamed the folder?

#

rather i made a duplicate and renamed it svm,

#

have to head to class, cu. have a great day all

charred blaze
#

So with Circuit Python how do I access Serial1 on a board? do I just read/write to the RX/TX pins of the board? or is there something else?

stuck elbow
#

not sure what you mean by Serial1

lone sandalBOT
manic glacierBOT
#

Fixes the remaining items in #1128:

  • Breaking Change: busio.UART constructor timeout parameter is now in seconds instead of msecs
  • UART.readinto(buf) now does not allow an optional length parameter UART.readinto(buf, len)
  • UART.write(...) no longer allows strings to be written. The bytes written must be bytes or bytearray or an array.array.

The fixes are to make UART more compatible with PySerial, so that PySerial can substitute for UART on Linux platforms.

tulip sleet
#

@charred blaze you would do something like serial1 = busio.UART(board.TX, board.RX) and then write to the UART object. Of course you don't have to call it serial1

charred blaze
#

Ahhhhh ok! thank you danh!!

#

apologies @stuck elbow i guess I meant UART with the RX/TX pins.

manic glacierBOT
manic glacierBOT
stuck elbow
#

@charred blaze ah, I see, like on the arduino leonardo

charred blaze
#

Im not sure. never used a leonardo.

slender iron
#

@marble hornet @stuck elbow SPI should work from boot.py. Only usb isn't up yet.

#

@timber mango you'll need to make a supervisor/serial.c in ports/atmel-samd/ that implements the supervisor/serial.h API and change the Makefile to use it instead.

#

@cedar beacon slides look awesome!

cedar beacon
#

๐Ÿ™

manic glacierBOT
charred blaze
#

What would cause an issue like this from the REPL?
code.py output:
Traceback (most recent call last):
File "code.py", line 26, in <module>
File "neopixel.py", line 91, in init
ValueError: Pin PA18 in use

tulip sleet
#

you tried to create a new I/O object on pins already in use. Post your code if you'd like

charred blaze
#

give me one sec dan. I dont wanna paste the whole thing even though its only 32 lines. Lemme get a link to it on my github. its super basic right now because im still learning Circuit Python

tulip sleet
#

you can post a file with the "+" button over on the left if you don't want to do it inline

#

but github too np

charred blaze
#

ah true. I'll do that isntead

#

I forget about that sometimes

#

I took the imports from Noe's lightsaber build. I am working on a similar project

tulip sleet
#

the neopixel.NeoPixel creations are inside the while True loop, so they happen over and over. Move the btns = and strip = out before the while True loop

#

and the other stuff is in the loop too, which probably only needs to happen once. so move that out. For now, just do

while True:
    pass
#

and put all the stuff in the loop before the loop

#

this is like in init() vs loop() in Arduino

main meteor
#

s/init/setup/

tulip sleet
#

tnx ๐Ÿ˜ƒ

charred blaze
#

ahhh ok.

idle owl
#

<@&356864093652516868> Reminder about today's meeting in ~46 minutes. Everyone is welcome to attend! Here is today's notes doc if you'd like to add your hug reports or status updates before the meeting. Thanks! https://docs.google.com/document/d/1LsFNPxpDJvRZUeDlDT1jTg03OPOsaMKd5-iwDMwcRj0/edit#

raven canopy
#

@idle owl thanks! I was just about to scroll back for the link! ๐Ÿ˜

charred blaze
#

How does one join? id just like to listen in maybe

raven canopy
#

@charred blaze we do the meeting here in discord. Just need to join the CircuitPython voice channel. If you'll just be listening, simply note that you're lurking (text here, or voice).

charred blaze
#

Alrighty!

#

im still new to Circuit Python so i have nothing to add.

manic glacierBOT
charred blaze
#

So now the repl is telling me that
blade.fill((255, 0, 0)) is invalid syntax for the neopixel library on CP

slender iron
#

whats before that?

charred blaze
#

This is the 3 lines above that:

  1. blade = neopixel.NeoPixel(LED_PIN, NUM_PIXELS, brightness=1, auto_write=False)
  2. while True

ignore the #) before the text, just marking the lines

slender iron
#

the while True is missing a :

charred blaze
#

derp...

lone sandalBOT
slender iron
#

may be just a few minutes late. still wrapping up our internal meeting

hard timber
#

I'm lurking/listening/learning ๐Ÿ˜ƒ

#

yes

raven canopy
#

๐Ÿ‘‹

charred blaze
#

I am also lurking

#

and listening too

raven canopy
#

It's "touchy"

#

Haha. I've helped cause a thing!

stuck elbow
#

I'm in lurk mode as well

#

Sorry

slender iron
#

๐ŸŽ‰

idle owl
charred blaze
#

Actually can I say a thank you, Scott?

idle owl
#

@charred blaze Of course!

hard timber
#

general hug to everybody on the project ๐Ÿ˜ƒ

charred blaze
#

Dang. network is being wonky. But yes thats what I said

meager fog
#

hiya here just for aminute in text

idle owl
#

@meager fog Let us know hug reports and status updates and we'll read them off

meager fog
#

mega hug report to @raven canopy for the adabot updates, they're so helpful!

#

@tidal kiln for picking up so many small issues & fixes

errant grail
#

Wonky audio, so will type today. General group hug to the entire team and community. Special hug to Ladyada for her early MIDI and musical synth guide work. Still relevant!

meager fog
#

im doing a lot of embedded linux ports for blinka so you can run circuitpython code/drivers on various SBC's - all are welcome to add support for their boards

charred blaze
#

Hiiiii LadyAda!

meager fog
#

hii

raven canopy
#
  • @kattni, @carter, @tannewt, and @ladyada for the various reviews and merges
  • @sajattack, @jerryn, @danh, @carter, and some I've probably missed for Discord and forum support
  • Everyone continuing translation work; such an awesome thing to see
  • The groupiest of group hugs!
charred blaze
#

Every time I hear someone say your name Scott I think they are talking to me. my name is also Scott

#

Apparently Im getting hug reports. I dont know what im doing here pretend there is fire all around me

river quest
#

one update for weekly chat, the awesome-circuitpython list was updated...

charred blaze
#

I can make noise. does that count for anything? Asking for a friend.

river quest
#

awesome-circuitpython is a curated list of awesome CircuitPython guides, videos, libraries, frameworks, software and resources. Lots of updates, the latest include: added newsletter archive list, added the latest boards that run CircuitPython from Adafruit, Sparkfun, and Digi-Key python section, added video newsletter podcast playlists, added the Adafruit Hallowing m0 express in hardware, added the CircuitPython libraries in code, added CircuitPython in MicroSolutions Digital Magazine, The Amp Hour #383 in news, and added CircuitPython Development Workshop in books. Did we miss anything? Make the awesome list more awesome by adding to it! - awesome-circuitpython @
https://github.com/adafruit/awesome-circuitpython

charred blaze
#

I'll pass

errant grail
#

Working on PCB designs this past week, not so much with CircuitPython. Besides shrinking the size of the lunchbox synth daughterboard, Iโ€™ve been playing around with PCB art and backlighting with SMD LEDs designed for reverse-mounting. Itโ€™s more difficult and mysterious than I thought it would be.
Next week will be focused on two CircuitPython NeoTrellis projects (and one โ€œclassicโ€ Trellis, too), a musique concrete instrument, and wrapping up some project enclosures.

charred blaze
#

Yes hi hello, that was me

raven canopy
#

Last Week:

  • Adabot:
    • Added an Arduino library script for comparing release tag to library properties
    • Finished up ability to run CircuitPython library validators "a la carte"
    • Hopefully fixed bundle updates for running Adabot on Travis
  • FRAM: Finished up SPI version

This Week:

  • Update FRAM Learn Guides with CircuitPython usage
  • Add "haz commits, needs release" to Adabot Arduino

gotta run for a day_job meeting. Thanks everyone! Have a great day. ๐Ÿ‘‹

tidal kiln
#

IN THE W33DS

  • how to test blinka PRs locally
  • how to approve NOT on behalf of CP librarians
hard timber
#

ty

errant grail
#

Thanks!

idle owl
dense pike
#

Question, On the 28nov18 Ask and Engineer, LadyAda mentioned that there was a new tutorial/course on using Circuit Python on the CPX. Can anyone point me to a link for it?

#

Thanks

slender iron
#

@dense pike I'll find it now. I think it was in the newsletter

idle owl
slender iron
#

it has a link to the youtube playlist too

#

its in tomorrow's newsletter ๐Ÿ˜ƒ

dense pike
#

@slender iron Asume, thanks

meager fog
#

back @tidal kiln to test blinka locally, pull, then set PYTHONPATH to include the folder

#

rather that pip3 installing

tidal kiln
#

@meager fog thanks. @gusty kiln also suggested a venv approach which sounded cool and will hopefully write up ๐Ÿ˜ƒ

solar whale
#

Welcome Shawn ๐Ÿ‘‹

errant grail
#

Welcome Shawn!

#

Bye

main meteor
#

It seems to me that reverse mounted LEDs would be straightforward (you may have thought so too), so now I'm curious as to what difficulties you ran into.

manic glacierBOT
#

Yes that will then probably also be an issue for Arduino.

What I would have in mind is being able to extend CircuitPython with your own compiled modules that are based on the Arduino API, so there would be a need for a translation layer that takes calls to the Arduino API (digitalWrite, analogRead, Serial.write etc.) and translates that to either the CircuitPython API or let it access the hardware peripherals directly if that can work out without making a horrible mess.
I know too little ...

charred blaze
#

So now my repl is giving me this for an error.
Traceback (most recent call last):
File "code.py", line 29, in <module>
File "neopixel.py", line 227, in show
ReloadException:
soft reboot

This is what my line 29 is.
blade.show()
and this is my line 28
blade.fill((0, 0, 255))

blade is a neopixel strip

exotic pumice
#

I think ReloadException just means the board rebooted or something. I'd like to know more as well.

#

so it's just saying it rebooted while that line was running, not that there's anything wrong with that line

charred blaze
#

hmmm ok

exotic pumice
#

did you maybe save the code and it triggered an auto-reload?

#

or depending on your editor it could even autosave

charred blaze
#

yeah it seems that it auto-reloads after I hit save. and Im using MU

exotic pumice
#

yeah that's probably all it was then

charred blaze
#

ah

marble hornet
#

a late hug report to @tulip sleet : Thank you for being so kind and willing to help!

tulip sleet
#

yw!

charred blaze
#

Now I gotta figure out why my led signal isn't getting sent to my strip of leds. I have them attached to the neopixel pins on the prop maker wing

tidal kiln
exotic pumice
#

@charred blaze I'm not sure why that would be. Neopixels are pretty finicky. One note though, you don't need that loop, the LEDs will stay on when you set them once.

idle owl
#

@tidal kiln Thank you

#

@tidal kiln Were there no screenshots to begin with?

#

REPL screenshots

charred blaze
#

@exotic pumice I figured as much. I was originally trying to make it alternate colors for the moment to get them working

exotic pumice
#

I see

tidal kiln
#

@idle owl there were....let me guess...

idle owl
#

@tidal kiln ๐Ÿ˜„

tidal kiln
#

no worries. will do. actually want to set one up to check one of those issues posted in the soon to be deprecated repo

idle owl
#

Sounds good, thanks you for both!

#

@tidal kiln Can you do the release on ADS1x15? You'll know better what to put in the release notes, noting that it breaks the API.

tidal kiln
#

yep

idle owl
#

Thank you!

manic glacierBOT
idle owl
#

That'll work. Thanks!

#

Trying to come up with a name for a lib. I'm pulling the Motor FeatherWing helper code out into its own library because it works on the Motor Pi Hat (and presumably the shield though that's to be tested soon). Adafruit_CircuitPython_MotorAddOn ? "add-on" was mentioned as a general name for shields/hats/wings. I don't know if I like it though. MotorKit? MotorHelper? I'm trying to picture what the import will look like and I want it to make sense. Add-on might be growing on me.

tulip sleet
#

@idle owl MotorBoard?

idle owl
#

hmm

tidal kiln
#

MotorBoard seems OK, marketing may not like it though

charred blaze
#

Motor Mover!!!

tidal kiln
#

MotorFHS? (Feather Hat Shield)

raven canopy
#

@tidal kiln needs a B for Bonnet. ๐Ÿ˜„

tidal kiln
#

oh wait, it's a wing

raven canopy
#

oh...and a W

charred blaze
#

M Wing (like he X Wing) but M is for motor

tidal kiln
#

MotorParty

charred blaze
#

I still like my idea the Motor Mover!!!! (You gotta keep the exclamation points in there too)

tidal kiln
#

MotorWiSH (Wing Shield Hat)

charred blaze
#

You forgot the silent B, for bonnet, like Sommersoft said

tidal kiln
#

it's a non printing unicode character

charred blaze
#

Ahhh ok

#

What about WooooooooSH instead of WiSH? With the oooooo being the circles your motors will spin???

tidal kiln
#

MotorV8R

charred blaze
#

Hahaha

#

@idle owl any of these ideas work??? Hahaha

idle owl
#

So I'm not sure there's a motor bonnet kit anyway. I don't know ๐Ÿ˜„

charred blaze
#

Lol

#

Darn. We had soooooo many great names

idle owl
#

It can't be wing specific, it already is and we're moving away from that. I love MotorParty but I don't think that explains much. MotorWiSH is pretty great.

tidal kiln
#

MotorChimera

idle owl
#

haha

#

There isn't a motor bonnet. But there's also no guarantee there won't eventually be.

#

harrumph.

tidal kiln
#

indeed. surprised there isn't one already. there is a servo one.

idle owl
#

Yep

tidal kiln
#

motor one would basically just be that + h bridges

#

and since it all fits on a wing, not a space issue

idle owl
#

MotorBWiSH? Preempt it? ๐Ÿ˜„

#

AddOn isn't much less general than Board.

#

Kit isn't in all of the descriptions, only the shield and hat descriptions

#

EasyMotor?

#

SimpleMotor?

#

Go the other direction and highlight it's ease of use instead of what it's for?... bleh

#

Now I want to have an excuse to say "bwish" though.

#

Helper is .. not good.

tidal kiln
#

Motor1A39 (all 3 PID's added up and converted to hex)

idle owl
#

LOL

#

Well played

#

MotorStepper?

#

Those are the two properties contained within.

#

well there's 6 but it's motor1,2,3,4 and stepper1,2

#

Makes it seem like maybe it's for steppers though, not also for dc motors

#

DCMotorStepper?

#

Eh.

tidal kiln
#

MotorStepper is ok, in that context should be obvious it's two things

idle owl
#

Think so?

tidal kiln
#

"stepper motor" means one thing, but by flipping them, seems ok

idle owl
#

that was my thought but then I second guessed it.

tidal kiln
#

if it were truly only for steppers, you would either say "Stepper" or "StepperMotor"

charred blaze
#

"Mighty Motor Mover" ???

idle owl
#

Points for creativity ๐Ÿ˜„

charred blaze
#

Woooo!

idle owl
#

More points for alliteration

charred blaze
#

"Meowtor Meowver" Cuz CATS!!!!

#

wait. thats not right

idle owl
#

Cat ideas from you? Never!

#

๐Ÿ˜‰

charred blaze
#

"Meowtor Mewver"

#

thats better

idle owl
#

๐Ÿ˜„

#

Nicely done

charred blaze
idle owl
#

If you fits, you sits.

charred blaze
#

Hang on.... I have a better response to that one. just gotta find it

idle owl
#

Ok, one more but then we're done or it should move to #general-chat

charred blaze
#

ok, back to circuit python topics lol

cosmic patrol
#

Hello everyone! I've been trying to get the SleepyDog library to work on an Adafruit feather M0 basic. The micro seems to draw far too much power in deepSleep mode(0.75mA at 3.3V external supply). I raised an issue in the repo and would love any suggestions for what I could try to reduce the power consumption. Thanks in advance!

sacred edge
#

Why when I name a python section of code anything other than "Code.py" It will not execute?

idle owl
#

@sacred edge There are a few filenames that run automatically. CircuitPython looks for code.py. If you name it something else, it doesn't look for it, that's why it doesn't execute.

cosmic patrol
sacred edge
#

That explains it!.. So save the "code.py" to a "named folder, but move the "code.py" to the drive?

idle owl
#

Yes, when you're ready to run your code.py file, copy it to CIRCUITPY and it will run automatically.

#

Unless you have an error, in which case, begin troubleshooting ๐Ÿ˜‰

sacred edge
#

Thanks!!.. Wow.. This is getting interesting knowing the little bits and pieces to writing and running the code..

idle owl
#

You're welcome! The more you get into it, the more you learn ๐Ÿ˜ƒ

river quest
#
Adafruit Industries - Makers, hackers, artists, designers and engineers!

These prototypes by Terrill Moore, CEO, MCCI look really cool โ€“ its an ICE40 Ultra Plus FPGA, with the RISC-V core running on it. If that were not enough, he even put some sensors on there! Lโ€ฆ

exotic pumice
#

Just watching CircuitPython Weekly now. Thank you'se for the thank yous. I'm happy to help support the community that supports me.

sacred edge
#

BTW, I got my Jewel Up and running just fine.. Neat little board..

exotic pumice
tidal kiln
#

@exotic pumice from today's meeting question?

exotic pumice
#

yeah

tidal kiln
#

thanks. yep. i use that too.

exotic pumice
#

I think it's a nice way to approve without fully committing

#

or allow multiple people to approve

teal bear
#

someone is asking me hard questions... "does the CPX have an rtos thing?"

tidal kiln
#

RTOS = real time operating system

#

a CPX does not have one

teal bear
#

is there a simplistic scheduler?

manic glacierBOT
manic glacierBOT
manic glacierBOT
#

Hmmm, request from @ptorrone was:

please use the "Single-pin capacitive sensor support" - no external resistor is required then!

... but in https://devzone.nordicsemi.com/tutorials/b/design-examples/posts/capacitive-touch-on-the-nrf52-series there's the following update:

Important updates:

Due to erratum 84 (COMP: ISOURCE not functional), capacitive sensing using the relaxation oscillator method is not usable in a real product with the nRF52832, as it will only work reliably...

manic glacierBOT
manic glacierBOT
timber mango
#

@slender iron thank you

manic glacierBOT
manic glacierBOT
#

The current CircuitPython "calibration" on SAMD21 is pretty simple: when the TouchIn object is created, we assume that it's not being touched. Touch threshold is that value + 100. But TouchIn.raw_value is available for people who want or need it, and the threshold can also be adjusted.

If the nRF errata are saying that the readings are really erratic, yeah, that could be a significant issue.

upbeat plover
tidal kiln
#

datasheet time! seems possible, just need to work through the details in the datasheet. have you done anything like this before?

upbeat plover
#

never...

#

i would like to learn though

#

i find useful chips in all kinds of discarded/antiquated devices

tidal kiln
#

are you familiar with SPI in a general sense - the basic idea of how it works, what CS does, etc?

upbeat plover
#

no, i think you have to pull cs down to do stuff?

#

should i add pins for hold and write protect pin?

tidal kiln
#

in general yes, and you can see some traces in the datasheet. but SPI is a general communication thing, not specific to this chip. so i'd first do some reading on SPI.

upbeat plover
tidal kiln
#

that's a little too high level, only covering the software aspects

#

but it links to ye 'ole wikipedia

#

so that level of reading

upbeat plover
#

this was my first failed attempt

import board
import digitalio
import busio
from adafruit_bus_device.spi_device import SPIDevice
import time

cs = digitalio.DigitalInOut(board.A5)
cs.direction = digitalio.Direction.OUTPUT
cs.value = True

spi = busio.SPI(board.SCK, MOSI=board.MOSI, MISO=board.MISO)

device = SPIDevice(spi, cs, baudrate=5000000, polarity=0, phase=0)
time.sleep(4)

while True:
    with device:
        cs.value = False
        result = bytearray(256)
        spi.readinto(result)
        cs.value = True
    break
#

nvm that was like 3 or 4th... lol

tidal kiln
#

yep. backup and read about SPI - how it's working under the hood.

#

i think it will be difficult and frustrating to try to just do it by iterating on software

upbeat plover
#

reading the wiki now

tidal kiln
#

you'll want to really understand what CS/SCK/MOSI/MISO do

#

read the wiki, the datasheet, and also maybe an existing CP driver for a SPI device

upbeat plover
#

for the mode, the chip im using can do 0 or 3, but the wiki doesnt really tell what "Clock edge
(CKE/NCPHA) " is

tidal kiln
#

where is that quote coming from?

#

oh i see it. the table on wiki page.

upbeat plover
#

is that not needed?

#

its only mentioned in the mode

tidal kiln
#

it looks like it's just the terminology for clock and phase for a specific microcontroller

#

so, typical datasheet fun, you've already found that good bit of info - "Both SPI bus mode 0 and 3 are supported"

#

the next question is how the chip gets set to one or the other....hopefully it's in the datasheet somewhere...maybe inferred from the diagrams....buried in a footer note....google for errata...??? etc.

#

however it works, just use mode 0

#

and what the datasheet is calling "Standard SPI"

upbeat plover
#

datasheet references the HOLD# and WP# pins alot i think i need to wire that to like board.A4 and board.A3?

#

currently board.A5 is my cs

raven canopy
#

@upbeat plover the interaction with that chip looks a lot like the FRAM chip I just dealt with. HOLD and WP aren't required, from what I can see.

upbeat plover
#

i was looking at the "block diagram" it looks like nothing can be done without the "write control logic"

#

im very new to this so im probably mistaken

raven canopy
#

Correct. You need to send the "write/read" command before sending data/location.

upbeat plover
#

wow, might take a bit to look through that

tidal kiln
#

it will, but you've got good info to go on

#

a combination of general info like the wiki page to understand SPI + the specifics in the datasheet to understand your device + examples like above for helpful reference

upbeat plover
#

yeah thanks for info guys

idle owl
#

@prime flower I see you're working on TinyLoRa

prime flower
#

@idle owl yep! implementing a bunch of cater's changes

idle owl
#

Right on.

prime flower
#

cleaning it up and then I was going to ping you re: linting issues,

idle owl
#

Ok, sounds good ๐Ÿ˜ƒ

#

Do your thing and let me know when you're ready

prime flower
#

absolutely, thank you

upbeat plover
#

for commands like "E7H" that is just 0xe7 ?

#

i assume the H stands for hexadecimal

tidal kiln
#

yep

prime flower
#

Yeap, that's the encoding

upbeat plover
#

ty

idle owl
#

@tidal kiln Let me know if/when you'd like help deprecating the ADS1x15 Python library. I was pinged to assist.

tidal kiln
#

you wanna just do it?

idle owl
#

I've got plenty on my plate. More importantly, it may be a process worth knowing how to do as the plan is to deprecate as many as possible.

tidal kiln
#

ok. maybe later today then.

idle owl
#

Whenever works for you is fine, I was going through my list and helping you with that was on it so I pinged.

tidal kiln
#

okie dokie. i'm wading through the forums swamp for a bit. will try and ping you later.

idle owl
#

I have to leave for the evening around 1800EST. If we don't get to it today, that's ok.

prime flower
#

@idle owl alright, lib. is at a good point to sort out the issues.

#

@tidal kiln thanks for such a comprehensive review

tidal kiln
#

@prime flower np. i think it was mainly a lot of "make it more pythonic" suggestions.

idle owl
#

@prime flower Ok.

#

Everything is happy with an __init__.py file in the packages directory, correct?

prime flower
#

@idle owl yeah (just tested), it removes the no-name-in-module error

idle owl
#

@prime flower Out of curiosity, what version of Pylint are you running locally?

prime flower
#

2.1.1

idle owl
#

Hmm ok.

#

I was hoping for 1.9.2 ๐Ÿ˜„

tulip sleet
#

that's too bad - i thought it would be happier in 2.1.1

idle owl
#

We were postulating that it might be resolved in Pylint 2.x

#

And still trying to figure out why there are other libs that work fine without an init.py file.

#

I feel like it's not worth blocking this for us to try to figure this out.

tulip sleet
idle owl
#

Indeed ๐Ÿ˜ƒ

tulip sleet
#

but i'm not going to do that now

idle owl
#

@prime flower Please include the __init__.py file, but include a comment/docstring that explains why it's necessary since we are putting in an effort to move away from it and I'd rather not have someone else come along and go through this whole thing again when we've already done it.

#

We'll deal with figuring out what is different about your lib another time.

#

Since it doesn't seem like anything should be ๐Ÿ˜„

prime flower
#

Incl. the docstring inside the __init__.py explaining it?

idle owl
#

Yes please

#

Doesn't have to be super long, but explain that without it pylint fails with the following errors, we should revisit this when we can look into it or something like that

prime flower
#

added, pylinted locally, pushing to pr..

#

travis looks like it passed, yey

slender iron
#

what is the lint error that requires init.py?

prime flower
#

no-name-in-module

tulip sleet
#

pylint doesn't seem to realize it's a package

slender iron
#

what is the context of the error? is it linting an example

raven canopy
finite coral
#

Hey guys, question for ya.
I'm playing some WAV files when my Circuit Playground is tapped. But it's occasionally throwing a memory allocation error.

Do I need to some how... free the old objects or close the previous file... ? before playing a new WAV file? Each file can play at least once... but occasionally, when the played file changes, it's crashing.

slender iron
#

@raven canopy ah, that makes sense. if you have subdirectories then you need an init.py

#

@finite coral how are you playing the file?

finite coral
#

@slender iron

audio = audioio.AudioOut(board.A0)
wave = 0

def play_file_two(filename):
    global wave
    global currentlyLoadedFilename
    print("Playing sound: " + filename)
    # the requested filename is different from the previous one,
    # so open the file and play
    if currentlyLoadedFilename != filename:
        wave_file = open(filename, "rb")
        wave = audioio.WaveFile(wave_file)
        currentlyLoadedFilename = filename
        audio.play(wave)
    # the requested filename is the same as the last one,
    # so don't reload the WAV file if it is already open
    else:
        audio.play(wave)

I kinda hacked apart some of the sample code.

#

Detecting a tap calls this function. But only if the audio isn't currently playing.

prime flower
#

@idle owl with travis passing, OK to merge into master? Git's site alerts me that squash and merge is not enabled for this repository

tulip sleet
#

we don't do squashes any more, so merge is fine

prime flower
#

oh, ok

#

@tulip sleet was this discussed on the cpy weekly? (didnt listen to it yet)

tulip sleet
#

about no squash? we stopped doing squashes more than a year ago (starting on the circuitpython repo). If it's still enabled on some repos that's left over

idle owl
#

Yeah that isn't recent.

#

I can merge it.

prime flower
#

maybe still enabled on some of the arduino libs ive worked on.. ๐Ÿคท

idle owl
#

We haven't disabled it for Arduino. It's a CircuitPython specific thing

#

@prime flower Do you want me to merge it?

prime flower
#

that'd be great, thank you

tulip sleet
#

we decided it wasn't worth it for commit "cleanliness". the commits show a good history of the dev process; we don't really need to hide the intermediate steps.

idle owl
#

We strive for transparency and it can be a great learning experience for others.

#

@prime flower Done.

prime flower
#

Thanks!

vague folio
#

Hi everyone, I'm new to CircuitPython, and I had a question about the libraries. I'm using the INA219 library, and noticed that the chip has more features than are implemented in the library (power register, etc). Were these not implemented intentionally to save space? Or has no one gotten around to it? (If the latter, I hope to help out by implementing those)

finite coral
#

@slender iron
Hmm... welp, I didn't find the problem, but I think I found a solution.
Before playing a new WAV file, I call audio.deinit(), immediately followed by gc.collect() to free up some memory manually. ยฏ_(ใƒ„)_/ยฏ

idle owl
#

@vague folio I'm betting it's that no one has gotten around to it.

tulip sleet
#

@vague folio the CircuitPython library usually takes its lead from the earlier Arduino library -- not sure what was done in this case.

vague folio
#

@idle owl Ok, good to know. So just to double check, if I were to update the library to implement all the features of the chip, that would be ok? (I will be needing help to navigate the github process, but that's another topic)

#

@tulip sleet Also good to know. I also can update the arduino/c library, as I'm going to be using that as well. Does that work?

idle owl
slender iron
#

@finite coral I'm glad you sorted it out

vague folio
#

@idle owl Thanks for the link. If you don't mind, could I reach out to you directly if I have any questions with that?

#

(I apologize to those other users starting with Katt*. Turns out I should check my mentions before hitting enter.)

idle owl
#

Absolutely. But there are also many people here who can answer questions too. ๐Ÿ˜ƒ

#

If I'm around, I'm happy to help

vague folio
#

ok cool, will do

idle owl
#

@slender iron We have a number of libraries that have packages that do not require an __init__.py file. That's why we were looking into it. We'll deal with it when we have more time to look into what the deal is.

prime flower
#

@idle owl created a branch for pypi, going to submit a PR, can I tag you for reviewing?

idle owl
#

@prime flower Yes please

slender iron
#

@idle owl ya, seems like its inconsistent when its needed and we should just add them

idle owl
#

There was discussion that concluded we shouldn't use them.

#

ยฏ_(ใƒ„)_/ยฏ

#

There's already an issue open for it. We'll sort it when we get to it.

tulip sleet
#

i'm confused by the pointer to the 3.7.1 doc that says they're needed, cause Python 3 started making them optional. I need to sort all this out.

raven canopy
#

@tulip sleet I was confused as well, especially since your aforementioned statement of "3.x optional".

slender iron
#

and it seems having init.py leads to more predictable behavior

exotic pumice
#

lmao

prime flower
#

@idle owl This initial release would be v1.0.0, correct?

#

(not sure if the travis config would be ok with pre-release versions for verifying)

idle owl
#

@prime flower Sure. Or if you feel like it's not entirely done yet, or you know there are more features to be added you can start at 0.x.0. Version numbers are free, so you can choose what you think makes the most sense.

tidal kiln
#

@prime flower in case you haven't read yet:
https://semver.org/
i don't think it answers the question of what the initial number should be, but does explain what the 3 digits are for

prime flower
#

thanks for the link, I just wasn't sure if travis would release differently if I didn't do a 1.0.0

idle owl
#

No, it doesn't care, it simply wants a release.

#

@prime flower Travis failed on auth info for PyPI deployment.

prime flower
#

just saw that...I manually typed in the password too after it prompted me

finite coral
#

Any tips for improving NeoPixel animation speeds?
When I change the value of all 10 NeoPixels on the CircuitPlayground express, it takes about 250ms.
This is with my neopixel.NeoPixel() initializer with auto_write set to False.

#

Conversly, only setting a single NeoPixel is pretty darn fast.

manic glacierBOT
#

ok thanks for your comments!
@dhalbert so do you mean to change the behavior of the timer initialization >6MHz to create a 50% duty-cycle?
i don't know if the voltage drop comes from my meassurement mistakes/ my osiliscope or eventually from some not 50% dutycycle?!
anyone an idea how i can test this more?
or do you think it is just good leaving 6MHz max, adding the 'magic number' fix and a comment (similar to what i have done currently)?

idle owl
#

@prime flower What I've been doing when something like this happens is deleting the release, deleting the tag, and starting fresh.

#

@prime flower There's a process to do this though.

prime flower
#

oh jeez that @ came in right as I was doing a release

idle owl
#

Heh ok. That's fine.

#

Please include this entire section in every release, @prime flower: ```To use in CircuitPython, download the .mpy file and copy it to the lib folder on the CIRCUITPY drive. Or, simply install the Adafruit CircuitPython bundle.

To use in CPython, pip install adafruit-circuitpython-<libname>.

Read the docs for info on how to use it.```

#

Also apparently you didn't update the libname part. I pasted that out of the initial release.

prime flower
#

yeah, I saw that

#

added the entire section to my notes on this

#

didnt deploy again...invalid option "--api_key="

idle owl
#

I looked at it, it passed....

prime flower
#

the tagged build?

idle owl
#

#16 passed Tag 1.0.1

prime flower
#

shows failed on my other tab...weird

idle owl
#

Travis can be weird with updating to a new build sometimes.

prime flower
#

ok, great. Just exported my notes on the process to dropbox. thanks for the help

manic glacierBOT
idle owl
#

@prime flower At some point we need to figure out why you can't encrypt the password successfully or you'll always need someone to fix it, or need someone else to do the entire process. Right now isn't great, but we should probably keep it on our radar.

prime flower
#

I agree, I'd like to know why it isn't encrypting either..

#

are the instructions for building the bundle still valid? I can't seem to find build-bundle.py in the current repo

idle owl
#

I don't run that. I do the submodule add only. I commit, push, and then verify in the PR that I've only updated .gitmodules and added module at point <hash>.

#

I didn't even know about that step.

manic glacierBOT
#

@s-light what is the spec'd bandwidth of your oscilloscope? (Or, what model is it?) If you are looking at the waveforms and they look more like sine waves than square waves (of some width), then the limited bandwidth of the scope may be giving incorrect peak-to-peak results.

As the frequency increases, the duty cycle granularity will increase. At some point only 0, 50%, and 100% will be possible. 6 MHz may or may not have been an exact calculation: it may have just been "that's a good uppe...

slender iron
#

@tulip sleet want to wait for a ladyada review before merging your UART PR?

tulip sleet
#

@slender iron I did test it. You can go ahead and merge and that will give a good build for her to test more thoroughly. thanks!

slender iron
#

kk

solar whale
#

@prime flower Congratulations on the TinyLoRa release!! Woo Hoo! I just ran a quick test on my RaspBerry Pi -- wroked fine with one samll detail. the ttn_*.py files are not "installed" by pip3 -- should they have been? -- I had to copy them to the local folder. No big deal, but just a surprise.

#

sorry -- they are installed but my system did not find them -- may be something on my end --

prime flower
#

@solar whale They should have been...was the encryption file included as well?

#

might be an issue with the setup.py not sourcing them?

solar whale
#

yes - they are there --trying to figure out why python could not find them.. It worked fine when I copied just them into my folder --

#

have you treid it on a RPi?

prime flower
#

not yet

solar whale
#

OK -- It may be my problem -- I'll keep looking -- Nice job!!

prime flower
#

thanks. it;s probably that line of setup, though. i cant think of anywhere else where those files would be imported.