Ψηφιακή έξοδος#
Εισαγωγή#
Η συσκευή Ψηφιακής εξόδου 3 καλωδίων επιτρέπει στον εγκέφαλο EXP να στέλνει ψηφιακό σήμα σε ένα εξωτερικό εξάρτημα, όπως μια λυχνία LED, ένα ρελέ ή άλλη ηλεκτρονική συσκευή. Μπορεί να στείλει υψηλό σήμα (5 βολτ) ή χαμηλό σήμα (0 βολτ).
This page uses dig_out as the example Digital Out device name. Replace it with your own configured name as needed.
Παρακάτω είναι μια λίστα με τις διαθέσιμες μεθόδους:
set– Sets the signal level of a 3-Wire Digital Out port to high or low.
Constructor – Μη αυτόματη αρχικοποίηση και διαμόρφωση μιας συσκευής ψηφιακής εξόδου.
DigitalOut– Create a Digital Out device.
σειρά#
set sets the signal level of the selected 3-Wire Port.
Usage:
dig_out.set(boolean)
Παράμετρος |
Περιγραφή |
|---|---|
|
Whether to send a high or low signal: |
# Send out a low signal from dig_out
dig_out.set(False)
Κατασκευαστής#
Constructors are used to manually create DigitalOut objects, which are necessary for configuring a Digital Out device outside of VEXcode.
DigitalOut#
DigitalOut creates a Digital Out device.
Usage:
DigitalOut(port)
Παράμετρος |
Περιγραφή |
|---|---|
|
The 3-Wire Port that the Digital Out device is connected to:
|
# Create a Digital Out device in Port A
dig_out = DigitalOut(brain.three_wire_port.a)