If anyone stumbles upon this thread - the attached script will allow init.d 
to start the PRU at boot time which the new pru_rproc driver doesn't seem 
to do. In debian 8.7 with 4.4 kernels, it needed a reboot once the kernel 
module had loaded because of a bug creating the rpmsg entry in /dev. I've 
modified my pru-rebooting script to instead start the PRU.

Configure the script to start with the following:

1. Copy script to /etc/init.d

2. chmod 755 script

3. sudo update-rc.d start-pru.sh defaults




On Tuesday, 28 May 2019 17:36:09 UTC+1, Hugh Frater wrote:
>
> Fixed it...
>
> sudo sh -c "echo 'start' > state" from within 
> /sys/devices/platform/ocp/4a326004.pruss-soc-bus/4a300000.pruss/4a338000.pru/remoteproc/remoteproc2
>
>
>
> On Tuesday, 28 May 2019 17:25:44 UTC+1, Hugh Frater wrote:
>>
>> My takeaway from Mark's excellent writeup is that I should be able to 
>> copy my .out file into /lib/firmware with the correct naming convention.
>>
>> I should then be able to echo 'start' or 'stop' to the correct state 
>> file. Which seems to be located at:
>>
>> debian@beaglebone:/sys/devices/platform/ocp/4a326004.pruss-soc-bus/4a300000.pruss/4a338000.pru/remoteproc/remoteproc2$
>>  
>> cat state
>> offline
>>
>> For PRU1
>>
>> Hmmm.... 
>>
>> On Tuesday, 28 May 2019 17:00:04 UTC+1, Hugh Frater wrote:
>>>
>>> Reading it now, I'll be back... Cheers for all your help up till now
>>>
>>> On Tuesday, 28 May 2019 16:53:47 UTC+1, RobertCNelson wrote:
>>>>
>>>> On Tue, May 28, 2019 at 10:41 AM Hugh Frater <[email protected]> 
>>>> wrote: 
>>>> > 
>>>> > Tried both those fixes Robert, no joy. Is it still acceptable 
>>>> practice to symlink am335x-pru1-fw to our .out file? 
>>>> > 
>>>> > Google led me to this post: 
>>>> > 
>>>> > 
>>>> http://e2e.ti.com/support/processors/f/791/t/783113?Linux-AM3358-remoteproc-remoteproc0-Direct-firmware-load-for-tmp-PRU-LED1-out-failed-with-error-2
>>>>  
>>>> > 
>>>> > Where the OP had a fix which involved echo'ing the path of the PRU 
>>>> binary from /lib/firmware into /sys/class/remoteproc/remoteproc2/firmware. 
>>>> I've tried that also... 
>>>> > 
>>>> > Have things changed in the move to 4.14 and uBoot overlays or should 
>>>> the old ways still work? 
>>>>
>>>> Take a look at Mark's writeup: 
>>>>
>>>> https://markayoder.github.io/PRUCookbook/ 
>>>>
>>>> Regards, 
>>>>
>>>> -- 
>>>> Robert Nelson 
>>>> https://rcn-ee.com/ 
>>>>
>>>

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/af2622b2-bfb7-491b-aa29-bfee763d0aff%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
#!/bin/bash

### BEGIN INIT INFO
# Provides:          start-pru
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: start-pru
# Description:       Starts PRU1 after boot
#                      

### END INIT INFO

# Author: Hugh Frater <[email protected]


DESC="start-pru"

echo 'start' > /sys/class/remoteproc/remoteproc2/state

Reply via email to