Roboterforum Willkommen Gast. Bitte einloggen oder registrieren.
Haben Sie Ihre Aktivierungs E-Mail übersehen?
08. Februar 2012, 14:59:58
Übersicht Hilfe Suche Kalender Einloggen Registrieren
News: >> Roboterprogrammierer gesucht !? <<

Roboterforum für Industrieroboter Anwender  |  Industrieroboter Helpcenter  |  Mitsubishi Roboter (Moderatoren: Werner Hampel, Urmel)  |  Thema: Mitsubishi RM-501 0 Mitglieder und 1 Gast betrachten dieses Thema. « vorheriges nächstes »
Seiten: [1] Nach unten Drucken
Autor Thema: Mitsubishi RM-501  (Gelesen 3527 mal)
max666
Gast
« am: 09. Mai 2006, 16:25:20 »

meine deutch ist nicht gut Sad
es gibt keine antworten am englisch forum, so ich muss hier thema beginn
so:

I have been trying to use this old Mitsubishi for use with my object
detection software, but have problems with communication.

It works ok on a dos machine, but as i need to control the robot from
winXP (Borland Delphi), both serial and parallel port are problematic Sad

Serials seems to accept my commands but DTR and DSR seems not to work
becuse PC will send commands although the robot is still busy Sad

Have you had any luck? what software are you using for communication?
Gespeichert
Werner Hampel
Administrator
Forenjunkie
*****
Offline Offline

Geschlecht: Männlich
Beiträge: 1476



WWW
« Antworten #1 am: 14. Mai 2006, 17:07:36 »

I dont know any good Solutions for this old Robot.
Gespeichert

Roboter sichern die Arbeitsplätze und den Fortschritt der Industrieländer, da sie kostengünstig und qualitativ hochwertig produzieren.
Ohne Automatisierung mit Robotern werden unsere Produkte in Billiglohnländern hergestellt.
max666
Gast
« Antworten #2 am: 15. Mai 2006, 07:50:15 »

Thanks for the answer anyway Smile

If somebody has any solution feel free to answer
I will keep trying and send my project when I
find the solution Smile
Gespeichert
sirnoname
Stammgast
**
Offline Offline

Beiträge: 22



« Antworten #3 am: 24. Oktober 2006, 11:28:12 »

Yes, it is as you said, windows is difficult with this.
Use Serial Port and check the high, low's manualy after sending over TXD and RXD.
Dont use  overlapped. Use the windows API commands for checking the serial port bits, no Portio.dll etc.
I have done it and it works ... for stall use and extra routine which count after getting no low.
Parallel is not working.
Gespeichert
max666
Gast
« Antworten #4 am: 24. Oktober 2006, 12:38:22 »

Use Serial Port and check the high, low's manualy after sending over TXD and RXD.

Hey, thnx for this... We have already created microcontroller that does the job,
but I'll sure try to do this - it would be simpler.

Have you maybe done something like this in delphi? If you have some sample
code I would be very gratefull Smile
Gespeichert
sirnoname
Stammgast
**
Offline Offline

Beiträge: 22



« Antworten #5 am: 24. Oktober 2006, 12:45:41 »

sample code i can give u in c++, delphi
has not worked either.

Or use Linux with java:

page 96 with samples: (sorry german)
http://www.aicas.com/papers/Diplomarbeit-Kubo.pdf
Gespeichert
sirnoname
Stammgast
**
Offline Offline

Beiträge: 22



« Antworten #6 am: 24. Oktober 2006, 12:57:08 »

bool MyDlg::SendCommand(int command, int wert1, int wert2, int wert3, int wert4, int wert5)
{
   bool ok=true;
   CString Wert1,Wert2,Wert3,Wert4,Wert5;
   Wert1.Format("%d",wert1);
   Wert2.Format("%d",wert2);
   Wert3.Format("%d",wert3);
   CString sendstring;
   CHAR* ccb;
   CHAR* fccb;
   //Nest
   if (command == 1){fccb="N";ccb="T\r";}
   //Move
   if (command == 2){fccb="M";sendstring="O "+Wert1+"\r";ccb=sendstring.GetBuffer();}
   //GripPressure
   if (command == 3){fccb="G";sendstring="P "+Wert1+","+Wert2+","+Wert3+"\r";ccb=sendstring.GetBuffer();}
   //GripClose
   if (command == 4){fccb="G";ccb="O\r";}
   //GripOpen
   if (command == 5){fccb="G";ccb="C\r";}
   //Speed
   if (command == 6)
   {
      fccb="S";
      sendstring="P "+Wert1+"\r";
      ccb=sendstring.GetBuffer();
      m_speed.SetPos(wert1);
   }
   //Reset
   if (command == 20){fccb="R";ccb="S\r";}
   //Senden über Com Port
   int timeout=robotimeout;
   if (command < 7 || command==20)
   {
      DWORD reward;
      int lang=strlen(ccb);
      bWriteRC = WriteFile(m_hCom, fccb,1,&iBytesWritten,NULL);
      Sleep(200);
      bool fertig=false;
      while(fertig==false)
      {
         GetCommModemStatus(m_hCom,&reward);
         if (reward & MS_CTS_ON)
         {
            fertig=true;
         }
         Sleep(1);
         timeout--;
         if (timeout < 0){AfxMessageBox("Timeout bei der Kommunikation mit dem Roboter",0,NULL);ok=false;break;}
      }
      bWriteRC = WriteFile(m_hCom, ccb,lang,&iBytesWritten,NULL);
   }

   return ok;
}


please make m_hCom your create handle of your used comport.
Also use the Comport Settings like I described here for my software.
Notice the 200ms after FIRST byte !!
it is very stable, we run about a half year with that.

SW1: 1,2,4,5,6,7,8=Off     3=On
SW2: 1,3,4,8=Off     2,5,6,7=On

perhaps u can translate the API in Delphi ? don't know ...
Gespeichert
Seiten: [1] Nach oben Drucken 
Roboterforum für Industrieroboter Anwender  |  Industrieroboter Helpcenter  |  Mitsubishi Roboter (Moderatoren: Werner Hampel, Urmel)  |  Thema: Mitsubishi RM-501 « vorheriges nächstes »
Gehe zu:  


Einloggen mit Benutzername, Passwort und Sitzungslänge

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2006, Simple Machines Prüfe XHTML 1.0 Prüfe CSS