mirror of
https://github.com/Derisis13/AT-VFD.git
synced 2025-12-07 03:42:49 +01:00
Feature: explicit function to reset the VFD controller
This commit is contained in:
11
PT6302.c
11
PT6302.c
@@ -28,10 +28,8 @@ inline void PT6302_startup (void)
|
||||
DDRC |= RSTpin;
|
||||
PORTB |= (CSBpin | CLKBpin);
|
||||
PORTB &= ~DINpin;
|
||||
PORTC &= ~RSTpin;
|
||||
_delay_us (TPRZ);
|
||||
PORTC |= RSTpin;
|
||||
_delay_us (TWRSTB);
|
||||
PT6302_reset();
|
||||
}
|
||||
|
||||
inline void transmit_bit(const uint8_t data)
|
||||
@@ -161,3 +159,10 @@ void all_off (void)
|
||||
const uint8_t command = 0x71;
|
||||
transmit_byte (command);
|
||||
}
|
||||
void PT6302_reset (void)
|
||||
{
|
||||
PORTC &= ~RSTpin;
|
||||
_delay_us (TPRZ);
|
||||
PORTC |= RSTpin;
|
||||
_delay_us (TWRSTB);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user