**** BEGIN LOGGING AT Sun Oct 02 02:59:58 2016 Oct 02 16:05:29 Has anyone herein used the TI 15.4-Stack Linux® Gateway Example Application? They used a BBB as a host system and a CC1310 kit running TI RTOS Oct 02 16:16:31 hello Oct 02 16:28:27 GenTooMan: I'm using the native linux stack with 6lowpan and a AT96RF231 as the RF frontend Oct 02 17:24:14 hello so i have this installed on my BBB http://elinux.org/BeagleBoardUbuntu Oct 02 17:24:37 but when trying to install a snap i am getting an error saying the kernal needs patched to support apparmor Oct 02 17:24:42 and suggestions? Oct 02 17:24:56 any suggestions? Oct 02 17:31:27 im getting this Failed to start LSB: AppArmor initialization Oct 02 17:42:32 johnorjias: if you want to play with snappy, use one of the ubuntu snappy images Oct 02 17:43:09 otherwise you'll need to rebuild the kernel on another computer Oct 02 17:43:18 there is no snappy core image for BBB for 16.04, well not that i found Oct 02 17:44:54 ok So i do need to do the apparmore patch then? i just wanted to be sure before i spend to much time researchign this, beings a lot of things said the ubuntu kernals should already be patched for it by now Oct 02 17:47:17 do have someone experience with python gpio inputs on BBB? Oct 02 17:48:04 I would like to use all ports on header P8 as inputs, but I have some GPIO on high level without connected anything Oct 02 17:49:01 karsoft: when nothing is connected the level will be determined by the pull-up/down resistors Oct 02 17:49:26 these are configurable in DT and the defaults vary per pin Oct 02 17:49:45 I tried do GPIO.setup("P8_3", GPIO.IN, pull_up_down=GPIO.PUD_DOWN) or GPIO.setup("P8_3", GPIO.IN, pull_up_down=GPIO.PUD_UP) Oct 02 17:49:54 but everytime is High Oct 02 17:50:02 when i connect ground, it goes to 0 Oct 02 17:50:47 on port P8_05 is in low and when i connect 3,3V its high Oct 02 17:50:47 you should not configure internal pull-downs on pins normally used for eMMC since those have external pull-up/down Oct 02 17:51:07 ditto for pins 31-46 of P8 Oct 02 17:51:50 I have disabled eMMC and HDMI Oct 02 17:51:57 I boot from SD Oct 02 17:53:03 I would like to use P8_03-P8_26 as inputs for buttons and P8_27-P8_46 as outpus for relay Oct 02 17:53:06 that doesn't matter. in general if you're going to use pins as inputs, make sure they are externally driven or pulled with sufficiently low resistance Oct 02 17:54:35 so connect P8_03 to GND by 1kOhm resitor and than use 3.3V to conntrol state of GPIO? Oct 02 17:55:23 the eMMC pins actually have 10K pull-ups. I would suggest not fighting it and just connecting the buttons between pin and GND Oct 02 17:55:47 if you want you can have the kernel implicitly invert signals by marking them as active-low Oct 02 17:56:27 you mean to compile own kenerl? Oct 02 17:56:31 no Oct 02 17:57:23 it's just a sysfs attribute of the gpio, so if the python wrapper doesn't support it yet then it would be trivial to add such support Oct 02 17:57:56 I dont want to mix port GND and 3.3V, because I am going to use BBB as "smart" controll of lights in my house and I will be confusing to have some buttons controled by ground and some by 3.3V Oct 02 17:58:35 well it's far more common to connect buttons to ground then to +3.3V (e.g. the three buttons on the BBB all connect to ground) Oct 02 17:58:59 *than Oct 02 18:00:49 is it some big difference to use 3.3V instead GND in buttons? Oct 02 18:01:08 e.g. interference etc...? Oct 02 18:02:21 I think it's more common to use ground since then you don't have to worry about power domains: an input of a device is always electrically okay with being pulled to ground Oct 02 18:02:43 e.g. the power button signal of the BBB is something you wouldn't be able to drive high since its supply is an internal one of the pmic Oct 02 18:03:21 ok, so i will reconnect all switches to ground instead 3.3V Oct 02 18:03:39 but there is still issue with state of inputs Oct 02 18:03:49 some ports are in low, some in high Oct 02 18:04:08 do you have please any idea, where I can find sysfs attribute? Oct 02 18:04:22 i am using python Oct 02 18:04:31 configuring as pull-up should actually work fine for P8.3-P8.30 Oct 02 18:04:40 they should all read high then when not connected Oct 02 18:04:44 in ?/sys/class/gpio/gpiochip Oct 02 18:04:51 in python Oct 02 18:06:28 I would recommend external pull-ups though, 1K or so. the internal pulls are very weak hence you'd very easily pick up noise Oct 02 18:06:58 I setup GPIO.setup("P8_3", GPIO.IN, pull_up_down=GPIO.PUD_UP) to GPIO.setup("P8_46", GPIO.IN, pull_up_down=GPIO.PUD_UP) Oct 02 18:07:07 that should work Oct 02 18:07:39 and after print ("P8_3", GPIO.input("P8_3")) to print ("P8_3", GPIO.input("P8_46")) Oct 02 18:08:05 I get ('P8_3', 1) ('P8_4', 1) ('P8_5', 0) ('P8_6', 0) ('P8_7', 1) ('P8_8', 1) ('P8_9', 1) ('P8_10', 1) ('P8_11', 0) ('P8_12', 0) Oct 02 18:08:26 that's odd Oct 02 18:08:46 can you check with my show-pins utility from https://github.com/mvduin/bbb-pin-utils what it says? Oct 02 18:08:56 sudo ./show-pins | sort Oct 02 18:09:20 ok i will try it Oct 02 18:09:21 btw how are you making sure the eMMC is disabled or held in reset? Oct 02 18:09:21 mmt Oct 02 18:09:43 i edit /boot/uenw.txt Oct 02 18:10:06 unless you really need all those pins I'd recommend avoiding the emmc clk pin (P8.21) Oct 02 18:10:07 and uncomment cape_disable=capemgr.disable_partno=BB-BONELT-HDMI,BB-BONELT-HDMIN,BB-BONE-EMMC-2G Oct 02 18:10:17 i am using debian image 7.11 Oct 02 18:10:26 that just makes linux not use the eMMC, it doesn't disable the eMMC itself Oct 02 18:10:30 i tried before last jessie Oct 02 18:10:42 and it was same Oct 02 18:10:42 ouch, ancient stuff Oct 02 18:12:02 ./show-pins: 6: ./show-pins: Syntax error: newline unexpected Oct 02 18:12:35 sorry my bad.. Oct 02 18:12:37 again.. Oct 02 18:14:03 the easiest way to avoid problems with eMMC is just by avoiding the use of the emmc clk pin. otherwise you need to make sure the eMMC reset signal is asserted (I think the dtb will take care of this in kernel 4.x, no idea in 3.8) Oct 02 18:14:27 and moreover enable this signal in the eMMC, which requires setting a one-time-programmable bit in the eMMC's internal configuration Oct 02 18:15:12 can i paste here output< Oct 02 18:15:14 ? Oct 02 18:15:25 no. use pastebin or some other paste service Oct 02 18:16:32 http://pastebin.com/NAtqfjxd Oct 02 18:17:57 looks like most eMMC pins are still muxed to emmc rather than gpio, and python ignored your request for pull-up Oct 02 18:18:37 do you think that last jessie will works better? Oct 02 18:19:24 well I strongly suggest it anyway since wheezy is _ancient_ Oct 02 18:19:52 ok i will halt BBB and reimage SD Oct 02 18:20:31 whether it works any better dunno, doing pin config requires an overlay or use of cape-universal... I know some libraries can deal with both but I don't know what python library you're using or what it does or doesn't support Oct 02 18:21:31 it's certainly not nice that the library pretend to give control over pull-up/down when it doesn't work, it should have given an error instead Oct 02 18:22:17 i am using https://pypi.python.org/pypi/Adafruit_BBIO/1.0.0 Oct 02 18:24:30 hello Oct 02 18:24:57 can i use beaglebone black as wifi repater Oct 02 18:25:03 ? Oct 02 18:25:55 karsoft: ah yes, that badly written silly library Oct 02 18:27:11 thank you ~@ Karsoft Oct 02 18:27:49 amh: the bbb doesn't have wifi Oct 02 18:28:46 sorry Oct 02 18:28:53 my conenction goes down Oct 02 18:29:16 did you wrote something after my url with Adafruid...? Oct 02 18:29:23 20:25 < zmatt> karsoft: ah yes, that badly written silly library Oct 02 18:29:42 do you some better? Oct 02 18:29:57 maybe thats only my issue Oct 02 18:29:58 I still don't get why they wrote it in C instead of pure Python, it's basically just read/writing files Oct 02 18:30:05 i am using wrong library Oct 02 18:30:10 no it's not "wrong" Oct 02 18:30:25 just... not very good, nor very efficient Oct 02 18:30:43 and implementing it in C just makes it unnecessarily opaque to python programmers Oct 02 18:30:50 i am using similar on RPi3 and there it works fine Oct 02 18:31:05 yeah it should work fine, mostly Oct 02 18:31:24 it has some shortcomings like not being able to configure a pin as initially-high output Oct 02 18:31:26 so do you have some recomendation to another one? Oct 02 18:32:01 well I don't use python nor would I even bother to use a library at all, so no Oct 02 18:33:12 I'd configure gpios using device tree, ensure they have appropriate permissions using udev, and after that you just read or write the file (sysfs node) representing the gpio's value Oct 02 18:33:22 I have to reboot, because i cant see SD card... will you be here in 5 minutes? Oct 02 18:33:42 my udev rule also makes convenient named symlinks, e.g. /dev/gpio/dsp-reset Oct 02 18:33:45 sure Oct 02 18:33:54 i dont thing, that i am able to make new device tree Oct 02 18:33:58 ok i am leaving Oct 02 18:48:33 intersting definition of 5 minute Oct 02 18:48:34 s Oct 02 18:52:00 i am back Oct 02 18:52:09 sorry damm windows update ... :(( Oct 02 18:53:47 lol Oct 02 18:54:03 so don't use windows Oct 02 18:54:15 so i am imaging sdcard to jessie Oct 02 18:54:44 njn, i have on second notebook debian, but I more offten use Windows Oct 02 18:55:20 after few minutes we will see, how it looks on jessie Oct 02 18:55:57 where are you from? is it not to late in your country? Oct 02 18:56:39 no, but I am about to head to work Oct 02 18:56:57 the netherlands Oct 02 18:57:17 we are allmost neigbourhs :) i am from czech Oct 02 18:57:57 hehe, with that radius of neighbourhood, you'll sure have a lot of neightbours Oct 02 18:58:04 *neighbours Oct 02 18:58:24 :)) yes Oct 02 18:59:32 I lost history of chat, so what you recomend to complete disable eMMC to use gpio? Or connect 1k resistor to ground? Oct 02 19:01:26 or make some DT with overlay? Oct 02 19:01:45 those are not things that make sense when connected with "or", they're all solutions to different problems Oct 02 19:02:23 for eMMC I recommend just leaving P8.21 unused Oct 02 19:03:15 OK, so I will not initialize as input P8.21 Oct 02 19:03:32 next connect all buttons to ground instead 3.3V? Oct 02 19:04:52 yeah, with 1K-10K pull-up near the beaglebone (optional for the pins 3-6, 20, and 22-25 since they already have 10K pull-up on the BBB) Oct 02 19:05:41 it doesn't really matter how P8.21 is initialized btw as long as the pin is not used Oct 02 19:06:24 I am not sure, if only one 1-10K is enought or each pin need rezistor. Oct 02 19:06:48 how exactly did you imagine using one resistor? Oct 02 19:07:19 (answer: yes I meant one resistor per pin) Oct 02 19:09:03 yes, you have right. I use only one resistor to 1-wire thermisotrs, but all are on one pin... Oct 02 19:09:09 it was silly question Oct 02 19:10:32 especially if you intend to connect long wires you might also want to consider a small capacitor to ground to suppress noise and EMI Oct 02 19:10:53 but that's icing on the cake I guess :P Oct 02 19:11:39 with external pulls present the internal ones aren't very important, but you might want to change them to pull-up or no-pull to avoid pointlessly wasting (a tiny amount of) energy Oct 02 19:12:34 that and configuring the pins to gpio function can be done in device tree (usually using an overlay) or by using cape-universal (enabled by default in jessie images) Oct 02 19:13:03 with some luck adafruit already understands how to use cape-universal though, so it might do it for you Oct 02 19:13:09 on debian 8.5 is it similar... 'P8_24', 1) ('P8_25', 1) ('P8_26', 1) ('P8_27', 0) ('P8_28', 0) ('P8_29', 0) Oct 02 19:14:28 check with show-pins ? Oct 02 19:14:45 could you provide me please again your website? Oct 02 19:14:52 https://github.com/mvduin/bbb-pin-utils Oct 02 19:15:17 btw for differences between 3.x and 4.x kernels there's http://elinux.org/Beagleboard:BeagleBone_Debian_Image_Migration Oct 02 19:15:37 it's still lacks a lot of essential info though Oct 02 19:16:36 http://pastebin.com/PpnDZbTy Oct 02 19:17:40 well they're configured as gpio, just the pull is wrong Oct 02 19:18:15 all are UP Oct 02 19:18:24 i can try DOWN Oct 02 19:18:29 nope, they're not Oct 02 19:18:38 as show-pins shows they're a mix of up and down Oct 02 19:19:12 i meant in my python Oct 02 19:19:26 so how can I make all them down or up? Oct 02 19:19:40 you can try complaining to the makers, but note that once you add external pull resistors the built-in ones will not have any real impact anymore anyway Oct 02 19:20:16 they're like 50-150KΩ or so (with a wide margin) Oct 02 19:20:31 so you can also just ignore it Oct 02 19:21:33 is better to use 1 od 10k? Oct 02 19:21:40 to each pin? Oct 02 19:22:02 doesn't hugely matter I think Oct 02 19:23:16 so i will connect each pin to ground with 1k, and after that I will connect GND from button to GPIO Oct 02 19:23:20 i am right? Oct 02 19:23:46 1K from pin to +3.3V Oct 02 19:23:46 and after that I will connect GND from button to GPIO trought switch Oct 02 19:23:59 ok Oct 02 19:24:19 otherwise the pin is pulled to ground which means nothing will happen if you use a connect to pull it to... ground Oct 02 19:24:25 *use a button Oct 02 19:26:56 in the fact, if I connect all gpio trought 1 or 10k to 3.3V, all will be on High and connectiong to GND by switch/button will goes low and I will detect it in my python Oct 02 19:28:12 I thing there is max drain 50mA, so it will be better to use more than 1k to not reach the maximum drain Oct 02 19:29:22 and little capaciton near button and GND to avoid interference Oct 02 19:29:34 and it should be OK. Oct 02 19:29:40 cap near the beaglebone Oct 02 19:29:55 (not near the button) Oct 02 19:29:59 ok Oct 02 19:30:32 so thank you very much for you time and advice. I will try it on table and than on real circuit Oct 02 19:30:45 how long will the wires to buttons me? Oct 02 19:30:46 *be Oct 02 19:31:17 long... about 20-30m Oct 02 19:31:27 without shield Oct 02 19:31:33 is it only UTP not FTP Oct 02 19:31:39 and is near 230V Oct 02 19:31:40 ouch, I would definitely use a lot more protection than just a resistor and a cap then Oct 02 19:31:43 bad instalation Oct 02 19:32:20 Hey, does anyone know why I can't ssh over USB but can screen /dev/ttyACM0 perfectly .? Oct 02 19:32:33 if it runs near or parallel to 230V, especially if it is being switched, then you will definitely want serious protection on the inputs or you may very well risk damaging the processor Oct 02 19:33:12 Unee0x: evidently usb-network is not working right (due to configuration problems or otherwise) Oct 02 19:33:42 oops... any idea? some relay or photodiode...? Oct 02 19:34:50 karsoft: opto-couplers might not be a bad idea, although it might suffice to just use robust input buffers Oct 02 19:35:11 and/or transient voltage spike suppressors Oct 02 19:35:42 i have to google it what is mean Oct 02 19:36:05 zmatt: on a fresh install? Oct 02 19:36:32 Unee0x: which network manager do you use? Oct 02 19:36:40 (on your computer) Oct 02 19:37:00 zener diode... i could be... Oct 02 19:39:22 zmatt: cinnamon network manager Oct 02 19:41:20 zmatt: I've tried gnome network manager, but still no dice... Oct 02 19:41:38 never heard of it Oct 02 19:41:43 does the bbb show up on ip link ? Oct 02 19:43:18 zmatt: sure does, and it's up. Oct 02 19:43:40 karsoft: yeah or TVS diode Oct 02 19:45:08 at least you used twisted pair, that should help a lot already Oct 02 19:46:08 but the am335x is a fairly modern processor (40nm) which is nice for price/performance ratio but does mean it's really quite intolerant to overvoltage Oct 02 19:46:46 on RPi3 it works... even hotplate, owen or sunshades does not kill RPi, but I need more inputs Oct 02 19:47:25 I wouldn't expect the rpi series to be more tolerant Oct 02 19:48:09 maybe the use of twisted pair does a sufficiently good job of avoiding pickup of transients, but I personally wouldn't feel very comfortable relying on that alone Oct 02 19:50:03 maybe... so thanks again, you will help me very much. I will buy tomorow some resistors and i will try it to connect Oct 02 19:50:54 so good shift at work and i will know you, if i suceed Oct 02 19:51:10 good luck :) Oct 02 19:51:40 bye **** ENDING LOGGING AT Mon Oct 03 02:59:58 2016