blink65 1.0
Write Arduino-style sketches for VIC-20 and Commodore 64.
Loading...
Searching...
No Matches
blink65.h
Go to the documentation of this file.
1/*- blink65 - Copyright 2026 Fabio Carignano -------------------------------*/
2
3#ifndef BLINK65_H
4#define BLINK65_H
5
6#include <stdint.h>
7
8#if defined(__C64__)
9#include <c64/pins.h>
10#elif defined(__PET__)
11#include <pet/pins.h>
12#elif defined(__VIC20__)
13#include <vic20/pins.h>
14#endif
15
16
17/*- CONSTANTS --------------------------------------------------------------*/
18
19#define INPUT 0
20#define OUTPUT 1
21
22#define LOW 0
23#define HIGH 1
24
25
26/*- EXPORTED LIBRARY FUNCTIONS ---------------------------------------------*/
27
31void delay(
32 uint32_t milliseconds
33);
34
39 uint8_t pin
40);
41
46 uint8_t pin,
47 uint8_t state
48);
49
54 uint8_t pin,
55 uint8_t mode
56);
57
58
59/*- IMPORTED USER FUNCTIONS ------------------------------------------------*/
60
64void setup(void);
65
69void loop(void);
70
71#endif /* BLINK65_H */
72/*--------------------------------------------------------------------------*/
void loop(void)
Called repeatedly after setup().
void delay(uint32_t milliseconds)
Stops execution for the given amount of milliseconds.
void setup(void)
Called once before loop().
void pinMode(uint8_t pin, uint8_t mode)
Set mode of a pin.
uint8_t digitalRead(uint8_t pin)
Read state of an input pin.
void digitalWrite(uint8_t pin, uint8_t state)
Set state of an output pin.