Hmm...looking at the code it appears the output pins have a conditional for the pin numbering fixup:
https://github.com/machinekit/machinekit/blob/master/src/hal/drivers/hal_bb_gpio/hal_bb_gpio.c#L365-L370 ...that's missing for the input pins: https://github.com/machinekit/machinekit/blob/master/src/hal/drivers/hal_bb_gpio/hal_bb_gpio.c#L272-L275 Combined with the legacy use of 1xx and 2xx for the BeagleBone pin numbers (which is why the fixup exists in the first place) it looks like that's breaking you pin numbering scheme. Can you try with just output pins and see if that works? On 5/20/2019 4:06 PM, markus wrote: > That actually is the problem - the driver takes the p1 and p2 pins and > uses them as p8 and p9 pins, this is the excerpt from the hal file that > I used: > > # load low-level drivers > loadrt hal_bb_gpio board=PocketBeagle input_pins=201,202,203,204 > output_pins=217,227,228,229,230,231,232 > loadrt [PRUCONF](DRIVER) prucode=$(HAL_RTMOD_DIR)/[PRUCONF](PRUBIN) > [PRUCONF](CONFIG) > > Same thing happens if I do it manually with halrun - and it complains > about the first pin in the command line, so if I remove 201 it > complains about 902 not being valid. > > > On Mon, 20 May 2019 15:55:37 -0500 > Charles Steinkuehler <[email protected]> wrote: > >> On 5/20/2019 3:36 PM, markus wrote: >>> Thanks for the clarification - much appreciated. >>> >>> It seems the driver is ignoring the parameter though. And I get the >>> same result. From linuxcnc.log: >> >> Look closer, it's not the same result. >> >>> May 20 00:07:37 pocketbeagle msgd:0: startup pid=1376 >>> flavor=rt-preempt rtlevel=1 usrlevel=1 halsize=524288 shm=Posix >>> cc=gcc 6.3.0 20170516 version=v0.1~-----~355496b May 20 00:07:37 >>> pocketbeagle msgd:0: ØMQ=4.2.1 czmq=4.0.2 protobuf=3.0.0 >>> atomics=gcc intrinsics libwebsockets=2.0.3 May 20 00:07:37 >>> pocketbeagle msgd:0: configured: sha=355496b May 20 00:07:37 >>> pocketbeagle msgd:0: built: Mar 14 2019 10:47:55 sha=355496b >>> May 20 00:07:37 pocketbeagle msgd:0: register_stuff: actual >>> hostname as announced by avahi='pocketbeagle.local' May 20 00:07:37 >>> pocketbeagle msgd:0: zeroconf: registering: 'Log service on >>> pocketbeagle.local pid 1376' May 20 00:07:38 pocketbeagle msgd:0: >>> zeroconf: registered 'Log service on pocketbeagle.local pid 1376' >>> _machinekit._tcp 49152 TXT >>> "uuid=4e7e123c-1726-4351-bdfc-eba93047fb35" >>> "instance=f2ce6258-7acd-11e9-aea4-606405e00475" "service=log" >>> "dsn=tcp://pocketbeagle.local:49152" May 20 00:07:39 pocketbeagle >>> rtapi:0: 1:rtapi_app:1381:user hal_bb_gpio: ERROR: invalid pin >>> number '901'. Valid pins are 101-136 and 201-236. >> >> The P8/P9 headers do not exist on the PocketBone. Try using legal pin >> numbers: 101-136 and 201-236 >> > -- Charles Steinkuehler [email protected] -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/machinekit/dcb35ed3-9316-5e5f-b6b8-2b914fcda8b2%40steinkuehler.net. For more options, visit https://groups.google.com/d/optout.
