now using resistors