Registri shift
I registri shift sono utilizzati per aggiungere ulteriori input o output a una scheda Arduino. È possibile utilizzare i registri shift serial-in/parallel-out per controllare più output o i registri shift parallel-in/serial-out per raccogliere più input utilizzando un solo pin su una scheda Arduino. Ad esempio, è possibile controllare più luci LED utilizzando un singolo pin su una scheda Arduino. È possibile utilizzare le funzioni dei registri shift per leggere o scrivere dati seriali. I registri shift supportati sono i seguenti:
Creare un oggetto Arduino utilizzando arduino
prima di utilizzare le funzioni dei registri shift. Per maggiori informazioni vedere Connect to Arduino Hardware.
Funzioni
shiftRegister | Connection to shift register on Arduino hardware |
read | Read data from shift register |
write | Write data to shift register |
reset | Clear all outputs of shift register |
Argomenti
- Push Button Control with 74HC165 Shift Register
This example shows how to use the MATLAB® Support Package for Arduino® Hardware to collect large number of push button states with a 74HC165 8-bit parallel-in-serial-out shift register.
- Control 7-Segment Display with 74HC595 Shift Register
This example shows how to use the MATLAB® Support Package for Arduino® Hardware to control a 1-Digit 7-Segment display with a 74HC595 8-bit serial-in-parallel-out shift register.
- Control LEDs with 74HC595 Shift Register
This example shows how to use the MATLAB® Support Package for Arduino® Hardware to control multiple LEDs with two 74HC595 8-bit serial-in-parallel-out shift registers.