debian: test images (2014-01-16)

Yeah I noticed that. I was hoping to go the ioctl route because I’m working on a cape that gives the option of RS232 or RS485 on UART4, so the runtime switching would be great.

Hopefully I’m just doing something stupid, but I can’t get it to work through ioctl. I’ve tried in both C and Python on an Angstrom image with 3.8, this testing image, and an old Angstrom with 3.2 on the original BB. The tests I’m trying are here: https://gist.github.com/alexanderhiam/8548894

On all three bones the C ioctl() call raise errno 25. On the two with 3.8 the Python ioctl() call raises ‘IOError: [Errno 25] Inappropriate ioctl for device’ and on the bone with 3.2 it raises ‘IOError: [Errno 22] Invalid argument’.

I was under the impression that you had to enable the RS485 ioctl settings when building the kernel, but I can’t remember where I got that idea and I haven’t actually tried it yet :stuck_out_tongue:

Perhaps I should start a new thread for this one…

-Alex

Hi,

About the RS485 support on the BBB, you have to modify the driver omap serial and control the gpio that you want. But if you want a quick solution, i already made a patch for that :slight_smile:

You just need to :

git clone git://github.com/RobertCNelson/linux-dev.git
cd linux-dev/
git checkout origin/am33x-v3.8 -b tmp

in the linux-dev folder, you have the KERNEL folder. You just need to put the file in the patches/omap folder and edit the patch.sh :
:

${git} “${DIR}/patches/omap/000X-omap-rs485-support.patch”

in the linux-dev folder :
cp system.sh.sample system.sh
edit the file system.sh:

be sure that you have :
##For TI: OMAP3/4/AM35xx
ZRELADDR=0x80008000 <== uncomment !

the correct path to your sdcard :
MMC=/dev/sdc

to build the kernel , you just need to use this command : ./build_kernel.sh

to install the new kernel to your sdcard : ./tools/install_kernel.sh

000X-omap-rs485-support.patch (8.81 KB)

No, apparently not! Once I configured the wifi for connman and restarted the service, it hung for a minute, then panic’d:

`
root@beaglebone:/var/lib/connman# systemctl restart connman.service

[15841.027741] INFO: task wpa_supplicant:515 blocked for more than 60 seconds.
[15841.035254] “echo 0 > /proc/sys/kernel/hung_task_timeout_secs” disables this message.
[15841.043567] wpa_supplicant D c045aae7 0 515 1 0x00000000
[15841.050462] Kernel panic - not syncing: hung_task: blocked tasks
[15841.056860] [] (unwind_backtrace+0x1/0x8a) from [] (panic+0x51/0x148)
[15841.065512] [] (panic+0x51/0x148) from [] (watchdog+0x14f/0x194)
[15841.073718] [] (watchdog+0x14f/0x194) from [] (kthread+0x67/0x74)
[15841.082011] [] (kthread+0x67/0x74) from [] (ret_from_fork+0x11/0x34)
[15841.090550] drm_kms_helper: panic occurred, switching back to text console

`

After rebooting, ethernet comes up, but the wifi doesn’t. According to syslog, it does try to authenticate but times out. This is a rtl8192cu based USB Wifi adapter (EDIMax), which I never have seen work reliably, so this many not be a connman issue.

-W.

Ah, that’s very helpful, thanks.

Ideally I was hoping to use the RTS signal though. From what I had read that seemed to be the standard for UART RS485 mode in the Linux kernel, but looking into the omap_serial driver it looks like it wasn’t implemented (on 3.8 at least).