**** BEGIN LOGGING AT Wed Jun 12 03:00:27 2019 Jun 12 03:04:40 rcn-ee[m]: no prob. have you thought any more about shrinking the images? Jun 12 03:12:09 dabbler: maybe friday to look at it more... i finally finished the last project on my honey do list for the summer (well so far). so i should have more free time to work on these fun projects Jun 12 03:15:04 i think i'll just borrow the raspberry pi script, then just figure how to minimze the base *.img Jun 12 03:17:08 rcn-ee[m]: https://pastebin.com/qFQb4NCq Jun 12 03:22:08 chopping off the header (to be able to use ext2 tools) and gluing it back can be replaced by using a loopback device to access the rootfs partition Jun 12 03:24:45 bbl Jun 12 03:28:08 off with their headers! Jun 12 07:37:56 Following adafruit tutorial https://cdn-learn.adafruit.com/downloads/pdf/dht-humidity-sensing-on-raspberry-pi-with-gdocs-logging.pdf to read DHT11 device with beaglebone, I'm ended with this python script: https://pastebin.com/ZfYGeWC0 Jun 12 07:39:28 when started it gives back: https://pastebin.com/ZtUwC0mp Jun 12 07:40:18 what's the problem ? Jun 12 07:57:43 it is in the error msg, python is expecting an indentation but you did not indent that line (you have no indentation at all) Jun 12 07:57:43 https://docs.python.org/2.0/ref/indentation.html Jun 12 08:00:10 just figured out the problem is on the structure of .py file (tabs and spaces on the right places...) Jun 12 08:00:24 that is called indentation ;) Jun 12 08:00:31 ah... Jun 12 08:00:41 my poor knowledge.... Jun 12 09:15:09 How should I modify this https://pastebin.com/R0L9u12t to add a second 1-wire pin ?? Jun 12 09:52:34 why would you want that? Jun 12 09:52:58 (instead of just connecting both devices to the same 1-wire bus) Jun 12 09:53:50 kedidie: btw that link is to the old python2 documentation (although the same of course still applies for python3) Jun 12 10:17:05 any recommendation for a wifi antenna for the BBBW? the pigtails really don't cut it Jun 12 10:24:18 kedidie: please don't unnecessarily use private messages Jun 12 10:24:58 and yeah it's a bit annoying that google still tends to yield the docs for obsolete python versions before the current Jun 12 10:54:42 true Jun 12 11:00:42 m Jun 12 11:43:03 zmatt: honestly , I'm trying to read data from DHT11 sensor via Python/Adafruit driver, If I connect sensor to a generic gpio I get completely wrong readings, while connecting to a 1-wire pin I get right data. Jun 12 11:44:29 The only 1-wire pin is connected to ds18b20 sensor that gives me back strange readings when connected together with DHT11 Jun 12 11:47:39 DHT11 also has not such a 1-wire behavior as DS18B20 , this last one is recognized by board (/sys/devices/w1_bus_master1/deviceid directory is created) while DHT11 connection on 1-wire bus has no effect Jun 12 11:49:52 Practically here, there is no reason for these two devices to be connected at the same time, then configuring two 1-wire pins is just for curiousity , to know if it can be done.... Jun 12 12:08:09 dht11 isn't 1-wire, it's a custom protocol iirc Jun 12 12:09:04 yeah, IIRC bastardized SPI-ish protocol Jun 12 12:09:26 nah it's a single wire, but not actually 1-wire Jun 12 12:09:58 I just went with the one that speaks proper I2C Jun 12 12:10:50 ok, anyway, it gives right reading only if I connect it to 1-wire BB pin....(don't ask me why...) Jun 12 12:10:51 AM2320 Jun 12 12:11:00 fred__tv_: what do you mean by that? Jun 12 12:11:20 especially since you said the 1-wire bus doesn't recognize the sensor (which makes sense, since it's not 1-wire) Jun 12 12:12:27 If I connect DHT sensor to any gpio pin and declare to use that pin in python script, i get wrong readings. Jun 12 12:13:07 If I connect it to the 1-wire pin (and choose that pin in python script) it works correctly.... Jun 12 12:13:17 there are no "gpio pins" or "1-wire pins" Jun 12 12:13:24 be more clear Jun 12 12:13:49 sounds like it might just need proper pin config, direction and pull-up/down Jun 12 12:14:26 it needs external pull-up Jun 12 12:15:15 that 1-wire overlay you've seen before , set P9_12 as the header pin for 1-wire Jun 12 12:15:50 the overlay just creates a kernel device for a 1-wire bus on a gpio Jun 12 12:16:01 which is useless for a dht11 since it doesn't use 1-wire Jun 12 12:16:59 ok but DHT11 reading are OK ONLY if I connect the sensor to THAT header pin, don't know why Jun 12 12:18:04 me neither, there's no difference between one gpios or the other Jun 12 12:18:11 *gpio Jun 12 12:18:48 there's nothing special about that pin, it was picked arbitrarily Jun 12 12:18:50 it's just a gpio Jun 12 12:19:46 do you have the required external pull-up resistor (4.7 kOhm or so) ? Jun 12 12:20:23 yes (a little board with 10k resistor) Jun 12 12:20:52 https://ktechnics.com/wp-content/uploads/2015/12/dht11temp-humid-800x800-e1515136718531.jpg Jun 12 12:21:36 any gpio should be fine then Jun 12 12:21:52 or rather, I'd expect any gpio to be equally unreliable Jun 12 12:22:24 why not use the dht11 kernel driver? I'm pretty sure there is one. it'll still suck, but less so than doing it in userspace Jun 12 12:22:45 overlay-utils even has an example for it Jun 12 12:23:00 uh ? looking.... Jun 12 12:23:42 nah....just seen.... Jun 12 12:23:55 ? Jun 12 12:28:30 Just realized DHT11 overlay is into overlay-utils..... Jun 12 12:32:49 zmatt: got a sec for a dumb C question Jun 12 12:33:52 kremlin: you should know better than asking to ask :P Jun 12 12:34:00 #define usleep_range(l, u) do { DELAY(u); } while (0) Jun 12 12:34:04 this should do *nothing*, right? Jun 12 12:34:21 it'll call DELAY(u); Jun 12 12:34:57 ty Jun 12 12:35:08 sane people would replace this by an inline function Jun 12 12:36:19 kremlin: huh no Jun 12 12:36:40 the do { ... } while(0) around it is just to ensure it becomes a single statement, even if this DELAY macro expands to multiple statements (in which case the author of that macro should be shot) Jun 12 12:36:44 kremlin: it does not no nothing. Jun 12 12:36:57 like I said, it'll call DELAY(u) Jun 12 12:37:43 zmatt: yep. not nothing. Jun 12 12:37:43 gotcha Jun 12 12:37:52 i forgot the condition is checked last on dowhiles Jun 12 12:41:30 what could the benefit of ensuring it's a single statement be, i wonder Jun 12 12:41:50 zmatt: what should I expect with that overlay loaded and DHT11 connected to that pin ? Jun 12 12:42:13 presumably an iio device Jun 12 12:44:43 sorry for no-knowledge... where to search for and how to use ? Jun 12 12:46:53 ls /sys/bus/iio/devices/*/*humidity* Jun 12 12:51:33 found Jun 12 12:55:35 based on reports it seems to be fairly unreliable, as I'd expect from any gpio-based dht readout on linux Jun 12 13:07:25 cat /sys/bus/iio/devices/iio\:device0/in_humidityrelative_input : Connection timed out ..... Jun 12 13:07:41 yep, that Jun 12 13:14:08 gpios = <&gpio0 30 0>; what does the last 0 mean ? Jun 12 13:15:10 it's a flags field, 0 = default (active-high). it can have an active-low flag but that's not applicable here Jun 12 13:22:17 mah..... python script works ok on that pin now, I'll go that way....:P Jun 12 13:23:06 don't forget to remove the overlay to avoid conflict with the kernel driver Jun 12 13:23:41 (normally the kernel would enforce this by disallowing gpio from userspace on pins used by the kernel, but for some reason that's been deliberately broken on beaglebone kernels) Jun 12 13:29:21 copying a modified dtbo (with the same name) on /lib/firmware , already declared on uEnv.txt , mods take place just on next reboot, isn't it ? Jun 12 13:29:49 sure Jun 12 13:45:33 hey there :) I just downloaded the Debian 9.5 2018-10-07 4GB SD IoT image and want to update some packets. I also need sudo but I cannot find the password anywhere. Can someone help me? Thanks Jun 12 13:45:56 what does the password prompt for sudo ask? Jun 12 13:47:08 "password for debian:" Jun 12 13:47:24 i.e. the same password as the one you used to log in Jun 12 13:47:35 "password for debian" Jun 12 13:47:53 im accessing the board via the terminal from cloud9 Jun 12 13:48:18 in that case it's on the first google hit for "beaglebone black password" Jun 12 13:48:29 (which is, at least for me, the getting started guide) Jun 12 13:49:05 ok - thanks :) Jun 12 13:50:11 found it - thank you :) Jun 12 14:08:21 zmatt: Turned out that the reason USB wasn't working on that custom board I asked for help on was due to usb0 needing to be set to host mode rather than peripheral in am335x-bone-common.dtsi - I finally got the information from the board vendor. Jun 12 14:08:55 outrageous_: that should _not_ be set in am335x-bone-common.dtsi. your board is not bbb-compatible, make a custom dts Jun 12 14:09:12 (or overlay) Jun 12 14:09:44 it doesn't have to be fancy, but you should override that property in your custom definitions, not modify "am335x-bone-common.dtsi" which is common to all beaglebone models Jun 12 14:10:07 zmatt: Yes, you are right. This was the quick solution the vendor suggested. Jun 12 14:31:00 in other words, the vendor is an idiot :P Jun 12 14:40:42 good lord Jun 12 14:40:46 dwc2 is a nightmare Jun 12 14:41:07 lol Jun 12 14:41:38 i can't even find a leak of the docs. Jun 12 14:43:49 zmatt: Can't disagree with you on that. Would have saved me some tens of hours if it had been done properly with the Debian 8 image that came on the eMMC. Jun 12 14:44:13 But it has at least caused me to learn something. Jun 12 14:48:26 yeah if they used an overlay or custom dtb, it would have been immediately clear Jun 12 14:48:50 if they used an overlay, you probably also could have copy-pasted that to the new image and be pretty much done Jun 12 14:50:51 Yes, exactly. **** ENDING LOGGING AT Thu Jun 13 02:59:57 2019