== USB Support == The [wiki:WikiStart Cardinal 825] supports many USB devices such as Flash Drives, Printers (Cardinal supported only!), keyboards, and mice. === USB Mass Storage === The 825 supports USB flash storage devices formatted with the FAT (file allocation table) and FAT32 file systems. From the serial command line when a USB storage device is inserted the display will appear similar to: [[Image(usb_insert.jpg)]] Use the mount command to access files on the USB flash drive: {{{ mount –t vfat /dev/sda1 /mnt/fl1 }}} The files will then appear in the path /mnt/fl1 such as: [[Image(usb_mount.jpg)]] The file manager may be used to access USB flash drives. When the /mnt/fl1 folder is selected the file manager will automatically perform the mount command. [[Top]] === USB Keyboards === As of kernel 2008-11-13 many USB keyboards should work with the 825. Simply plug the keyboard into an 825 USB connection. [[Image(usb_keyboard.jpg)]] Applications using the lib825 functions such as [[lib825:source:trunk/kypdbeep.cpp#L78 ReadKeypad]] or [[lib825:source:trunk/form.cpp#L1027 FormLCD] will automatically work with the USB keyboard. To test the keyboard without any app running type some characters on the keyboard and type: {{{ # cat /dev/usbkybd }}} Output: [[Image(usb_keyboard_test.jpg)]] The characters typed on the USB keyboard should show on the serial port terminal. [[Top]] === USB Printing === usblp.ko device driver module for usb printing support. Type: {{{ # modprobe usblp }}} Kernel should be configured with /dev/usblp0 device node. If not type: {{{ # mknod /tmp/usblp0 c 180 0 }}} ''/dev is in read-only file system so device node can be created under /tmp instead'' This creates the character device driver with major number 180 and minor number 0. This should work unmodified with USB printers that accept raw text for printing using a default font. A simple test is: {{{ # echo “ABCDEFGH” > /dev/usblp0 '''or''' # echo “ABCDEFGH” > /tmp/usblp0 }}} ''Applications may be written to open “/dev/usblp0” to print to USB printer 0 instead of “/dev/ttyS1” to open COM2'' ==== Successful Tests ==== * Okidata Microline 320 Turbo - ''Older versions of this printer do not have USB port'' * Hewlett Packard !DeskJet 830C - ''Does not print page until filled so extra line feeds are required to fill the page to finish the print'' ==== Currently Developing ==== * HP !LaserJet P1020 ==== Unsuccessful ==== * HP !LaserJet P1006 - ''Research indicates this printer requires host to send firmware update file to printer, and does not accept raw text but requires XQX stream protocol'' [[Top]] === USB to PC communications === To load the driver for USB to PC communications type: {{{ # modprobe g_serial use_acm=1 }}} When the 825 is connected to the PC it will be recognized by the PC and if the driver is not already installed it will prompt for it. Refer to “gadget_serial.txt” When the driver is installed the PC will appear to have another COM port. For testing on the PC you can then open a communications program such as HyperTerminal and set it to the appropriate COM port (which is actually a USB connection). On the serial connection to the indicator type: {{{ # echo “abcdefg” > /dev/ttygserial }}} “abcdefg” will then appear on the Hyperterm display. In HyperTerminal, type: {{{ 123456 }}} On the serial connection to the indicator type: {{{ # cat < /dev/ttygserial }}} The received characters “123456” from the PC will then be displayed. [[Top]]