Did you start with an image that came with 3,8 kernel? The config-pin tool 
has changed a lot due to changes in the device tree overlay. The config-pin 
tool hosted on Charles GitHub repo does not do the right thing, make sure 
to stick with the one that ships with the distro.

Am Mittwoch, 11. Oktober 2017 20:13:35 UTC+2 schrieb Dimitar Dobrev:
>
> Thank you for the tip, Bas. Unfortunately the BBB is not available right 
> now so I am forced to reply tomorrow.
>
> On Wednesday, October 11, 2017 at 8:49:31 PM UTC+3, Bas de Bruijn wrote:
>>
>>
>> On 11 Oct 2017, at 03:50, 'Dimitar Dobrev' via Machinekit <
>> [email protected]> wrote:
>>
>> Thank you for the tip. I followed the link which in turn leads to 
>> https://elinux.org/Beagleboard:BeagleBoneBlack_Debian#U-Boot_Overlays . 
>> I have so far followed the instructions up to:
>>
>> U-Boot /boot/uEnv.txt configuration
>> /boot/uEnv.txt:
>>
>> enable_uboot_overlays=1
>>
>>
>> I keep getting the same error. Do I need to complete all steps? Up to 
>> where, "Debian Build Instructions"? Please help.
>>
>>
>> what does the following say?
>> grep -c bone_capemgr.uboot_capemgr_enabled=1 /proc/cmdline
>>
>>
>>
>>
>> On Tuesday, October 10, 2017 at 7:54:27 AM UTC+3, Bas de Bruijn wrote:
>>>
>>>
>>>
>>> On 9 Oct 2017, at 23:14, 'Dimitar Dobrev' via Machinekit <machi...@
>>> googlegroups.com> wrote:
>>>
>>> Hello Alexander,
>>>
>>> Thank you very much for your help. It allowed me to get further.
>>> I ran the script and restarted the machine. Now "uname -a" gives me the 
>>> following:
>>>
>>> Linux beaglebone 4.4.90-ti-rt-r132 #1 SMP PREEMPT RT Sat Oct 7 02:00:37 
>>> UTC 2017 armv7l GNU/Linux
>>>
>>> So everything went fine. I then reinstalled the package for machinekit. 
>>> Now I get this message in the terminal:
>>>
>>> grep: /sys/devices/bone_capemgr.*/slots: No such file or directory
>>> bash: /sys/devices/bone_capemgr.*/slots: No such file or directory
>>> Error loading device tree overlay file: cape-universal
>>> CRAMPS.hal:10: program './setup.sh' failed, returned 1
>>>
>>>
>>> See this comment from Robert:
>>>
>>> https://github.com/machinekit/Machinekit-HAL/issues/17#issuecomment-324726740
>>>
>>> I have also attached my new log.
>>> My guess is that I need to somehow load these bone_capemgr devices. I 
>>> have found https://elinux.org/Capemgr but it advises to manually load 
>>> them. Would there be any way to automatically load them?
>>>
>>> On Monday, October 9, 2017 at 4:56:17 PM UTC+3, Alexander Rössler wrote:
>>>>
>>>> Hi Dimitar,
>>>>
>>>> Here are some things that will help you with the Stretch image:
>>>>
>>>> ### 3. Install PREEMPT_RT kernel
>>>>
>>>> ```bash
>>>> cd /opt/scripts/tools/
>>>> sudo su
>>>> git pull
>>>> ./update_kernel.sh --ti-rt-channel --lts-4_4
>>>> ```
>>>>
>>>> ### 4. Setup UIO
>>>>
>>>> Old bootloader on eMMC might cause conflicts.
>>>>
>>>> ```bash
>>>> sudo dd if=/dev/zero of=/dev/mmcblk1 count=1 seek=1 bs=128k
>>>> ```
>>>>
>>>> In `/boot/uEnv.txt` change:
>>>> ```
>>>> ###Disable auto loading of virtual capes (emmc/video/wireless/adc)
>>>> #disable_uboot_overlay_emmc=1
>>>> disable_uboot_overlay_video=1
>>>> disable_uboot_overlay_audio=1
>>>> disable_uboot_overlay_wireless=1
>>>> #disable_uboot_overlay_adc=1
>>>> ```
>>>>
>>>> ### Install Machinekit - arceye version
>>>> ```bash
>>>> su -c 'echo "deb http://deb.mgware.co.uk/ stretch main" >> 
>>>> /etc/apt/sources.list.d/mgware.list'
>>>> wget -O /tmp/[email protected] 
>>>> http://deb.mgware.co.uk/[email protected] 
>>>> sudo apt-key add /tmp/[email protected]
>>>> sudo apt-get update
>>>> ```
>>>>
>>>> You may need to run machinekit with FLAVOR=rt-preempt.
>>>>
>>>> Cheers,
>>>> Alexander
>>>>
>>>>
>>>>
>>>> Am Montag, 9. Oktober 2017 15:34:04 UTC+2 schrieb Dimitar Dobrev:
>>>>>
>>>>> My packages are from:
>>>>>
>>>>> http://deb.mgware.co.uk/
>>>>>
>>>>> They are for POSIX and rt-preempt only.
>>>>> About the index, I actually don't have iio:device0 under 
>>>>> /sys/bus/iio/devices/ 
>>>>> so that's the problem.
>>>>> I could try changing the kernel on my existing installation, I hope 
>>>>> it's possible. Another option would be to build Machinekit from source 
>>>>> for 
>>>>> Stretch. Do you think it's possible?
>>>>>
>>>>> On Monday, October 9, 2017 at 4:25:15 PM UTC+3, Schooner wrote:
>>>>>>
>>>>>>
>>>>>> On 09/10/17 12:57, 'Dimitar Dobrev' via Machinekit wrote:
>>>>>>
>>>>>> I created /usr/lib/linuxcnc/xenomai and copied pru_generic.bin there. 
>>>>>> After trying again I got:
>>>>>>
>>>>>> Traceback (most recent call last):
>>>>>>   File "/usr/bin/hal_temp_bbb", line 198, in <module>
>>>>>>     checkAdcInput(pin)
>>>>>>   File "/usr/bin/hal_temp_bbb", line 156, in checkAdcInput
>>>>>>     pin.filename = tempName[0]
>>>>>> IndexError: list index out of range
>>>>>>
>>>>>>
>>>>>> This is not an error linked to pru_generic.bin AFAIK, but you need 
>>>>>> someone who knows about BBB.
>>>>>>
>>>>>> If it is saying that an index of 0 is out of range, 
>>>>>> you need to look at what it is trying to do and work out how it can 
>>>>>> be empty.
>>>>>>
>>>>>> https://github.com/machinekit/machinekit/blob/master/src/hal/user_comps/hal_temp_bbb.py#L156
>>>>>>
>>>>>>
>>>>>> In case the pru_generic.bin for rt-preempt cannot work in xenomai, 
>>>>>>
>>>>>>
>>>>>> The pru_generic.bin is identical for all kernel flavours so you can 
>>>>>> just copy it across
>>>>>>
>>>>>> The rt-preempt component modules may work with xenomai, there has 
>>>>>> been discussion as to whether they are actually different, 
>>>>>> but the bigger problem is that you will lack ulapi_xenomai.so and 
>>>>>> rtapi_app_xenomai.
>>>>>>
>>>>>> There are no xenomai packages for Stretch either, as Stretch is on 
>>>>>> Xenomai3, which does not work with Machinekit
>>>>>> I assume you have manually installed the Jessie ones?
>>>>>>
>>>>>> I suggest you read this thread
>>>>>> https://groups.google.com/forum/#!topic/machinekit/RrNLUo4ASP4
>>>>>> and contact Darren or one of the others to find where you can 
>>>>>> download an image with the rt-preempt kernel, 
>>>>>> or even just the kernel, modules etc and install it into your 
>>>>>> existing image
>>>>>>
>>>>>> do I correctly understand that switching from xenomai to rt-preempt 
>>>>>> on an existing installation is impossible and I need to install a new 
>>>>>> image 
>>>>>> instead?
>>>>>>
>>>>>> On Saturday, October 7, 2017 at 5:06:38 PM UTC+3, Schooner wrote:
>>>>>>>
>>>>>>> I don't use a BBB, it looks like Debian only provide i386 and amd64 
>>>>>>> rt-preempt kernels for Stretch.
>>>>>>>
>>>>>>> I don't know which rt kernel others have used, probably one from here
>>>>>>>
>>>>>>> https://elinux.org/Beagleboard:BeagleBoneBlack_Debian#Mainline_.284.14.x_lts.29
>>>>>>>
>>>>>>> The one I used on my server is 4.4.68-ti-rt-r112, but there are 
>>>>>>> probably newer ones.
>>>>>>> Looks like linux-image-4.9.40-bone-rt-r7 is quite new, the BBG 
>>>>>>> people have to use rt-preempt I believe to get everything working.
>>>>>>>
>>>>>>> Someone should be able to give you a link
>>>>>>> In fact if you have a root around here 
>>>>>>> https://rcn-ee.com/rootfs/bb.org/testing/
>>>>>>> you may find an image which suits
>>>>>>>
>>>>>>> rt-preempt kernels are quite easy to build, I have even built one on 
>>>>>>> a 4 core aarm64, but that has much more processing power
>>>>>>> than a BBB, might take quite a while on a BBB
>>>>>>>
>>>>>>> Is there any reason why you have to use a BBB at all?
>>>>>>> Life is much simpler with a proper computer ;\
>>>>>>>
>>>>>>> On 07/10/17 14:39, 'Dimitar Dobrev' via Machinekit wrote:
>>>>>>>
>>>>>>> Schooner, thank you very much for all of your help. I am definitely 
>>>>>>> going to try it. Would you have some directions about the switch to 
>>>>>>> rt-preempt? Do I need to compile it from source code or is it just a 
>>>>>>> matter 
>>>>>>> of installing packages?
>>>>>>>
>>>>>>> On Saturday, October 7, 2017 at 4:25:21 PM UTC+3, Schooner wrote:
>>>>>>>>
>>>>>>>> In that case, get hold of the rt-preempt kernel from Stretch and 
>>>>>>>> use that.
>>>>>>>>
>>>>>>>> Then you will be able to install machinekit-rt-preempt for 
>>>>>>>> stretch-armhf from my repo and it should work, with the pru_* binaries 
>>>>>>>> built and
>>>>>>>> symlinked to the /usr/lib/linuxcnc/rt-preempt directory where they 
>>>>>>>> can be found by hal_pru_generic
>>>>>>>>
>>>>>>>> Xenomai is becoming of lessening importance, as the rt-preempt 
>>>>>>>> kernel latency improves.
>>>>>>>> Because the BBB uses the PRU for step generation etc, all that is 
>>>>>>>> required is a stable servo thread which rt-preempt should be able to 
>>>>>>>> provide.
>>>>>>>>
>>>>>>>> Bas is already using rt-preempt on his BBB, as has Charles.
>>>>>>>> The reason for the recent commit to make pru_generic.* available to 
>>>>>>>> all armhf kernel flavours, was to allow this, without the user having 
>>>>>>>> to 
>>>>>>>> kludge
>>>>>>>> together symlinks or copy the binaries from another install.
>>>>>>>>
>>>>>>>> Be aware there will be a major change to the libczmq and libzeromq 
>>>>>>>> dependencies in a few days.
>>>>>>>> The packages as they are now will work together, but if you upgrade 
>>>>>>>> at a later date, you will probably need to remove all packages and 
>>>>>>>> re-install
>>>>>>>> to get the correct deps.
>>>>>>>>
>>>>>>>> Good luck
>>>>>>>>
>>>>>>>> On 07/10/17 14:05, 'Dimitar Dobrev' via Machinekit wrote:
>>>>>>>>
>>>>>>>> I have used Stretch for the following reason:
>>>>>>>> I need to run a Qt application built with 
>>>>>>>> https://github.com/qtquickvcp/QtQuickVcp on the BBB itself. I had 
>>>>>>>> to therefore build QtQuickVcp for that BBB which in turn meant I 
>>>>>>>> needed to 
>>>>>>>> build Qt itself for it. After multiple attempts to do so failed, I 
>>>>>>>> discovered 
>>>>>>>> http://software-dl.ti.com/processor-sdk-linux/esd/AM335X/latest/index_FDS.html
>>>>>>>>  . The problem with it is that it contains Qt 5.7.1 while the Qt 
>>>>>>>> from packages on Debian Jessi is 5.3.2. So when I compiled my 
>>>>>>>> application 
>>>>>>>> it could not run on the BBB. So I upgraded the BBB to use Stretch 
>>>>>>>> where the 
>>>>>>>> Qt from packages is 5.7.1 as well. I tried using the same Qt from this 
>>>>>>>> SDK 
>>>>>>>> on the BBB but I kept getting an error while starting up that the 
>>>>>>>> wayland 
>>>>>>>> plug-in could not be found.
>>>>>>>> I would deeply appreciate any suggestions to improve the above 
>>>>>>>> configuration.
>>>>>>>>
>>>>>>>> On Saturday, October 7, 2017 at 1:06:47 PM UTC+3, Schooner wrote:
>>>>>>>>>
>>>>>>>>> Thanks for the extra info, that makes things clearer
>>>>>>>>> You have installed an old Xenomai2 kernel onto Stretch
>>>>>>>>> My testing repo for Stretch does not contain any packages for 
>>>>>>>>> Xenomai and so you appear to have installed machinekit-rt-preempt 
>>>>>>>>> instead
>>>>>>>>> So when machinekit looks for the pru_generic.bin file, based upon 
>>>>>>>>> the kernel in use, it does not find it and you get this error
>>>>>>>>> Oct  6 23:33:14 beaglebone rtapi:0: 1:rtapi_app:10176:user 
>>>>>>>>> hal_pru_generic: cant find /usr/lib/linuxcnc/xenomai/pru_generic.bin 
>>>>>>>>> in 
>>>>>>>>> /home/machinekit/CRAMPS or /lib/firmware/pru/
>>>>>>>>> Oct  6 23:33:14 beaglebone rtapi:0: 1:rtapi_app:10176:user hpg: 
>>>>>>>>> ERROR: failed to initialize PRU
>>>>>>>>> So use the official, supported image and all will work and leave 
>>>>>>>>> you free to do whatever you intended with the board,
>>>>>>>>> rather than mess around trying to get the wrong packages working 
>>>>>>>>> on the wrong kernel.
>>>>>>>>> Use the Jessie SD card image from Robert Nelsons site ( as 
>>>>>>>>> indicated in the 'Getting Started' section of the docs)
>>>>>>>>> There is no reason to use Stretch and currently many reasons not 
>>>>>>>>> to, which is why we are working using an unofficial testing repo at 
>>>>>>>>> present.
>>>>>>>>> Anything there may or may not work and is subject to change or 
>>>>>>>>> removal without notice.
>>>>>>>>>
>>>>>>>>> regards
>>>>>>>>>
>>>>>>>>> On 07/10/2017 02:03, 'Dimitar Dobrev' via Machinekit wrote:
>>>>>>>>>
>>>>>>>>> Kernel:
>>>>>>>>>
>>>>>>>>> Linux beaglebone 3.8.13-xenomai-r83 #1 Wed Jan 4 23:10:15 UTC 2017 
>>>>>>>>> armv7l GNU/Linux
>>>>>>>>>
>>>>>>>>> Packages from:
>>>>>>>>>
>>>>>>>>> http://deb.mgware.co.uk/
>>>>>>>>>
>>>>>>>>> Log:
>>>>>>>>>
>>>>>>>>> Attached.
>>>>>>>>>
>>>>>>>>> I already have pru_generic.bin:
>>>>>>>>>
>>>>>>>>> /usr/lib/linuxcnc/rt-preempt/pru_generic.bin
>>>>>>>>> /usr/lib/linuxcnc/prubin/pru_generic.bin
>>>>>>>>>
>>>>>>>>> Please let me know if you need anything else.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Thursday, October 5, 2017 at 1:46:48 PM UTC+3, Schooner wrote:
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 05/10/17 10:55, 'Dimitar Dobrev' via Machinekit wrote:
>>>>>>>>>>
>>>>>>>>>> Hello all,
>>>>>>>>>>
>>>>>>>>>> My name is Dimitar Dobrev. I work as an application programmer 
>>>>>>>>>> and I have tried using CRAMPS. I have encountered an error I would 
>>>>>>>>>> like to 
>>>>>>>>>> ask for your help about.
>>>>>>>>>> I have a BeagleBone Black with Debian Stretch. 
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> kernel?  kernel version? git version of Machinekit? etc. etc.
>>>>>>>>>>
>>>>>>>>>> I need to start Machinekit on to connect to a real machine. I 
>>>>>>>>>> started run.py and got one error which I solved but I am now stuck 
>>>>>>>>>> at:
>>>>>>>>>>
>>>>>>>>>> CRAMPS.hal:28: insmod failed, returned -1;
>>>>>>>>>> rtapi_app_main(hal_pru_generic): -1 Operation not permitted
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> What is the rest of the error output (/var/log/linuxcnc.log or 
>>>>>>>>>> dmesg if it caused a segfault)
>>>>>>>>>> insmod errors are rather vague and can be from several causes.
>>>>>>>>>>
>>>>>>>>>> Try running with 'DEBUG=5 preceding the machinekit command and 
>>>>>>>>>> change the inifile 'debug = ' stanza to a higher number 
>>>>>>>>>> if you don't get a cause printed.
>>>>>>>>>> Make sure you have rsyslogd running to log output
>>>>>>>>>>
>>>>>>>>>> If you are running an older pull of machinekit, on a rt_preempt 
>>>>>>>>>> kernel, it won't have my recent
>>>>>>>>>> commits which make pru_generic.bin etc available
>>>>>>>>>>
>>>>>>>>>> https://github.com/machinekit/machinekit/commit/a6ac2576fc9a7f9d8a9a3f0e9da0eb244b8336d3
>>>>>>>>>>
>>>>>>>>>> That is one possibility, but impossible to say with this little 
>>>>>>>>>> info.
>>>>>>>>>>
>>>>>>>>>> My Machinekit is installed from packages rather than built from 
>>>>>>>>>> source. 
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Where did you get the packages?
>>>>>>>>>>
>>>>>>>>>> There is no official support for Stretch yet.
>>>>>>>>>>
>>>>>>>>>> The only packages for Stretch are in my unofficial repo.
>>>>>>>>>> They HAVE been tested on a BBB and work
>>>>>>>>>>
>>>>>>>>>> I have been able to find 
>>>>>>>>>> https://groups.google.com/forum/#!msg/machinekit/RrNLUo4ASP4/840ireJEBgAJ
>>>>>>>>>>  and 
>>>>>>>>>> https://groups.google.com/forum/#!topic/machinekit/qncQ_Dh7V9sbut 
>>>>>>>>>> I haven't been able to find a solution there. Any direction you can 
>>>>>>>>>> give me 
>>>>>>>>>> will be both useful and appreciated.
>>>>>>>>>> Thank you for your time.
>>>>>>>>>>
>>>>>>>>>> Dimitar Dobrev,
>>>>>>>>>> https://gitlab.com/ddobrev/QtSharp
>>>>>>>>>> -- 
>>>>>>>>>> website: http://www.machinekit.io blog: http://blog.machinekit.io
>>>>>>>>>>  github: https://github.com/machinekit
>>>>>>>>>> --- 
>>>>>>>>>> You received this message because you are subscribed to the 
>>>>>>>>>> Google Groups "Machinekit" group.
>>>>>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>>>>>> send an email to machinekit+...@googlegroups. 
>>>>>>>>>> <http://googlegroups.com/>com <http://googlegroups.com/>.
>>>>>>>>>> Visit this group at https://groups.google.com/group/machinekit.
>>>>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> -- 
>>>>>>>>> website: http://www.machinekit.io blog: http://blog.machinekit.io 
>>>>>>>>> github: https://github.com/machinekit
>>>>>>>>> --- 
>>>>>>>>> You received this message because you are subscribed to the Google 
>>>>>>>>> Groups "Machinekit" group.
>>>>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>>>>> send an email to machinekit+...@googlegroups. 
>>>>>>>>> <http://googlegroups.com/>com <http://googlegroups.com/>.
>>>>>>>>> Visit this group at https://groups.google.com/group/machinekit.
>>>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> -- 
>>>>>>>> website: http://www.machinekit.io blog: http://blog.machinekit.io 
>>>>>>>> github: https://github.com/machinekit
>>>>>>>> --- 
>>>>>>>> You received this message because you are subscribed to the Google 
>>>>>>>> Groups "Machinekit" group.
>>>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>>>> send an email to machinekit+...@googlegroups. 
>>>>>>>> <http://googlegroups.com/>com <http://googlegroups.com/>.
>>>>>>>> Visit this group at https://groups.google.com/group/machinekit.
>>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>>
>>>>>>>>
>>>>>>>> -- 
>>>>>>> website: http://www.machinekit.io blog: http://blog.machinekit.io 
>>>>>>> github: https://github.com/machinekit
>>>>>>> --- 
>>>>>>> You received this message because you are subscribed to the Google 
>>>>>>> Groups "Machinekit" group.
>>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>>> send an email to machinekit+...@googlegroups. 
>>>>>>> <http://googlegroups.com/>com <http://googlegroups.com/>.
>>>>>>> Visit this group at https://groups.google.com/group/machinekit.
>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>
>>>>>>>
>>>>>>> -- 
>>>>>> website: http://www.machinekit.io blog: http://blog.machinekit.io 
>>>>>> github: https://github.com/machinekit
>>>>>> --- 
>>>>>> You received this message because you are subscribed to the Google 
>>>>>> Groups "Machinekit" group.
>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>> send an email to machinekit+...@googlegroups. 
>>>>>> <http://googlegroups.com/>com <http://googlegroups.com/>.
>>>>>> Visit this group at https://groups.google.com/group/machinekit.
>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>
>>>>>>
>>>>>> -- 
>>> website: http://www.machinekit.io blog: http://blog.machinekit.io 
>>> github: https://github.com/machinekit
>>> --- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Machinekit" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to [email protected].
>>> Visit this group at https://groups.google.com/group/machinekit.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>> <linuxcnc.log>
>>>
>>>
>> -- 
>> website: http://www.machinekit.io blog: http://blog.machinekit.io github:
>>  https://github.com/machinekit
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "Machinekit" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> Visit this group at https://groups.google.com/group/machinekit.
>> For more options, visit https://groups.google.com/d/optout.
>>
>>
>>
>

-- 
website: http://www.machinekit.io blog: http://blog.machinekit.io github: 
https://github.com/machinekit
--- 
You received this message because you are subscribed to the Google Groups 
"Machinekit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
Visit this group at https://groups.google.com/group/machinekit.
For more options, visit https://groups.google.com/d/optout.

Reply via email to