Opening a Text File Via USB on a Flex Pendant

in RobotStudio
I'm currently working on a project where we have to read a text file in order to pull values out of cut lumber to stack. We are able to put the file on a usb and read it via the virtual flex pendant with the file location / path being
" VAR string File_Location:="F:/CutList(Test).TRS"; " Then calling it later with " Open File_Location,File\Read; "
However when it comes to opening it on the pendant through the USB port on it, we are having trouble. We've tried many different paths "USB" "RemovableDisk" ect. But we either get an error saying it can't find it, or errors opening it for some reason. Could it just be the wrong path, maybe wrong usb. Any help would be appreciated.
" VAR string File_Location:="F:/CutList(Test).TRS"; " Then calling it later with " Open File_Location,File\Read; "
However when it comes to opening it on the pendant through the USB port on it, we are having trouble. We've tried many different paths "USB" "RemovableDisk" ect. But we either get an error saying it can't find it, or errors opening it for some reason. Could it just be the wrong path, maybe wrong usb. Any help would be appreciated.
Tagged:
Comments
You can not access the USB on the FlexPendant from RAPID.
There used to be a USB port on the front of the controller but this was removed shortly after the introduction of the USB port on the FlexPendant.
You can purchase from ABB aftersales the USB connector for the front of the cabinet and connect this to one of the USB ports on the main computer (if you want access to the USB port without opening the controller door).
VAR dir Directory;
VAR string Filename;
VAR iodev PartFile;
!open the directory for reading
OpenDir Directory, usbdisk1;
WHILE ReadDir(Directory,Filename) DO
Load usbdisk1\File:=FileName;
!do other stuff as required
ENDWHILE
!Close directory
Close PartFile;
CloseDir Directory: