Zur Übersicht - INFO - Neueste 50 Beiträge - Neuer Beitrag - Suchen - FAQ - Zum CC1-Forum - Zum CC-Pro-Forum

RelaisKarte 8-fach - M.Unit Kategorie: Programmierung (von Thijs - 1.10.2006 22:14)


Dear sir,

 

I'm trying te let the relaisplatine 8-fach seriell (conrad nr: 96 77 20) work with the C-control M-unit 2.0.

I'm trying to program it in the M-unit but I cant get it right.
I don't understand how to give the commando's at the right way from the M-unit to the relaisplatine.
I'f make a cal the Dutch Conrad helpdesk but the don't know anything about de C-control.
So, I Have an M-unit 2.0, a programming station and a relaiskarte en many evenings
 trying to let it work, but the result is zero.

My question is if anybody could help me. Maybe you see what I do wrong.
I copyâ??d de .bas file Iâ??ve made below.

Or is there a example file for this relaiskate?

I hope you can help me so I can go further with it

With kind regard,
Thijs

 

 

 

 

 

Aansturing Conrad relaiskaart 8-voudig serrieel (967720)

'

'

'--------------------Aanstuurgegevens relaiskaart----------------------------

'kadropbouw : byte 0      byte1             byte 2        byte 3  

'              commando    Printplaatadres   gegevens      checksum(XOR)

 



 

Const Kaartadres=1

Const CodeOn=3

Const CodeOff=3

Const Rel1 = 1

 

Define CodeOn as byte

Define Kaartadres as Byte

'Define Rel1 as byte

Define Checksum as Byte

Define 1 as byte

Define 0 as byte

 

Baud R19200

 

 

 

'-------Initialisatie relais kaart---------------------------

    Put 1

    Put Kaartadres  

    Put 0      

    Checksum=1+Kaartadres+0

    Checksum=(1 XOR Kaartadres XOR 0) +1

    Put Checksum

 

End sub

 

'-----------------Inschakelen relais---------------------------

 

    put CodeOn

    put Kaartadres

    put 1

    Checksum=CodeOn+Kaartadres+1

    Checksum=(Checksum XOR FFh) +1

    put Checksum

   

End sub

 

 

 

attributes

         

End attributes  


    Antwort schreiben


Antworten:

Re: RelaisKarte 8-fach - M.Unit (von CodeXP - 5.10.2006 3:41)