llvm-mos-sdk
system.h
Go to the documentation of this file.
1 // Copyright 2024 LLVM-MOS Project
2 // Licensed under the Apache License, Version 2.0 with LLVM Exceptions.
3 // See https://github.com/llvm-mos/llvm-mos-sdk/blob/main/LICENSE for license
4 // information.
5 
6 #include <stdint.h>
7 
8 #ifndef _NEO_SYSTEM_H
9 #define _NEO_SYSTEM_H
10 
11 #include <neo6502.h>
12 
13 #ifdef __cplusplus
14 extern "C" {
15 #endif
16 
23 
29 long neo_system_timer(void);
30 
38 
42 void neo_system_credits(void);
43 
47 void neo_system_serial_update(void);
48 
54 void neo_system_locale(const char *locale);
55 
59 __attribute__((leaf, noreturn))
60 void neo_system_reset(void);
61 
67 void neo_system_debug_putc(char ch);
68 
69 typedef struct neo_version {
72 
79 
80 #ifdef __cplusplus
81 }
82 #endif
83 
84 #endif
version
uint8_t version
neo_system_version
void neo_system_version(neo_version_t *version)
Retrieve the Neo6502 version.
neo_system_debug_putc
void neo_system_debug_putc(char ch)
Write a character to the debug port.
neo_version::major
uint8_t major
Definition: system.h:70
neo_version
Definition: system.h:69
neo_system_timer
long neo_system_timer(void)
Query the value of the 100Hz system timer.
std::uint8_t
::uint8_t uint8_t
Definition: cstdint:21
neo_system_credits
void neo_system_credits(void)
Print the Neo6502 project contributors.
neo_version::minor
uint8_t minor
Definition: system.h:70
neo6502.h
neo_api_error
uint8_t neo_api_error(void)
Return the error code, if any.
neo_system_locale
void neo_system_locale(const char *locale)
Set the locale code.
neo_version_t
struct neo_version neo_version_t
neo_system_key_status
uint8_t neo_system_key_status(char key)
Query the state of the specific keyboard key.
neo_system_serial_update
void neo_system_serial_update(void)
Update the serial command handler.
neo_version::patch
uint8_t patch
Definition: system.h:70